diff --git a/qframelesswindow/titlebar/__init__.py b/qframelesswindow/titlebar/__init__.py index ed559f0..3a8146a 100644 --- a/qframelesswindow/titlebar/__init__.py +++ b/qframelesswindow/titlebar/__init__.py @@ -80,7 +80,7 @@ def _isDragRegion(self, pos): if button.isVisible(): width += button.width() - return 0 < pos.x() < self.width() - width + return self.window().BORDER_WIDTH < pos.x() < self.width() - width and pos.y() > self.window().BORDER_WIDTH def _hasButtonPressed(self): """ whether any button is pressed """