[glom] Main window: Show the table title in find mode too.



commit 6ea9a8a92a9fea70829a18c34972d9c016ca2112
Author: Murray Cumming <murrayc murrayc com>
Date:   Thu Jun 23 00:45:08 2011 +0200

    Main window: Show the table title in find mode too.
    
    * glom/frame_glom.[h|cc]: Use an extra label for the
    find mode.

 ChangeLog          |    7 +++++++
 glom/frame_glom.cc |   18 +++++++++++++-----
 glom/frame_glom.h  |    3 ++-
 3 files changed, 22 insertions(+), 6 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 560301f..a9befda 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2011-06-23  Murray Cumming  <murrayc murrayc com>
 
+	Main window: Show the table title in find mode too.
+
+	* glom/frame_glom.[h|cc]: Use an extra label for the 
+	find mode.
+
+2011-06-23  Murray Cumming  <murrayc murrayc com>
+
 	Do not hide table-specific menu items in Operator mode.
 
 	* glom/application.cc: update_table_sensitive_ui().
diff --git a/glom/frame_glom.cc b/glom/frame_glom.cc
index 60b64b1..c46142e 100644
--- a/glom/frame_glom.cc
+++ b/glom/frame_glom.cc
@@ -78,7 +78,8 @@ namespace Glom
 
 Frame_Glom::Frame_Glom(BaseObjectType* cobject, const Glib::RefPtr<Gtk::Builder>& builder)
 : PlaceHolder(cobject, builder),
-  m_pLabel_Table(0),
+  m_pLabel_Table_DataMode(0),
+  m_pLabel_Table_FindMode(0),
   m_box_footer(0),
   m_pBox_RecordsCount(0),
   m_pLabel_RecordsCount(0),
@@ -119,9 +120,13 @@ Frame_Glom::Frame_Glom(BaseObjectType* cobject, const Glib::RefPtr<Gtk::Builder>
   set_border_width(Glom::Utils::DEFAULT_SPACING_LARGE);
   #endif
 
-  m_pLabel_Table = Gtk::manage(new Gtk::Label(_("No Table Selected")));
-  m_pLabel_Table->show();
-  m_Notebook_Data.set_action_widget(m_pLabel_Table, Gtk::PACK_START);
+  m_pLabel_Table_DataMode = Gtk::manage(new Gtk::Label(_("No Table Selected")));
+  m_pLabel_Table_DataMode->show();
+  m_Notebook_Data.set_action_widget(m_pLabel_Table_DataMode, Gtk::PACK_START);
+
+  m_pLabel_Table_FindMode = Gtk::manage(new Gtk::Label(_("No Table Selected")));
+  m_pLabel_Table_FindMode->show();
+  m_Notebook_Find.set_action_widget(m_pLabel_Table_FindMode, Gtk::PACK_START);
 
   //QuickFind widgets:
   //We don't use Glade for these, so it easier to modify them for the Maemo port.
@@ -1466,7 +1471,10 @@ void Frame_Glom::show_table_title()
 
   // We hide this anyway: m_pLabel_Table->set_markup("<b>" + table_label + "</b>");
 #else
-  m_pLabel_Table->set_markup("<b>" + table_label + "</b>"); //Show the table title in bold text, because it's important to the user.
+  //Show the table title in bold text, because it's important to the user.
+  const Glib::ustring title = "<b>" + table_label + "</b>";
+  m_pLabel_Table_DataMode->set_markup(title);
+  m_pLabel_Table_FindMode->set_markup(title);
 #endif
 }
 
diff --git a/glom/frame_glom.h b/glom/frame_glom.h
index 5df625d..ffb5c2f 100644
--- a/glom/frame_glom.h
+++ b/glom/frame_glom.h
@@ -253,7 +253,8 @@ private:
   Glib::ustring m_table_name;
 
   //Child widgets:
-  Gtk::Label* m_pLabel_Table;
+  Gtk::Label* m_pLabel_Table_DataMode;
+  Gtk::Label* m_pLabel_Table_FindMode;
   Gtk::HBox* m_box_footer;
 
   Gtk::HBox* m_pBox_RecordsCount; //Only show this when in Data mode.



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