Changeset 247cb58 in sasview


Ignore:
Timestamp:
Apr 15, 2010 10:57:33 AM (15 years ago)
Author:
Jae Cho <jhjcho@…>
Branches:
master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
2339249f
Parents:
8ea48a0
Message:

fixed a bug, not exiting mask panel when no model was selected.

Location:
sansview/perspectives/fitting
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • sansview/perspectives/fitting/basepage.py

    r5d81167 r247cb58  
    10351035                    # set mask    
    10361036                    is_modified = self._validate_Npts() 
    1037  
     1037                     
    10381038            else: 
    10391039                self.fitrange = False     
     
    10411041            ## if any value is modify draw model with new value 
    10421042            if not self.fitrange: 
    1043                 self.btFit.Disable() 
     1043                #self.btFit.Disable() 
    10441044                if is_2Ddata: self.btEditMask.Disable() 
    10451045            else: 
    1046                 self.btFit.Enable(True) 
     1046                #self.btFit.Enable(True) 
    10471047                if is_2Ddata: self.btEditMask.Enable(True) 
    10481048 
     
    11161116        #For invalid q range, disable the mask editor and fit button, vs.     
    11171117        if not self.fitrange: 
    1118             self.btFit.Disable() 
     1118            #self.btFit.Disable() 
    11191119            self.btEditMask.Disable() 
    11201120        else: 
    1121             self.btFit.Enable(True) 
     1121            #self.btFit.Enable(True) 
    11221122            self.btEditMask.Enable(True) 
    11231123 
  • sansview/perspectives/fitting/fitpage.py

    r2012eae r247cb58  
    11291129 
    11301130        is_valid_qrange = self._update_paramv_on_fit() 
     1131 
    11311132        if is_valid_qrange: 
     1133            # try re draw the model plot if it exists 
    11321134            self._draw_model() 
    11331135            self.panel.Destroy() # frame 
    11341136            self.set_npts2fit() 
     1137        elif self.model == None: 
     1138            self.panel.Destroy() 
     1139            self.set_npts2fit() 
     1140            msg= "No model is found on updating MASK in the model plot... " 
     1141            wx.PostEvent(self.parent.parent, StatusEvent(status = msg )) 
    11351142        else: 
    1136             msg = ' Please consider your Q range.' 
     1143            msg = ' Please consider your Q range, too.' 
    11371144            self.panel.ShowMessage(msg) 
    11381145         
Note: See TracChangeset for help on using the changeset viewer.