Mercurial > fife-parpg
comparison clients/editor/plugins/LayerTool.py @ 324:e249fa887259
* Split EventListener into several internal subclasses. This fixes issue with multiple inheritance where each BaseClass.__init__() call would overwrite the previous one. This meant that you could only add EventListener to one type of event managers.
* MapView now adds maps and layers to EventListener
* LayerEditor should now fetch only NameClash exceptions when creating or editing layers
author | cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222 |
---|---|
date | Fri, 21 Aug 2009 14:39:54 +0000 |
parents | b64ce990abb1 |
children | 7e5717105212 |
comparison
equal
deleted
inserted
replaced
323:b64ce990abb1 | 324:e249fa887259 |
---|---|
442 cellgrid.setYShift(y_offset) | 442 cellgrid.setYShift(y_offset) |
443 | 443 |
444 try: | 444 try: |
445 layer = self.map.createLayer(str(layerId), cellgrid) | 445 layer = self.map.createLayer(str(layerId), cellgrid) |
446 | 446 |
447 except: | 447 except fife.NameClash: |
448 print 'The layer ' + str(layerId) + ' already exists!' | 448 print 'The layer ' + str(layerId) + ' already exists!' |
449 return | 449 return |
450 else: | 450 else: |
451 cellgrid = layer.getCellGrid() | 451 cellgrid = layer.getCellGrid() |
452 cellgrid.setRotation(rotation) | 452 cellgrid.setRotation(rotation) |