[Vimperator] [patch] Mappings refactoring
Виктор
Виктор
Mon May 28 23:45:37 PDT 2007
В вт, 2007-05-29 в 00:57 +0200, Martin Stubenschrott написа:
> On Sun, May 27, 2007 at 03:15:08PM +0300, Виктор Кожухаров wrote:
> > actually, don't add it. I'll add it later, so that you can look at it
> > (it won't break anything since it won't be used yet)
>
I reverted the flags so that the first one starts at 1 << 1.
> Ok, now I looked at it more closely and it really looks good.
>
> There are only a few things I marked with XXX: in the repo for now,
> which should be changed public->private.
> Apart from that, the most challenging part now would be the integration
> into the keyhandling code. For this to work, the API needs to be
> slightly changed to return an array of partial commands.
>
> I propose to add a third argument to:
> this.get = function(mode, cmd)
> to make it:
> this.get = function(mode, cmd, partial)
>
> If "partial" is given and true, it should _always_ return an array of
> commands (with 0,1 or more entries), which start with cmd. Or do you
> have an better idea or better name for "partial"?
btw, the hint commands will also have to be changed to be objects. but
don't use strings to store a function and then eval it, since it's
slower than a closure. As for the two flags afterwards (what is their
name, and what do they do exactly?), when they are added to the flags
attribute, make them start from 1 << 10. That way we won't need to
change them if we need to add more global flags later on.
>
> --
> Martin
> _______________________________________________
> Vimperator mailing list
> Vimperator at mozdev.org
> http://www.mozdev.org/mailman/listinfo/vimperator
--
Виктор Кожухаров /Viktor Kojouharov/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: =?UTF-8?Q?=D0=A2=D0=BE=D0=B2=D0=B0?= =?UTF-8?Q?_=D0=B5?=
=?UTF-8?Q?_=D1=86=D0=B8=D1=84=D1=80=D0=BE=D0=B2=D0=BE?=
=?UTF-8?Q?_=D0=BF=D0=BE=D0=B4=D0=BF=D0=B8=D1=81=D0=B0=D0=BD=D0=B0?=
=?UTF-8?Q?_=D1=87=D0=B0=D1=81=D1=82?= =?UTF-8?Q?_=D0=BE=D1=82?=
=?UTF-8?Q?_=D0=BF=D0=B8=D1=81=D0=BC=D0=BE=D1=82=D0=BE?=
Url : http://www.mozdev.org/pipermail/vimperator/attachments/20070529/49022deb/attachment.bin
More information about the Vimperator
mailing list