summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/Patchage.cpp12
-rw-r--r--src/main.cpp2
2 files changed, 8 insertions, 6 deletions
diff --git a/src/Patchage.cpp b/src/Patchage.cpp
index 56f3ff2..7207567 100644
--- a/src/Patchage.cpp
+++ b/src/Patchage.cpp
@@ -101,20 +101,21 @@ PATCHAGE_RESTORE_WARNINGS
#ifdef PATCHAGE_GTK_OSX
+# include <gtkmm/main.h>
# include <gtkosxapplication.h>
namespace {
gboolean
-can_activate_cb(GtkWidget* widget, guint signal_id, gpointer data)
+can_activate_cb(GtkWidget* widget, guint, gpointer)
{
return gtk_widget_is_sensitive(widget);
}
void
-terminate_cb(GtkosxApplication* app, gpointer data)
+terminate_cb(GtkosxApplication*, gpointer data)
{
- Patchage* patchage = (Patchage*)data;
+ auto* patchage = static_cast<patchage::Patchage*>(data);
patchage->save();
Gtk::Main::quit();
}
@@ -379,8 +380,9 @@ Patchage::Patchage(Options options)
#ifdef PATCHAGE_GTK_OSX
// Set up Mac menu bar
- GtkosxApplication* osxapp =
- (GtkosxApplication*)g_object_new(GTKOSX_TYPE_APPLICATION, nullptr);
+ GtkosxApplication* osxapp = static_cast<GtkosxApplication*>(
+ g_object_new(GTKOSX_TYPE_APPLICATION, nullptr));
+
_menubar->hide();
_menu_file_quit->hide();
gtkosx_application_set_menu_bar(osxapp, GTK_MENU_SHELL(_menubar->gobj()));
diff --git a/src/main.cpp b/src/main.cpp
index fb1744c..c677e01 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -44,7 +44,7 @@ namespace {
void
set_bundle_environment()
{
- const std::string bundle = bundle_location();
+ const std::string bundle = patchage::bundle_location();
const std::string lib_path = bundle + "/lib";
if (!Glib::file_test(lib_path, Glib::FILE_TEST_EXISTS)) {
// If lib does not exist, we have not been bundleified, do nothing