diff options
author | Huang Peng <shawn.p.huang@gmail.com> | 2008-06-18 17:40:51 +0800 |
---|---|---|
committer | Huang Peng <shawn.p.huang@gmail.com> | 2008-06-18 17:40:51 +0800 |
commit | b79cab04739d6896f62e8257a0155b9c2a1193ce (patch) | |
tree | 481736a07bc0d4b3c9e2d675a099718c9c303114 /ibus/object.py | |
parent | 69150f225cd8de1886b82e103dd196677706cfeb (diff) | |
download | ibus-b79cab04739d6896f62e8257a0155b9c2a1193ce.tar.gz ibus-b79cab04739d6896f62e8257a0155b9c2a1193ce.tar.xz ibus-b79cab04739d6896f62e8257a0155b9c2a1193ce.zip |
Only send destroy signal one time.
Diffstat (limited to 'ibus/object.py')
-rw-r--r-- | ibus/object.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/ibus/object.py b/ibus/object.py index af6a0fe..e250b0c 100644 --- a/ibus/object.py +++ b/ibus/object.py @@ -8,7 +8,13 @@ class Object (gobject.GObject): ()) } + def __init__ (self): + gobject.GObject.__init__ (self) + self._destroyed = False + def destroy (self): - self.emit ("destroy") + if not self._destroyed: + self.emit ("destroy") + self._destroyed = True gobject.type_register (Object) |