Changeset 1837
- Timestamp:
- 08/04/07 14:45:50 (1 year ago)
- Files:
-
- gaphor/trunk/gaphor/diagram/diagramline.py (modified) (2 diffs)
- gaphor/trunk/gaphor/services/copyservice.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
gaphor/trunk/gaphor/diagram/diagramline.py
r1747 r1837 114 114 h = self.head 115 115 116 x, y = self.canvas.get_matrix_i2c(self).transform_point(h.x, h.y) 117 x, y = self.canvas.get_matrix_c2i(self._load_head_connection).transform_point(x, y) 118 adapter.connect(h, x, y) 116 adapter.connect(h, float(h.x), float(h.y)) 119 117 del self._load_head_connection 120 118 … … 124 122 h = self.tail 125 123 126 x, y = self.canvas.get_matrix_i2c(self).transform_point(h.x, h.y) 127 x, y = self.canvas.get_matrix_c2i(self._load_tail_connection).transform_point(x, y) 128 adapter.connect(h, x, y) 124 adapter.connect(h, float(h.x), float(h.y)) 129 125 del self._load_tail_connection 130 126 LineItem.postload(self) gaphor/trunk/gaphor/services/copyservice.py
r1362 r1837 122 122 ci.save(self.copy_func) 123 123 124 # move pasted items a bit, so user can see result of his action :) 125 # update items' matrix immediately 126 # TODO: if it is new canvas, then let's not move, how to do it? 124 127 for item in self._new_items.values(): 125 128 item.matrix.translate(10, 10) 129 canvas.update_matrix(item) 126 130 131 # solve internal constraints of items immediately as item.postload 132 # reconnects items and all handles has to be in place 133 canvas.solver.solve() 127 134 for item in self._new_items.values(): 128 135 item.postload()
