[ibus-libpinyin] Fixes ibus-libpinyin upstream issue #33

Peng Wu pwu at fedoraproject.org
Mon Mar 9 05:29:18 UTC 2015


commit 9299cc400692a90971192e272a29f6549b7f8b72
Author: Peng Wu <alexepico at gmail.com>
Date:   Mon Mar 9 13:28:12 2015 +0800

    Fixes ibus-libpinyin upstream issue #33

 ibus-libpinyin-1.7.x-head.patch | 92 +++++++++++++++++++++++++++++++++++++++++
 ibus-libpinyin.spec             |  7 +++-
 2 files changed, 97 insertions(+), 2 deletions(-)
---
diff --git a/ibus-libpinyin-1.7.x-head.patch b/ibus-libpinyin-1.7.x-head.patch
index e69de29..960f360 100644
--- a/ibus-libpinyin-1.7.x-head.patch
+++ b/ibus-libpinyin-1.7.x-head.patch
@@ -0,0 +1,92 @@
+From e64b6ec09ec934e506d566174ac6524c61336228 Mon Sep 17 00:00:00 2001
+From: Peng Wu <alexepico at gmail.com>
+Date: Fri, 6 Mar 2015 15:34:43 +0800
+Subject: [PATCH 1/2] fixes shortcut keys in setup dialog
+
+---
+ setup/main2.py          | 6 +++---
+ setup/shortcuteditor.py | 2 ++
+ 2 files changed, 5 insertions(+), 3 deletions(-)
+
+diff --git a/setup/main2.py b/setup/main2.py
+index 20a2dac..0103804 100644
+--- a/setup/main2.py
++++ b/setup/main2.py
+@@ -437,12 +437,12 @@ class PreferencesDialog:
+         self.__shortcut_editor.set_orientation(Gtk.Orientation.VERTICAL)
+         self.__shortcut_editor.show()
+ 
+-        # set shortcuts
+-        self.__shortcut_editor.update_shortcuts(self.__values)
+-
+         # connect "shortcut-changed" signal
+         self.__shortcut_editor.connect("shortcut-changed", self.__shortcut_changed_cb)
+ 
++        # set shortcuts
++        self.__shortcut_editor.update_shortcuts(self.__values)
++
+     def __shortcut_changed_cb(self, editor, key, value):
+         self.__set_value(key, value)
+ 
+diff --git a/setup/shortcuteditor.py b/setup/shortcuteditor.py
+index 3ef76f1..fafb3c5 100644
+--- a/setup/shortcuteditor.py
++++ b/setup/shortcuteditor.py
+@@ -215,6 +215,8 @@ class ShortcutEditor(Gtk.Box):
+         for label, keyname, defvalue in accelerators:
+             value = values[keyname] if keyname in values else defvalue
+             self.__shortcut_treeview.set_shortcut_value(keyname, value)
++            # store the default value
++            self.emit_shortcut_changed(keyname, value)
+ 
+ class ShortcutEditorDialog(Gtk.Dialog):
+     def __init__(self, title = None, transient_for = None, flags = 0):
+-- 
+2.1.0
+
+
+From cc5b6765c3ce22fc7876a48c2ffc292cae6aceb0 Mon Sep 17 00:00:00 2001
+From: Peng Wu <alexepico at gmail.com>
+Date: Mon, 9 Mar 2015 13:21:40 +0800
+Subject: [PATCH 2/2] fixes default values
+
+---
+ src/PYConfig.cc  | 5 +++++
+ src/PYPConfig.cc | 5 +++++
+ 2 files changed, 10 insertions(+)
+
+diff --git a/src/PYConfig.cc b/src/PYConfig.cc
+index ca419ce..4a3c0a7 100644
+--- a/src/PYConfig.cc
++++ b/src/PYConfig.cc
+@@ -64,6 +64,11 @@ Config::initDefaultValues (void)
+     m_special_phrases = TRUE;
+ 
+     m_dictionaries = "2";
++
++    m_main_switch = "<Shift>";
++    m_letter_switch = "";
++    m_punct_switch = "<Control>period";
++    m_trad_switch = "<Control><Shift>f";
+ }
+ 
+ 
+diff --git a/src/PYPConfig.cc b/src/PYPConfig.cc
+index ff897ea..b33038a 100644
+--- a/src/PYPConfig.cc
++++ b/src/PYPConfig.cc
+@@ -110,6 +110,11 @@ LibPinyinConfig::initDefaultValues (void)
+     m_special_phrases = TRUE;
+ 
+     m_dictionaries = "2";
++
++    m_main_switch = "<Shift>";
++    m_letter_switch = "";
++    m_punct_switch = "<Control>period";
++    m_trad_switch = "<Control><Shift>f";
+ }
+ 
+ static const struct {
+-- 
+2.1.0
+
diff --git a/ibus-libpinyin.spec b/ibus-libpinyin.spec
index 24c49c2..81e2b29 100644
--- a/ibus-libpinyin.spec
+++ b/ibus-libpinyin.spec
@@ -1,8 +1,8 @@
-%global snapshot 0
+%global snapshot 1
 
 Name:       ibus-libpinyin
 Version:    1.7.0
-Release:    1%{?dist}
+Release:    2%{?dist}
 Summary:    Intelligent Pinyin engine based on libpinyin for IBus
 License:    GPLv2+
 Group:      System Environment/Libraries
@@ -88,6 +88,9 @@ make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
 %{_datadir}/ibus/component/*
 
 %changelog
+* Mon Mar  9 2015 Peng Wu <pwu at redhat.com> - 1.7.0-2
+- Fixes ibus-libpinyin upstream issue #33
+
 * Wed Mar  4 2015 Peng Wu <pwu at redhat.com> - 1.7.0-1
 - Update to 1.7.0
 


More information about the scm-commits mailing list