From 227ea04a300da1d0f721721a213ae76632443b90 Mon Sep 17 00:00:00 2001 From: Mason Larobina Date: Thu, 17 Dec 2009 19:29:36 +0800 Subject: New bind class that's onexec & nonarg when a bind ends in a '!'. --- examples/data/uzbl/plugins/bind.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'examples') diff --git a/examples/data/uzbl/plugins/bind.py b/examples/data/uzbl/plugins/bind.py index ee1e0c4..969dd18 100644 --- a/examples/data/uzbl/plugins/bind.py +++ b/examples/data/uzbl/plugins/bind.py @@ -169,13 +169,13 @@ class Bind(object): # Is the binding a MODCMD or KEYCMD: mod_cmd = ismodbind(glob) - # Execute the command on UPDATES or EXEC's: - on_exec = True if glob.endswith('_') else False + # Do we execute on UPDATES or EXEC events? + on_exec = True if glob[-1] in ['!', '_'] else False - # Does the command store arguments: + # Does the command take arguments? has_args = True if glob[-1] in ['*', '_'] else False - glob = glob[:-1] if has_args else glob + glob = glob[:-1] if has_args or on_exec else glob mods, glob = split_glob(glob) stack.append((on_exec, has_args, mods, glob, index)) -- cgit v1.2.3