Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delay setupLayers to LayerGui being shown #2858

Merged
merged 1 commit into from
May 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion ilastik/applets/layerViewer/layerViewerGui.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ def __init__(

self._stopped = False
self._initialized = False
self._need_update = True
self.__cleanup_fns = []

self.threadRouter = ThreadRouter(self) # For using @threadRouted
Expand Down Expand Up @@ -211,7 +212,6 @@ def __init__(

def _after_init(self):
self._initialized = True
self.updateAllLayers()

def setNeedUpdate(self, slot=None):
self._need_update = True
Expand Down
2 changes: 2 additions & 0 deletions ilastik/workflows/carving/carvingGui.py
Original file line number Diff line number Diff line change
Expand Up @@ -613,6 +613,8 @@
def _update_colors(self):
"""Update colors of objects in 3D viewport"""
op = self.topLevelOperatorView
if not self._shownObjects3D.items():
return

Check warning on line 617 in ilastik/workflows/carving/carvingGui.py

View check run for this annotation

Codecov / codecov/patch

ilastik/workflows/carving/carvingGui.py#L617

Added line #L617 was not covered by tests
ctable = self._doneSegmentationLayer.colorTable

for name, label in self._shownObjects3D.items():
Expand Down