@@ -242,6 +242,10 @@ def update_project_view(self) -> None:
242
242
# because we don't want validation errors going off while editing the model is in-progress
243
243
self .draft_project : dict = create_draft_project (self .parent_model .project )
244
244
245
+ for tab in self .tabs :
246
+ self .view_tabs [tab ].update_model (self .draft_project )
247
+ self .edit_tabs [tab ].update_model (self .draft_project )
248
+
245
249
self .absorption_checkbox .setChecked (self .parent_model .project .absorption )
246
250
self .calculation_type .setText (self .parent_model .project .calculation )
247
251
self .model_type .setText (self .parent_model .project .model )
@@ -252,10 +256,6 @@ def update_project_view(self) -> None:
252
256
self .model_combobox .setCurrentText (self .parent_model .project .model )
253
257
self .geometry_combobox .setCurrentText (self .parent_model .project .geometry )
254
258
255
- for tab in self .tabs :
256
- self .view_tabs [tab ].update_model (self .draft_project )
257
- self .edit_tabs [tab ].update_model (self .draft_project )
258
-
259
259
self .handle_tabs ()
260
260
self .handle_controls_update ()
261
261
@@ -460,11 +460,6 @@ def update_model(self, new_model):
460
460
table .update_model (classlist )
461
461
if self .edit_mode :
462
462
table .edit ()
463
- if "layers" in self .tables :
464
- self .tables ["layers" ].set_absorption (new_model ["absorption" ])
465
- if "contrasts" in self .tables :
466
- self .tables ["contrasts" ].set_domains (new_model ["calculation" ] == Calculations .Domains )
467
-
468
463
469
464
def handle_controls_update (self , controls ):
470
465
"""Reflect changes to the Controls object."""
0 commit comments