|
ProgrammingModel
Please follow this...
IntroductionPowerWindows applies to very ancient wisdoms and philosophy. Details
PowerWindows is dynamic. From any release to another anything is allowed to change - except the static interfaces of the portalMan and masterControl Objects. There are three important GLOBAL Object you will meet in the PW system:
The very simpliest rule you need to follow to build a smooth running system is to never instantiate anything! Use the global Namespaces and their static methods only.
Featured Methods to usePortal Manager Runtime
The very basic method to access the masterControl Object. This will create the Singleton masterControl Object for you in the first place(therefore will consume run - time). Afterwards you will always get the (one and only) instance of the mc. This will certainly boot your portal by loading some additional scripts. masterControlThe Brain.
On the fly changing the skin of your windows (Titlebar and Footer) by overwriting the style classname with your own classname. The portal uses a central style sheet (window12.css). Provide your own and name your classes with a suffix that suits your project. For example copy the window12.css and rename the window12 style with your name let's say 'bgcc'. Then append bgcc to any objects that end with '12'. Use hd12bgcc instead of hd12, ft12bgcc instead of ft12. The strCustomExt is therefore set to 'bgcc' in your case. For a sample have a look in your assets folder there is a file 'custom_bgcc.css' that will give you an idea of what is meant here. Provide Header and Footer heights in iHeaderHeight/iFooterHeight arguments. Most important is to set the strCSSUrl to the path (URI or URL) so that it gets loaded into the portal.
Load content from a URL into a window. Use the argument bNewWindow to control wether a new window is opened (in the grid not a new browser window). Similar to requestContent but will create always a new Window that IS NOT bound to the grid. The new Window will be fully draggable to any place on the canvas without being snapped to the grid layout. Identical to requestContent but capable to load any HTML code into a Window. This method you would use to load flash content into a Window. Ah, ye this one. Well, imagine that. This function would turn a certain DIV element from your DOM into a Window. It will 'hook' the content and put it into a Window frame and snap it to grid. The strSIM argument will control where the Window will show up. Values here depend on your layout. Usually you will have (top, left, center, right) for your choices. See the (infamous) veri Folder of your installation directory there is a sample HTML for this.
I don't think you will need this - it will inform the masterControl instance to adjust its layout - will reposition all windows. Just in case you loaded the logger snapIn. This will dump to the logger. Load any compatible snapIn from any source into the portal. |
Sign in to add a comment