Changes in / [aa4b4f05:e42c8e9d] in sasview
- Location:
- src/sas/sasgui/perspectives/fitting
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/sasgui/perspectives/fitting/basepage.py
rcf2e6b4 rc8e1996 52 52 FONT_VARIANT = 1 53 53 ON_MAC = True 54 54 55 55 56 class BasicPage(ScrolledPanel, PanelBase): … … 1456 1457 self.state_change = True 1457 1458 self._draw_model() 1458 # Time delay has been introduced to prevent _handle error1459 # on Windows1460 # This part of code is executed when model is selected and1461 # it's parameters are changed (with respect to previously1462 # selected model). There are two Iq evaluations occuring one1463 # after another and therefore there may be compilation error1464 # if model is calculated for the first time.1465 # This seems to be Windows only issue - haven't tested on Linux1466 # though.The proper solution (other than time delay) requires1467 # more fundemental code refatoring1468 # Wojtek P. Nov 7, 20161469 if not ON_MAC:1470 time.sleep(0.1)1471 1459 self.Refresh() 1472 1460 … … 2403 2391 2404 2392 # Redraw the model 2405 # Wojtek P. Nov 7, 2016: Redrawing seems to be unnecessary here 2406 # self._draw_model() 2393 self._draw_model() 2407 2394 # self._undo.Enable(True) 2408 2395 event = PageInfoEvent(page=self) -
src/sas/sasgui/perspectives/fitting/fitpage.py
rbf44249e rc8e1996 81 81 flag = check_data_validity(self.data) & (self.model is not None) 82 82 self.btFit.Enable(flag) 83 83 84 84 def on_set_focus(self, event): 85 85 """ 86 Override the basepage focus method to ensure the save flag is set 86 Override the basepage focus method to ensure the save flag is set 87 87 properly when focusing on the fit page. 88 88 """ … … 238 238 239 239 weighting_set_box = wx.StaticBox(self, wx.ID_ANY, 240 240 'Set Weighting by Selecting dI Source') 241 241 weighting_box = wx.StaticBoxSizer(weighting_set_box, wx.HORIZONTAL) 242 242 sizer_weighting = wx.BoxSizer(wx.HORIZONTAL) … … 1164 1164 if event is not None: 1165 1165 if (event.GetEventObject() == self.formfactorbox 1166 and self.structurebox.GetLabel() != 'None')\1167 or event.GetEventObject() == self.structurebox\1168 or event.GetEventObject() == self.multifactorbox:1166 and self.structurebox.GetLabel() != 'None')\ 1167 or event.GetEventObject() == self.structurebox\ 1168 or event.GetEventObject() == self.multifactorbox: 1169 1169 copy_flag = self.get_copy_params() 1170 1170 is_poly_enabled = self.enable_disp.GetValue() … … 1205 1205 self._keep.Enable(not self.batch_on) 1206 1206 self._set_save_flag(True) 1207 #Setting smearing for cases with and without data. 1208 self._set_smear(self.data) 1207 self._set_smear(self.data) 1209 1208 1210 1209 # more disables for 2D … … 1213 1212 try: 1214 1213 # update smearer sizer 1215 #This call for smearing set up caused double evaluation of 1216 #I(q) and double compilation as results 1217 #self.onSmear(None) 1214 self.onSmear(None) 1218 1215 temp_smear = None 1219 1216 if not self.disable_smearer.GetValue(): … … 1229 1226 # set smearing value whether or not data contain the smearing info 1230 1227 evt = ModelEventbox(model=self.model, 1231 1232 1233 1234 1235 1236 1228 smearer=temp_smear, 1229 enable_smearer=not self.disable_smearer.GetValue(), 1230 qmin=float(self.qmin_x), 1231 uid=self.uid, 1232 caption=self.window_caption, 1233 qmax=float(self.qmax_x)) 1237 1234 1238 1235 self._manager._on_model_panel(evt=evt) -
src/sas/sasgui/perspectives/fitting/fitting.py
re0d9ed2 rec72ceb 864 864 enable1D=enable1D, enable2D=enable2D, 865 865 qmin=qmin, qmax=qmax, weight=weight) 866 self._mac_sleep(0.2) 866 867 867 868 def _mac_sleep(self, sec=0.2): … … 1965 1966 ## May need rethinking 1966 1967 ## 1967 ## -PDB August 12, 2014 1968 ## -PDB August 12, 2014 1968 1969 while self.calc_1D.isrunning(): 1969 1970 time.sleep(0.1)
Note: See TracChangeset
for help on using the changeset viewer.