Forums | developer.brewmp.com Forums | developer.brewmp.com

Developer

Forums

Forums:

As I know, IDisplay has two status, enabled & disabled. I think when I create a IDisplay, its status is "enabled" right? Then when is it going to be disabled? Is it when the Application that have made the IDisplay is stopped? suspended?

Another question: How to verify which Application is owner of a IDisplay?

Each app has a default display object created for it, and this display object is associated with the primary display. Access to a display may be disabled when an app obtains an IDisplay interface. IDisplay_IsEnabled() is provided to allow an app to determine whether is has access to the display. An app may also register for notification of the display becoming enabled or disabled with IDisplay_NotifyEnable(). Displays become enabled and disabled differently for the primary display and all other displays. For the primary display, this happens synchronously with a suspend or resume event, so the notification will happen immediately before EVT_APP_RESUME and immediately after EVT_APP_SUSPEND. Coming to next question:- Top visible application gets the access of IDisplay. As only one application can be top visible(foreground app) so it only will be owner of display object.

Each app has a default display object created for it, and this display object is associated with the primary display. Access to a display may be disabled when an app obtains an IDisplay interface. IDisplay_IsEnabled() is provided to allow an app to determine whether is has access to the display. An app may also register for notification of the display becoming enabled or disabled with IDisplay_NotifyEnable(). Displays become enabled and disabled differently for the primary display and all other displays. For the primary display, this happens synchronously with a suspend or resume event, so the notification will happen immediately before EVT_APP_RESUME and immediately after EVT_APP_SUSPEND. Coming to next question:- Top visible application gets the access of IDisplay. As only one application can be top visible(foreground app) so it only will be owner of display object.