mirror of
https://github.com/lalbornoz/roar.git
synced 2024-11-22 15:26:37 +00:00
MiRCART.png: updates screenshot.
MiRCARTCanvas.py:onPanelKeyboardInput(): only handle {no,shift}-modifier keyboard events. MiRCARTFrame.py: fix {de,in}crease canvas size accelerators (hotkeys.)
This commit is contained in:
parent
38e90f96ca
commit
dec1e4c0d4
BIN
MiRCART.png
BIN
MiRCART.png
Binary file not shown.
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 43 KiB |
@ -71,7 +71,9 @@ class MiRCARTCanvas(wx.Panel):
|
|||||||
def onPanelKeyboardInput(self, event):
|
def onPanelKeyboardInput(self, event):
|
||||||
eventDc, tmpDc = self.canvasBackend.getDeviceContexts(self)
|
eventDc, tmpDc = self.canvasBackend.getDeviceContexts(self)
|
||||||
tool = self.canvasCurTool; mapPoint = self.brushPos;
|
tool = self.canvasCurTool; mapPoint = self.brushPos;
|
||||||
if event.GetModifiers() != wx.MOD_NONE:
|
keyModifiers = event.GetModifiers()
|
||||||
|
if keyModifiers != wx.MOD_NONE \
|
||||||
|
and keyModifiers != wx.MOD_SHIFT:
|
||||||
event.Skip()
|
event.Skip()
|
||||||
else:
|
else:
|
||||||
patches = tool.onKeyboardEvent( \
|
patches = tool.onKeyboardEvent( \
|
||||||
|
@ -57,9 +57,9 @@ class MiRCARTFrame(MiRCARTGeneralFrame):
|
|||||||
CID_PASTE = [0x10c, TID_COMMAND, "Paste", "&Paste", ["", wx.ART_PASTE], None, False]
|
CID_PASTE = [0x10c, TID_COMMAND, "Paste", "&Paste", ["", wx.ART_PASTE], None, False]
|
||||||
CID_DELETE = [0x10d, TID_COMMAND, "Delete", "De&lete", ["", wx.ART_DELETE], None, False]
|
CID_DELETE = [0x10d, TID_COMMAND, "Delete", "De&lete", ["", wx.ART_DELETE], None, False]
|
||||||
CID_INCR_CANVAS = [0x10e, TID_COMMAND, "Increase canvas size", \
|
CID_INCR_CANVAS = [0x10e, TID_COMMAND, "Increase canvas size", \
|
||||||
"&Increase canvas size", ["", wx.ART_PLUS], [wx.ACCEL_SHIFT, ord("+")]]
|
"I&ncrease canvas size", ["", wx.ART_PLUS], [wx.ACCEL_ALT, ord("+")]]
|
||||||
CID_DECR_CANVAS = [0x10f, TID_COMMAND, "Decrease brush size", \
|
CID_DECR_CANVAS = [0x10f, TID_COMMAND, "Decrease canvas size", \
|
||||||
"&Decrease brush size", ["", wx.ART_MINUS], [wx.ACCEL_SHIFT, ord("-")]]
|
"D&ecrease canvas size", ["", wx.ART_MINUS], [wx.ACCEL_ALT, ord("-")]]
|
||||||
CID_INCR_BRUSH = [0x110, TID_COMMAND, "Increase brush size", \
|
CID_INCR_BRUSH = [0x110, TID_COMMAND, "Increase brush size", \
|
||||||
"&Increase brush size", ["", wx.ART_PLUS], [wx.ACCEL_CTRL, ord("+")]]
|
"&Increase brush size", ["", wx.ART_PLUS], [wx.ACCEL_CTRL, ord("+")]]
|
||||||
CID_DECR_BRUSH = [0x111, TID_COMMAND, "Decrease brush size", \
|
CID_DECR_BRUSH = [0x111, TID_COMMAND, "Decrease brush size", \
|
||||||
@ -120,7 +120,7 @@ class MiRCARTFrame(MiRCARTGeneralFrame):
|
|||||||
# {{{ Accelerators (hotkeys)
|
# {{{ Accelerators (hotkeys)
|
||||||
AID_EDIT = (0x500, TID_ACCELS, ( \
|
AID_EDIT = (0x500, TID_ACCELS, ( \
|
||||||
CID_NEW, CID_OPEN, CID_SAVE, CID_UNDO, CID_REDO, \
|
CID_NEW, CID_OPEN, CID_SAVE, CID_UNDO, CID_REDO, \
|
||||||
CID_INCR_CANVAS, CID_INCR_BRUSH, CID_INCR_BRUSH, CID_DECR_BRUSH))
|
CID_INCR_CANVAS, CID_DECR_CANVAS, CID_INCR_BRUSH, CID_DECR_BRUSH))
|
||||||
# }}}
|
# }}}
|
||||||
# {{{ Lists
|
# {{{ Lists
|
||||||
LID_ACCELS = (0x600, TID_LIST, (AID_EDIT))
|
LID_ACCELS = (0x600, TID_LIST, (AID_EDIT))
|
||||||
|
Loading…
Reference in New Issue
Block a user