2011/7/22 thron7 <[email protected]>

> I think I get what you're up against. Of course I'm not in your shoes, but
> I wouldn't be so shy if I were. This is an almost mechanical refactoring.
> What will you do when you have real tough refac's to do, that involve
> conceptual/architectural changes?! You wrote you just migrated your app to
> qooxdoo 1.5, so you have to fix all kinds of issues anyway. A good
> opportunity to do some clean-up :-).
>

Yeah, you can't imagine how much I will like to refactor it, but as you know
releases always have a limit date and I have no time to make refactoring. If
I could update to qooxdoo 1.5 it's because the migration change were
minimal, do you think there will be many hidden bugs because the migration?
=S


> > I cant convert it to a static class because the developer than creates
> > basefile.js used the base namespace as class, I mean the source is like:
>
> > myapp/
> >   source/
> >     class/
> >       myapp/
> >         ui/
> >           Window.js
> >         Message.js
> >       myapp.js
>
> Why don't you just move this into the myapp folder, and christen it, say,
> myapp.Myapp:
>
> qx.Class.define("myapp.Myapp", {
>
>  statics : {
>
> >   init: function() { ... },
> >   callServer: function() { ... },
> >   getMessageBus: function() { ... },
> >   ...
>  }
> });
>
> It has a finite number of methods, so it's just a matter of doing for each
> a global search-replace over the code base, e.g. of the form
>
>     s/myapp.init/myapp.Myapp.init/
>

Yeah, I thinked this way, but I think I can't do so huge change (its the
application main class, used everywhere) without autorization so until
Monday I will not know if this will be possible, anyway I am not very
optimist about this.


>
> > myapp.init();
> > myapp.callServer();
> > myapp.getMessageBus()
>
> > And I cannot change the code because the functions are used so many times
> > inside the code and the code is like 5MB when compressed so I hope you
> > understand I cannot make a replace-in-files without breaking something I
> > dont know.
> >
>
> So you have 5MB code, compressed. Let's suppose each of the methods are
> called 500 times in the entire code base. - So what?! Replacing them
> individually makes the change very precise, little chance for misses or
> false positives. It's mechanical.


I hope so, but there are many changes than in theory doesn't have a rason to
fail but they do, I will try this way at the weekend  to see if it really is
so easy and if it is i thoght it will be easier to get autorization to
change the class location.


> > And also like:
> >
> > new myapp.ui.Window();
> > new myapp.Message();
>
> Those won't get hurt. And if there are actually a few issues you should be
> able to sort them out quickly by hand. If you're super-nervous you can do
> it step-wise, keep the old basefile.js and migrate one method at a time,
> test, fix, then the next.
>
> > If there is some way to tell qooxdoo to compile a file called as the
> > library
> > namespace this will be great to me, but I did not found a way to do it.
>
> No, that's not a good idea. Rather, move it into the name space.
>

You're right, I hope your idea work fine, thank you so much for your time!


> Good luck,
> T.
>
>
>
>
> ------------------------------------------------------------------------------
> 10 Tips for Better Web Security
> Learn 10 ways to better secure your business today. Topics covered include:
> Web security, SSL, hacker attacks & Denial of Service (DoS), private keys,
> security Microsoft Exchange, secure Instant Messaging, and much more.
> http://www.accelacomm.com/jaw/sfnl/114/51426210/
> _______________________________________________
> qooxdoo-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
>
------------------------------------------------------------------------------
Storage Efficiency Calculator
This modeling tool is based on patent-pending intellectual property that
has been used successfully in hundreds of IBM storage optimization engage-
ments, worldwide.  Store less, Store more with what you own, Move data to 
the right place. Try It Now! http://www.accelacomm.com/jaw/sfnl/114/51427378/
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to