Added ibus-771115-property-compatible.patch for f16
This commit is contained in:
parent
bf8c2dea8f
commit
3b4ca626a5
163
ibus-771115-property-compatible.patch
Normal file
163
ibus-771115-property-compatible.patch
Normal file
@ -0,0 +1,163 @@
|
||||
--- ibus-1.4.0/src/ibusproperty.c.orig 2012-01-04 12:31:08.697335369 +0900
|
||||
+++ ibus-1.4.0/src/ibusproperty.c 2012-01-04 12:58:07.191725794 +0900
|
||||
@@ -218,6 +218,17 @@ ibus_property_class_init (IBusPropertyCl
|
||||
static void
|
||||
ibus_property_init (IBusProperty *prop)
|
||||
{
|
||||
+ prop->key = NULL;
|
||||
+ prop->type = 0;
|
||||
+ prop->label = NULL;
|
||||
+ prop->icon = NULL;
|
||||
+ prop->tooltip = NULL;
|
||||
+ prop->sensitive = FALSE;
|
||||
+ prop->visible = FALSE;
|
||||
+ prop->state = 0;
|
||||
+
|
||||
+ prop->sub_props = NULL;
|
||||
+
|
||||
prop->priv = IBUS_PROPERTY_GET_PRIVATE (prop);
|
||||
|
||||
ibus_property_set_label (prop, NULL);
|
||||
@@ -308,6 +319,27 @@ ibus_property_get_property (IBusProperty
|
||||
static void
|
||||
ibus_property_destroy (IBusProperty *prop)
|
||||
{
|
||||
+ g_free (prop->key);
|
||||
+ prop->key = NULL;
|
||||
+
|
||||
+ g_free (prop->icon);
|
||||
+ prop->icon = NULL;
|
||||
+
|
||||
+ if (prop->label) {
|
||||
+ g_object_unref (prop->label);
|
||||
+ prop->label = NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (prop->tooltip) {
|
||||
+ g_object_unref (prop->tooltip);
|
||||
+ prop->tooltip = NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (prop->sub_props) {
|
||||
+ g_object_unref (prop->sub_props);
|
||||
+ prop->sub_props = NULL;
|
||||
+ }
|
||||
+
|
||||
g_free (prop->priv->key);
|
||||
prop->priv->key = NULL;
|
||||
|
||||
@@ -494,6 +526,17 @@ ibus_property_set_label (IBusProperty *p
|
||||
g_assert (IBUS_IS_PROPERTY (prop));
|
||||
g_return_if_fail (label == NULL || IBUS_IS_TEXT (label));
|
||||
|
||||
+ if (prop->label) {
|
||||
+ g_object_unref (prop->label);
|
||||
+ }
|
||||
+
|
||||
+ if (label == NULL) {
|
||||
+ prop->label = ibus_text_new_from_static_string ("");
|
||||
+ }
|
||||
+ else {
|
||||
+ prop->label = g_object_ref_sink (label);
|
||||
+ }
|
||||
+
|
||||
if (prop->priv->label) {
|
||||
g_object_unref (prop->priv->label);
|
||||
}
|
||||
@@ -512,6 +555,9 @@ ibus_property_set_icon (IBusProperty *pr
|
||||
{
|
||||
g_assert (IBUS_IS_PROPERTY (prop));
|
||||
|
||||
+ g_free (prop->icon);
|
||||
+ prop->icon = g_strdup (icon != NULL ? icon : "");
|
||||
+
|
||||
g_free (prop->priv->icon);
|
||||
prop->priv->icon = g_strdup (icon != NULL ? icon : "");
|
||||
}
|
||||
@@ -525,6 +571,19 @@ ibus_property_set_tooltip (IBusProperty
|
||||
|
||||
IBusPropertyPrivate *priv = prop->priv;
|
||||
|
||||
+ if (prop->tooltip) {
|
||||
+ g_object_unref (prop->tooltip);
|
||||
+ }
|
||||
+
|
||||
+ if (tooltip == NULL) {
|
||||
+ prop->tooltip = ibus_text_new_from_static_string ("");
|
||||
+ g_object_ref_sink (prop->tooltip);
|
||||
+ }
|
||||
+ else {
|
||||
+ prop->tooltip = tooltip;
|
||||
+ g_object_ref_sink (prop->tooltip);
|
||||
+ }
|
||||
+
|
||||
if (priv->tooltip) {
|
||||
g_object_unref (priv->tooltip);
|
||||
}
|
||||
@@ -544,6 +603,7 @@ ibus_property_set_sensitive (IBusPropert
|
||||
gboolean sensitive)
|
||||
{
|
||||
g_assert (IBUS_IS_PROPERTY (prop));
|
||||
+ prop->sensitive = sensitive;
|
||||
prop->priv->sensitive = sensitive;
|
||||
}
|
||||
|
||||
@@ -552,6 +612,7 @@ ibus_property_set_visible (IBusProperty
|
||||
gboolean visible)
|
||||
{
|
||||
g_assert (IBUS_IS_PROPERTY (prop));
|
||||
+ prop->visible = visible;
|
||||
prop->priv->visible = visible;
|
||||
}
|
||||
|
||||
@@ -564,6 +625,7 @@ ibus_property_set_state (IBusProperty *
|
||||
state == PROP_STATE_CHECKED ||
|
||||
state == PROP_STATE_INCONSISTENT);
|
||||
|
||||
+ prop->state = state;
|
||||
prop->priv->state = state;
|
||||
}
|
||||
|
||||
@@ -576,6 +638,19 @@ ibus_property_set_sub_props (IBusPropert
|
||||
|
||||
IBusPropertyPrivate *priv = prop->priv;
|
||||
|
||||
+ if (prop->sub_props) {
|
||||
+ g_object_unref (prop->sub_props);
|
||||
+ }
|
||||
+
|
||||
+ if (prop_list) {
|
||||
+ prop->sub_props = prop_list;
|
||||
+ g_object_ref_sink (prop_list);
|
||||
+ }
|
||||
+ else {
|
||||
+ prop->sub_props = ibus_prop_list_new ();
|
||||
+ g_object_ref_sink (prop->sub_props);
|
||||
+ }
|
||||
+
|
||||
if (priv->sub_props) {
|
||||
g_object_unref (priv->sub_props);
|
||||
}
|
||||
--- ibus-1.4.0/src/ibusproperty.h.orig 2012-01-04 12:30:52.189069565 +0900
|
||||
+++ ibus-1.4.0/src/ibusproperty.h 2012-01-04 12:34:38.101706419 +0900
|
||||
@@ -140,6 +140,20 @@ typedef struct _IBusPropListClass IBusPr
|
||||
struct _IBusProperty {
|
||||
/*< private >*/
|
||||
IBusSerializable parent;
|
||||
+
|
||||
+ /*< public >*/
|
||||
+ gchar *key;
|
||||
+ gchar *icon;
|
||||
+ IBusText *label;
|
||||
+ IBusText *tooltip;
|
||||
+
|
||||
+ gboolean sensitive;
|
||||
+ gboolean visible;
|
||||
+ guint type;
|
||||
+ guint state;
|
||||
+
|
||||
+ IBusPropList *sub_props;
|
||||
+
|
||||
IBusPropertyPrivate *priv;
|
||||
|
||||
gpointer pdummy[7];
|
11
ibus.spec
11
ibus.spec
@ -33,7 +33,7 @@
|
||||
|
||||
Name: ibus
|
||||
Version: 1.4.0
|
||||
Release: 16%{?dist}
|
||||
Release: 17%{?dist}
|
||||
Summary: Intelligent Input Bus for Linux OS
|
||||
License: LGPLv2+
|
||||
Group: System Environment/Libraries
|
||||
@ -55,6 +55,7 @@ Patch91: ibus-gjs-xx-gnome-shell-3.1.4-build-failure.patch
|
||||
# Workaround to disable preedit on gnome-shell until bug 658420 is fixed.
|
||||
# https://bugzilla.gnome.org/show_bug.cgi?id=658420
|
||||
Patch92: ibus-xx-g-s-disable-preedit.patch
|
||||
Patch93: ibus-771115-property-compatible.patch
|
||||
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
|
||||
@ -214,6 +215,10 @@ mv data/ibus.schemas.in data/ibus.schemas.in.in
|
||||
%patch3 -p1 -b .bridge-key
|
||||
%patch4 -p1 -b .setup-frequent-lang
|
||||
|
||||
%if 0%{?fedora} <= 16
|
||||
%patch93 -p1 -b .compat
|
||||
%endif
|
||||
|
||||
%build
|
||||
%if %have_libxkbfile
|
||||
XKB_PRELOAD_LAYOUTS=\
|
||||
@ -435,6 +440,10 @@ fi
|
||||
%{_datadir}/gtk-doc/html/*
|
||||
|
||||
%changelog
|
||||
* Wed Jan 04 2012 Takao Fujiwara <tfujiwar@redhat.com> - 1.4.0-17
|
||||
- Added ibus-771115-property-compatible.patch for f16
|
||||
Fixed Bug 771115 - IBusProperty back compatibility.
|
||||
|
||||
* Fri Dec 30 2011 Takao Fujiwara <tfujiwar@redhat.com> - 1.4.0-16
|
||||
- Enhanced ibus-gnome3 shell lookup window.
|
||||
- Updated ibus-HEAD.patch from upstream
|
||||
|
Loading…
Reference in New Issue
Block a user