[gedit/zbrown/deteplification-src: 217/633] Remove GeditAppX11 class
- From: Zander Brown <zbrown src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gedit/zbrown/deteplification-src: 217/633] Remove GeditAppX11 class
- Date: Sat, 10 Apr 2021 12:47:58 +0000 (UTC)
commit 5fc6a6a6505117db1de3fb38f363ae7c172b6dd7
Author: Sébastien Wilmet <swilmet gnome org>
Date: Wed Mar 18 19:10:32 2020 +0100
Remove GeditAppX11 class
In the main() function, create the parent class instead: GeditApp (this
requires a small change in GeditApp to make it a concrete class instead
of an abstract class).
GeditAppX11 did only one thing (providing the desktop-startup-id in case
the information is needed but not already set). And by looking at the
GTK 3 code, it's now done by GtkApplication (search "desktop-startup-id"
in gtkapplication.c).
This removes some X11-specific code from gedit, which is also a welcome
change since X11 is deprecated and linking against the X11 library
prevents gedit from being a native Wayland app.
docs/reference/meson.build | 1 -
gedit/gedit-app-x11.c | 110 ---------------------------------------------
gedit/gedit-app-x11.h | 38 ----------------
gedit/gedit-app.c | 2 +-
gedit/gedit.c | 4 +-
gedit/meson.build | 3 --
6 files changed, 2 insertions(+), 156 deletions(-)
---
diff --git a/docs/reference/meson.build b/docs/reference/meson.build
index 1c816b3c3..f73915691 100644
--- a/docs/reference/meson.build
+++ b/docs/reference/meson.build
@@ -25,7 +25,6 @@ gedit_doc_dep = declare_dependency(
libgedit_reference_ignored_h = [
'gedit-app-osx.h',
'gedit-app-win32.h',
- 'gedit-app-x11.h',
'gedit-close-confirmation-dialog.h',
'gedit-dirs.h',
'gedit-document-private.h',
diff --git a/gedit/gedit-app.c b/gedit/gedit-app.c
index ecdccb370..daadc3610 100644
--- a/gedit/gedit-app.c
+++ b/gedit/gedit-app.c
@@ -150,7 +150,7 @@ static const GOptionEntry options[] =
{NULL}
};
-G_DEFINE_ABSTRACT_TYPE_WITH_PRIVATE (GeditApp, gedit_app, GTK_TYPE_APPLICATION)
+G_DEFINE_TYPE_WITH_PRIVATE (GeditApp, gedit_app, GTK_TYPE_APPLICATION)
static void
gedit_app_dispose (GObject *object)
diff --git a/gedit/gedit.c b/gedit/gedit.c
index 878532c01..35bad3e99 100644
--- a/gedit/gedit.c
+++ b/gedit/gedit.c
@@ -26,8 +26,6 @@
# include "gedit-app-osx.h"
#elif defined G_OS_WIN32
# include "gedit-app-win32.h"
-#else
-# include "gedit-app-x11.h"
#endif
#include <glib.h>
@@ -130,7 +128,7 @@ main (int argc, char *argv[])
type = GEDIT_TYPE_APP_WIN32;
#else
- type = GEDIT_TYPE_APP_X11;
+ type = GEDIT_TYPE_APP;
#endif
/* NOTE: we should not make any calls to the gedit api before the
diff --git a/gedit/meson.build b/gedit/meson.build
index f99220852..f0d515e7c 100644
--- a/gedit/meson.build
+++ b/gedit/meson.build
@@ -149,9 +149,6 @@ elif host_machine.system() == 'windows'
'gedit-app-win32.c',
)
else
- libgedit_sources += files(
- 'gedit-app-x11.c',
- )
libgedit_deps += [
x11_dep,
]
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]