Changeset 3800
- Timestamp:
- 12/11/07 14:46:32 (1 year ago)
- Files:
-
- trunk/ide/ClassDesigner.py (modified) (1 diff)
- trunk/ide/ClassDesignerEditor.py (modified) (2 diffs)
- trunk/ide/ClassDesignerFormMixin.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/ide/ClassDesigner.py
r3748 r3800 1644 1644 1645 1645 def flushCodeEditor(self): 1646 """Forces the content of the editor to update the code repository.""" 1646 1647 self.EditorForm.updateText() 1648 1649 1650 def updateCodeEditor(self): 1651 """Forces the code repository to update the contents of the editor.""" 1652 self.EditorForm.refreshCode() 1647 1653 1648 1654 trunk/ide/ClassDesignerEditor.py
r3668 r3800 213 213 214 214 215 def edit(self, obj, mthd=None, nonEvent=None): 215 def refreshCode(self): 216 """When an external event modified an object's code, this will update the 217 code displayed in the editor. 218 """ 219 self.edit(self.ddObject.KeyValue, discardChanges=True) 220 221 222 def edit(self, obj, mthd=None, nonEvent=None, discardChanges=False): 216 223 """Opens an editor for the specified object and method.""" 217 224 if mthd is None: … … 223 230 rep = self.CodeRepository 224 231 ed = self.editor 225 self.updateText() 232 if not discardChanges: 233 self.updateText() 226 234 objCode = rep.get(obj) 227 235 mvPointer = False trunk/ide/ClassDesignerFormMixin.py
r3760 r3800 798 798 # Make sure that the pk is retrieved! 799 799 flds.append(pk) 800 cd = self.Controller.getCodeForObject(self, create=True) 800 rep = self.Controller.getCodeDict() 801 cd = rep.get(self) 801 802 if cd is None: 802 803 cd = {} 803 804 ######805 ##TODO: handle this case.806 804 currCode = cd.get("createBizobjs", "") 807 # See if there is a bizobj defined for this table.808 ######809 805 810 806 bizcode = self.getBizobjTemplate() … … 823 819 currCode += code 824 820 cd["createBizobjs"] = currCode 821 rep[self] = cd 822 self.Controller.updateCodeEditor() 825 823 826 824
