From c0412bcf3853abeb6911c82aaf35125c25529277 Mon Sep 17 00:00:00 2001 From: Blaine Date: Thu, 11 Jun 2020 22:53:36 +0530 Subject: fixed context menu --- src/main/python/utils/canvas.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/main/python/utils') diff --git a/src/main/python/utils/canvas.py b/src/main/python/utils/canvas.py index 88e3c43..480a2e1 100644 --- a/src/main/python/utils/canvas.py +++ b/src/main/python/utils/canvas.py @@ -37,7 +37,11 @@ class canvas(customView): self.painter.setSceneRect(0, 0, *paperSizes[self._canvasSize][self._ppi]) self.parentMdiArea = parentMdiArea self.parentFileWindow = parentFileWindow + self.customContextMenuRequested.connect(self.sideViewContextMenu) + def sideViewContextMenu(self, pos): + self.parentFileWindow.sideViewContextMenu(self.mapTo(self.parentFileWindow, pos)) + def resizeView(self, w, h): #helper function to resize canvas self.painter.setSceneRect(0, 0, w, h) -- cgit