From: Kevin A. <ka...@us...> - 2004-05-10 00:45:35
|
Update of /cvsroot/pythoncard/PythonCard/tools/resourceEditor In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16543/tools/resourceEditor Modified Files: resourceEditor.py Log Message: removed Stack class, changed self.stack.app references to self.application changed childWindow, Background, and CustomDialog inits so stack arg isn't passed in. only did minimal testing of tools and samples Index: resourceEditor.py =================================================================== RCS file: /cvsroot/pythoncard/PythonCard/tools/resourceEditor/resourceEditor.py,v retrieving revision 1.192 retrieving revision 1.193 diff -C2 -d -r1.192 -r1.193 *** resourceEditor.py 9 May 2004 19:46:25 -0000 1.192 --- resourceEditor.py 10 May 2004 00:45:24 -0000 1.193 *************** *** 77,81 **** if wx.Platform == '__WXMSW__': ! path = os.path.join(self.stack.app.applicationDirectory, 'images', 'sizingHandle.bmp') sizingHandleTemplate = {'type':'ImageButton', 'name':'topLeft', --- 77,81 ---- if wx.Platform == '__WXMSW__': ! path = os.path.join(self.application.applicationDirectory, 'images', 'sizingHandle.bmp') sizingHandleTemplate = {'type':'ImageButton', 'name':'topLeft', *************** *** 87,91 **** elif wx.Platform == '__WXMAC__': #self.resizingHandleColor = (0,0,128) ! path = os.path.join(self.stack.app.applicationDirectory, 'images', 'sizingHandle.bmp') sizingHandleTemplate = {'type':'Image', 'name':'topLeft', --- 87,91 ---- elif wx.Platform == '__WXMAC__': #self.resizingHandleColor = (0,0,128) ! path = os.path.join(self.application.applicationDirectory, 'images', 'sizingHandle.bmp') sizingHandleTemplate = {'type':'Image', 'name':'topLeft', *************** *** 125,129 **** self.alignToGrid = self.menuBar.getChecked('menuOptionsAlignToGrid') ! path = os.path.join(self.stack.app.applicationDirectory, 'templates', \ RESOURCE_TEMPLATE) self.rsrc = resource.ResourceFile(path).getResource() --- 125,129 ---- self.alignToGrid = self.menuBar.getChecked('menuOptionsAlignToGrid') ! path = os.path.join(self.application.applicationDirectory, 'templates', \ RESOURCE_TEMPLATE) self.rsrc = resource.ResourceFile(path).getResource() *************** *** 177,181 **** log.info('resourceEditor filename: ' + filename) if not os.path.exists(filename): ! filename = os.path.abspath(os.path.join(self.stack.app.startingDirectory, sys.argv[1])) if os.path.isfile(filename): if filename.endswith('rsrc.py'): --- 177,181 ---- log.info('resourceEditor filename: ' + filename) if not os.path.exists(filename): ! filename = os.path.abspath(os.path.join(self.application.startingDirectory, sys.argv[1])) if os.path.isfile(filename): if filename.endswith('rsrc.py'): *************** *** 366,371 **** if target.name not in self.sizingHandleNames: self.startName = target.name ! if self.stack.app.pw is not None: ! self.stack.app.pw.selectComponentsList(target.name, target.__class__.__name__) # KEA 2002-02-23 self.propertyEditorWindow.selectComponentList(target.name, target.__class__.__name__) --- 366,371 ---- if target.name not in self.sizingHandleNames: self.startName = target.name ! if self.application.pw is not None: ! self.application.pw.selectComponentsList(target.name, target.__class__.__name__) # KEA 2002-02-23 self.propertyEditorWindow.selectComponentList(target.name, target.__class__.__name__) *************** *** 694,698 **** self.resetAndClearWidgets() if self.filename is None: ! path = os.path.join(self.stack.app.applicationDirectory, 'templates', \ RESOURCE_TEMPLATE) self.rsrc = resource.ResourceFile(path).getResource() --- 694,698 ---- self.resetAndClearWidgets() if self.filename is None: ! path = os.path.join(self.application.applicationDirectory, 'templates', \ RESOURCE_TEMPLATE) self.rsrc = resource.ResourceFile(path).getResource() *************** *** 712,716 **** def getNewFileTemplates(self): ! templatesDir = os.path.join(self.stack.app.applicationDirectory, 'templates') fileList = os.listdir(templatesDir) #fileList.sort() --- 712,716 ---- def getNewFileTemplates(self): ! templatesDir = os.path.join(self.application.applicationDirectory, 'templates') fileList = os.listdir(templatesDir) #fileList.sort() *************** *** 849,854 **** self.startSize = (0, 0) self.offset = (0, 0) ! if self.stack.app.pw is not None: ! self.stack.app.pw.selectComponentsList('topLeft', 'ImageButton') # KEA 2002-02-23 self.propertyEditorWindow.clearComponentList() --- 849,854 ---- self.startSize = (0, 0) self.offset = (0, 0) ! if self.application.pw is not None: ! self.application.pw.selectComponentsList('topLeft', 'ImageButton') # KEA 2002-02-23 self.propertyEditorWindow.clearComponentList() *************** *** 918,925 **** self.components[c].Lower() ! if self.stack.app.pw is not None: ! self.stack.app.pw.clearComponentsList() ! self.stack.app.pw.displayComponents(self.components) ! self.stack.app.pw.selectComponentsList(name, self.components[name].__class__.__name__) # KEA 2002-02-23 ##self.propertyEditorWindow.Freeze() --- 918,925 ---- self.components[c].Lower() ! if self.application.pw is not None: ! self.application.pw.clearComponentsList() ! self.application.pw.displayComponents(self.components) ! self.application.pw.selectComponentsList(name, self.components[name].__class__.__name__) # KEA 2002-02-23 ##self.propertyEditorWindow.Freeze() |