diff options
author | Tom Feist <shabble@metavore.org> | 2010-10-06 22:34:52 +0000 |
---|---|---|
committer | Tom Feist <shabble@metavore.org> | 2010-10-06 22:34:52 +0000 |
commit | 7b1700479745a48379fecd44d5a07a4436cb0444 (patch) | |
tree | 185848577421d45eb8ded8f3ae8f9e73bed71ab1 | |
parent | fixed a bug causing prompt to not get updated properly, and added a nasty compat (diff) | |
download | irssi-scripts-7b1700479745a48379fecd44d5a07a4436cb0444.tar.gz irssi-scripts-7b1700479745a48379fecd44d5a07a4436cb0444.zip |
fixed priorities (-1) and position (100) of prompt statusbars
-rw-r--r-- | prompt_info/prompt_replace.pl | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/prompt_info/prompt_replace.pl b/prompt_info/prompt_replace.pl index 350d74f..3055afc 100644 --- a/prompt_info/prompt_replace.pl +++ b/prompt_info/prompt_replace.pl @@ -284,8 +284,9 @@ sub replace_prompt_items { # add the new one. _sbar_command('prompt', 'add', 'uberprompt', - qw/-alignment left -before input -priority 0/); + qw/-alignment left -before input -priority '-1'/); + _sbar_command('prompt', 'position', '100'); } sub restore_prompt_items { @@ -295,9 +296,12 @@ sub restore_prompt_items { print "Restoring original prompt" if DEBUG; _sbar_command('prompt', 'add', 'prompt', - qw/-alignment left -before input -priority 0/); + qw/-alignment left -before input -priority '-1'/); _sbar_command('prompt', 'add', 'prompt_empty', - qw/-alignment left -after prompt -priority 0/); + qw/-alignment left -after prompt -priority '-1'/); + + _sbar_command('prompt', 'position', '100'); + } sub _sbar_command { @@ -305,7 +309,7 @@ sub _sbar_command { my $args_str = join ' ', @args; - $args_str .= ' ' if length $args_str; + $args_str .= ' ' if length $args_str && defined $item; my $command = sprintf 'STATUSBAR %s %s %s%s', $bar, $cmd, $args_str, defined($item)?$item:''; |