[gcalctool] Don't change window title to match mode (no need to)



commit a0f6b66802ebe129ec8e87c5de34732f008fe20a
Author: Robert Ancell <robert ancell gmail com>
Date:   Mon Mar 29 09:38:00 2010 +1100

    Don't change window title to match mode (no need to)

 NEWS              |    4 +++-
 data/gcalctool.ui |    1 +
 src/gtk.c         |   14 --------------
 3 files changed, 4 insertions(+), 15 deletions(-)
---
diff --git a/NEWS b/NEWS
index e195e16..93f4cdd 100644
--- a/NEWS
+++ b/NEWS
@@ -9,7 +9,9 @@ Overview of changes in gcalctool 5.31.1
     * Rename View menu to Mode
     
     * Merge advanced and scientific mode
- 
+
+    * Don't change window title to match mode (no need to)
+
 Overview of changes in gcalctool 5.30.0
 
     * Fix errors in variable exponents (e.g. xy²)
diff --git a/data/gcalctool.ui b/data/gcalctool.ui
index ecf7060..db91dc6 100644
--- a/data/gcalctool.ui
+++ b/data/gcalctool.ui
@@ -5,6 +5,7 @@
   <object class="GtkWindow" id="calc_window">
     <property name="events">GDK_BUTTON_PRESS_MASK</property>
     <property name="role">gcalctool</property>
+    <property name="title" translatable="yes" comments="Title of main window">Calculator</property>
     <property name="resizable">False</property>
     <accel-groups>
       <group name="accelgroup1"/>
diff --git a/src/gtk.c b/src/gtk.c
index b16a670..2cbfed4 100644
--- a/src/gtk.c
+++ b/src/gtk.c
@@ -90,18 +90,6 @@ static ButtonData button_data[] = {
 static char *registers[] = {"a", "b", "c", "x", "y", "z", NULL};
 #define MAX_REGISTERS 6
 
-/* Window titles dependant on mode */
-static char *titles[] = {
-    /* Translators: The window title when in basic mode */
-    N_("Calculator"),
-    /* Translators: The window title when in advanced mode */
-    N_("Calculator â?? Advanced"),
-    /* Translators: The window title when in financial mode */
-    N_("Calculator â?? Financial"),
-    /* Translators: The window title when in programming mode */
-    N_("Calculator â?? Programming")
-};
-
 /* The names of each field in the dialogs for the financial functions */
 static char *finc_dialog_fields[][5] = {
     {"ctrm_pint", "ctrm_fv",     "ctrm_pv",    NULL,         NULL},
@@ -442,8 +430,6 @@ ui_set_mode(ModeType mode)
     g_object_set(G_OBJECT(X.prog_panel), "visible", mode == PROGRAMMING, NULL);
     g_object_set(G_OBJECT(X.bit_panel), "visible", mode == PROGRAMMING, NULL);
 
-    gtk_window_set_title(GTK_WINDOW(X.main_window), gettext(titles[mode]));
-
     /* Update the menu */
     switch (mode) {
         case BASIC:



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