[kupu-dev] Object notation change in kupubasetools.js

Duncan Booth duncan.booth at suttoncourtenay.org.uk
Tue Jun 3 15:43:30 CEST 2008


Guido Wesdorp <johnny at johnnydebris.net> wrote:

> Hi!
> 
> When I had to dig around in kupubasetools.js a bit, I found that the 
> object notation used there was rather old - methods were defined in-line 
> rather than on the prototype. This is not optimal, although I think in 
> Kupu the impact is rather minimal since objects are instantiated only 
> once, looks a bit ugly and, most importantly, is inconsistent with new 
> code written for Kupu. On these grounds I decided to update the file, 
> change the 'old-style' objects so that methods are set on the prototypes 
> rather than directly on the objects.
> 
> I've tested Kupu stand-alone (common/kupu.html) and in Silva, and the 
> changes don't seem to break anything there (after fixing some closure 
> issues), but I'm afraid that it may break some other code (e.g. Plone). 
> Please test if everything still works as expected (mostly regarding 
> subclassing), if not see if a rollback to revision 55491 helps and 
> notify me of the problem so I can try to fix...
> 
I'll see if I can check your changes. I seem to remember I thought about 
doing that some time back but the closure issues made it hard to do cleanly 
(I think that was mostly in the drawer code though rather than 
kupubasetools).




More information about the kupu-dev mailing list