Browse Source

dragging with right mouse-button now, doesn't interfere with the selecting this way

master
Christian Voigt 1 year ago
parent
commit
e9a93198c7
  1. 2
      README.md
  2. 9
      sdtd_world/world_regions_widget.py

2
README.md

@ -12,7 +12,7 @@ That's about it for now
#### Core Functions
Loading of 7dtd RAW map files (dtm.raw, any RAW 16bit grayscale that's stored in order) (CTRL+O)
*proper* Zooming in and out and navigate in a loaded map (Wheel, leftMouseDrag)
*proper* Zooming in and out and navigate in a loaded map (Wheel, rightMouseDrag)
Visually selecting a region of a loaded map file (leftMouse)
Visually marking regions of a loaded 7dtd map file (CTRL+leftMouse)
Identifying region strings (Statusbar on Hover)

9
sdtd_world/world_regions_widget.py

@ -124,9 +124,12 @@ class WorldRegionsWidget(QScrollArea):
""" altering class functions """
def mousePressEvent(self, event):
self.drag_in_progress = True
self.drag_start.setX(event.x())
self.drag_start.setY(event.y())
if event.button() == Qt.RightButton:
self.drag_in_progress = True
self.drag_start.setX(event.x())
self.drag_start.setY(event.y())
else:
self.drag_in_progress = False
super().mousePressEvent(event)

Loading…
Cancel
Save