[balsa/wip/gtk4] main and main-window: Pass the GtkApplication
- From: Peter Bloomfield <peterb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [balsa/wip/gtk4] main and main-window: Pass the GtkApplication
- Date: Sat, 9 Jun 2018 01:22:39 +0000 (UTC)
commit e01a638f806e309a5d897dcb465e8c3bbf363214
Author: Peter Bloomfield <PeterBloomfield bellsouth net>
Date: Fri Jun 8 21:19:29 2018 -0400
main and main-window: Pass the GtkApplication
Pass the GtkApplication as an argument to balsa_window_new(), instead of
having it use BalsaApplication::application.
src/main-window.c | 4 ++--
src/main-window.h | 2 +-
src/main.c | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/main-window.c b/src/main-window.c
index 88404404..67cc9f72 100644
--- a/src/main-window.c
+++ b/src/main-window.c
@@ -2250,7 +2250,7 @@ bw_enable_next_unread(BalsaWindow * window, gboolean has_unread_mailbox)
}
GtkWidget *
-balsa_window_new()
+balsa_window_new(GtkApplication *application)
{
BalsaWindow *window;
BalsaWindowPrivate *priv;
@@ -2270,7 +2270,7 @@ balsa_window_new()
balsa_register_pixmaps();
window = g_object_new(BALSA_TYPE_WINDOW,
- "application", balsa_app.application,
+ "application", application,
NULL);
priv = balsa_window_get_instance_private(window);
diff --git a/src/main-window.h b/src/main-window.h
index 6b6d1506..32bbcc02 100644
--- a/src/main-window.h
+++ b/src/main-window.h
@@ -73,7 +73,7 @@ enum {
};
GType balsa_window_get_type(void);
-GtkWidget *balsa_window_new(void);
+GtkWidget *balsa_window_new(GtkApplication *application);
gboolean balsa_window_fix_paned(BalsaWindow *window);
GtkWidget *balsa_window_find_current_index(BalsaWindow * window);
void balsa_window_update_book_menus(BalsaWindow *window);
diff --git a/src/main.c b/src/main.c
index e75c3aaa..4a23edb9 100644
--- a/src/main.c
+++ b/src/main.c
@@ -526,7 +526,7 @@ real_main(int argc, char *argv[])
signal( SIGPIPE, SIG_IGN );
- window = balsa_window_new();
+ window = balsa_window_new(balsa_app.application);
balsa_app.main_window = BALSA_WINDOW(window);
g_object_add_weak_pointer(G_OBJECT(window),
(gpointer) &balsa_app.main_window);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]