Changeset 346

Show
Ignore:
Timestamp:
Sat Oct 20 11:30:54 2007
Author:
Brian
Message:

Finish removing the canvas level shape to dcid xref. (It is stored in the shape object instead.)

Files:

Legend:

Unmodified
Added
Removed
Modified
  • scripts/trunk/ORM/Open ORM Window.py

    r345 r346  
    3111 3111         new_shape = self.AddNode('ORMNote', self.popupx, self.popupy)  
    3112 3112         Data.SetUndo('Add Note')  
    3113           id = self.shapeid_to_dcid_xref[new_shape.ID]  
    3114           self.RedisplayID(id)  
      3113         # id = self.shapeid_to_dcid_xref[new_shape.ID]  
      3114         self.RedisplayID(new_shape.dcid)  
    3115 3115  
    3116 3116     def OnPopupTwo(self, event):  
    3117 3117         new_shape = self.AddNode('ORMFact', self.popupx, self.popupy)  
    3118 3118         Data.SetUndo('Add Fact')  
    3119           id = self.shapeid_to_dcid_xref[new_shape.ID]  
    3120           self.RedisplayID(id)  
      3119         # id = self.shapeid_to_dcid_xref[new_shape.ID]  
      3120         self.RedisplayID(new_shape.dcid)  
    3121 3121  
    3122 3122     def OnPopupThree(self, event):  
     
    3182 3182         # need to remember which dc id belongs to which shape  
    3183 3183         # can't store in object, must be in the graphics window -- WRONG!  
    3184           self.shapeid_to_dcid_xref[shape.ID] = id  # convert to 'shape.dcid' instead  
      3184 #        self.shapeid_to_dcid_xref[shape.ID] = id  # convert to 'shape.dcid' instead  
    3184 3184         shape._SetInShell('dcid', id)  
    3185 3185  
     
    3297 3297         else:  
    3298 3298             return  
    3299           id = self.shapeid_to_dcid_xref[new_shape.ID]  
    3300           self.RedisplayID(id)  
      3299 #        id = self.shapeid_to_dcid_xref[new_shape.ID]  
      3300         self.RedisplayID(new_shape.dcid)  
    3301 3301  
    3302 3302     def OnMouse(self, event):  
     
    3321 3321                     Data.SetUndo('Add %s' % self.leftClickType)  
    3322 3322                     # redisplay object??  
    3323                       id = self.shapeid_to_dcid_xref[new_shape.ID]  
    3324                       self.RedisplayID(id)  
      3323                     # id = self.shapeid_to_dcid_xref[new_shape.ID]  
      3324                     self.RedisplayID(new_shape.dcid)  
    3325 3325                     # make object current selection  
    3326 3326                     self.dragid = id  # remember start of drag