[glom/gtkmm4v4] gtkmm4: Adapt to FileChooserAction as FileChooser::Action.



commit 86611abf262b8b440e150b19775f325a0f947a9e
Author: Murray Cumming <murrayc murrayc com>
Date:   Fri Apr 28 09:22:13 2017 +0200

    gtkmm4: Adapt to FileChooserAction as FileChooser::Action.

 glom/appwindow.cc                                  |   10 +++++-----
 glom/filechooser_export.cc                         |    2 +-
 glom/frame_glom.cc                                 |    2 +-
 .../mode_design/translation/window_translations.cc |    4 ++--
 .../filechooserdialog_saveextras.cc                |    4 ++--
 .../utility_widgets/filechooserdialog_saveextras.h |    4 ++--
 glom/utility_widgets/imageglom.cc                  |    4 ++--
 7 files changed, 15 insertions(+), 15 deletions(-)
---
diff --git a/glom/appwindow.cc b/glom/appwindow.cc
index 20efe25..d1aa940 100644
--- a/glom/appwindow.cc
+++ b/glom/appwindow.cc
@@ -2089,12 +2089,12 @@ Glib::ustring AppWindow::ui_file_select_save(const Glib::ustring& old_file_uri)
   //Create the appropriate dialog, depending on how the caller set m_ui_save_extra_showextras:
   if(m_ui_save_extra_showextras)
   {
-    fileChooser_SaveExtras = new Glom::FileChooserDialog_SaveExtras(_("Save Document"), 
Gtk::FileChooserAction::SAVE);
+    fileChooser_SaveExtras = new Glom::FileChooserDialog_SaveExtras(_("Save Document"), 
Gtk::FileChooser::Action::SAVE);
     fileChooser_Save.reset(fileChooser_SaveExtras);
   }
   else
   {
-    fileChooser_Save.reset(new Gtk::FileChooserDialog(gettext("Save Document"), 
Gtk::FileChooserAction::SAVE));
+    fileChooser_Save.reset(new Gtk::FileChooserDialog(gettext("Save Document"), 
Gtk::FileChooser::Action::SAVE));
   }
 
   fileChooser_Save->set_do_overwrite_confirmation(); //Ask the user if the file already exists.
@@ -2380,7 +2380,7 @@ void AppWindow::on_menu_developer_export_backup()
   starting_name = Utils::string_replace(starting_name, ":", "-");
 
   // This actually creates the directory:
-  Gtk::FileChooserDialog dialog(*this, _("Save Backup"), Gtk::FileChooserAction::CREATE_FOLDER);
+  Gtk::FileChooserDialog dialog(*this, _("Save Backup"), Gtk::FileChooser::Action::CREATE_FOLDER);
   dialog.add_button(_("_Cancel"), Gtk::ResponseType::CANCEL);
   dialog.add_button(_("_Save"), Gtk::ResponseType::ACCEPT);
   dialog.set_local_only(); //Because pg_dump, pg_restore and tar can't use URIs.
@@ -2408,7 +2408,7 @@ void AppWindow::on_menu_developer_export_backup()
 
 void AppWindow::on_menu_developer_restore_backup()
 {
-  Gtk::FileChooserDialog file_dlg(_("Choose a backup file"), Gtk::FileChooserAction::OPEN);
+  Gtk::FileChooserDialog file_dlg(_("Choose a backup file"), Gtk::FileChooser::Action::OPEN);
   file_dlg.set_transient_for(*this);
   file_dlg.set_local_only(); //Because we can't untar remote files.
 
@@ -2792,7 +2792,7 @@ Glib::ustring AppWindow::ui_file_select_open(const Glib::ustring& starting_folde
 {
   Gtk::Window* pWindow = this;
 
-  Gtk::FileChooserDialog fileChooser_Open(_("Open Document"), Gtk::FileChooserAction::OPEN);
+  Gtk::FileChooserDialog fileChooser_Open(_("Open Document"), Gtk::FileChooser::Action::OPEN);
   fileChooser_Open.add_button(_("_Cancel"), Gtk::ResponseType::CANCEL);
   fileChooser_Open.add_button(_("_Open"), Gtk::ResponseType::OK);
   fileChooser_Open.set_default_response(Gtk::ResponseType::OK);
diff --git a/glom/filechooser_export.cc b/glom/filechooser_export.cc
index a20bd28..7200efe 100644
--- a/glom/filechooser_export.cc
+++ b/glom/filechooser_export.cc
@@ -29,7 +29,7 @@ namespace Glom
 {
 
 FileChooser_Export::FileChooser_Export()
-: Gtk::FileChooserDialog(_("Export to File"), Gtk::FileChooserAction::SAVE),
+: Gtk::FileChooserDialog(_("Export to File"), Gtk::FileChooser::Action::SAVE),
   m_extra_widget(Gtk::Orientation::HORIZONTAL, Utils::to_utype(UiUtils::DefaultSpacings::SMALL)),
 #ifndef GLOM_ENABLE_CLIENT_ONLY
   m_button_format(_("Define Data _Format"), true /* use mnenomic */),
diff --git a/glom/frame_glom.cc b/glom/frame_glom.cc
index ae03c09..e8fd1a9 100644
--- a/glom/frame_glom.cc
+++ b/glom/frame_glom.cc
@@ -593,7 +593,7 @@ void Frame_Glom::on_menu_file_import()
   }
   else
   {
-    Gtk::FileChooserDialog file_chooser(*get_app_window(), _("Open CSV Document"), 
Gtk::FileChooserAction::OPEN);
+    Gtk::FileChooserDialog file_chooser(*get_app_window(), _("Open CSV Document"), 
Gtk::FileChooser::Action::OPEN);
     file_chooser.add_button(_("_Cancel"), Gtk::ResponseType::CANCEL);
     file_chooser.add_button(_("_Open"), Gtk::ResponseType::ACCEPT);
     auto filter_csv = Gtk::FileFilter::create();
diff --git a/glom/mode_design/translation/window_translations.cc 
b/glom/mode_design/translation/window_translations.cc
index 16600ec..56c906b 100644
--- a/glom/mode_design/translation/window_translations.cc
+++ b/glom/mode_design/translation/window_translations.cc
@@ -338,7 +338,7 @@ void Window_Translations::on_treeview_edited(const Glib::ustring& /* path */, co
 void Window_Translations::on_button_export()
 {
   //Show the file-chooser dialog, to select an output .po file:
-  Gtk::FileChooserDialog file_dlg(_("Choose .po File Name"), Gtk::FileChooserAction::SAVE);
+  Gtk::FileChooserDialog file_dlg(_("Choose .po File Name"), Gtk::FileChooser::Action::SAVE);
   file_dlg.set_transient_for(*this);
   file_dlg.set_do_overwrite_confirmation();
 
@@ -378,7 +378,7 @@ void Window_Translations::on_button_export()
 
 void Window_Translations::on_button_import()
 {
-  Gtk::FileChooserDialog file_dlg(_("Choose .po File Name"), Gtk::FileChooserAction::OPEN);
+  Gtk::FileChooserDialog file_dlg(_("Choose .po File Name"), Gtk::FileChooser::Action::OPEN);
   file_dlg.set_transient_for(*this);
 
   // Only po files
diff --git a/glom/utility_widgets/filechooserdialog_saveextras.cc 
b/glom/utility_widgets/filechooserdialog_saveextras.cc
index 45c45d6..f1ed46b 100644
--- a/glom/utility_widgets/filechooserdialog_saveextras.cc
+++ b/glom/utility_widgets/filechooserdialog_saveextras.cc
@@ -27,14 +27,14 @@
 namespace Glom
 {
 
-FileChooserDialog_SaveExtras::FileChooserDialog_SaveExtras(const Glib::ustring& title, 
Gtk::FileChooserAction action)
+FileChooserDialog_SaveExtras::FileChooserDialog_SaveExtras(const Glib::ustring& title, 
Gtk::FileChooser::Action action)
 : Gtk::FileChooserDialog(title, action),
   m_extra_widget(Gtk::Orientation::VERTICAL)
 {
   create_child_widgets();
 }
 
-FileChooserDialog_SaveExtras::FileChooserDialog_SaveExtras(Gtk::Window& parent, const Glib::ustring& title, 
Gtk::FileChooserAction action)
+FileChooserDialog_SaveExtras::FileChooserDialog_SaveExtras(Gtk::Window& parent, const Glib::ustring& title, 
Gtk::FileChooser::Action action)
 : Gtk::FileChooserDialog(parent, title, action),
   m_extra_widget(Gtk::Orientation::VERTICAL)
 {
diff --git a/glom/utility_widgets/filechooserdialog_saveextras.h 
b/glom/utility_widgets/filechooserdialog_saveextras.h
index 5235738..6d049d8 100644
--- a/glom/utility_widgets/filechooserdialog_saveextras.h
+++ b/glom/utility_widgets/filechooserdialog_saveextras.h
@@ -39,8 +39,8 @@ namespace Glom
 class FileChooserDialog_SaveExtras : public Gtk::FileChooserDialog
 {
 public:
-  explicit FileChooserDialog_SaveExtras(const Glib::ustring& title, Gtk::FileChooserAction action = 
Gtk::FileChooserAction::OPEN);
-  FileChooserDialog_SaveExtras(Gtk::Window& parent, const Glib::ustring& title, Gtk::FileChooserAction 
action = Gtk::FileChooserAction::OPEN);
+  explicit FileChooserDialog_SaveExtras(const Glib::ustring& title, Gtk::FileChooser::Action action = 
Gtk::FileChooser::Action::OPEN);
+  FileChooserDialog_SaveExtras(Gtk::Window& parent, const Glib::ustring& title, Gtk::FileChooser::Action 
action = Gtk::FileChooser::Action::OPEN);
 
   void set_extra_message(const Glib::ustring& message);
   void set_extra_newdb_title(const Glib::ustring& title);
diff --git a/glom/utility_widgets/imageglom.cc b/glom/utility_widgets/imageglom.cc
index bbcee56..8103a6d 100644
--- a/glom/utility_widgets/imageglom.cc
+++ b/glom/utility_widgets/imageglom.cc
@@ -702,7 +702,7 @@ void ImageGlom::on_menupopup_activate_save_file()
 {
   auto pApp = get_appwindow();
 
-  Gtk::FileChooserDialog dialog(_("Save Image"), Gtk::FileChooserAction::SAVE);
+  Gtk::FileChooserDialog dialog(_("Save Image"), Gtk::FileChooser::Action::SAVE);
   if(pApp)
     dialog.set_transient_for(*pApp);
 
@@ -791,7 +791,7 @@ void ImageGlom::on_menupopup_activate_select_file()
 
   auto pApp = get_appwindow();
 
-  Gtk::FileChooserDialog dialog(_("Choose Image"), Gtk::FileChooserAction::OPEN);
+  Gtk::FileChooserDialog dialog(_("Choose Image"), Gtk::FileChooser::Action::OPEN);
   if(pApp)
     dialog.set_transient_for(*pApp);
 


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