cherrypick fix for building against libpeas-0.5.3
This commit is contained in:
parent
a38855123e
commit
b5a6e485dd
98
fix-libpeas-0.5.3-api-changes.patch
Normal file
98
fix-libpeas-0.5.3-api-changes.patch
Normal file
@ -0,0 +1,98 @@
|
||||
From c73bd203eed8b8d1cb45f8746a988d8cda0d408d Mon Sep 17 00:00:00 2001
|
||||
From: Philip Withnall <philip@tecnocode.co.uk>
|
||||
Date: Wed, 14 Jul 2010 22:24:48 +0000
|
||||
Subject: Update builtin plugin support in line with the latest libpeas changes
|
||||
|
||||
Due to the changes in bgo#621858 we can drop some code which handled
|
||||
hiding builtin plugins in the plugin manager.
|
||||
---
|
||||
diff --git a/src/plugins/totem-plugins-engine.c b/src/plugins/totem-plugins-engine.c
|
||||
index 5be4d6e..4cd9f47 100644
|
||||
--- a/src/plugins/totem-plugins-engine.c
|
||||
+++ b/src/plugins/totem-plugins-engine.c
|
||||
@@ -46,7 +46,6 @@
|
||||
#define GCONF_PREFIX_PLUGINS GCONF_PREFIX"/plugins"
|
||||
#define GCONF_PREFIX_PLUGIN GCONF_PREFIX"/plugins/%s"
|
||||
#define GCONF_PLUGIN_ACTIVE GCONF_PREFIX_PLUGINS"/%s/active"
|
||||
-#define GCONF_PLUGIN_HIDDEN GCONF_PREFIX_PLUGINS"/%s/hidden"
|
||||
|
||||
typedef struct _TotemPluginsEnginePrivate{
|
||||
PeasExtensionSet *activatable_extensions;
|
||||
@@ -86,27 +85,6 @@ totem_plugins_engine_class_init (TotemPluginsEngineClass *klass)
|
||||
g_type_class_add_private (klass, sizeof (TotemPluginsEnginePrivate));
|
||||
}
|
||||
|
||||
-static gboolean
|
||||
-plugin_is_builtin (PeasPluginInfo *info)
|
||||
-{
|
||||
- const GHashTable *keys;
|
||||
- const GValue *value;
|
||||
- gboolean builtin;
|
||||
-
|
||||
- keys = peas_plugin_info_get_keys (info);
|
||||
- if (keys == NULL)
|
||||
- return FALSE;
|
||||
- value = g_hash_table_lookup ((GHashTable *) keys, "Builtin");
|
||||
- if (value == NULL)
|
||||
- return FALSE;
|
||||
-
|
||||
- builtin = g_value_get_boolean (value);
|
||||
- if (builtin != FALSE)
|
||||
- peas_plugin_info_set_visible (info, FALSE);
|
||||
-
|
||||
- return builtin;
|
||||
-}
|
||||
-
|
||||
static void
|
||||
totem_plugins_engine_load_all (TotemPluginsEngine *engine)
|
||||
{
|
||||
@@ -124,7 +102,7 @@ totem_plugins_engine_load_all (TotemPluginsEngine *engine)
|
||||
g_message ("checking peas_plugin_info_get_module_name (info) %s", peas_plugin_info_get_module_name (info));
|
||||
|
||||
/* Builtin plugins are activated by default; other plugins aren't */
|
||||
- if (plugin_is_builtin (info)) {
|
||||
+ if (peas_plugin_info_is_builtin (info)) {
|
||||
g_ptr_array_add (activate, (gpointer) peas_plugin_info_get_module_name (info));
|
||||
g_message ("peas_plugin_info_get_module_name (info) %s, to activate", peas_plugin_info_get_module_name (info));
|
||||
continue;
|
||||
@@ -135,11 +113,6 @@ totem_plugins_engine_load_all (TotemPluginsEngine *engine)
|
||||
g_ptr_array_add (activate, (gpointer) peas_plugin_info_get_module_name (info));
|
||||
}
|
||||
g_free (key_name);
|
||||
-
|
||||
- key_name = g_strdup_printf (GCONF_PLUGIN_HIDDEN, peas_plugin_info_get_module_name (info));
|
||||
- if (gconf_client_get_bool (engine->priv->client, key_name, NULL) != FALSE)
|
||||
- peas_plugin_info_set_visible (info, FALSE);
|
||||
- g_free (key_name);
|
||||
}
|
||||
g_ptr_array_add (activate, NULL);
|
||||
|
||||
@@ -166,7 +139,7 @@ on_activatable_extension_added (PeasExtensionSet *set,
|
||||
{
|
||||
g_message ("on_activatable_extension_added");
|
||||
if (peas_extension_call (exten, "activate", engine->priv->totem)) {
|
||||
- if (peas_plugin_info_get_visible (info)) {
|
||||
+ if (peas_plugin_info_is_builtin (info) == FALSE) {
|
||||
char *key_name;
|
||||
|
||||
key_name = g_strdup_printf (GCONF_PLUGIN_ACTIVE,
|
||||
@@ -185,7 +158,7 @@ on_activatable_extension_removed (PeasExtensionSet *set,
|
||||
g_message ("on_activatable_extension_removed");
|
||||
peas_extension_call (exten, "deactivate", engine->priv->totem);
|
||||
|
||||
- if (peas_plugin_info_get_visible (info)) {
|
||||
+ if (peas_plugin_info_is_builtin (info) == FALSE) {
|
||||
char *key_name;
|
||||
|
||||
key_name = g_strdup_printf (GCONF_PLUGIN_ACTIVE,
|
||||
@@ -329,8 +302,6 @@ totem_plugins_engine_gconf_cb (GConfClient *gconf_client,
|
||||
} else {
|
||||
peas_engine_unload_plugin (PEAS_ENGINE (engine), info);
|
||||
}
|
||||
- } else if (g_str_equal (action_name, "hidden") != FALSE) {
|
||||
- peas_plugin_info_set_visible (info, !gconf_value_get_bool (entry->value));
|
||||
}
|
||||
|
||||
g_free (action_name);
|
||||
--
|
||||
cgit v0.8.3.1
|
||||
13
totem.spec
13
totem.spec
@ -6,12 +6,19 @@
|
||||
Summary: Movie player for GNOME
|
||||
Name: totem
|
||||
Version: 2.90.5
|
||||
Release: 2%{?dist}
|
||||
Release: 3%{?dist}
|
||||
License: GPLv2+ with exceptions
|
||||
Group: Applications/Multimedia
|
||||
URL: http://projects.gnome.org/totem/
|
||||
Source0: http://download.gnome.org/sources/totem/2.90/totem-%{version}.tar.bz2
|
||||
|
||||
# totem does not build against libpeas-devel-0.5.3
|
||||
# missing symbols: peas_plugin_info_{s|g}et_visible
|
||||
# Cherrypick fix from totem upstream commit:
|
||||
# http://git.gnome.org/browse/totem/commit/?id=c73bd203eed8b8d1cb45f8746a988d8cda0d408d
|
||||
# rhbz#618791
|
||||
Patch0: fix-libpeas-0.5.3-api-changes.patch
|
||||
|
||||
Requires(pre): GConf2 >= 2.14
|
||||
Requires(preun): GConf2 >= 2.14
|
||||
Requires(post): GConf2 >= 2.14
|
||||
@ -188,6 +195,7 @@ audio and video files in the properties dialog.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch0 -p1 -b .fix-libpeas-0.5.3-api-changes
|
||||
|
||||
autoreconf -i -f
|
||||
|
||||
@ -382,6 +390,9 @@ fi
|
||||
%{_libdir}/totem/plugins/publish
|
||||
|
||||
%changelog
|
||||
* Tue Jul 27 2010 David Malcolm <dmalcolm@redhat.com> - 2.90.5-3
|
||||
- cherrypick fix for building against libpeas-0.5.3
|
||||
|
||||
* Tue Jul 27 2010 David Malcolm <dmalcolm@redhat.com> - 2.90.5-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user