Page MenuHomePhabricator

ILifecycleAwarePart to notify views if they are visible or not is not working
Closed, WontfixPublic

Description

E.g. the segmentation view is always active and toggles datanodes, even if it is not visible anymore.
I tested if the methods (activated, visible, invisible, etc.) are used at all and they are never accessed, no matter what you do with the view.

Event Timeline

neher triaged this task as High priority.Dec 5 2017, 12:15 PM
neher created this task.
kislinsk lowered the priority of this task from High to Normal.
kislinsk added a subscriber: kislinsk.

Using the current master I can debug and access the functions

void QmitkSegmentationView::Visible()
{}

void QmitkSegmentationView::Hidden()
{}

void QmitkSegmentationView::Activated()
{}

void QmitkSegmentationView::Deactivated()
{}

However, they do not contain any logic.
What do you mean by toggles datanodes; selecting nodes automatically due to the auto selection property?

selecting nodes automatically due to the auto selection property?

Yes. The auto selection should not be done if the view is not visible.

This should be handled in the method mentioned above, as it is for example done in the image statistics view. Nevertheless, on linux these methods are never entered (current master). This probably also causes T23972.

I tried it now with the current master using Ubuntu 16.04.
I am able to load two images, create a segmentation node for each image and toggle the node selection via auto-selection.

I temporarily added a m_Visible variable, that is correctly set to true/false in the Visible() / Hidden() functions and checked in the OnSelectionChanged-function.
Then, when the segmentation plugin view is hidden by another view, the node selection does not change anymore automatically, when (de-)selecting nodes in the data storage.

I tried it again with the current master using Ubuntu 18.04.
I still have no problems debugging into the mentioned functions.

I still see your problem with the auto selection not deactivated when the view is hidden, but before we fix this with the m_Visible variable, could you recheck if you can enter the mentioned methods?

kislinsk added a project: Auto-closed.

Hi there! 🙂

This task was auto-closed according to our Task Lifecycle Management.
Please follow this link for more information and don't forget that you are encouraged to reasonable re-open tasks to revive them. 🚑

Best wishes,
The MITK devs