diff --git a/CHANGELOG.rst b/CHANGELOG.rst index f2c3033..aff0e7c 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -1,6 +1,11 @@ 0.3.3 - (unreleased) ==================== +Fixed +----- + +* Fixed a crash when pressing the keyboard shortcut for New Scene + while in the process of doing a rubberband selection 0.3.2 - 2024-01-21 diff --git a/beeref/scene.py b/beeref/scene.py index 69c428b..167b9fd 100644 --- a/beeref/scene.py +++ b/beeref/scene.py @@ -54,6 +54,7 @@ class BeeGraphicsScene(QtWidgets.QGraphicsScene): def clear(self): super().clear() self.internal_clipboard = [] + self.rubberband_item = RubberbandItem() def addItem(self, item): logger.debug(f'Adding item {item}') diff --git a/beeref/selection.py b/beeref/selection.py index 6b8d4ab..fc39875 100644 --- a/beeref/selection.py +++ b/beeref/selection.py @@ -639,7 +639,7 @@ class MultiSelectItem(SelectableMixin, def fit_selection_area(self, rect): """Updates itself to fit the given selection area.""" - logger.debug(f'Fit selection area to {rect}') + logger.trace(f'Fit selection area to {rect}') # Only update when values have changed, otherwise we end up in an # infinite event loop sceneChange -> itemChange -> sceneChange ... @@ -688,4 +688,4 @@ class RubberbandItem(BaseItemMixin, QtWidgets.QGraphicsRectItem): """Updates itself to fit the two given points.""" self.setRect(utils.get_rect_from_points(point1, point2)) - logger.debug(f'Updated rubberband {self}') + logger.trace(f'Updated rubberband {self}')