Mercurial > mamba
changeset 266:190aa1481908
Add forced_click method to buttons
author | Neil Muller <drnlmuller@gmail.com> |
---|---|
date | Thu, 15 Sep 2011 12:53:52 +0200 |
parents | 74ae1645df6e |
children | 1e8dca95c48a |
files | mamba/widgets/base.py |
diffstat | 1 files changed, 7 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/mamba/widgets/base.py Thu Sep 15 12:24:05 2011 +0200 +++ b/mamba/widgets/base.py Thu Sep 15 12:53:52 2011 +0200 @@ -88,6 +88,13 @@ return True return False + def forced_click(self): + """Force calling the clicked handler""" + for callback, args in self.callbacks['clicked']: + if callback(None, self, *args): + return True + return False + class Container(Widget):