[glom] Do not blank the data when showing the field definitions dialog.
- From: Murray Cumming <murrayc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glom] Do not blank the data when showing the field definitions dialog.
- Date: Thu, 3 Nov 2011 08:58:07 +0000 (UTC)
commit 63474d78ec5ece94e007823e17a2dfa7ff68c990
Author: Murray Cumming <murrayc murrayc com>
Date: Thu Nov 3 09:57:54 2011 +0100
Do not blank the data when showing the field definitions dialog.
* glom/frame_glom.cc: do_menu_developer_fields(): Only blank the data
view if using SQLite, which requires it, because it looks like a bug to
the user.
ChangeLog | 8 ++++++++
glom/frame_glom.cc | 4 +++-
glom/mode_data/box_data_list.cc | 2 +-
3 files changed, 12 insertions(+), 2 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 72b9b6c..2153b90 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
2011-11-03 Murray Cumming <murrayc murrayc com>
+ Do not blank the data when showing the field definitions dialog.
+
+ * glom/frame_glom.cc: do_menu_developer_fields(): Only blank the data
+ view if using SQLite, which requires it, because it looks like a bug to
+ the user.
+
+2011-11-03 Murray Cumming <murrayc murrayc com>
+
Fix make check.
* examples/example_smallbusiness.glom: Resaved with correctly-formatted
diff --git a/glom/frame_glom.cc b/glom/frame_glom.cc
index 0f3a50a..4b82511 100644
--- a/glom/frame_glom.cc
+++ b/glom/frame_glom.cc
@@ -1535,7 +1535,9 @@ void Frame_Glom::do_menu_developer_fields(Gtk::Window& parent, const Glib::ustri
// Some database backends (SQLite) require the table to change to no longer
// be in use when changing the records, so we stop the database usage
// here. We reshow everything in on_developer_dialog_hide() anyway.
- show_no_table();
+ Document* document = dynamic_cast<Document*>(get_document());
+ if(document && document->get_hosting_mode() == Document::HOSTING_MODE_SQLITE)
+ show_no_table();
// Remember the old table name so that we re-show the previous table as
// soon as the dialog has been closed.
diff --git a/glom/mode_data/box_data_list.cc b/glom/mode_data/box_data_list.cc
index 736296a..b1bf541 100644
--- a/glom/mode_data/box_data_list.cc
+++ b/glom/mode_data/box_data_list.cc
@@ -419,7 +419,7 @@ void Box_Data_List::create_layout()
sharedptr<Field> field_primary_key = get_field_primary_key_for_table(m_table_name);
if(!field_primary_key)
{
- std::cerr << G_STRFUNC << ": primary key not found." << std::endl;
+ std::cerr << G_STRFUNC << ": primary key not found for table: " << m_table_name << std::endl;
return;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]