Posts: 246
Threads: 38
Joined: May 2007
I'm in the process of a complete interface redesign and before I go too far I have some generic questions about how overlays function. First, is there any issue with having multiple overlay areas on a template in terms of performance or useability? I'm considering 4 separate overlays on one template two of which I'd like to have interact with each other.
Let's assume I have two overlay areas on the template (overlay1 and overlay2). Is it possible to load a new template into overlay1 based on a button in overlay1? What about a button in overlay1 template causing a new template to load in overlay2?
I know I can load new templates into an overlay based on command buttons on a template but I am trying to determine if it is possible for buttons on existing overlay templates to load new templates in either the original overlay or a different one. I guess I'm looking for the ability to have anything call anything regardless of where it is located. Fat chance huh?
Posts: 3,415
Threads: 158
Joined: Jan 2006
1.) To load a new template into an overlay using a button on the template in that same overlay use the IntfViewer::LoadNewTemplate command.
2.) To load a new template in Overlay2 from a template in Overlay1 use the IntfViewer::LoadSiblingOverlay.
Posts: 246
Threads: 38
Joined: May 2007
In my original post I questioned performance of multiple overlays and it appears doing this is fairly slow on a very fast PC. I'm not looking forward to seeing what it's like on a Sammy.
I suppose slow is a relative term. It probably takes about a second to load two sibling overlays but this has a very slow look to it. Can overlays be loaded into a container based on some global variable on the base template? If so that might be faster than making a call to load several overlays based on a button click.
Posts: 40,483
Threads: 491
Joined: Aug 2002
There shouldn't be anything inherently slow about loading overlays. If they load slowly then probably everything is running slowly for some reason. They will though load sequentially. I.e. one has to download its template and initialize, then the next one, and so on.
Dean Roddey
Explorans limites defectum
Posts: 246
Threads: 38
Joined: May 2007
I think that is what I'm seeing and it just looks slow. What about loading several overlays on the base template and hiding them until needed. Could these be tied to states to become visible or invisible based on a field value? This would tie one template to each overlay and then cycle the overlay container and not the overlay template based on the value of the field.
I'm just trying to get things to look a little more responsive and I know there have to be some tricks to do this. The initial load time of the base template with all the extra overlay containers is not important.
Posts: 40,483
Threads: 491
Joined: Aug 2002
You could certainly mark the overlays as initially invisible and then in the OnLoad of the parent template, as the last thing you do there, make them visible.
And, when you say they take a few seconds, do you mean to visibly display, or to get device state info displayed?
Dean Roddey
Explorans limites defectum
Posts: 246
Threads: 38
Joined: May 2007
I suppose it is a combination of both. I'm trying to fill two different overlays one of which has data linked to a driver field and the other does not. But in all cases one will have device state info and the other may or may not.
Is device state info populated on an overlay template if the container is loaded but not visible?
Posts: 40,483
Threads: 491
Joined: Aug 2002
dgeffs Wrote:Is device state info populated on an overlay template if the container is loaded but not visible?
Yeh, it's all still be loaded and being gotten ready, even if not visible.
Dean Roddey
Explorans limites defectum