mirror of
https://github.com/ZoiteChat/zoitechat.git
synced 2026-03-17 19:20:20 +00:00
Set the GTK program name/class to the desktop ID before initialization to ensure window-to-desktop-entry mapping uses the correct identifier.
Updated the desktop file’s StartupWMClass to match the desktop ID for consistent icon matching.
This commit is contained in:
@@ -9,7 +9,7 @@ Terminal=false
|
|||||||
Type=Application
|
Type=Application
|
||||||
Categories=GTK;Network;IRCClient;
|
Categories=GTK;Network;IRCClient;
|
||||||
StartupNotify=true
|
StartupNotify=true
|
||||||
StartupWMClass=Zoitechat
|
StartupWMClass=net.zoite.Zoitechat
|
||||||
X-GNOME-UsesNotifications=true
|
X-GNOME-UsesNotifications=true
|
||||||
MimeType=x-scheme-handler/irc;x-scheme-handler/ircs;application/x-zoitechat-theme;application/x-hexchat-theme;
|
MimeType=x-scheme-handler/irc;x-scheme-handler/ircs;application/x-zoitechat-theme;application/x-hexchat-theme;
|
||||||
Actions=SafeMode;
|
Actions=SafeMode;
|
||||||
|
|||||||
@@ -123,6 +123,7 @@ fe_args (int argc, char *argv[])
|
|||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
GOptionContext *context;
|
GOptionContext *context;
|
||||||
char *buffer;
|
char *buffer;
|
||||||
|
const char *desktop_id = "net.zoite.Zoitechat";
|
||||||
|
|
||||||
#ifdef ENABLE_NLS
|
#ifdef ENABLE_NLS
|
||||||
bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
|
bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
|
||||||
@@ -241,6 +242,10 @@ fe_args (int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
g_set_prgname (desktop_id);
|
||||||
|
#ifndef WIN32
|
||||||
|
gdk_set_program_class (desktop_id);
|
||||||
|
#endif
|
||||||
gtk_init (&argc, &argv);
|
gtk_init (&argc, &argv);
|
||||||
|
|
||||||
#ifdef HAVE_GTK_MAC
|
#ifdef HAVE_GTK_MAC
|
||||||
|
|||||||
Reference in New Issue
Block a user