summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlberts Muktupāvels <alberts.muktupavels@gmail.com>2022-09-16 13:00:38 +0300
committerAlberts Muktupāvels <alberts.muktupavels@gmail.com>2022-09-16 14:23:50 +0000
commitda527e0fb78dc1cb24b60394b4c4163410c8c70e (patch)
treee6fc8d12b62b4aecddff8abf3d0d8859c62439fe
parent4b7fe0a052291f7f9bc6030a72c965305a945add (diff)
downloadlibwnck-da527e0fb78dc1cb24b60394b4c4163410c8c70e.tar.gz
util: remove deprecated API
https://gitlab.gnome.org/GNOME/libwnck/-/issues/150
-rw-r--r--libwnck/util.c72
-rw-r--r--libwnck/util.h9
2 files changed, 1 insertions, 80 deletions
diff --git a/libwnck/util.c b/libwnck/util.c
index 83659dc..acd21cd 100644
--- a/libwnck/util.c
+++ b/libwnck/util.c
@@ -113,88 +113,18 @@ wnck_pid_read_resource_usage (GdkDisplay *gdisplay,
_wnck_read_resource_usage_pid (gdisplay, pid, usage);
}
-static WnckClientType client_type = 0;
-
-/**
- * wnck_set_client_type:
- * @ewmh_sourceindication_client_type: a role for the client.
- *
- * Sets the role of the libwnck user.
- *
- * The default role is %WNCK_CLIENT_TYPE_APPLICATION. Therefore, for
- * applications providing some window management features, like pagers or
- * tasklists, it is important to set the role to %WNCK_CLIENT_TYPE_PAGER for
- * libwnck to properly work.
- *
- * This function should only be called once per program. Additional calls
- * with the same client type will be silently ignored. An attempt to change
- * the client type to a differnet value after it has already been set will
- * be ignored and a critical warning will be logged.
- *
- * Since: 2.14
- */
-void
-wnck_set_client_type (WnckClientType ewmh_sourceindication_client_type)
-{
- /* Clients constantly switching types makes no sense; this should only be
- * set once.
- */
- if (client_type != 0 && client_type != ewmh_sourceindication_client_type)
- g_critical ("wnck_set_client_type: changing the client type is not supported.\n");
- else
- client_type = ewmh_sourceindication_client_type;
-}
-
static WnckHandle *wnck_handle = NULL;
WnckHandle *
_wnck_get_handle (void)
{
if (wnck_handle == NULL)
- {
- /* If the type hasn't been set yet, use the default--treat it as a
- * normal application.
- */
- if (client_type == 0)
- client_type = WNCK_CLIENT_TYPE_APPLICATION;
-
- wnck_handle = wnck_handle_new (client_type);
- }
+ wnck_handle = wnck_handle_new (WNCK_CLIENT_TYPE_APPLICATION);
return wnck_handle;
}
/**
- * wnck_set_default_icon_size:
- * @size: the default size for windows and application standard icons.
- *
- * The default main icon size is %WNCK_DEFAULT_ICON_SIZE. This function allows
- * to change this value.
- *
- * Since: 2.4.6
- */
-void
-wnck_set_default_icon_size (gsize size)
-{
- wnck_handle_set_default_icon_size (_wnck_get_handle(), size);
-}
-
-/**
- * wnck_set_default_mini_icon_size:
- * @size: the default size for windows and application mini icons.
- *
- * The default main icon size is %WNCK_DEFAULT_MINI_ICON_SIZE. This function
- * allows to change this value.
- *
- * Since: 2.4.6
- */
-void
-wnck_set_default_mini_icon_size (gsize size)
-{
- wnck_handle_set_default_mini_icon_size (_wnck_get_handle (), size);
-}
-
-/**
* _make_gtk_label_bold:
* @label: The label.
*
diff --git a/libwnck/util.h b/libwnck/util.h
index 91a4e08..4c1e9b2 100644
--- a/libwnck/util.h
+++ b/libwnck/util.h
@@ -100,18 +100,9 @@ typedef enum {
WNCK_CLIENT_TYPE_PAGER = 2
} WnckClientType;
-G_DEPRECATED_FOR(wnck_handle_new)
-void wnck_set_client_type (WnckClientType ewmh_sourceindication_client_type);
-
#define WNCK_DEFAULT_ICON_SIZE 32
#define WNCK_DEFAULT_MINI_ICON_SIZE 16
-G_DEPRECATED_FOR(wnck_handle_set_default_icon_size)
-void wnck_set_default_icon_size (gsize size);
-
-G_DEPRECATED_FOR(wnck_handle_set_default_mini_icon_size)
-void wnck_set_default_mini_icon_size (gsize size);
-
void wnck_shutdown (void);
void wnck_xid_read_resource_usage (GdkDisplay *gdk_display,