repo/extra/firefox/patches/no-dbus.patch

70 lines
2.2 KiB
Diff
Raw Normal View History

2022-07-25 11:24:39 -06:00
diff -r fc5ee47dac3e toolkit/components/remote/moz.build
--- a/toolkit/components/remote/moz.build Tue Jun 28 12:00:27 2022 -0500
+++ b/toolkit/components/remote/moz.build Thu Jun 30 00:35:24 2022 -0500
@@ -26,7 +26,7 @@
2022-05-05 01:25:58 -06:00
"nsUnixRemoteServer.h",
"RemoteUtils.h",
]
- else:
+ elif CONFIG["MOZ_X11"]:
SOURCES += [
"nsGTKRemoteServer.cpp",
"nsXRemoteClient.cpp",
2022-07-25 11:24:39 -06:00
diff -r fc5ee47dac3e toolkit/components/remote/nsRemoteService.cpp
--- a/toolkit/components/remote/nsRemoteService.cpp Tue Jun 28 12:00:27 2022 -0500
+++ b/toolkit/components/remote/nsRemoteService.cpp Thu Jun 30 00:35:24 2022 -0500
@@ -6,12 +6,14 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
2022-05-05 01:25:58 -06:00
#ifdef MOZ_WIDGET_GTK
-# ifdef MOZ_ENABLE_DBUS
+# if defined(MOZ_ENABLE_DBUS)
# include "nsDBusRemoteServer.h"
# include "nsDBusRemoteClient.h"
-# else
+# elif defined(MOZ_X11)
# include "nsGTKRemoteServer.h"
# include "nsXRemoteClient.h"
+# else
+# include "nsRemoteClient.h"
# endif
#elif defined(XP_WIN)
# include "nsWinRemoteServer.h"
2022-07-25 11:24:39 -06:00
@@ -94,8 +96,10 @@
2022-05-05 01:25:58 -06:00
#ifdef MOZ_WIDGET_GTK
# if defined(MOZ_ENABLE_DBUS)
client = MakeUnique<nsDBusRemoteClient>();
+# elif defined(MOZ_X11)
2022-07-25 11:24:39 -06:00
+ client = MakeUnique<nsXRemoteClient>();
# else
- client = MakeUnique<nsXRemoteClient>();
2022-05-05 01:25:58 -06:00
+ return REMOTE_NOT_FOUND;
# endif
#elif defined(XP_WIN)
client = MakeUnique<nsWinRemoteClient>();
2022-07-25 11:24:39 -06:00
@@ -138,8 +142,10 @@
2022-05-05 01:25:58 -06:00
#ifdef MOZ_WIDGET_GTK
# if defined(MOZ_ENABLE_DBUS)
mRemoteServer = MakeUnique<nsDBusRemoteServer>();
+# elif defined(MOZ_X11)
2022-07-25 11:24:39 -06:00
+ mRemoteServer = MakeUnique<nsGTKRemoteServer>();
# else
- mRemoteServer = MakeUnique<nsGTKRemoteServer>();
2022-05-05 01:25:58 -06:00
+ return;
# endif
#elif defined(XP_WIN)
mRemoteServer = MakeUnique<nsWinRemoteServer>();
2023-10-09 08:19:40 -06:00
--- a/widget/gtk/nsAppShell.cpp
+++ b/widget/gtk/nsAppShell.cpp
@@ -296,8 +296,10 @@
do_GetService(POWERMANAGERSERVICE_CONTRACTID);
if (powerManagerService) {
+#ifdef MOZ_ENABLE_DBUS
powerManagerService->AddWakeLockListener(
WakeLockListener::GetSingleton());
+#endif
} else {
NS_WARNING(
"Failed to retrieve PowerManagerService, wakelocks will be broken!");