Changeset 2518


Ignore:
Timestamp:
Nov 9, 2016 10:06:10 AM (5 years ago)
Author:
toby
Message:

bind for Sequential Refine in wrong place

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASII.py

    r2516 r2518  
    240240        item = parent.Append(help='', id=wx.ID_ANY, kind=wx.ITEM_NORMAL,
    241241            text='Sequential refine')
     242        self.Bind(wx.EVT_MENU, self.OnSeqRefine, id=item.GetId())
    242243        if len(self.SeqRefine): # extend state for new menus to match main (on mac)
    243244            state = self.SeqRefine[0].IsEnabled()
     
    246247        item.Enable(state)
    247248        self.SeqRefine.append(item) # save menu obj for use in self.EnableSeqRefineMenu
    248         if GSASIIpath.GetConfigValue('debug'): # allow exceptions for debugging
    249             self.Bind(wx.EVT_MENU, self.OnSeqRefine, id=item.GetId())
    250             item = parent.Append(help='', id=wx.ID_ANY, kind=wx.ITEM_NORMAL,
    251                 text='Debug graphics refresh')
    252             self.Bind(wx.EVT_MENU, self.TestResetPlot, id=item.GetId())
     249#        if GSASIIpath.GetConfigValue('debug'): # allow exceptions for debugging
     250#            item = parent.Append(help='', id=wx.ID_ANY, kind=wx.ITEM_NORMAL,
     251#                text='Debug graphics refresh')
     252#            self.Bind(wx.EVT_MENU, self.TestResetPlot, id=item.GetId())
    253253
    254254    def _init_Imports(self):
     
    38753875        '''Perform a sequential refinement.
    38763876        Called from the Calculate/Sequential refine menu.
    3877         '''       
     3877        '''
    38783878        Id = G2gd.GetPatternTreeItemId(self,self.root,'Sequential results')
    38793879        if not Id:
     
    38813881            self.PatternTree.SetItemPyData(Id,{})           
    38823882        Controls = self.PatternTree.GetItemPyData(G2gd.GetPatternTreeItemId(self,self.root, 'Controls'))
     3883        if not Controls.get('Seq Data'):
     3884            print('Error: a sequential refinement has not been set up')
     3885            return
    38833886        Controls['ShowCell'] = True
    38843887        self.OnFileSave(event)
Note: See TracChangeset for help on using the changeset viewer.