Changeset d97dd6f in sasview for sansguiframe/src/sans


Ignore:
Timestamp:
Sep 21, 2011 6:01:53 PM (13 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:
22ce7e2
Parents:
e1a97f8
Message:

fixed a bug in delete plotpanels

Location:
sansguiframe/src/sans/guiframe
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • sansguiframe/src/sans/guiframe/gui_manager.py

    r6774d79 rd97dd6f  
    16461646            self.panel_on_focus = None 
    16471647            panel = self.panels[ID] 
     1648            self._mgr.DetachPane(panel) 
    16481649            self._plotting_plugin.delete_panel(panel.group_id) 
    1649             self._mgr.DetachPane(panel) 
    16501650            panel.Hide() 
    16511651            panel.clear() 
    16521652            panel.Close() 
     1653            if panel in self.schedule_full_draw_list: 
     1654               self.schedule_full_draw_list.remove(panel)  
    16531655            #CallAfter: make sure panel is clear before updating mgr 
    16541656            wx.CallAfter(self._mgr.Update) 
  • sansguiframe/src/sans/guiframe/local_perspectives/plotting/plotting.py

    ra48ecbd rd97dd6f  
    175175 
    176176        wx.EVT_SHOW(new_panel, self._on_close_panel) 
    177           
     177 
    178178         
    179179    def create_1d_panel(self, data, group_id): 
     
    258258            self.delete_menu_item(panel.window_caption, panel.uid) 
    259259            del self.plot_panels[group_id] 
    260             self.parent.delete_panel(uid) 
     260            #self.parent.delete_panel(uid) 
    261261            return True 
     262 
    262263        return False 
    263264     
     
    280281                return self.hide_panel(group_id) 
    281282            if event.action.lower() == 'delete': 
    282                 return self.delete_panel(group_id) 
     283                panel = self.plot_panels[group_id] 
     284                uid = panel.uid 
     285                return self.parent.delete_panel(uid) 
    283286            if event.action.lower() == "clear": 
    284287                return self.clear_panel_by_id(group_id) 
Note: See TracChangeset for help on using the changeset viewer.