[gimp] plug-ins: remove KDE screenshot portal in favor of Freedesktop portal.
- From: Jehan <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] plug-ins: remove KDE screenshot portal in favor of Freedesktop portal.
- Date: Fri, 17 Dec 2021 19:14:28 +0000 (UTC)
commit ef9c4837711ef04c29bbc973ecdc1de177454b67
Author: Jehan <jehan girinstud io>
Date: Fri Dec 17 19:37:35 2021 +0100
plug-ins: remove KDE screenshot portal in favor of Freedesktop portal.
On recent KDE, the screenshot plug-in fails with an authorization error,
unless we add a desktop file with a special KDE-only desktop entry to
give the permission, which seems a bit over-the-top (if we were to add a
desktop file for every plug-in, and with dedicated entries to every
desktop environment out there, it's never-ending). Of course, we are not
against either, but nobody has contributed a patch doing this in the
last year anyway.
Also Méven (KDE dev) was telling us that KDE recommends to use the
Freedesktop portal nowadays. So maybe let's just move on from the
KDE-specific portal, just as we did recently for the GNOME portal too.
This should hopefully take care of all permission issues and in the same
time simplifies the code.
Note that the Freedesktop API might miss some of the features (this was
one of the reason we were avoiding putting it as priority implementation
until now, to avoid feature regression), but the more we go, the less we
have a choice. It's either this or always fighting against the current.
plug-ins/screenshot/Makefile.am | 2 -
plug-ins/screenshot/meson.build | 1 -
plug-ins/screenshot/screenshot-kwin.c | 206 ----------------------------------
plug-ins/screenshot/screenshot-kwin.h | 32 ------
plug-ins/screenshot/screenshot.c | 11 +-
plug-ins/screenshot/screenshot.h | 2 -
6 files changed, 1 insertion(+), 253 deletions(-)
---
diff --git a/plug-ins/screenshot/Makefile.am b/plug-ins/screenshot/Makefile.am
index 3db7e5bc1b..be35c0ca50 100644
--- a/plug-ins/screenshot/Makefile.am
+++ b/plug-ins/screenshot/Makefile.am
@@ -49,8 +49,6 @@ screenshot_SOURCES = \
screenshot-freedesktop.c \
screenshot-freedesktop.h \
screenshot-icon.h \
- screenshot-kwin.c \
- screenshot-kwin.h \
screenshot-osx.c \
screenshot-osx.h \
screenshot-x11.c \
diff --git a/plug-ins/screenshot/meson.build b/plug-ins/screenshot/meson.build
index 467fe23401..5e48aecda6 100644
--- a/plug-ins/screenshot/meson.build
+++ b/plug-ins/screenshot/meson.build
@@ -2,7 +2,6 @@ plugin_name = 'screenshot'
plugin_sources = [
'screenshot-freedesktop.c',
- 'screenshot-kwin.c',
'screenshot-osx.c',
'screenshot-win32.c',
'screenshot-x11.c',
diff --git a/plug-ins/screenshot/screenshot.c b/plug-ins/screenshot/screenshot.c
index 2c5241a863..2e40af977c 100644
--- a/plug-ins/screenshot/screenshot.c
+++ b/plug-ins/screenshot/screenshot.c
@@ -29,7 +29,6 @@
#include "screenshot.h"
#include "screenshot-freedesktop.h"
#include "screenshot-icon.h"
-#include "screenshot-kwin.h"
#include "screenshot-osx.h"
#include "screenshot-x11.h"
#include "screenshot-win32.h"
@@ -255,12 +254,6 @@ screenshot_run (GimpProcedure *procedure,
}
#endif
- if (! backend && screenshot_kwin_available ())
- {
- backend = SCREENSHOT_BACKEND_KWIN;
- capabilities = screenshot_kwin_get_capabilities ();
- }
-
#ifdef GDK_WINDOWING_X11
if (! backend && screenshot_x11_available ())
{
@@ -268,7 +261,7 @@ screenshot_run (GimpProcedure *procedure,
capabilities = screenshot_x11_get_capabilities ();
}
#endif
- else if (! backend && screenshot_freedesktop_available ())
+ if (! backend && screenshot_freedesktop_available ())
{
backend = SCREENSHOT_BACKEND_FREEDESKTOP;
capabilities = screenshot_freedesktop_get_capabilities ();
@@ -426,8 +419,6 @@ shoot (GdkMonitor *monitor,
if (backend == SCREENSHOT_BACKEND_FREEDESKTOP)
return screenshot_freedesktop_shoot (&shootvals, monitor, image, error);
- else if (backend == SCREENSHOT_BACKEND_KWIN)
- return screenshot_kwin_shoot (&shootvals, monitor, image, error);
#ifdef GDK_WINDOWING_X11
if (backend == SCREENSHOT_BACKEND_X11)
diff --git a/plug-ins/screenshot/screenshot.h b/plug-ins/screenshot/screenshot.h
index ab5b896733..274ed80257 100644
--- a/plug-ins/screenshot/screenshot.h
+++ b/plug-ins/screenshot/screenshot.h
@@ -25,8 +25,6 @@ typedef enum
SCREENSHOT_BACKEND_OSX,
SCREENSHOT_BACKEND_WIN32,
SCREENSHOT_BACKEND_FREEDESKTOP,
- SCREENSHOT_BACKEND_GNOME_SHELL,
- SCREENSHOT_BACKEND_KWIN,
SCREENSHOT_BACKEND_X11
} ScreenshotBackend;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]