PDA

View Full Version : Multiple Window Application



bereal
23 Oct 2008, 12:57 AM
Hello there.

Currently I am developing business application with the power of ExtJS framework under the Adobe AIR platform. Everything works just fine, I am very satisfied with the perfomance. But I am still not sure about one thing:

I have multi-window application, which means that there is a root window and other windows can also be opened. And I am talking about the really native windows, not ExtJS ones - they look very pretty but cant be dragged out of the area of containing nativeWindow. As my application will be used on multi monitor systems, I need to open new windows as nativeWindow instances.

The issue is in ExtJS (or even jQuery?) core code. The perfect situation which I was trying to get is to have all core code in the root window of the application and use it to manage other windows. It would make opening of new windows much faster and would eat less memory. But unfortunately it seems to be impossible in the current version of ExtJS (or jQuery?). Simple example - there is a lot of document.createElement calls without mentioning the window.

So I have to load all ExtJS code (500k+) and CSS in every opened window, which adds about 10-20 Mb of memory which is used by air application. Its not crytical for the moment but makes me think about this issue more and more.

Does anyone have any ideas or experience about this issue?

digitalkaoz
3 Nov 2008, 1:54 AM
i had the same problems...and ended up in reconstruction my app so it fits in one native window...the other way makes more problems than benefits

bereal
3 Nov 2008, 2:01 AM
At the moment I open small dialogs as ExtJS windows but big ones as nativeWindow.

I will see how it works and maybe will do the same as you

funkadelic
4 Dec 2008, 10:46 AM
you can reference other windows with something like this...

for example, if you want to control a particular window that is a Ext.air.NativeWindow(), you could do something along these lines:


Ext.air.NativeWindowManager.get('windowId').loader.window.someJsFunctionInThatWindow();

this will reference a javascript function in a window with id "windowId"