[gnome-sound-recorder] Remove deprecated rtl/ltr margins



commit aebd02c0a3885424506ee388447ebbc8a2d462b1
Author: Meg Ford <megford gnome org>
Date:   Sun Feb 1 14:36:47 2015 -0600

    Remove deprecated rtl/ltr margins
    
    Replace margin_right and margin_left with margin_start and margin_end.

 src/info.js        |   14 +++++++-------
 src/mainWindow.js  |   33 +++++++++++++++------------------
 src/preferences.js |    8 ++++----
 3 files changed, 26 insertions(+), 29 deletions(-)
---
diff --git a/src/info.js b/src/info.js
index 58b90ac..ccddf48 100644
--- a/src/info.js
+++ b/src/info.js
@@ -55,7 +55,7 @@ const InfoDialog = new Lang.Class({
         let cancelButton = new Gtk.Button({ label: _("Cancel"),
                                             margin_bottom: 4,
                                             margin_top: 6,
-                                            margin_right: 6 });
+                                            margin_start: 6 });
         cancelButton.connect("clicked", Lang.bind(this, this.onCancelClicked));
         cancelToolbar.pack_end(cancelButton, false, true, 0);
         cancelButton.show();
@@ -68,8 +68,8 @@ const InfoDialog = new Lang.Class({
         
         let button = new Gtk.Button({ label: _("Done"),
                                       margin_bottom: 4,
-                                      margin_top: 6,
-                                      margin_right: 6 });
+                                      margin_end: 6,
+                                      margin_top: 6 });
         button.connect("clicked", Lang.bind(this, this.onDoneClicked));
         buttonToolbar.pack_end(button, false, true, 0);
         button.show();
@@ -81,10 +81,10 @@ const InfoDialog = new Lang.Class({
                                    halign: Gtk.Align.CENTER,
                                    row_spacing: 6,
                                    column_spacing: 24,
-                                   margin_top: 12,
-                                   margin_left: 24,
-                                   margin_right: 24,
-                                   margin_bottom: 12 });
+                                   margin_bottom: 12,
+                                   margin_end: 24,
+                                   margin_start: 24,
+                                   margin_top: 12 });
 
         let contentArea = this.widget.get_content_area();
         contentArea.pack_start(grid, true, true, 2);
diff --git a/src/mainWindow.js b/src/mainWindow.js
index fb31111..e19f3fa 100644
--- a/src/mainWindow.js
+++ b/src/mainWindow.js
@@ -281,16 +281,16 @@ const MainView = new Lang.Class({
         this.widgetRecord.insert(this._groupRecord, -1);
 
         this.recordTextLabel = new Gtk.Label({ margin_bottom: 4,
-                                               margin_top: 6,
-                                               margin_left: rtl ? 0 : 6,
-                                               margin_right: rtl ? 6 : 0 });
+                                               margin_end: 6,
+                                               margin_start: 6, 
+                                               margin_top: 6 });
         this.recordTextLabel.label = _("Recording…");
         this._boxRecord.pack_start(this.recordTextLabel, false, true, 0);
 
         this.recordTimeLabel = new Gtk.Label({ margin_bottom: 4,
-                                               margin_top: 6,
-                                               margin_left: rtl ? 0 : 6,
-                                               margin_right: rtl ? 6 : 0 });
+                                               margin_end: 6,
+                                               margin_start: 6, 
+                                               margin_top: 6});
 
         this._boxRecord.pack_start(this.recordTimeLabel, false, true, 0);
 
@@ -303,9 +303,9 @@ const MainView = new Lang.Class({
                                           valign: Gtk.Align.CENTER,
                                           hexpand: true,
                                           margin_bottom: 4,
-                                          margin_top: 6,
-                                          margin_left: rtl ? 0 : 6,
-                                          margin_right: rtl ? 6 : 0 });
+                                          margin_end: 6,
+                                          margin_start: 6, 
+                                          margin_top: 6 });
         stopRecord.get_style_context().add_class('text-button');
         stopRecord.connect("clicked", Lang.bind(this, this.onRecordStopClicked));
         this.toolbarStart.pack_start(stopRecord, true, true, 0);
@@ -431,8 +431,7 @@ const MainView = new Lang.Class({
                                                  ellipsize: rtl ? Pango.EllipsizeMode.START : 
Pango.EllipsizeMode.END,
                                                  halign: Gtk.Align.START,
                                                  valign: Gtk.Align.START,
-                                                 margin_left: rtl ? 0 : 15,
-                                                 margin_right: rtl ? 15 : 0,
+                                                 margin_start: 15,
                                                  margin_top: 5,
                                                  use_markup: true,
                                                  width_chars: 35,
@@ -451,8 +450,7 @@ const MainView = new Lang.Class({
                 this.playDurationLabel = new Gtk.Label({ name: "PlayDurationLabel",
                                                          halign: Gtk.Align.END,
                                                          valign: Gtk.Align.END,
-                                                         margin_left: rtl ? 0 : 15,
-                                                         margin_right: rtl ? 15 : 0,
+                                                         margin_start: 15,
                                                          margin_top: 5 });
                 this.fileDuration = this._formatTime(this._files[i].duration/Gst.SECOND);
                 this.playDurationLabel.label = this.fileDuration;
@@ -470,7 +468,7 @@ const MainView = new Lang.Class({
                 this.playTimeLabel = new Gtk.Label({ name: "PlayTimeLabel",
                                                      halign: Gtk.Align.START,
                                                      valign: Gtk.Align.END,
-                                                     margin_right: rtl ? 15 : 0,
+                                                     margin_end: 15,
                                                      margin_top: 5 });
                 this.playTimeLabel.label = "0:00";
                 this._playLabelBox.pack_start(this.playTimeLabel, false, true, 0);
@@ -480,8 +478,7 @@ const MainView = new Lang.Class({
                 this.dateModifiedLabel = new Gtk.Label({ name: "dateModifiedLabel",
                                                          halign: Gtk.Align.END,
                                                          valign: Gtk.Align.END,
-                                                         margin_left: rtl ? 0 : 15,
-                                                         margin_right: rtl ? 15 : 0,
+                                                         margin_start: 15,
                                                          margin_top: 5 });
                 this.dateModifiedLabel.label = this._files[i].dateModified;
                 this.dateModifiedLabel.get_style_context().add_class('dim-label');
@@ -502,7 +499,7 @@ const MainView = new Lang.Class({
                 this._info = new Gtk.Button({ name: "InfoButton",
                                               hexpand: false,
                                               vexpand: true,
-                                              margin_right: 2 });
+                                              margin_end: 2 });
                 this._info.image = Gtk.Image.new_from_icon_name("dialog-information-symbolic", 
Gtk.IconSize.BUTTON);
                 this._info.connect("clicked", Lang.bind(this,
                     function() {
@@ -519,7 +516,7 @@ const MainView = new Lang.Class({
                 // delete button
                 this._delete = new Gtk.Button({ name: "DeleteButton",
                                                 hexpand: false,
-                                                margin_left: rtl ? 0 : 2, });
+                                                margin_start: 2, });
                 this._delete.image = Gtk.Image.new_from_icon_name("user-trash-symbolic", 
Gtk.IconSize.BUTTON);
                 this._delete.connect("clicked", Lang.bind(this,
                     function() {
diff --git a/src/preferences.js b/src/preferences.js
index ff9edfe..3ddfc8e 100644
--- a/src/preferences.js
+++ b/src/preferences.js
@@ -53,10 +53,10 @@ const Preferences = new Lang.Class({
                                    halign: Gtk.Align.CENTER,
                                    row_spacing: 6,
                                    column_spacing: 24,
-                                   margin_top: 12,
-                                   margin_left: 24,
-                                   margin_right: 24,
-                                   margin_bottom: 12 });
+                                   margin_bottom: 12,
+                                   margin_end: 24,
+                                   margin_start: 24,
+                                   margin_top: 12 });
         let contentArea = this.widget.get_content_area();
         contentArea.pack_start(grid, true, true, 2);
         


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