VMware {code} Community
linlin_dl
Contributor
Contributor

How to catch the navigator click event

I have a plugin on host object. When the hostA is selected, my plugin view will display a popup windows, while this popup window have a delay, during this time, I could select to hostB, that might cause the popup windows display on the hostB view, because the contextObject is not set to null. (If the selected node from a host navigate to a cluster or VM, the _contextObject would be set to null.)

public function set contextObject(value:Object):void {
      _contextObject = IResourceReference(value);
      if (_contextObject == null) {        
         clearData();
         return;
      }

     requestData();

}

So I want to let hostA view know that now the hostB is selected(Navigated to), and hostA should be deactive, and do not popup the window.

I had try the deactive event, but it did not work.

Which event should I use or listen to? Or is there any good way to do this? My plugin is now base on Flex, but not html5.

Reply
0 Kudos
1 Reply
_vladi_
VMware Employee
VMware Employee

Hi,

It is not obvious what you are trying to achieve but it seems you are best off opening a modal dialog from your plugin view. It would essentially catch the context for which it had been invoked and not allow the user to switch the context before they close the modal.

If you meant something else please provide more info - ideally with a screenshot or by modifying the existing Flex samples.

Thanks.

Cheers,

Vladi

Reply
0 Kudos