glom r1646 - in trunk: . glom



Author: arminb
Date: Wed Jul 23 10:19:23 2008
New Revision: 1646
URL: http://svn.gnome.org/viewvc/glom?rev=1646&view=rev

Log:
2008-07-23  Armin Burgmeier  <armin openismus com>

	* glom/glom.glade: Removed the image from the Select button in the
	initial dialog.

	* glom/dialog_existing_or_new.cc: Add the image in the Code, via
	Gtk::Button::set_image. This way the image is not shown when the theme
	doesn't show images on buttons, such as the MS-Windows theme.


Modified:
   trunk/ChangeLog
   trunk/glom/dialog_existing_or_new.cc
   trunk/glom/glom.glade

Modified: trunk/glom/dialog_existing_or_new.cc
==============================================================================
--- trunk/glom/dialog_existing_or_new.cc	(original)
+++ trunk/glom/dialog_existing_or_new.cc	Wed Jul 23 10:19:23 2008
@@ -44,9 +44,9 @@
 namespace
 {
 
-const char* RECENT_DUMMY_TEXT = _("No recently used documents available.");
-const char* TEMPLATE_DUMMY_TEXT = _("No templates available.");
-const char* NETWORK_DUMMY_TEXT = _("No sessions found on the local network.");
+const char* RECENT_DUMMY_TEXT = N_("No recently used documents available.");
+const char* TEMPLATE_DUMMY_TEXT = N_("No templates available.");
+const char* NETWORK_DUMMY_TEXT = N_("No sessions found on the local network.");
 
 /*bool has_dummy(const Gtk::TreeModel::iterator& parent, const std::auto_ptr<Gtk::TreeModel::iterator>& dummy)
 {
@@ -160,6 +160,9 @@
   gchar* dir = g_win32_get_package_installation_subdirectory(NULL, NULL, "share/doc/examples");
   std::string path(dir);
   g_free(dir);
+
+  if(!Glib::file_test(path, Glib::FILE_TEST_EXISTS))
+    path = GLOM_EXAMPLES_DIR;
 #else
 #ifndef GLOM_ENABLE_CLIENT_ONLY
   const char* path = GLOM_EXAMPLES_DIR;
@@ -216,6 +219,7 @@
   m_existing_view->expand_row(m_existing_model->get_path(m_iter_existing_recent), false);
 
   m_select_button->signal_clicked().connect(sigc::mem_fun(*this, &Dialog_ExistingOrNew::on_select_clicked));
+  m_select_button->set_image(*Gtk::manage(new Gtk::Image(Gtk::Stock::APPLY, Gtk::ICON_SIZE_BUTTON)));
 
 #ifndef GLOM_ENABLE_CLIENT_ONLY
   m_notebook->signal_switch_page().connect(sigc::mem_fun(*this, &Dialog_ExistingOrNew::on_switch_page));

Modified: trunk/glom/glom.glade
==============================================================================
--- trunk/glom/glom.glade	(original)
+++ trunk/glom/glom.glade	Wed Jul 23 10:19:23 2008
@@ -332,31 +332,9 @@
                 <property name="receives_default">True</property>
                 <property name="has_tooltip">True</property>
                 <property name="tooltip_text">Applies the currently selected item. Depending on the item, this might create a new document or open an existing document.</property>
+                <property name="label" translatable="yes">_Select</property>
+                <property name="use_underline">True</property>
                 <property name="response_id">0</property>
-                <child>
-                  <widget class="GtkHBox" id="hbox1">
-                    <property name="visible">True</property>
-                    <child>
-                      <widget class="GtkImage" id="image1">
-                        <property name="visible">True</property>
-                        <property name="stock">gtk-apply</property>
-                      </widget>
-                      <packing>
-                        <property name="expand">False</property>
-                      </packing>
-                    </child>
-                    <child>
-                      <widget class="GtkLabel" id="label1">
-                        <property name="visible">True</property>
-                        <property name="label" translatable="yes">_Select</property>
-                        <property name="use_underline">True</property>
-                      </widget>
-                      <packing>
-                        <property name="position">1</property>
-                      </packing>
-                    </child>
-                  </widget>
-                </child>
               </widget>
               <packing>
                 <property name="pack_type">GTK_PACK_END</property>



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