Changeset bf39777 in sasview for sansguiframe/src/sans
- Timestamp:
- Oct 19, 2011 11:39:21 AM (13 years ago)
- 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:
- f6933b8
- Parents:
- 46c4ccb
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sansguiframe/src/sans/guiframe/data_panel.py
r66f7016 rbf39777 138 138 self.tree_ctrl_theory = None 139 139 self.perspective_cbox = None 140 ## Create context menu for page 141 self.data_menu = None 140 142 141 143 self.owner = None … … 358 360 NewBatchEvent(enable=True)) 359 361 362 def on_edit_data(self, event): 363 """ 364 Pop Up Data Editor 365 """ 366 print "Edit Data" 367 360 368 def layout_data_list(self): 361 369 """ … … 366 374 self.tree_ctrl = DataTreeCtrl(parent=self, style=wx.SUNKEN_BORDER) 367 375 self.tree_ctrl.Bind(CT.EVT_TREE_ITEM_CHECKING, self.on_check_item) 376 self.tree_ctrl.Bind(CT.EVT_TREE_ITEM_MENU, self.on_right_click) 377 ## Create context menu for page 378 self.data_menu = wx.Menu() 379 id = wx.NewId() 380 name = "Edit" 381 msg = "Edit the current Data" 382 self.data_menu.Append(id, name, msg) 383 wx.EVT_MENU(self, id, self.on_edit_data) 384 368 385 tree_ctrl_theory_label = wx.StaticText(self, -1, "Theory") 369 386 tree_ctrl_theory_label.SetForegroundColour('blue') … … 377 394 self.sizer1.Add(self.tree_ctrl_theory, 1, wx.EXPAND|wx.ALL, 10) 378 395 396 397 def on_right_click(self, event): 398 """ 399 Allow Editing Data 400 """ 401 print "on_right_click" 402 if self.data_menu is not None: 403 self.PopupMenu(self.data_menu) 404 379 405 def onContextMenu(self, event): 380 406 """
Note: See TracChangeset
for help on using the changeset viewer.