Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error with canvas scenes when deleting selected vertices in list #278

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ RELEASING:
-->

## Unreleased

### Fixed
- Error with canvas scenes when deleting selected vertices in list ([#278](https://github.com/GIScience/orstools-qgis-plugin/pull/278))
-
### Added
- Processing algorithms for the Network Export endpoint ([#210](https://github.com/GIScience/orstools-qgis-plugin/issues/210))

Expand Down
2 changes: 1 addition & 1 deletion ORStools/gui/ORStoolsDialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -579,7 +579,7 @@ def _on_clear_listwidget_click(self) -> None:
self._clear_annotations()

# Remove blue lines (rubber band)
if self.line_tool:
if self.line_tool and hasattr(self.line_tool, "rubberBand"):
self.line_tool.canvas.scene().removeItem(self.line_tool.rubberBand)

def _linetool_annotate_point(
Expand Down
1 change: 1 addition & 0 deletions ORStools/utils/maptools.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ def canvasDoubleClickEvent(self, e):
# noinspection PyUnresolvedReferences
self.doubleClicked.emit()
self.canvas.scene().removeItem(self.rubberBand)
del self.rubberBand

def deactivate(self):
super(LineTool, self).deactivate()
Expand Down
Loading