Skip to content

Commit

Permalink
BUG: missing preset manager ui file in CMakeLists.txt
Browse files Browse the repository at this point in the history
- renamed NewPresetDialog to PresetManager
  • Loading branch information
che85 authored and lassoan committed Nov 5, 2024
1 parent bae993a commit 000bae4
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions Elastix/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ set(MODULE_PYTHON_SCRIPTS
set(MODULE_PYTHON_RESOURCES
Resources/Icons/${MODULE_NAME}.png
Resources/UI/${MODULE_NAME}.ui
Resources/UI/PresetManager.ui
)

set(REGISTRATION_PARAMETER_FILES
Expand Down
6 changes: 3 additions & 3 deletions Elastix/Elastix.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,12 +218,12 @@ def updateGUIFromParameterNode(self, caller=None, event=None):
self._updatingGUIFromParameterNode = False

def onCreatePresetPressed(self):
from ElastixLib.manager import NewPresetDialog
dialog = NewPresetDialog()
from ElastixLib.manager import PresetManagerDialog
dialog = PresetManagerDialog()

returnCode = dialog.exec_()
while returnCode not in [qt.QDialog.Accepted, qt.QDialog.Rejected]:
dialog = NewPresetDialog()
dialog = PresetManagerDialog()
returnCode = dialog.exec_()

if returnCode == qt.QDialog.Accepted:
Expand Down
4 changes: 2 additions & 2 deletions Elastix/ElastixLib/manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def makeAction(parent, text, slot, icon=None):
return action


class NewPresetDialog:
class PresetManagerDialog:

@property
def selectionModel(self):
Expand All @@ -48,7 +48,7 @@ def __init__(self):

def setup(self):
scriptedModulesPath = os.path.dirname(slicer.util.modulePath("Elastix"))
self.widget = slicer.util.loadUI(os.path.join(scriptedModulesPath, 'Resources', "UI/NewPresetDialog.ui"))
self.widget = slicer.util.loadUI(os.path.join(scriptedModulesPath, 'Resources', "UI/PresetManager.ui"))
self.ui = slicer.util.childWidgetVariables(self.widget)

self.ui.presetSelector.addItem('')
Expand Down
File renamed without changes.

0 comments on commit 000bae4

Please sign in to comment.