[gnome-clocks] Set button arrow icons according to locale's text direction



commit c38c796b284ce825ef09fbd9f3c8b6168a1d1d8f
Author: Yosef Or Boczko <yosefor3 walla com>
Date:   Tue Jun 18 21:12:46 2013 +0300

    Set button arrow icons according to locale's text direction
    
    https://bugzilla.gnome.org/show_bug.cgi?id=702589

 src/world.vala |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/src/world.vala b/src/world.vala
index fdda32a..4c8353c 100644
--- a/src/world.vala
+++ b/src/world.vala
@@ -272,7 +272,13 @@ public class MainPanel : Gtk.Stack, Clocks.Clock {
         header_bar.pack_start (new_button);
 
         back_button = new Gtk.Button ();
-        var back_button_image = new Gtk.Image.from_icon_name ("go-previous-symbolic", Gtk.IconSize.MENU);
+        var back_button_image = new Gtk.Image ();
+        back_button_image.icon_size = Gtk.IconSize.MENU;
+        if (get_direction () == Gtk.TextDirection.LTR) {
+            back_button_image.icon_name = "go-previous-symbolic";
+        } else {
+            back_button_image.icon_name = "go-previous-rtl-symbolic";
+        }
         back_button.valign = Gtk.Align.CENTER;
         back_button.get_style_context ().add_class ("image-button");
         back_button.set_image (back_button_image);


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