Stop using G_APPLICATION_FLAGS_NONE

It has been deprecated in favor of G_APPLICATION_DEFAULT_FLAGS.
This commit is contained in:
Matthias Clasen 2024-09-25 22:03:23 -04:00
parent ecfe47af73
commit 76e93206f3
8 changed files with 9 additions and 11 deletions

View File

@ -49,7 +49,7 @@ main (int argc,
g_chdir (GTK_SRCDIR);
#endif
GtkApplication *app = gtk_application_new ("org.gtk.example", G_APPLICATION_FLAGS_NONE);
GtkApplication *app = gtk_application_new ("org.gtk.example", G_APPLICATION_DEFAULT_FLAGS);
g_signal_connect (app, "activate", G_CALLBACK (activate), NULL);
int status = g_application_run (G_APPLICATION (app), argc, argv);

View File

@ -173,7 +173,7 @@ main (int argc,
GtkApplication *app;
int status;
app = gtk_application_new ("org.gtk.example", G_APPLICATION_FLAGS_NONE);
app = gtk_application_new ("org.gtk.example", G_APPLICATION_DEFAULT_FLAGS);
g_signal_connect (app, "activate", G_CALLBACK (activate), NULL);
status = g_application_run (G_APPLICATION (app), argc, argv);
g_object_unref (app);

View File

@ -60,7 +60,7 @@ main (int argc,
GtkApplication *app;
int status;
app = gtk_application_new ("org.gtk.example", G_APPLICATION_FLAGS_NONE);
app = gtk_application_new ("org.gtk.example", G_APPLICATION_DEFAULT_FLAGS);
g_signal_connect (app, "activate", G_CALLBACK (activate), NULL);
status = g_application_run (G_APPLICATION (app), argc, argv);
g_object_unref (app);

View File

@ -37,10 +37,8 @@ main (int argc,
{
GtkApplication *app;
app = gtk_application_new ("org.gtk.Example.GtkSearchBar",
G_APPLICATION_FLAGS_NONE);
g_signal_connect (app, "activate",
G_CALLBACK (activate_cb), NULL);
app = gtk_application_new ("org.gtk.Example.GtkSearchBar", G_APPLICATION_DEFAULT_FLAGS);
g_signal_connect (app, "activate", G_CALLBACK (activate_cb), NULL);
return g_application_run (G_APPLICATION (app), argc, argv);
}

View File

@ -19,7 +19,7 @@ main (int argc,
GtkApplication *app;
int status;
app = gtk_application_new ("org.gtk.example", G_APPLICATION_FLAGS_NONE);
app = gtk_application_new ("org.gtk.example", G_APPLICATION_DEFAULT_FLAGS);
g_signal_connect (app, "activate", G_CALLBACK (activate), NULL);
status = g_application_run (G_APPLICATION (app), argc, argv);
g_object_unref (app);

View File

@ -102,7 +102,7 @@ main (int argc,
int result;
application = gtk_application_new ("org.gtk.test.infobar",
G_APPLICATION_FLAGS_NONE);
G_APPLICATION_DEFAULT_FLAGS);
g_signal_connect (application, "activate", G_CALLBACK (on_activate), NULL);
result = g_application_run (G_APPLICATION (application), argc, argv);

View File

@ -203,7 +203,7 @@ test_app_new (void)
test_app = g_object_new (test_app_get_type (),
"application-id", "org.gtk.testlist4",
"flags", G_APPLICATION_FLAGS_NONE,
"flags", G_APPLICATION_DEFAULT_FLAGS,
NULL);
return test_app;

View File

@ -86,7 +86,7 @@ main (int argc,
char *argv[])
{
GtkApplication *application = gtk_application_new ("org.gtk.test.modelbutton",
G_APPLICATION_FLAGS_NONE);
G_APPLICATION_DEFAULT_FLAGS);
int result;
g_signal_connect (application, "activate",