rem
stringlengths
1
322k
add
stringlengths
0
2.05M
context
stringlengths
4
228k
meta
stringlengths
156
215
self.SetScrollbars(oiLineHeight, oiLineHeight, 0, height + 1) self.refreshSplitter()
self.refreshSplitter()
def readObject(self):
746f53548fb8bb54a235b1bfa31a4bdb769818e8 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/746f53548fb8bb54a235b1bfa31a4bdb769818e8/Inspector.py
sys.stdout = ShellEditor.PseudoFileOutStore()
sys.stdout = Utils.PseudoFileOutStore()
def getModelData(self): try: code = compile(self.model.data, self.model.filename, 'exec') except: oldOut = sys.stdout sys.stdout = ShellEditor.PseudoFileOutStore() try: print "''' Code does not compile\n\n Disassembly of Traceback:\n'''" try: dis.distb(sys.exc_info()[2]) except: print "''' Could not disassemble trac...
6587664c49e92efca26bda2d489bdc19d5c58217 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/6587664c49e92efca26bda2d489bdc19d5c58217/SourceViews.py
sys.stdout = ShellEditor.PseudoFileOutStore()
sys.stdout = Utils.PseudoFileOutStore()
def getModelData(self): try: code = compile(self.model.data, self.model.filename, 'exec') except: oldOut = sys.stdout sys.stdout = ShellEditor.PseudoFileOutStore() try: print "''' Code does not compile\n\n Disassembly of Traceback:\n'''" try: dis.distb(sys.exc_info()[2]) except: print "''' Could not disassemble trac...
6587664c49e92efca26bda2d489bdc19d5c58217 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/6587664c49e92efca26bda2d489bdc19d5c58217/SourceViews.py
def defaultAction(self): self.designer.inspector.props.getNameValue('Images').propEditor.edit(None)
def designTimeSource(self): return {'width': '16', 'height': '16'}
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
self.editors.update({'Bitmap': BitmapConstrPropEdit, 'Mask': BitmapConstrPropEdit})
self.editors = {'Bitmap': BitmapConstrPropEdit, 'Mask': BitmapConstrPropEdit}
def __init__(self, name, designer, parentCompanion, ctrl): CollectionDTC.__init__(self, name, designer, parentCompanion, ctrl) self.editors.update({'Bitmap': BitmapConstrPropEdit, 'Mask': BitmapConstrPropEdit}) from Views.CollectionEdit import ImageListCollectionEditor self.CollEditorFrame = ImageListCollectionEditor
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
'mask': 'wxNullBitmap'}
'mask': 'wxNullBitmap'}
def designTimeSource(self, wId): return {'bitmap': 'wxNullBitmap', 'mask': 'wxNullBitmap'}
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
def getDisplayProp(self): value = self.textConstrLst[self.index].params[self.displayProp] if value != 'wxNullBitmap': value = os.path.basename(value[10:-21]) return value
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
class AcceleratorTableDTC(ChoicesConstr, UtilityDTC):
class AcceleratorTableDTC(ChoicesConstr, NYIDTC):
def designTimeSource(self): return {}
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'ATCollectionDTC'
def SetName(self, oldName, newName): print 'ATCollectionDTC' CollectionDTC.SetName(self, oldName, newName)
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
class ImageListImagesCDTC(ImageListImagesConstr, CollectionDTC): wxDocs = HelpCompanions.wxImageListDocs propName = 'Images' displayProp = 'bitmap' indexProp = '(None)' insertionMethod = 'Add' deletionMethod = 'Remove' def __init__(self, name, designer, parentCompanion, ctrl): CollectionDTC.__init__(self, name, design...
def applyDesignTimeDefaults(self, params): return
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
'checkable': 'false'}
'checkable': 'false'}
def designTimeSource(self, wId): newItemName = '%s%d'%(self.propName, wId) return {'id': self.newWinId(newItemName), 'item': `newItemName`, 'helpString': `newItemName`, 'checkable': 'false'}
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print name, name[:4]
def designTimeDefaults(self, vals): dtd = {} for param in vals.keys(): if param == 'menu': name = vals[param] if name[:4] == 'self': dtd[param] = self.designer.objects[name[5:]][1] elif name == 'wxMenu()': dtd[param] = wxMenu() else: print name, name[:4] raise 'Invalid menu reference' else: try: dtd[param] = eval(vals[...
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'MenuBarMenusCDTC.GetMenu'
def GetMenu(self): print 'MenuBarMenusCDTC.GetMenu' return self.textConstrLst[self.index].params['menu']
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'MenuBarMenusCDTC.SetMenu'
def SetMenu(self, value): print 'MenuBarMenusCDTC.SetMenu' self.textConstrLst[self.index].params['menu'] = value
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'OwnedCollectionDTC'
def SetName(self, oldName, newName): print 'OwnedCollectionDTC' CollectionDTC.SetName(self, oldName, newName)
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'redefined OwnedColl'
def SetName(self, oldName, newName): print 'OwnedCollectionDTC' CollectionDTC.SetName(self, oldName, newName)
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'apply constraints', self.parentCompanion.control
def applyConstraints(self): nullConstr = ['wxUnconstrained'] print 'apply constraints', self.parentCompanion.control if self.inited and len(self.textConstrLst) >= 4: constraints = wxLayoutConstraints() validConstr = 0 for constrt in self.textConstrLst: if constrt.params['rel'] not in nullConstr: validConstr = validCons...
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'appling constraints'
def applyConstraints(self): nullConstr = ['wxUnconstrained'] print 'apply constraints', self.parentCompanion.control if self.inited and len(self.textConstrLst) >= 4: constraints = wxLayoutConstraints() validConstr = 0 for constrt in self.textConstrLst: if constrt.params['rel'] not in nullConstr: validConstr = validCons...
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'adtd', otherWin
def applyConstraints(self): nullConstr = ['wxUnconstrained'] print 'apply constraints', self.parentCompanion.control if self.inited and len(self.textConstrLst) >= 4: constraints = wxLayoutConstraints() validConstr = 0 for constrt in self.textConstrLst: if constrt.params['rel'] not in nullConstr: validConstr = validCons...
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'setting attr', params
def applyConstraints(self): nullConstr = ['wxUnconstrained'] print 'apply constraints', self.parentCompanion.control if self.inited and len(self.textConstrLst) >= 4: constraints = wxLayoutConstraints() validConstr = 0 for constrt in self.textConstrLst: if constrt.params['rel'] not in nullConstr: validConstr = validCons...
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'applied constraints'
def applyConstraints(self): nullConstr = ['wxUnconstrained'] print 'apply constraints', self.parentCompanion.control if self.inited and len(self.textConstrLst) >= 4: constraints = wxLayoutConstraints() validConstr = 0 for constrt in self.textConstrLst: if constrt.params['rel'] not in nullConstr: validConstr = validCons...
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
'otherWin': 'None', 'otherEdge': 'wxLeft', 'value': '0', 'margin': '0'}
'otherWin': 'None', 'otherEdge': 'wxLeft', 'value': '0', 'margin': '0'}
def designTimeSource(self, wId): return {'rel': 'wxUnconstrained', 'otherWin': 'None', 'otherEdge': 'wxLeft', 'value': '0', 'margin': '0'}
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'append item'
def appendItem(self): print 'append item' if len(self.textConstrLst) == 4: raise 'Only 4 constraints allowed' ai = self.availableItems() if not ai: raise 'All constraints set' self.sourceObjName = '%s.%s'%(self.__class__.sourceObjName, ai[0]) OwnedCollectionDTC.appendItem(self) self.applyConstraints()
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'applying', f, self.control
def deleteItem(self, idx): # remove from ctrl if self.deletionMethod != '(None)': f = RTTI.getFunction(self.control, self.deletionMethod) print 'applying', f, self.control apply(f, [self.control, idx]) del self.textConstrLst[idx] # renumber items following deleted one if self.indexProp != '(None)': for constr in self....
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'adtd', otherWin
def applyDesignTimeDefaults(self, params): return attr = getattr(self.constraints, string.split(self.textConstrLst[self.index].comp_name, '.')[1]) params = copy.copy(params) otherWin = params['otherWin'][5:] print 'adtd', otherWin if params['otherWin'] == 'None': params = self.designTimeDefaults(params) elif self.desi...
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'setting attr', params
def applyDesignTimeDefaults(self, params): return attr = getattr(self.constraints, string.split(self.textConstrLst[self.index].comp_name, '.')[1]) params = copy.copy(params) otherWin = params['otherWin'][5:] print 'adtd', otherWin if params['otherWin'] == 'None': params = self.designTimeDefaults(params) elif self.desi...
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'GetEdge', self.index, self.textConstrLst
def GetEdge(self): print 'GetEdge', self.index, self.textConstrLst return self.textConstrLst[self.index].comp_name
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
print 'INITCOLLECTION'
def initCollection(self): print 'INITCOLLECTION' self.inited = true self.applyConstraints()
e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/e6d3b1101435c39fbaff23b10ac5d7e8db0c67f3/UtilCompanions.py
otherApp = AppModel('', self.compareTo, '', self.model.editor, true)
otherApp = AppModel('', self.compareTo, '', self.model.editor, true, {})
def refreshCtrl(self): ListCtrlView.refreshCtrl(self) from EditorModels import AppModel otherApp = AppModel('', self.compareTo, '', self.model.editor, true) otherApp.load() otherApp.readModules() i = 0
77587d659ea8cd5652cc7212a2e0d03bceb2eca4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/77587d659ea8cd5652cc7212a2e0d03bceb2eca4/AppViews.py
if not cmp(self.model.moduleFilename(module), otherFile): i = self.addReportItems(i, module, otherFile, 'changed')
try: if not cmp(self.model.moduleFilename(module), otherFile): i = self.addReportItems(i, module, otherFile, 'changed') except OSError: pass
def refreshCtrl(self): ListCtrlView.refreshCtrl(self) from EditorModels import AppModel otherApp = AppModel('', self.compareTo, '', self.model.editor, true) otherApp.load() otherApp.readModules() i = 0
77587d659ea8cd5652cc7212a2e0d03bceb2eca4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/77587d659ea8cd5652cc7212a2e0d03bceb2eca4/AppViews.py
'wxWidht', 'wxCentreX', 'wxCentreY']
'wxWidth', 'wxCentreX', 'wxCentreY']
def reverseDict(dict): rev = {} for k in dict.keys(): rev[dict[k]] = k return rev
3b4b1c029ad0dcff669b6bb449d7b67f81515e8c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/3b4b1c029ad0dcff669b6bb449d7b67f81515e8c/Enumerations.py
('Attach to debugger', self.OnAttachToDebugger, '-', ''),
def actions(self, model): actions = [ ('-', None, '', ''), ('Import module into Shell', self.OnImportInShell, '-', ''), ('Reload module in Shell', self.OnReloadInShell, '-', ''), ('-', None, '', ''), ('Set command-line parameters', self.OnSetRunParams, '-', ''), ('Run application', self.OnRunApp, self.runAppBmp, 'RunAp...
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
actions.extend([ ('NDiff modules...', self.OnDiffModules, '-', ''), ('Run PyChecker', self.OnRunPyChecker, '-', ''), ('Configure PyChecker', self.OnConfigPyChecker, '-', '')])
try: imp.find_module('pychecker') except ImportError: pass else: actions.extend([ ('Run PyChecker', self.OnRunPyChecker, '-', ''), ('Configure PyChecker', self.OnConfigPyChecker, '-', '')])
def actions(self, model): actions = [ ('-', None, '', ''), ('Import module into Shell', self.OnImportInShell, '-', ''), ('Reload module in Shell', self.OnReloadInShell, '-', ''), ('-', None, '', ''), ('Set command-line parameters', self.OnSetRunParams, '-', ''), ('Run application', self.OnRunApp, self.runAppBmp, 'RunAp...
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
wxMessageBox('Stats file date unchanged!')
wxLogError('Stats file date unchanged, check for errors in script.')
def OnProfile(self, event): model = self.getModel() if self.checkUnsaved(model): return
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
wxMessageBox('Stats file not found')
wxLogError('Stats file not found, check for errors in script.')
def OnProfile(self, event): model = self.getModel() if self.checkUnsaved(model): return
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
def OnProfile(self, event): model = self.getModel() if self.checkUnsaved(model): return
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
def OnSetRunParams(self, event): model = self.getModel() dlg = wxTextEntryDialog(self.editor, 'Parameters:', 'Command-line parameters', model.lastRunParams) try: if dlg.ShowModal() == wxID_OK: model.lastRunParams = dlg.GetValue() # update running debuggers debugging this module debugger = self.editor.debugger if debugg...
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
def OnDiffModules(self, event=None, filename=''): model = self.getModel() if model: if self.checkUnsaved(model): return if not filename: filename = self.editor.openFileDlg() if filename: filename = model.assertLocalFile(filename) tbName = 'Diff with : '+filename if not model.views.has_key(tbName): from Views.DiffView ...
def OnSwitchApp(self, event): model = self.getModel() if model and isinstance(model, PythonEditorModels.ModuleModel) and model.app: # does this ensure correct app is reconnected? appmodel, controller = self.editor.openOrGotoModule(model.app.filename)
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
import shutil shutil.copyfile(os.path.join(Preferences.pyPath, 'ExternalLib', 'PyChecker', 'pycheckrc'), appConfig)
from pychecker import Config open(appConfig, 'w').write(Config.outputRc(Config.Config()))
def OnConfigPyChecker(self, event): model = self.getModel() if model: home = os.environ.get('HOME') if home: appDir = home appConfig = home+'/.pycheckrc' else: filename = model.assertLocalFile() appDir = os.path.dirname(filename) appConfig = appDir+'/.pycheckrc' if not os.path.exists(appConfig): dlg = wxMessageDialog(s...
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
def OnAttachToDebugger(self, event): from Debugger.RemoteDialog import create rmtDlg = create(self.editor) rmtDlg.ShowModal() rmtDlg.Destroy()
def OnTabNanny(self, event): model = self.getModel() if model: model.tabnanny()
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
def runDistUtilsCmd(self, cmd): model = self.getModel() if not model.savedAs: wxLogError('Cannot run distutils on an unsaved module') return
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
Controllers.DefaultController = ModuleController Controllers.DefaultModel = PythonEditorModels.ModuleModel Controllers.defaultExt = PythonEditorModels.ModuleModel.ext
def OnSetupPy2Exe(self, event): self.runDistUtilsCmd('py2exe')
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
FileExplorer.PyFileNode.subExplorerReg['folder'].append( (FileExplorer.PyFileNode, isPackage, PythonEditorModels.PackageModel.imgIdx),
FileExplorer.FileSysNode.subExplorerReg['folder'].append( (FileExplorer.FileSysNode, isPackage, PythonEditorModels.PackageModel.imgIdx),
def isPackage(filename): return os.path.exists(os.path.join(filename, PythonEditorModels.PackageModel.pckgIdnt))
afcd711775d85646ce673c3842edbc4541c27dcc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/afcd711775d85646ce673c3842edbc4541c27dcc/PythonControllers.py
return FileExplorer.PyFileNode(os.path.basename(defaultDir), defaultDir,
return FileExplorer.FileSysNode(os.path.basename(defaultDir), defaultDir,
def newFileNode(self, defaultDir): return FileExplorer.PyFileNode(os.path.basename(defaultDir), defaultDir, None, EditorHelper.imgFolder, None, None)
193456d428be7bff1abdca013fe2d59344bc0222 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/193456d428be7bff1abdca013fe2d59344bc0222/FileDlg.py
openuri = os.path.join(uri, catFile)
if uri.startswith('zip://') and uri.endswith('.zip'): openuri = uri +'://'+ catFile else: openuri = os.path.join(uri, catFile)
def openAndHandleCategoryErrors(self, uri, catFile=''): if catFile: openuri = os.path.join(uri, catFile) else: openuri = uri
193456d428be7bff1abdca013fe2d59344bc0222 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/193456d428be7bff1abdca013fe2d59344bc0222/FileDlg.py
from Explorers import FTPExplorer
from Explorers import FTPExplorer, ZipExplorer ExplorerNodes.fileOpenDlgProtReg.append('zip')
def OnFDEndLabelEdit(self, event): newText = event.GetText() event.Skip() if newText != self.oldLabelVal:# and isinstance(self.list.node, ZopeItemNode): self.node.renameItem(self.oldLabelVal, newText) self.refreshCurrent() self.selectItemNamed(newText) self.EnsureVisible(self.selected)
193456d428be7bff1abdca013fe2d59344bc0222 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/193456d428be7bff1abdca013fe2d59344bc0222/FileDlg.py
dlg = wxBoaFileDialog(None, defaultDir='recent.files://', wildcard='BoaFiles')
dlg = wxBoaFileDialog(None, defaultDir='zip://k:\\dev\\cvsfiles\\boa\\var\\archive2.zip', wildcard='BoaFiles')
def OnFDEndLabelEdit(self, event): newText = event.GetText() event.Skip() if newText != self.oldLabelVal:# and isinstance(self.list.node, ZopeItemNode): self.node.renameItem(self.oldLabelVal, newText) self.refreshCurrent() self.selectItemNamed(newText) self.EnsureVisible(self.selected)
193456d428be7bff1abdca013fe2d59344bc0222 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/193456d428be7bff1abdca013fe2d59344bc0222/FileDlg.py
"""Quits debugging, executing only the try/finally handlers. Non-blocking and immediate. """ self._ds.stopAnywhere() if self._ds.isRunning(): self._callNoWait('set_quit', 1)
"""Attempts to quits debugging, executing only the try/finally handlers. Non-blocking. """ self._callNoWait('set_quit', 1)
def set_quit(self): """Quits debugging, executing only the try/finally handlers. Non-blocking and immediate. """ self._ds.stopAnywhere() if self._ds.isRunning(): self._callNoWait('set_quit', 1)
7ba116743abeedcee197142439f36b3cd718e2a7 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/7ba116743abeedcee197142439f36b3cd718e2a7/IsolatedDebugger.py
if not full_speed: sys.settrace(self.trace_dispatch)
def set_continue(self, full_speed=0): # Only stop at breakpoints, exceptions or when finished self.stopframe = () self.returnframe = None self.quitting = 0
7ba116743abeedcee197142439f36b3cd718e2a7 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/7ba116743abeedcee197142439f36b3cd718e2a7/IsolatedDebugger.py
return str(v)
import traceback return ''.join(traceback.format_exception_only(t, v))
def pprintVarValue(self, expr, frameno): query_frame = self.getQueryFrame(frameno) if query_frame is None: return '' else: try: v = eval(expr, query_frame.f_globals, query_frame.f_locals) return pprint.pformat(v) except: t, v = sys.exc_info()[:2] return str(v)
7ba116743abeedcee197142439f36b3cd718e2a7 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/7ba116743abeedcee197142439f36b3cd718e2a7/IsolatedDebugger.py
def dispatch_return(self, frame, arg): Bdb.dispatch_return(self, frame, arg)
def dispatch_return(self, frame, arg): Bdb.dispatch_return(self, frame, arg) # XXX this can be used as a hook to detect when a debugging session is # XXX about to stop. frame.f_back will be None # XXX For the main thread this means the end of the program, but # XXX for threads I want to transfer control (tracing) back ...
98d683861bce22c4e655b4d83e500d94450819e1 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/98d683861bce22c4e655b4d83e500d94450819e1/IsolatedDebugger.py
if isPythonScriptMetaType(filename):
if isAPythonScriptMetaType(filename):
def getFilenameAndLine(self, frame): """Returns the filename and line number for the frame. Invoked often.
c4288c63b00f4964e49fd0ff0dc0f6b3617c356b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c4288c63b00f4964e49fd0ff0dc0f6b3617c356b/ZopeScriptDebugServer.py
if code.co_name == 'interpret':
if code.co_name == 'interpret' and isATALInterpeterFrame(frame):
def getFilenameAndLine(self, frame): """Returns the filename and line number for the frame. Invoked often.
c4288c63b00f4964e49fd0ff0dc0f6b3617c356b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c4288c63b00f4964e49fd0ff0dc0f6b3617c356b/ZopeScriptDebugServer.py
if frame.f_globals.get('__name__') == TAL_INTERP_MODULE_NAME: caller = frame.f_back if caller.f_globals.get('__name__') == TAL_INTERP_MODULE_NAME: caller_name = caller.f_code.co_name source_file = None position = None if caller_name in ('do_useMacro', 'do_defineSlot'): source_file = caller.f_locals.get('saved_sourc...
se = self.stack_extra if se: info = se.get(frame, None) if info: source_file, lineno = info return source_file, lineno interp = frame.f_locals.get('self', None) source_file = interp.sourceFile position = interp.position if position: lineno = position[0] or 0 else: lineno = 0 return source_file, lineno
def getTALPosition(self, frame): """If the frame is in TALInterpreter.interpret(), detects what template was being interpreted and where, but only for specific interpreter frames. Returns the source file and line number. """ # Get TAL frames. XXX brittle in many ways. if frame.f_globals.get('__name__') == TAL_INTERP_...
c4288c63b00f4964e49fd0ff0dc0f6b3617c356b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c4288c63b00f4964e49fd0ff0dc0f6b3617c356b/ZopeScriptDebugServer.py
if frame.f_code.co_name == 'interpret':
if isATALInterpeterFrame(frame):
def getFrameNames(self, frame): """Returns the module and function name for the frame. """ if frame.f_code.co_name == 'interpret': source_file, ln = self.getTALPosition(frame) if source_file: return '', source_file.split('/')[-1] try: modname = frame.f_globals['__name__'] except KeyError: modname = '' funcname = frame....
c4288c63b00f4964e49fd0ff0dc0f6b3617c356b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c4288c63b00f4964e49fd0ff0dc0f6b3617c356b/ZopeScriptDebugServer.py
try: modname = frame.f_globals['__name__'] except KeyError: modname = '' funcname = frame.f_code.co_name return modname, funcname
return DebugServer.getFrameNames(self, frame)
def getFrameNames(self, frame): """Returns the module and function name for the frame. """ if frame.f_code.co_name == 'interpret': source_file, ln = self.getTALPosition(frame) if source_file: return '', source_file.split('/')[-1] try: modname = frame.f_globals['__name__'] except KeyError: modname = '' funcname = frame....
c4288c63b00f4964e49fd0ff0dc0f6b3617c356b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c4288c63b00f4964e49fd0ff0dc0f6b3617c356b/ZopeScriptDebugServer.py
if isPythonScriptMetaType(code.co_filename):
if isAPythonScriptMetaType(code.co_filename):
def isTraceable(self, frame): """Indicates whether the debugger should step into the given frame.
c4288c63b00f4964e49fd0ff0dc0f6b3617c356b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c4288c63b00f4964e49fd0ff0dc0f6b3617c356b/ZopeScriptDebugServer.py
code = frame.f_code if isPythonScriptMetaType(code.co_filename):
if isAPythonScriptMetaType(frame.f_code.co_filename):
def isAScriptFrame(self, frame): """Indicates whether the given frame is a high-level script frame. """ code = frame.f_code if isPythonScriptMetaType(code.co_filename): return 1 if code.co_name == 'interpret': source_file, ln = self.getTALPosition(frame) if source_file: return 1 return 0
c4288c63b00f4964e49fd0ff0dc0f6b3617c356b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c4288c63b00f4964e49fd0ff0dc0f6b3617c356b/ZopeScriptDebugServer.py
if code.co_name == 'interpret': source_file, ln = self.getTALPosition(frame) if source_file: return 1
if isATALInterpeterFrame(frame): return 1
def isAScriptFrame(self, frame): """Indicates whether the given frame is a high-level script frame. """ code = frame.f_code if isPythonScriptMetaType(code.co_filename): return 1 if code.co_name == 'interpret': source_file, ln = self.getTALPosition(frame) if source_file: return 1 return 0
c4288c63b00f4964e49fd0ff0dc0f6b3617c356b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c4288c63b00f4964e49fd0ff0dc0f6b3617c356b/ZopeScriptDebugServer.py
code = frame.f_code if code.co_name == 'interpret': source_file, ln = self.getTALPosition(frame) if source_file: interp = frame.f_locals.get('self') if interp is not None: local_vars = getattr(interp.engine, 'local_vars', {}) global_vars = getattr(interp.engine, 'global_vars', {}) return global_vars, local_vars
if isATALInterpeterFrame(frame): interp = frame.f_locals.get('self') if interp is not None: local_vars = getattr(interp.engine, 'local_vars', {}) global_vars = getattr(interp.engine, 'global_vars', {}) return global_vars, local_vars
def getFrameNamespaces(self, frame): """Returns the locals and globals for a frame. """ code = frame.f_code if code.co_name == 'interpret': source_file, ln = self.getTALPosition(frame) if source_file: # This is a TAL interpret() frame. Use special locals # and globals. interp = frame.f_locals.get('self') if interp is ...
c4288c63b00f4964e49fd0ff0dc0f6b3617c356b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c4288c63b00f4964e49fd0ff0dc0f6b3617c356b/ZopeScriptDebugServer.py
wxID_FSFILTER, wxID_FSFILTERINTMODULES ) = map(lambda x: wxNewId(), range(10))
wxID_FSFILTER, wxID_FSFILTERINTMODULES, wxID_FSFINDINFILES, wxID_FSFINDFILES, ) = map(lambda x: wxNewId(), range(12))
def renameItem(self, name, newName): if self.entries.has_key(newName): raise Exception, 'Name exists' self.entries[newName] = newName del self.entries[name] self.updateConfig()
6c33bd36ca09844a3cab4c1f7ba0f7c1dc0c1a90 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/6c33bd36ca09844a3cab4c1f7ba0f7c1dc0c1a90/FileExplorer.py
(wxID_FSBOOKMARK, 'Find', self.OnFindFSItem, self.findBmp),
(wxID_FSFINDINFILES, 'Find', self.OnFindFSItem, self.findBmp),
def __init__(self, editor, list, cvsController = None): ExplorerNodes.Controller.__init__(self, editor) ExplorerNodes.ClipboardControllerMix.__init__(self) self.editor = editor
6c33bd36ca09844a3cab4c1f7ba0f7c1dc0c1a90 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/6c33bd36ca09844a3cab4c1f7ba0f7c1dc0c1a90/FileExplorer.py
transport = Explorer.openEx(contents)
def __init__(self, data, name, editor, saved): EditorModels.SourceModel.__init__(self, data, name, editor, saved)
d32ffcf225a926ed7d3ca90276a5d24ab6ad3abc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/d32ffcf225a926ed7d3ca90276a5d24ab6ad3abc/HelpBook.plug-in.py
transport = Explorer.openEx(indexes)
def __init__(self, data, name, editor, saved): EditorModels.SourceModel.__init__(self, data, name, editor, saved)
d32ffcf225a926ed7d3ca90276a5d24ab6ad3abc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/d32ffcf225a926ed7d3ca90276a5d24ab6ad3abc/HelpBook.plug-in.py
print k, v, q
def __call__(self,*args,**kw): method=self.method if method=='PUT' and len(args)==1 and not kw: query=[args[0]] args=() else: query=[] for i in range(len(args)): try: k=self.args[i] if kw.has_key(k): raise TypeError, 'Keyword arg redefined' kw[k]=args[i] except IndexError: raise TypeError, 'Too many arguments'
909920075b4c7c64942948339968e5fe0cac522a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/909920075b4c7c64942948339968e5fe0cac522a/Client.py
sock.connect(self.host,self.port)
sock.connect( (self.host,self.port) )
def _mp_call(self,kw, type2suffix={ type(1.0): ':float', type(1): ':int', type(1L): ':long', type([]): ':list', type(()): ':tuple', } ): # Call a function using the file-upload protcol
909920075b4c7c64942948339968e5fe0cac522a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/909920075b4c7c64942948339968e5fe0cac522a/Client.py
self.m = is_constr.search(line)
self.m = is_constr_factory.search(line)
def __init__(self, line=None, comp_name='', class_name='', params=None): self.comp_name = comp_name self.class_name = class_name if params is None: self.params = {} else: self.params = params self.factory = None
102b791569b78fa95f7f4bd8ae4158ca0037b827 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102b791569b78fa95f7f4bd8ae4158ca0037b827/methodparse.py
self.class_name = self.m.group('class')
self.class_name = '' self.factory = (self.m.group('factory'), self.m.group('method'))
def __init__(self, line=None, comp_name='', class_name='', params=None): self.comp_name = comp_name self.class_name = class_name if params is None: self.params = {} else: self.params = params self.factory = None
102b791569b78fa95f7f4bd8ae4158ca0037b827 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102b791569b78fa95f7f4bd8ae4158ca0037b827/methodparse.py
self.m = is_constr_frm.search(line)
self.m = is_constr.search(line)
def __init__(self, line=None, comp_name='', class_name='', params=None): self.comp_name = comp_name self.class_name = class_name if params is None: self.params = {} else: self.params = params self.factory = None
102b791569b78fa95f7f4bd8ae4158ca0037b827 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102b791569b78fa95f7f4bd8ae4158ca0037b827/methodparse.py
self.comp_name = ''
self.comp_name = self.m.group('name')
def __init__(self, line=None, comp_name='', class_name='', params=None): self.comp_name = comp_name self.class_name = class_name if params is None: self.params = {} else: self.params = params self.factory = None
102b791569b78fa95f7f4bd8ae4158ca0037b827 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102b791569b78fa95f7f4bd8ae4158ca0037b827/methodparse.py
self.m = is_constr_factory.search(line)
self.m = is_constr_frm.search(line)
def __init__(self, line=None, comp_name='', class_name='', params=None): self.comp_name = comp_name self.class_name = class_name if params is None: self.params = {} else: self.params = params self.factory = None
102b791569b78fa95f7f4bd8ae4158ca0037b827 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102b791569b78fa95f7f4bd8ae4158ca0037b827/methodparse.py
self.comp_name = self.m.group('name') self.class_name = '' self.factory = (self.m.group('factory'), self.m.group('method'))
self.comp_name = '' self.class_name = self.m.group('class')
def __init__(self, line=None, comp_name='', class_name='', params=None): self.comp_name = comp_name self.class_name = class_name if params is None: self.params = {} else: self.params = params self.factory = None
102b791569b78fa95f7f4bd8ae4158ca0037b827 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102b791569b78fa95f7f4bd8ae4158ca0037b827/methodparse.py
print 'MR shown'
def checkError(self, err, caption, out = None): if err or out: self.esf.updateCtrls(err, out) self.esf.Show(true) print 'MR shown' return self.esf else: return None
78a9947bbb01bffbe70ea5b742160a8a20e7c270 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/78a9947bbb01bffbe70ea5b742160a8a20e7c270/ModRunner.py
dlg = ProcessProgressDlg.ProcessProgressDlg(self.editor, cmd, 'Execute module')
dlg = ProcessProgressDlg.ProcessProgressDlg(None, cmd, 'Execute module')
def run(self, cmd): import ProcessProgressDlg, ErrorStack dlg = ProcessProgressDlg.ProcessProgressDlg(self.editor, cmd, 'Execute module') try: dlg.ShowModal() serr = ErrorStack.buildErrorList(dlg.errors) if len(serr): return self.checkError(serr, 'Ran', dlg.output) else: return None
78a9947bbb01bffbe70ea5b742160a8a20e7c270 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/78a9947bbb01bffbe70ea5b742160a8a20e7c270/ModRunner.py
print l,
def run(self, cmd): from popen2import import popen3 import ErrorStack inp, outp, errp = popen3(cmd)
78a9947bbb01bffbe70ea5b742160a8a20e7c270 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/78a9947bbb01bffbe70ea5b742160a8a20e7c270/ModRunner.py
'''Build a picklable dictionary of sizes/positions and save.'''
""" Build a picklable dictionary of sizes/positions and save. """
def saveSizes(self, filename): '''Build a picklable dictionary of sizes/positions and save.''' persProps = {}
3568842cd7be7c082aec0b19a765f296c187a364 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/3568842cd7be7c082aec0b19a765f296c187a364/OGLViews.py
compn, ctrl = self.controllerView.objects[ctrlName][:2] sizer = self.objects[Utils.ctrlNameFromSrcRef(prop.params[0])][1] compn.SetSizer(sizer) self.sizerConnectList.append(prop)
if prop.prop_setter == 'SetSizer': compn, ctrl = self.controllerView.objects[ctrlName][:2] sizer = self.objects[Utils.ctrlNameFromSrcRef(prop.params[0])][1] compn.SetSizer(sizer) self.sizerConnectList.append(prop)
def initObjectsAndCompanions(self, creators, objColl, dependents, depLinks): DataView.initObjectsAndCompanions(self, creators, objColl, dependents, depLinks)
0be2c016943365e0cda9b427184aa9d38e5b00d9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/0be2c016943365e0cda9b427184aa9d38e5b00d9/SizersView.py
EventCollections.EventCategories['DatePickerCtrlEvent'] = ('wx.EVT_DATE_CHANGED')
EventCollections.EventCategories['DatePickerCtrlEvent'] = ('wx.EVT_DATE_CHANGED',)
def inspectorEdit(self): if self.value.IsValid(): PropertyEditors.BITPropEditor.inspectorEdit(self)
7a5043c9f452d32ca6acdc5be09febf80af030f8 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/7a5043c9f452d32ca6acdc5be09febf80af030f8/DateTimeCompanions.py
except NameError:
except AttributeError:
def events(self): return BaseCompanions.WindowDTC.events(self) + ['DatePickerCtrlEvent']
7a5043c9f452d32ca6acdc5be09febf80af030f8 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/7a5043c9f452d32ca6acdc5be09febf80af030f8/DateTimeCompanions.py
locals = codeBlock.localnames() if name in locals:
if name in codeBlock.locals:
def getNameSig(self, name, method, module, codeBlock=None): if codeBlock: locals = codeBlock.localnames() if name in locals: objType = codeBlock.locals[name].objtype res = self.getTypeSig(objType, method, module) if res is not None: return res if name in module.globals: objType = module.globals[name].signature res = se...
0df8901faaa945bd36510b4a339f64decaa407d8 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/0df8901faaa945bd36510b4a339f64decaa407d8/PySourceView.py
locals = codeBlock.localnames() if name in locals:
if name in codeBlock.locals:
def getNameAttribs(self, name, module, codeBlock=None): if codeBlock: locals = codeBlock.localnames() if name in locals: objType = codeBlock.locals[name].objtype res = self.getTypeAttribs(objType, module) if res is not None: return res if name in module.globals: objType = module.globals[name].signature res = self.getTy...
0df8901faaa945bd36510b4a339f64decaa407d8 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/0df8901faaa945bd36510b4a339f64decaa407d8/PySourceView.py
def goto(self): # XXX What if page has been closed, notification self.modulePage.focus() self.modulePage.model.views[self.view].gotoBrowseMarker(self.marker)
c3729460957d832c9a645a0f5114f37d51e945a4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c3729460957d832c9a645a0f5114f37d51e945a4/Browse.py
def add(self, modulepage, view, marker): page = HistoryBrowsePage(modulepage, view, marker) if self.idx == len(self.pages)-1: self.pages.append(page) else: self.pages[self.idx:] = [page] self.idx = len(self.pages)-1
c3729460957d832c9a645a0f5114f37d51e945a4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c3729460957d832c9a645a0f5114f37d51e945a4/Browse.py
if idx < self.idx:
if idx <= self.idx:
def checkRemoval(self, modPage): for page in self.pages[:]: if page.modulePage == modPage: idx = self.pages.index(page) if idx < self.idx: self.idx = self.idx - 1 del self.pages[idx]
c3729460957d832c9a645a0f5114f37d51e945a4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c3729460957d832c9a645a0f5114f37d51e945a4/Browse.py
def forward(self):
c3729460957d832c9a645a0f5114f37d51e945a4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c3729460957d832c9a645a0f5114f37d51e945a4/Browse.py
def back(self):
c3729460957d832c9a645a0f5114f37d51e945a4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/c3729460957d832c9a645a0f5114f37d51e945a4/Browse.py
def designTimeSource(self, position = 'wxDefaultPosition', size = 'wxDefaultSize'):
def designTimeSource(self, position='wxDefaultPosition', size='wxDefaultSize'):
def designTimeSource(self, position = 'wxDefaultPosition', size = 'wxDefaultSize'): return {'pos': position, 'size': size, 'style': 'wxLC_ICON', 'validator': 'wxDefaultValidator', 'name': `self.name`}
bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553/ListCompanions.py
'validator': 'wxDefaultValidator',
def designTimeSource(self, position = 'wxDefaultPosition', size = 'wxDefaultSize'): return {'pos': position, 'size': size, 'style': 'wxLC_ICON', 'validator': 'wxDefaultValidator', 'name': `self.name`}
bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553/ListCompanions.py
self.names = {'Format': formatStyle}
def __init__(self, name, designer, parentCompanion, ctrl): CollectionDTC.__init__(self, name, designer, parentCompanion, ctrl) self.editors = {'Width': IntConstrPropEdit, 'Heading': StrConstrPropEdit, 'Format': EnumConstrPropEdit}#StyleConstrPropEdit}
bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553/ListCompanions.py
'validator': 'wxDefaultValidator',
def designTimeSource(self, position = 'wxDefaultPosition', size = 'wxDefaultSize'): return {'pos': position, 'size': size, 'style': 'wxTR_HAS_BUTTONS', 'validator': 'wxDefaultValidator', 'name': `self.name`}
bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553/ListCompanions.py
'validator': 'wxDefaultValidator',
def designTimeSource(self, position = 'wxDefaultPosition', size = 'wxDefaultSize'): return {'pos': position, 'size': size, 'choices': '[]', 'style': '0', 'validator': 'wxDefaultValidator', 'name': `self.name`}
bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553/ListCompanions.py
'Style': 'style', 'Validator': 'validator', 'Name': 'name'}
'Style': 'style', 'Name': 'name'}
def constructor(self): return {'Label': 'label', 'Position': 'point', 'Size': 'size', 'Choices': 'choices', 'MajorDimension': 'majorDimension', 'Style': 'style', 'Validator': 'validator', 'Name': 'name'}
bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553/ListCompanions.py
'validator': 'wxDefaultValidator',
def designTimeSource(self, position = 'wxDefaultPosition', size = 'wxDefaultSize'): return {'label': `self.name`, 'point': position, 'size': size, 'choices': `['asd']`, 'majorDimension': '1', 'style': 'wxRA_SPECIFY_COLS', 'validator': 'wxDefaultValidator', 'name': `self.name`}
bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/bf2d0fc28ac1c46bdc6f0710c24fe8c632cc2553/ListCompanions.py
if event.GetId() == dsgn.GetId() and dsgn.selection: dsgn.selection.selectCtrl(dsgn, dsgn.companion)
if event.GetId() == dsgn.GetId(): if dsgn.selection: dsgn.selection.selectCtrl(dsgn, dsgn.companion) elif dsgn.multiSelection: dsgn.clearMultiSelection() dsgn.assureSingleSelection() dsgn.selection.selectCtrl(dsgn, dsgn.companion) return
def OnControlResize(self, event): """ Control is resized, emulate native wxWindows layout behaviour """ dsgn = self.designer try: if event.GetId() == dsgn.GetId() and dsgn.selection: dsgn.selection.selectCtrl(dsgn, dsgn.companion)
102ae9e4df0cfddbfdb2acfb7df920a5d291af8c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102ae9e4df0cfddbfdb2acfb7df920a5d291af8c/Designer.py
def addDepLink(self, prop, name, dependents, depLinks): # XXX dependents does not seem to be used anymore ????
102ae9e4df0cfddbfdb2acfb7df920a5d291af8c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102ae9e4df0cfddbfdb2acfb7df920a5d291af8c/Designer.py
if self.selection: self.selection.selectNone()
if self.selection: self.selection.selectNone() self.selection = None elif self.multiSelection: for sel in self.multiSelection: sel.selectNone() sel.destroy() self.multiSelection = []
def selectNone(self): if self.selection: self.selection.selectNone()
102ae9e4df0cfddbfdb2acfb7df920a5d291af8c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102ae9e4df0cfddbfdb2acfb7df920a5d291af8c/Designer.py
pos = wxPoint(SelectionTags.granularise(pos.x), SelectionTags.granularise(pos.y))
def selectControlByPos(self, ctrl, pos, multiSelect): """ Handle selection of a control from a users click of creation of a new one if a component was selected on the palette. Some ctrls do not register clicks, the click is then picked up from the parent which checks if a click intersects any child regions. For effici...
102ae9e4df0cfddbfdb2acfb7df920a5d291af8c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102ae9e4df0cfddbfdb2acfb7df920a5d291af8c/Designer.py
for y in range(sze.y / sg): for x in range(sze.x / sg):
for y in range(sze.y / sg + 1): for x in range(sze.x / sg + 1):
def drawGrid_dots(self, dc, sze, sg): pen1 = wxPen(wxNamedColour('BLACK')) dc.SetPen(pen1) for y in range(sze.y / sg): for x in range(sze.x / sg): dc.DrawPoint(x * sg, y * sg)
102ae9e4df0cfddbfdb2acfb7df920a5d291af8c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102ae9e4df0cfddbfdb2acfb7df920a5d291af8c/Designer.py
def OnRecreateSelected(self, event): """ Recreate the current selection by cutting and pasting it. The clipboard is not disturbed. This is useful for applying changes to constructor parameters """ if self.selection and self.selection.selection != self: output = [] ctrlName = self.selection.name # XXX Boa should be able...
102ae9e4df0cfddbfdb2acfb7df920a5d291af8c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102ae9e4df0cfddbfdb2acfb7df920a5d291af8c/Designer.py
sel = self.selection if sel and sel.selection != self: sel.position.x = sel.position.x - 1 sel.startPos.x = sel.startPos.x - 1 sel.resizeCtrl() sel.setSelection()
for sel in self.getSelAsList(): if sel.selection != self: sel.position.x = sel.position.x - 1 sel.startPos.x = sel.startPos.x - 1 self.moveUpdate(sel)
def OnMoveLeft(self, event): sel = self.selection if sel and sel.selection != self: sel.position.x = sel.position.x - 1 sel.startPos.x = sel.startPos.x - 1 sel.resizeCtrl() sel.setSelection()
102ae9e4df0cfddbfdb2acfb7df920a5d291af8c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/102ae9e4df0cfddbfdb2acfb7df920a5d291af8c/Designer.py