[latexila/latexila-2-6] Set label to toolbuttons of the structure and file browser



commit 04c680583fec5f7b2111db5a4624c17a9877b6df
Author: SÃbastien Wilmet <swilmet gnome org>
Date:   Thu Nov 29 03:03:01 2012 +0100

    Set label to toolbuttons of the structure and file browser
    
    When the mini toolbar was partly hidden, the menu items were empty,
    except for the toolbuttons with a stock icon (the label is available for
    a stock icon).

 src/file_browser.vala |    3 +++
 src/structure.vala    |    3 +++
 2 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/src/file_browser.vala b/src/file_browser.vala
index c5508c4..29e0e6e 100644
--- a/src/file_browser.vala
+++ b/src/file_browser.vala
@@ -214,6 +214,7 @@ public class FileBrowser : Grid
     {
         ToolButton home_button = new ToolButton.from_stock (Stock.HOME);
         home_button.tooltip_text = _("Go to the home directory");
+        home_button.label = home_button.tooltip_text;
 
         home_button.clicked.connect (() =>
         {
@@ -228,6 +229,7 @@ public class FileBrowser : Grid
     {
         _parent_button = new ToolButton.from_stock (Stock.GO_UP);
         _parent_button.tooltip_text = _("Go to the parent directory");
+        _parent_button.label = _parent_button.tooltip_text;
 
         _parent_button.clicked.connect (() =>
         {
@@ -243,6 +245,7 @@ public class FileBrowser : Grid
     {
         ToolButton jump_button = new ToolButton.from_stock (Stock.JUMP_TO);
         jump_button.tooltip_text = _("Go to the active document directory");
+        jump_button.label = jump_button.tooltip_text;
 
         jump_button.clicked.connect (() =>
         {
diff --git a/src/structure.vala b/src/structure.vala
index e8f498b..1840519 100644
--- a/src/structure.vala
+++ b/src/structure.vala
@@ -156,6 +156,7 @@ public class Structure : Grid
     {
         ToolButton refresh_button = new ToolButton.from_stock (Stock.REFRESH);
         refresh_button.tooltip_text = _("Refresh");
+        refresh_button.label = refresh_button.tooltip_text;
 
         refresh_button.clicked.connect (() =>
         {
@@ -169,6 +170,7 @@ public class Structure : Grid
     {
         ToolButton collapse_button = new ToolButton.from_stock (Stock.ZOOM_OUT);
         collapse_button.tooltip_text = _("Collapse All");
+        collapse_button.label = collapse_button.tooltip_text;
 
         collapse_button.clicked.connect (() => _tree_view.collapse_all ());
 
@@ -193,6 +195,7 @@ public class Structure : Grid
             new ToggleToolButton.from_stock (get_icon_from_type (type));
 
         button.tooltip_text = tooltip;
+        button.label = tooltip;
 
         _simple_list_buttons += button;
 



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