Skip to content

Commit

Permalink
Skipping extra Iq evaluation by not calling draw_model function from …
Browse files Browse the repository at this point in the history
…set polydisperisty parameters routine, ref #624 and #576
  • Loading branch information
wpotrzebowski authored and wpotrzebowski committed Oct 8, 2016
1 parent 2abe6bf commit 47f2b5d
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/sas/sasgui/perspectives/fitting/basepage.py
Original file line number Diff line number Diff line change
Expand Up @@ -1037,7 +1037,6 @@ def set_model_state(self, state):
n = self.disp_box.GetCurrentSelection()
dispersity = self.disp_box.GetClientData(n)
name = dispersity.__name__

self._set_dipers_Param(event=None)

if name == "ArrayDispersion":
Expand Down Expand Up @@ -2289,7 +2288,11 @@ def _set_dipers_Param(self, event):
event = PageInfoEvent(page=self)
wx.PostEvent(self.parent, event)
#draw the model with the current dispersity
self._draw_model()

#Wojtek P, Oct 8, 2016: Calling draw_model seems to be unessecary.
#By comenting it we save an extra Iq calculation
#self._draw_model()

## Need to use FitInside again here to replace the next four lines.
## Otherwised polydispersity off does not resize the scrollwindow.
## PDB Nov 28, 2015
Expand Down

0 comments on commit 47f2b5d

Please sign in to comment.