summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorColomban Wendling <[email protected]>2025-05-14 19:03:41 +0200
committerVictor Kareh <[email protected]>2025-07-25 07:21:44 -0400
commite6d505d60e5f5fb8bfd7d9901251abea3ac9dfaa (patch)
treed824d9f385600538c14743e208ea02750b370f6c
parent5ebedfa80a795da9e7a785bfa19250120426acf9 (diff)
downloadmate-control-center-e6d505d60e5f5fb8bfd7d9901251abea3ac9dfaa.tar.bz2
mate-control-center-e6d505d60e5f5fb8bfd7d9901251abea3ac9dfaa.tar.xz
font-viewer: Bring the window to the front when triggering the app
If the app is already open, we need to tell the desktop that the window has been triggered, so it can either bring it to front, or notify the user the window claims attention. This fixes the cases where the font viewer is already open and gets triggered again, e.g. by opening a font or launching it directly.
-rw-r--r--font-viewer/font-view.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/font-viewer/font-view.c b/font-viewer/font-view.c
index 406b051b..dcbcb658 100644
--- a/font-viewer/font-view.c
+++ b/font-viewer/font-view.c
@@ -658,6 +658,8 @@ font_view_application_do_open (FontViewApplication *self,
gtk_widget_show_all (self->swin_preview);
gtk_notebook_set_current_page (GTK_NOTEBOOK (self->notebook), 1);
+
+ gtk_window_present (GTK_WINDOW (self->main_window));
}
static gboolean
@@ -933,6 +935,8 @@ font_view_application_activate (GApplication *application)
G_APPLICATION_CLASS (font_view_application_parent_class)->activate (application);
font_view_application_do_overview (self);
+
+ gtk_window_present (GTK_WINDOW (self->main_window));
}
static void