HomePhabricator
Diffusion MITK bb415ef6e788

FocusManager::GetNext() selects next visible renderer

Description

FocusManager::GetNext() selects next visible renderer

The renderers do not provide a function to check the visibility, so
here the size of the renderer is checked. If the renderer size is set
to 0 x 0 then it is considered not visible, otherwise it is visible.

Although this seems to be bad cheating, it is good practice to set
the size of the renderer to 0 x 0 when it is not visible (e.g. removed
from the layout), otherwise VTK will try to re-render the window
content even it is not visible, that is unnecessary and it results
ugly warnings on Mac. Similarly, when a renderer is displayed again
(added to a layout in Qt) then its size should be set to the size of
the containing widget.

Signed-off-by: Miklos Espak <m.espak@ucl.ac.uk>

Details

Provenance
espakAuthored on Jun 30 2014, 6:08 PM
Parents
rMITKb74eb09956aa: Focus moved to next renderer only if the deleted renderer has got the focus
Branches
Unknown
Tags
Unknown