--- rxvt-unicode/src/perl/selection-pastebin 2012/09/04 22:41:12 1.22 +++ rxvt-unicode/src/perl/selection-pastebin 2014/05/17 15:48:29 1.24 @@ -1,7 +1,7 @@ #! perl -#:META:X_RESOURCE:%.cmd:string:the command to run create a new pastebin -#:META:X_RESOURCE:%.url:string:the url template for new pastebins +#:META:RESOURCE:%.cmd:string:the command to run create a new pastebin +#:META:RESOURCE:%.url:string:the url template for new pastebins =head1 NAME @@ -115,12 +115,11 @@ () } -sub on_user_command { - my ($self, $cmd) = @_; +sub on_action { + my ($self, $action) = @_; - if ($cmd eq "selection-pastebin:remote-pastebin") { - $self->upload_paste; - } + $action eq "remote-pastebin" + and $self->upload_paste; () }