[gnome-devel-docs] Changed tabs to spaces.



commit 5220733d9303153336ec5afecb72a622967b7dcd
Author: Tiffany Antopolski <tiffany antopolski gmail com>
Date:   Tue May 29 09:50:11 2012 -0400

    Changed tabs to spaces.

 platform-demos/C/samples/dialog.js     |  149 +++++++++++++++-----------------
 platform-demos/C/samples/linkbutton.js |   84 +++++++++----------
 2 files changed, 111 insertions(+), 122 deletions(-)
---
diff --git a/platform-demos/C/samples/dialog.js b/platform-demos/C/samples/dialog.js
index f627879..fdff8b6 100644
--- a/platform-demos/C/samples/dialog.js
+++ b/platform-demos/C/samples/dialog.js
@@ -6,86 +6,79 @@ const Gtk = imports.gi.Gtk;
 const Lang = imports.lang;
 
 const DialogExample = new Lang.Class ({
-	Name: 'Dialog Example',
+    Name: 'Dialog Example',
 
-	// Create the application itself
+    // Create the application itself
         _init: function () {
-   	     this.application = new Gtk.Application ({
-  	          application_id: 'org.example.jsdialog',
-  	          flags: Gio.ApplicationFlags.FLAGS_NONE
-   	     });
-
-	// Connect 'activate' and 'startup' signals to the callback functions
-	this.application.connect('activate', Lang.bind(this, this._onActivate));
-	this.application.connect('startup', Lang.bind(this, this._onStartup));
-	},
-
-	// Callback function for 'activate' signal presents windows when active
-	_onActivate: function () {
-		this._window.present ();
-	},
-
-	// Callback function for 'startup' signal builds the UI
-	_onStartup: function () {
-		this._buildUI ();
-	},
-
-
-
-
-	// Build the application's UI
-	_buildUI: function () {
-
-		// Create the application window
-        	this._window = new Gtk.ApplicationWindow  ({ application: this.application,
-                                                     	     window_position: Gtk.WindowPosition.CENTER,
-                                                     	     title: "Gtk.Dialog Example",
-                                                     	     default_height: 50,
-                                                     	     default_width: 250 });
-
-		// Create a button
-		this._button = new Gtk.Button ({label: "Click Me"});
-		this._window.add (this._button);
-
-		// Bind it to the function that creates the dialog
-		this._button.connect ("clicked", Lang.bind(this, this._createDialog));
-
-       	 	// Show the window and all child widgets
-       	 	this._window.show_all();
-	},
-
-
-
-	_createDialog: function () {
-
-		// Create the dialog
-		this._dialog = new Gtk.Dialog ({ transient_for: this._window,
-						 modal: true,
-						 title: "A Gtk+ dialog" });
-
-		// Create the dialog's content area, which contains a message
-		this._contentArea = this._dialog.get_content_area();
-		this._message = new Gtk.Label ({label: "This demonstrates a dialog with a label"});
-		this._contentArea.add (this._message);
-
-		// Create the dialog's action area, which contains a button
-		this._actionArea = this._dialog.get_action_area();
-		this._OKButton = new Gtk.Button ({label: "OK"});
-		this._actionArea.add (this._OKButton);
-
-		// Connect the button to the function that handles what it does
-		this._OKButton.connect ("clicked", Lang.bind (this, this._OKHandler));
-
-		this._dialog.show_all();
-	},
-
-
-
-	_OKHandler: function (dialog, response_id) {
-
-		// Destroy the dialog
-		this._dialog.destroy();
-	}
+            this.application = new Gtk.Application ({
+                application_id: 'org.example.jsdialog',
+                flags: Gio.ApplicationFlags.FLAGS_NONE
+            });
+
+    // Connect 'activate' and 'startup' signals to the callback functions
+    this.application.connect('activate', Lang.bind(this, this._onActivate));
+    this.application.connect('startup', Lang.bind(this, this._onStartup));
+    },
+
+    // Callback function for 'activate' signal presents windows when active
+    _onActivate: function () {
+        this._window.present ();
+    },
+
+    // Callback function for 'startup' signal builds the UI
+    _onStartup: function () {
+        this._buildUI ();
+    },
+
+    // Build the application's UI
+    _buildUI: function () {
+
+        // Create the application window
+            this._window = new Gtk.ApplicationWindow  ({ application: this.application,
+                                                         window_position: Gtk.WindowPosition.CENTER,
+                                                         title: "Gtk.Dialog Example",
+                                                         default_height: 50,
+                                                         default_width: 250 });
+
+        // Create a button
+        this._button = new Gtk.Button ({label: "Click Me"});
+        this._window.add (this._button);
+
+        // Bind it to the function that creates the dialog
+        this._button.connect ("clicked", Lang.bind(this, this._createDialog));
+
+                // Show the window and all child widgets
+                this._window.show_all();
+    },
+
+    _createDialog: function () {
+
+        // Create the dialog
+        this._dialog = new Gtk.Dialog ({ transient_for: this._window,
+                         modal: true,
+                         title: "A Gtk+ dialog" });
+
+        // Create the dialog's content area, which contains a message
+        this._contentArea = this._dialog.get_content_area();
+        this._message = new Gtk.Label ({label: "This demonstrates a dialog with a label"});
+        this._contentArea.add (this._message);
+
+        // Create the dialog's action area, which contains a button
+        this._actionArea = this._dialog.get_action_area();
+        this._OKButton = new Gtk.Button ({label: "OK"});
+        this._actionArea.add (this._OKButton);
+
+        // Connect the button to the function that handles what it does
+        this._OKButton.connect ("clicked", Lang.bind (this, this._OKHandler));
+
+        this._dialog.show_all();
+    },
+
+    _OKHandler: function (dialog, response_id) {
+
+        // Destroy the dialog
+        this._dialog.destroy();
+    }
 
 });
 
diff --git a/platform-demos/C/samples/linkbutton.js b/platform-demos/C/samples/linkbutton.js
index f876152..4128a1c 100644
--- a/platform-demos/C/samples/linkbutton.js
+++ b/platform-demos/C/samples/linkbutton.js
@@ -6,52 +6,48 @@ const Gtk = imports.gi.Gtk;
 const Lang = imports.lang;
 
 const LinkButtonExample = new Lang.Class ({
-	Name: 'LinkButton Example',
+    Name: 'LinkButton Example',
 
-	// Create the application itself
+    // Create the application itself
         _init: function () {
-   	     this.application = new Gtk.Application ({
-  	          application_id: 'org.example.jslinkbutton',
-  	          flags: Gio.ApplicationFlags.FLAGS_NONE
-   	     });
-
-	// Connect 'activate' and 'startup' signals to the callback functions
-	this.application.connect('activate', Lang.bind(this, this._onActivate));
-	this.application.connect('startup', Lang.bind(this, this._onStartup));
-	},
-
-	// Callback function for 'activate' signal presents window when active
-	_onActivate: function () {
-		this._window.present ();
-	},
-
-	// Callback function for 'startup' signal initializes menus and builds the UI
-	_onStartup: function () {
-		this._buildUI ();
-	},
-
-
-
-
-	// Build the application's UI
-	_buildUI: function () {
-
-		// Create the application window
-        	this._window = new Gtk.ApplicationWindow  ({ application: this.application,
-                                                     	     window_position: Gtk.WindowPosition.CENTER,
-                                                     	     title: "GNOME LinkButton",
-                                                     	     default_height: 50,
-                                                     	     default_width: 250 });
-
-		// Create the LinkButton and have it link to live.gnome.org
-		this.LinkButton = new Gtk.LinkButton ({label: "Link to GNOME live!",
-						       uri: "http://live.gnome.org"});
-		this._window.add (this.LinkButton);
-
-       	 	// Show the window and all child widgets
-       	 	this._window.show_all();
-	},
-
+        this.application = new Gtk.Application ({
+              application_id: 'org.example.jslinkbutton',
+              flags: Gio.ApplicationFlags.FLAGS_NONE
+         });
+
+    // Connect 'activate' and 'startup' signals to the callback functions
+    this.application.connect('activate', Lang.bind(this, this._onActivate));
+    this.application.connect('startup', Lang.bind(this, this._onStartup));
+    },
+
+    // Callback function for 'activate' signal presents window when active
+    _onActivate: function () {
+        this._window.present ();
+    },
+
+    // Callback function for 'startup' signal initializes menus and builds the UI
+    _onStartup: function () {
+        this._buildUI ();
+    },
+
+    // Build the application's UI
+    _buildUI: function () {
+
+        // Create the application window
+    this._window = new Gtk.ApplicationWindow  ({ application: this.application,
+                                                 window_position: Gtk.WindowPosition.CENTER,
+                                                 title: "GNOME LinkButton",
+                                                 default_height: 50,
+                                                 default_width: 250 });
+
+        // Create the LinkButton and have it link to live.gnome.org
+        this.LinkButton = new Gtk.LinkButton ({label: "Link to GNOME live!",
+                               uri: "http://live.gnome.org"});
+        this._window.add (this.LinkButton);
+
+    // Show the window and all child widgets
+    this._window.show_all();
+    },
 
 });
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]