From 420e3cf7b23f1393f66599531bc108802199ec46 Mon Sep 17 00:00:00 2001 From: provokateurin Date: Tue, 29 Oct 2024 07:58:46 +0100 Subject: [PATCH] fix(example): Fix window icon on wayland Signed-off-by: provokateurin --- .cspell/tools.txt | 1 + packages/neon_framework/example/linux/my_application.cc | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/.cspell/tools.txt b/.cspell/tools.txt index 126ca4bdcc5..422996a4a33 100644 --- a/.cspell/tools.txt +++ b/.cspell/tools.txt @@ -53,6 +53,7 @@ openrelayprojectsecret petstore plantuml precache +prgname puml realpath rpath diff --git a/packages/neon_framework/example/linux/my_application.cc b/packages/neon_framework/example/linux/my_application.cc index 936d14e954e..701a5d23699 100644 --- a/packages/neon_framework/example/linux/my_application.cc +++ b/packages/neon_framework/example/linux/my_application.cc @@ -104,6 +104,12 @@ static void my_application_class_init(MyApplicationClass* klass) { static void my_application_init(MyApplication* self) {} MyApplication* my_application_new() { + // Set the program name to the application ID, which helps various systems + // like GTK and desktop environments map this running application to its + // corresponding .desktop file. This ensures better integration by allowing + // the application to be recognized beyond its binary name. + g_set_prgname(APPLICATION_ID); + return MY_APPLICATION(g_object_new(my_application_get_type(), "application-id", APPLICATION_ID, "flags", G_APPLICATION_NON_UNIQUE,