[glom] Rename ugly m_b* camel-cased variables.
- From: Murray Cumming <murrayc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glom] Rename ugly m_b* camel-cased variables.
- Date: Wed, 30 Mar 2016 13:17:26 +0000 (UTC)
commit 80c6b537e0653ccc2e7df1589767293155326ccf
Author: Murray Cumming <murrayc murrayc com>
Date: Wed Mar 30 12:43:26 2016 +0200
Rename ugly m_b* camel-cased variables.
glom/appwindow.cc | 8 ++++----
glom/appwindow.h | 2 +-
glom/bakery/appwindow.cc | 6 +++---
glom/bakery/appwindow.h | 2 +-
glom/bakery/appwindow_withdoc.cc | 12 ++++++------
glom/bakery/appwindow_withdoc.h | 2 +-
glom/libglom/document/bakery/document.cc | 24 ++++++++++++------------
glom/libglom/document/bakery/document.h | 6 +++---
glom/mode_data/box_data_details.cc | 8 ++++----
glom/mode_data/box_data_details.h | 2 +-
glom/mode_data/db_adddel/db_adddel.cc | 22 +++++++++++-----------
glom/mode_data/db_adddel/db_adddel.h | 6 +++---
glom/utility_widgets/adddel/adddel.cc | 14 +++++++-------
glom/utility_widgets/adddel/adddel.h | 6 +++---
14 files changed, 60 insertions(+), 60 deletions(-)
---
diff --git a/glom/appwindow.cc b/glom/appwindow.cc
index ee174b7..5933698 100644
--- a/glom/appwindow.cc
+++ b/glom/appwindow.cc
@@ -90,7 +90,7 @@ AppWindow::AppWindow(BaseObjectType* cobject, const Glib::RefPtr<Gtk::Builder>&
m_VBox_PlaceHolder(Gtk::ORIENTATION_VERTICAL),
m_pBoxTop(nullptr),
m_pFrame(nullptr),
- m_bAboutShown(false),
+ m_about_shown(false),
m_pAbout(nullptr),
#ifndef GLOM_ENABLE_CLIENT_ONLY
m_window_translations(nullptr),
@@ -446,7 +446,7 @@ void AppWindow::init_menus()
void AppWindow::on_menu_help_about()
{
- if(m_pAbout && m_bAboutShown) // "About" box hasn't been closed, so just raise it
+ if(m_pAbout && m_about_shown) // "About" box hasn't been closed, so just raise it
{
m_pAbout->set_transient_for(*this);
@@ -491,7 +491,7 @@ void AppWindow::on_menu_help_about()
std::cout << G_STRFUNC << ": Could not load icon from resource path=" << glom_icon_path << std::endl;
m_pAbout->signal_hide().connect( sigc::mem_fun(*this, &AppWindow::on_about_close) );
- m_bAboutShown = true;
+ m_about_shown = true;
static_cast<Gtk::Dialog*>(m_pAbout)->run(); //show() would be better. see below:
m_pAbout->hide();
//m_pAbout->show(); //TODO: respond to the OK button.
@@ -500,7 +500,7 @@ void AppWindow::on_menu_help_about()
void AppWindow::on_about_close()
{
- m_bAboutShown = false;
+ m_about_shown = false;
}
void AppWindow::on_menu_file_toggle_share()
diff --git a/glom/appwindow.h b/glom/appwindow.h
index d38fefd..e68e17c 100644
--- a/glom/appwindow.h
+++ b/glom/appwindow.h
@@ -309,7 +309,7 @@ private:
Gtk::Box* m_pBoxTop;
Frame_Glom* m_pFrame;
- bool m_bAboutShown;
+ bool m_about_shown;
Gtk::AboutDialog* m_pAbout; //About box.
Infobar_ProgressCreating* m_infobar_progress;
diff --git a/glom/bakery/appwindow.cc b/glom/bakery/appwindow.cc
index 0f62b83..c5f5887 100644
--- a/glom/bakery/appwindow.cc
+++ b/glom/bakery/appwindow.cc
@@ -22,7 +22,7 @@
namespace GlomBakery
{
-bool AppWindow::m_bOperationCancelled = false;
+bool AppWindow::m_operation_cancelled = false;
Glib::ustring AppWindow::m_strCommandLine_0;
Glib::ustring AppWindow::m_strAppName;
@@ -90,12 +90,12 @@ void AppWindow::on_menu_edit_clear()
void AppWindow::set_operation_cancelled(bool value /* = true */)
{
- m_bOperationCancelled = value;
+ m_operation_cancelled = value;
}
bool AppWindow::get_operation_cancelled()
{
- return m_bOperationCancelled;
+ return m_operation_cancelled;
}
void AppWindow::set_command_line_args(int argc, char **&argv)
diff --git a/glom/bakery/appwindow.h b/glom/bakery/appwindow.h
index 84aba8e..6fa4c3c 100644
--- a/glom/bakery/appwindow.h
+++ b/glom/bakery/appwindow.h
@@ -113,7 +113,7 @@ protected:
//Instances
- static bool m_bOperationCancelled; //see set/get_operation_cancelled().
+ static bool m_operation_cancelled; //see set/get_operation_cancelled().
//Command line args:
static Glib::ustring m_strCommandLine_0;
diff --git a/glom/bakery/appwindow_withdoc.cc b/glom/bakery/appwindow_withdoc.cc
index 414ef21..aac9470 100644
--- a/glom/bakery/appwindow_withdoc.cc
+++ b/glom/bakery/appwindow_withdoc.cc
@@ -32,7 +32,7 @@ AppWindow_WithDoc::type_list_strings AppWindow_WithDoc::m_mime_types;
AppWindow_WithDoc::AppWindow_WithDoc(const Glib::ustring& appname)
: AppWindow(appname),
m_document(nullptr),
- m_bCloseAfterSave(false)
+ m_close_after_save(false)
{
}
@@ -52,7 +52,7 @@ void AppWindow_WithDoc::on_menu_file_close()
if(m_document->get_modified())
{
//Offer to save changes:
- m_bCloseAfterSave = true; //Checked in FileChooser signal handler.
+ m_close_after_save = true; //Checked in FileChooser signal handler.
offer_to_save_changes(); //If a File|Exit is in progress, this could cancel it.
}
@@ -235,7 +235,7 @@ void AppWindow_WithDoc::on_menu_file_saveas()
//Close if this save was a result of a File|Close or File|Exit:.
- //if(bTest && m_bCloseAfterSave) //Don't close if the save failed.
+ //if(bTest && m_close_after_save) //Don't close if the save failed.
//{
// on_menu_file_close(); //This could be the second time, but now there are no unsaved changes.
//}
@@ -261,7 +261,7 @@ void AppWindow_WithDoc::on_menu_file_save()
after_successful_save();
//Close the document if this save was in response to a 'Do you want to save before closing?':
- //if(m_bCloseAfterSave) // || m_bExiting
+ //if(m_close_after_save) // || m_bExiting
// close_mark_or_destroy();
}
else
@@ -279,7 +279,7 @@ void AppWindow_WithDoc::on_menu_file_save()
}
}
- if(!m_bCloseAfterSave) //Don't try to do anything after closing - this instance would not exist anymore.
+ if(!m_close_after_save) //Don't try to do anything after closing - this instance would not exist anymore.
{
update_window_title();
}
@@ -371,7 +371,7 @@ void AppWindow_WithDoc::offer_to_save_changes()
void AppWindow_WithDoc::cancel_close_or_exit()
{
set_operation_cancelled();
- m_bCloseAfterSave = false;
+ m_close_after_save = false;
//exit_destroy_marked_instances(); //Clean up after an exit.
}
diff --git a/glom/bakery/appwindow_withdoc.h b/glom/bakery/appwindow_withdoc.h
index 5f9b495..74d4ced 100644
--- a/glom/bakery/appwindow_withdoc.h
+++ b/glom/bakery/appwindow_withdoc.h
@@ -166,7 +166,7 @@ protected:
//Document:
std::shared_ptr<Document> m_document; //An instance of a derived type.
- bool m_bCloseAfterSave;
+ bool m_close_after_save;
//Mime types which this application can load and save:
typedef std::list<Glib::ustring> type_list_strings;
diff --git a/glom/libglom/document/bakery/document.cc b/glom/libglom/document/bakery/document.cc
index 86f8409..94674e9 100644
--- a/glom/libglom/document/bakery/document.cc
+++ b/glom/libglom/document/bakery/document.cc
@@ -30,9 +30,9 @@ const guint BYTES_TO_PROCESS = 256;
Document::Document()
{
- m_bIsNew = true;
- m_bModified = false;
- m_bReadOnly = false;
+ m_is_new = true;
+ m_modified = false;
+ m_read_only = false;
m_pView = nullptr;
}
@@ -95,20 +95,20 @@ Glib::ustring Document::get_contents() const
void Document::set_modified(bool value /* = true */)
{
- m_bModified = value;
+ m_modified = value;
- if(m_bModified)
+ if(m_modified)
{
- m_bIsNew = false; //Can't be new if it's been modified.
+ m_is_new = false; //Can't be new if it's been modified.
}
//Allow the application or view to update it's UI accordingly:
- signal_modified().emit(m_bModified);
+ signal_modified().emit(m_modified);
}
bool Document::get_modified() const
{
- return m_bModified;
+ return m_modified;
}
bool Document::load(int& failure_code)
@@ -437,7 +437,7 @@ ViewBase* Document::get_view()
bool Document::get_read_only() const
{
- if(m_bReadOnly)
+ if(m_read_only)
{
//An application might have used set_read_only() to make this document explicitly read_only, regardless
of the positions of the storage location.
return true;
@@ -470,12 +470,12 @@ bool Document::get_read_only() const
void Document::set_read_only(bool value)
{
- m_bReadOnly = value;
+ m_read_only = value;
}
bool Document::get_is_new() const
{
- return m_bIsNew;
+ return m_is_new;
}
void Document::set_is_new(bool value)
@@ -483,7 +483,7 @@ void Document::set_is_new(bool value)
if(value)
set_modified(false); //can't be modified if it is new.
- m_bIsNew = value;
+ m_is_new = value;
}
void Document::set_file_extension(const Glib::ustring& strVal)
diff --git a/glom/libglom/document/bakery/document.h b/glom/libglom/document/bakery/document.h
index f38a148..f5b379d 100644
--- a/glom/libglom/document/bakery/document.h
+++ b/glom/libglom/document/bakery/document.h
@@ -133,9 +133,9 @@ protected:
type_signal_modified signal_modified_;
- bool m_bModified;
- bool m_bIsNew; //see get_is_new().
- bool m_bReadOnly;
+ bool m_modified;
+ bool m_is_new; //see get_is_new().
+ bool m_read_only;
};
} //namespace
diff --git a/glom/mode_data/box_data_details.cc b/glom/mode_data/box_data_details.cc
index c6e7cd7..a4ac9a3 100644
--- a/glom/mode_data/box_data_details.cc
+++ b/glom/mode_data/box_data_details.cc
@@ -51,7 +51,7 @@ Box_Data_Details::Box_Data_Details(bool bWithNavButtons /* = true */)
m_Button_Nav_Prev(_("_Back"), true),
m_Button_Nav_Next(_("_Forward"), true),
m_Button_Nav_Last(_("_Last"), true),
- m_bDoNotRefreshRelated(false),
+ m_do_not_refresh_related(false),
m_ignore_signals(true)
#ifndef GLOM_ENABLE_CLIENT_ONLY
, m_design_mode(false)
@@ -550,8 +550,8 @@ void Box_Data_Details::on_related_record_added(Gnome::Gda::Value /* strKeyValue
//Prevent deletion of Related boxes.
//One of them emitted this signal, and is probably still being edited.
//This prevents a crash.
- bool bDoNotRefreshRelated = m_bDoNotRefreshRelated;
- m_bDoNotRefreshRelated = true;
+ bool do_not_refresh_related = m_do_not_refresh_related;
+ m_do_not_refresh_related = true;
//std::cout << "debug: " << G_STRFUNC << ": " << strKeyValue << ", " << strFromKeyName << std::endl;
//Get current FromKey value:
@@ -572,7 +572,7 @@ void Box_Data_Details::on_related_record_added(Gnome::Gda::Value /* strKeyValue
//Restore value:
- m_bDoNotRefreshRelated = bDoNotRefreshRelated;
+ m_do_not_refresh_related = do_not_refresh_related;
}
Box_Data_Details::type_signal_void Box_Data_Details::signal_nav_first()
diff --git a/glom/mode_data/box_data_details.h b/glom/mode_data/box_data_details.h
index 75ed1da..0fcea46 100644
--- a/glom/mode_data/box_data_details.h
+++ b/glom/mode_data/box_data_details.h
@@ -158,7 +158,7 @@ protected:
Gtk::Button m_Button_Nav_Next;
Gtk::Button m_Button_Nav_Last;
- bool m_bDoNotRefreshRelated; //Stops us from refreshing related records in response to an addition of a
related record.
+ bool m_do_not_refresh_related; //Stops us from refreshing related records in response to an addition of a
related record.
bool m_ignore_signals;
type_signal_void m_signal_nav_first;
diff --git a/glom/mode_data/db_adddel/db_adddel.cc b/glom/mode_data/db_adddel/db_adddel.cc
index ce1a4bd..072fc1d 100644
--- a/glom/mode_data/db_adddel/db_adddel.cc
+++ b/glom/mode_data/db_adddel/db_adddel.cc
@@ -47,9 +47,9 @@ DbAddDel::DbAddDel()
m_column_is_sorted(false),
m_column_sorted_direction(false),
m_column_sorted(0),
- m_bAllowUserActions(true),
- m_bPreventUserSignals(false),
- m_bIgnoreTreeViewSignals(false),
+ m_allow_user_actions(true),
+ m_prevent_user_signals(false),
+ m_ignore_tree_view_signals(false),
m_allow_add(true),
m_allow_delete(true),
m_find_mode(false),
@@ -1049,12 +1049,12 @@ std::shared_ptr<const LayoutItem_Field> DbAddDel::get_column_field(guint column_
bool DbAddDel::get_prevent_user_signals() const
{
- return m_bPreventUserSignals;
+ return m_prevent_user_signals;
}
void DbAddDel::set_prevent_user_signals(bool value)
{
- m_bPreventUserSignals = value;
+ m_prevent_user_signals = value;
}
/*
@@ -1104,12 +1104,12 @@ void DbAddDel::set_allow_delete(bool val)
void DbAddDel::set_allow_user_actions(bool value)
{
- m_bAllowUserActions = value;
+ m_allow_user_actions = value;
}
bool DbAddDel::get_allow_user_actions() const
{
- return m_bAllowUserActions;
+ return m_allow_user_actions;
}
void DbAddDel::set_find_mode(bool val)
@@ -1171,12 +1171,12 @@ void DbAddDel::remove_item(const Gtk::TreeModel::iterator& iter)
bool DbAddDel::get_ignore_treeview_signals() const
{
- return m_bIgnoreTreeViewSignals;
+ return m_ignore_tree_view_signals;
}
void DbAddDel::set_ignore_treeview_signals(bool ignore)
{
- m_bIgnoreTreeViewSignals = ignore;
+ m_ignore_tree_view_signals = ignore;
}
DbAddDel::InnerIgnore::InnerIgnore(DbAddDel* pOuter)
@@ -1546,7 +1546,7 @@ void DbAddDel::on_treeview_column_resized(int model_column_index, DbTreeViewColu
return;
//Ignore this property change signal handler if we are setting the size in code:
- if(m_bIgnoreTreeViewSignals)
+ if(m_ignore_tree_view_signals)
return;
//We do not save the column width if this is the last column,
@@ -1604,7 +1604,7 @@ void DbAddDel::on_treeview_column_clicked(int model_column_index)
void DbAddDel::on_treeview_columns_changed()
{
- if(!m_bIgnoreTreeViewSignals)
+ if(!m_ignore_tree_view_signals)
{
//Get the new column order, and save it in m_vecColumnIDs:
m_vecColumnIDs.clear();
diff --git a/glom/mode_data/db_adddel/db_adddel.h b/glom/mode_data/db_adddel/db_adddel.h
index 96e95c4..c87c620 100644
--- a/glom/mode_data/db_adddel/db_adddel.h
+++ b/glom/mode_data/db_adddel/db_adddel.h
@@ -408,10 +408,10 @@ private:
Glib::RefPtr<Gio::SimpleAction> m_refContextLayout;
#endif
- bool m_bAllowUserActions;
+ bool m_allow_user_actions;
- bool m_bPreventUserSignals;
- bool m_bIgnoreTreeViewSignals;
+ bool m_prevent_user_signals;
+ bool m_ignore_tree_view_signals;
type_vec_strings m_vecColumnIDs; //We give each ViewColumn a special ID, so we know where they are after a
reorder.
diff --git a/glom/utility_widgets/adddel/adddel.cc b/glom/utility_widgets/adddel/adddel.cc
index 47103a8..af09eea 100644
--- a/glom/utility_widgets/adddel/adddel.cc
+++ b/glom/utility_widgets/adddel/adddel.cc
@@ -100,7 +100,7 @@ void AddDel::init()
set_spacing(Utils::to_utype(UiUtils::DefaultSpacings::SMALL));
- m_bAllowUserActions = true;
+ m_allow_user_actions = true;
//Start with a useful default TreeModel:
//set_columns_count(1);
@@ -891,12 +891,12 @@ Glib::ustring AddDel::get_column_field(guint column_index) const
bool AddDel::get_prevent_user_signals() const
{
- return m_bPreventUserSignals;
+ return m_prevent_user_signals;
}
void AddDel::set_prevent_user_signals(bool value)
{
- m_bPreventUserSignals = value;
+ m_prevent_user_signals = value;
}
void AddDel::set_column_choices(guint col, const type_vec_strings& vecStrings)
@@ -940,12 +940,12 @@ void AddDel::set_allow_delete(bool val)
void AddDel::set_allow_user_actions(bool value)
{
- m_bAllowUserActions = value;
+ m_allow_user_actions = value;
}
bool AddDel::get_allow_user_actions() const
{
- return m_bAllowUserActions;
+ return m_allow_user_actions;
}
@@ -970,12 +970,12 @@ void AddDel::finish_editing()
void AddDel::set_ignore_treeview_signals(bool value)
{
- m_bIgnoreSheetSignals = value;
+ m_ignore_sheet_signals = value;
}
bool AddDel::get_ignore_treeview_signals() const
{
- return m_bIgnoreSheetSignals;
+ return m_ignore_sheet_signals;
}
/*
diff --git a/glom/utility_widgets/adddel/adddel.h b/glom/utility_widgets/adddel/adddel.h
index 2d6d25e..474b6da 100644
--- a/glom/utility_widgets/adddel/adddel.h
+++ b/glom/utility_widgets/adddel/adddel.h
@@ -291,10 +291,10 @@ private:
typedef std::vector<AddDelColumnInfo> type_ColumnTypes;
type_ColumnTypes m_ColumnTypes;
- bool m_bAllowUserActions;
+ bool m_allow_user_actions;
- bool m_bPreventUserSignals;
- bool m_bIgnoreSheetSignals;
+ bool m_prevent_user_signals;
+ bool m_ignore_sheet_signals;
type_vec_strings m_vecColumnIDs; //We give each ViewColumn a special ID, so we know where they are after a
reorder.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]