blob: c58bc5accec0ae4d983b706e4ab2cb2804264b35 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
# HG changeset patch
# User Andrew Crerar <andrew@crerar.io>
# Date 1588883129 14400
# Thu May 07 16:25:29 2020 -0400
# Node ID 9970281ae22ce7cad35870ef91d27149ec7e9879
# Parent c9a2a8be0647d05e5f354794c3e7b7298cdbe26f
Use remoting name for GDK application names
diff --git a/toolkit/xre/nsAppRunner.cpp b/toolkit/xre/nsAppRunner.cpp
--- a/toolkit/xre/nsAppRunner.cpp
+++ b/toolkit/xre/nsAppRunner.cpp
@@ -3703,11 +3703,7 @@
// consistently.
// Set program name to the one defined in application.ini.
- {
- nsAutoCString program(gAppData->name);
- ToLowerCase(program);
- g_set_prgname(program.get());
- }
+ g_set_prgname(gAppData->remotingName);
// Initialize GTK here for splash.
diff --git a/widget/gtk/nsAppShell.cpp b/widget/gtk/nsAppShell.cpp
--- a/widget/gtk/nsAppShell.cpp
+++ b/widget/gtk/nsAppShell.cpp
@@ -24,6 +24,7 @@
# include "WakeLockListener.h"
#endif
#include "gfxPlatform.h"
+#include "nsAppRunner.h"
#include "ScreenHelperGTK.h"
#include "HeadlessScreenHelper.h"
#include "mozilla/widget/ScreenManager.h"
@@ -178,10 +179,8 @@
// creating top-level windows. (At this point, a child process hasn't
// received the list of registered chrome packages, so the
// GetBrandShortName call would fail anyway.)
- nsAutoString brandName;
- mozilla::widget::WidgetUtils::GetBrandShortName(brandName);
- if (!brandName.IsEmpty()) {
- gdk_set_program_class(NS_ConvertUTF16toUTF8(brandName).get());
+ if (gAppData) {
+ gdk_set_program_class(gAppData->remotingName);
}
}
}
|