Backed out changeset 360e214bf67b (bug 1530052) as requested. CLOSED TREE

This commit is contained in:
Razvan Maries 2020-07-14 12:19:59 +03:00
Родитель 4f6b5e6e2a
Коммит 269fbe86a7
2 изменённых файлов: 12 добавлений и 5 удалений

Просмотреть файл

@ -3780,7 +3780,11 @@ int XREMain::XRE_mainStartup(bool* aExitFlag) {
// consistently.
// Set program name to the one defined in application.ini.
g_set_prgname(gAppData->remotingName);
{
nsAutoCString program(gAppData->name);
ToLowerCase(program);
g_set_prgname(program.get());
}
// Initialize GTK here for splash.

Просмотреть файл

@ -24,7 +24,6 @@
# include "WakeLockListener.h"
#endif
#include "gfxPlatform.h"
#include "nsAppRunner.h"
#include "ScreenHelperGTK.h"
#include "HeadlessScreenHelper.h"
#include "mozilla/widget/ScreenManager.h"
@ -176,9 +175,13 @@ nsresult nsAppShell::Init() {
// See https://bugzilla.gnome.org/show_bug.cgi?id=747634
//
// Only bother doing this for the parent process, since it's the one
// creating top-level windows.
if (gAppData) {
gdk_set_program_class(gAppData->remotingName);
// 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());
}
}
}