[pygobject] Override Gtk.IMContext.get_surrounding to not return success value
- From: Sebastian Polsterl <sebp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pygobject] Override Gtk.IMContext.get_surrounding to not return success value
- Date: Tue, 26 Oct 2010 13:49:50 +0000 (UTC)
commit 0ed2e8772bdc405b0d0c7e0b2803e0e141abcb6a
Author: Sebastian Pölsterl <sebp k-d-w org>
Date: Sat Oct 23 14:16:21 2010 +0200
Override Gtk.IMContext.get_surrounding to not return success value
gi/overrides/Gtk.py | 10 ++++++++++
1 files changed, 10 insertions(+), 0 deletions(-)
---
diff --git a/gi/overrides/Gtk.py b/gi/overrides/Gtk.py
index 40757d8..07af899 100644
--- a/gi/overrides/Gtk.py
+++ b/gi/overrides/Gtk.py
@@ -424,6 +424,16 @@ class IconView(Gtk.IconView):
IconView = override(IconView)
__all__.append('IconView')
+class IMContext(Gtk.IMContext):
+
+ def get_surrounding(self):
+ success, text, cursor_index = super(IMContext, self).get_surrounding()
+ if success:
+ return (text, cursor_index,)
+
+IMContext = override(IMContext)
+__all__.append('IMContext')
+
class TextBuffer(Gtk.TextBuffer):
def _get_or_create_tag_table(self):
table = self.get_tag_table()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]