From 61904cd18b1d9d20b40fd249f5eafdc622a40691 Mon Sep 17 00:00:00 2001 From: anekos Date: Mon, 1 Mar 2010 12:21:42 +0000 Subject: 補完が見づらいので、extra.literal を設定 git-svn-id: http://svn.coderepos.org/share/lang/javascript/vimperator-plugins/trunk@36872 d0d07461-0603-4401-acd4-de1884942a52 --- tombloo.js | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) (limited to 'tombloo.js') diff --git a/tombloo.js b/tombloo.js index 59345cb..44d28c6 100644 --- a/tombloo.js +++ b/tombloo.js @@ -52,13 +52,14 @@ with (tomblooService) { commands.addUserCommand( ['tomblooAction'], 'Execute Tombloo actions', - function (arg) { - let f = Tombloo.Service.actions[arg.string]; + function (args) { + let f = Tombloo.Service.actions[args.literalArg]; (f instanceof Function) ? f.execute() - : liberator.echoerr(arg.string + ' is not Tombloo Action.'); + : liberator.echoerr(args.literalArg + ' is not Tombloo Action.'); }, { + literal: 0, completer: function (context) { context.title = ['Tombloo Actions']; @@ -76,17 +77,14 @@ commands.addUserCommand( ['tombloo'], 'Post by Tombloo', function (args) { - //let f = Tombloo.Service.extractors[args.string]; - let arg = args.string.replace(/\\(?=\u0020)/g, ''); - liberator.log(args.string, 0); - liberator.log(arg, 0); - - let f = Tombloo.Service.extractors[arg]; + liberator.log(args.literalArg, 0); + let f = Tombloo.Service.extractors[args.literalArg]; (typeof f === 'object') ? Tombloo.Service.share(getContext(), f, args.bang) : liberator.echoerr(args.string + ' is not Tombloo command'); }, { + literal: 0, bang: true, completer: function (context) { context.title = ['Tombloo']; -- cgit v1.2.3