Skip to content

Commit

Permalink
Added extra redundancy to ensure correct acquire ui is shown after pr…
Browse files Browse the repository at this point in the history
…otocol

Merge pull request #387 from EtalumaSupport/dovydas_dev3
  • Loading branch information
dovydasv2 authored Aug 21, 2024
2 parents 969ded8 + c255a33 commit 73f6d2d
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions lumaviewpro.py
Original file line number Diff line number Diff line change
Expand Up @@ -3627,6 +3627,7 @@ def _is_protocol_valid(self) -> bool:

def _autofocus_run_complete_callback(self, **kwargs):
live_histo_reverse()
reset_acquire_ui()
self._reset_run_autofocus_scan_button()

# Copy the Z-heights from the autofocus scan into the protocol
Expand Down Expand Up @@ -3705,6 +3706,7 @@ def _scan_run_complete(self, **kwargs):
self._reset_run_scan_button()
create_hyperstacks_if_needed()
live_histo_reverse()
reset_acquire_ui()


def run_scan_from_ui(self):
Expand Down Expand Up @@ -3752,6 +3754,7 @@ def _protocol_run_complete(self, **kwargs):
self._reset_run_protocol_button()
live_histo_reverse()
create_hyperstacks_if_needed()
reset_acquire_ui()


def run_protocol_from_ui(self):
Expand Down Expand Up @@ -4896,6 +4899,15 @@ def update_shader(self, dt):
else:
lumaview.ids['viewer_id'].update_shader('none')

def reset_acquire_ui():
for layer in common_utils.get_layers():
if settings[layer]['acquire'] == "image":
lumaview.ids['imagesettings_id'].ids[layer].ids['acquire_image'].active = True
elif settings[layer]['acquire'] == "video":
lumaview.ids['imagesettings_id'].ids[layer].ids['acquire_video'].active = True
else:
lumaview.ids['imagesettings_id'].ids[layer].ids['acquire_none'].active = True

# Z Stack functions class
# ---------------------------------------------------------------------
class ZStack(CompositeCapture):
Expand Down

0 comments on commit 73f6d2d

Please sign in to comment.