4.2.16 (Jan 2008)

New DisplayService Interface Method: (int) getUiUpdateFreezeCount()

For optimizations when processing large collections of UI document changes, DisplayService.freezeUiUpdates(true) is provided to allow screen painting to be temporarily suspended.

The standard pattern to ensure the UI is then unfrozen appropriately is to call DisplayService.freezeUiUpdates(false) in a finally block after each DisplayService.freezeUiUpdates(true).

Since these calls can be nested, a counter is used to keep track of how many times the UI has been frozen. A freeze count of 0 is considered unfrozen and will paint every time the UI document changes.

Note: If the standard patterns is not used, it is possible for the count to go negative, which is also considered unfrozen. If the count is negative and DisplayService.freezeUiUpdates(true) is called, the UI would still not be frozen.

This method is being exposed to assist customers using nontraditional patterns, such as event driven freezing and unfreezing of the UI so they can see the underlying state of the display service freeze counter for diagnostic purposes, such as tracking down when a call to unfreeze the UI is being made without a corresponding call to freeze the UI and vice-versa.


Defects Resolved
 
9055Panel with horizontal flowLayout does not fill vertically when children do not wrap
9056flowLayout without size is not displayed correctly
9064Display service (freezeUiUpdates) enhancement