From d32b79a662bdcf25acb3cd64e117cf000d11d120 Mon Sep 17 00:00:00 2001 From: falkTX Date: Sat, 16 Aug 2014 13:10:03 +0100 Subject: [PATCH] Make sure about dialogs on Windows are non-resizable --- source/carla_widgets.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/source/carla_widgets.py b/source/carla_widgets.py index e340413e3..74b6edc94 100755 --- a/source/carla_widgets.py +++ b/source/carla_widgets.py @@ -25,11 +25,11 @@ from carla_config import * # Imports (Global) if config_UseQt5: - from PyQt5.QtCore import pyqtSignal, pyqtSlot, QByteArray, QSettings + from PyQt5.QtCore import pyqtSignal, pyqtSlot, Qt, QByteArray, QSettings from PyQt5.QtGui import QColor, QCursor, QFontMetrics, QPainter, QPainterPath from PyQt5.QtWidgets import QDialog, QInputDialog, QLineEdit, QMenu, QVBoxLayout, QWidget else: - from PyQt4.QtCore import pyqtSignal, pyqtSlot, QByteArray, QSettings + from PyQt4.QtCore import pyqtSignal, pyqtSlot, Qt, QByteArray, QSettings from PyQt4.QtGui import QColor, QCursor, QFontMetrics, QPainter, QPainterPath from PyQt4.QtGui import QDialog, QInputDialog, QLineEdit, QMenu, QVBoxLayout, QWidget @@ -191,6 +191,9 @@ class CarlaAboutW(QDialog): self.adjustSize() self.setFixedSize(self.size()) + if WINDOWS: + self.setWindowFlags(self.windowFlags()|Qt.MSWindowsFixedSizeDialogHint) + def done(self, r): QDialog.done(self, r) self.close() @@ -209,6 +212,9 @@ class JuceAboutW(QDialog): self.adjustSize() self.setFixedSize(self.size()) + if WINDOWS: + self.setWindowFlags(self.windowFlags()|Qt.MSWindowsFixedSizeDialogHint) + def done(self, r): QDialog.done(self, r) self.close()