prevent right click double fire when closing notifications
This commit is contained in:
parent
63fd0b532f
commit
07cd1ce23d
@ -1,5 +1,16 @@
|
||||
[DEFAULTS]
|
||||
|
||||
[aqt]
|
||||
concurrency: 8
|
||||
baseurl: https://mirror.netcologne.de/qtproject
|
||||
baseurl: https://mirror.netcologne.de/qtproject
|
||||
|
||||
[mirrors]
|
||||
trusted_mirrors:
|
||||
https://download.qt.io
|
||||
blacklist:
|
||||
http://mirrors.ustc.edu.cn
|
||||
http://mirrors.tuna.tsinghua.edu.cn
|
||||
http://mirrors.geekpie.club
|
||||
fallbacks:
|
||||
https://mirrors.ocf.berkeley.edu/qt
|
||||
https://ftp.jaist.ac.jp/pub/qtproject
|
||||
http://ftp1.nluug.nl/languages/qt
|
||||
https://mirrors.dotsrc.org/qtproject
|
@ -61,9 +61,9 @@ else
|
||||
echo "Qt will be installed to: $QTPATH"
|
||||
|
||||
# Install Qt.
|
||||
aqt install-qt -O "$QTPATH" "$QTTARGET" "desktop" "$QTVERSION" "$QTARCH" -m "qtwebengine" "qtimageformats" "qtwebchannel" "qtmultimedia" "qt5compat" "qtpositioning" "qtserialport"
|
||||
aqt install-tool -O "$QTPATH" "$QTTARGET" "desktop" "tools_cmake"
|
||||
aqt install-tool -O "$QTPATH" "$QTTARGET" "desktop" "tools_ninja"
|
||||
aqt -c 'aqt/settings.ini' install-qt -O "$QTPATH" "$QTTARGET" "desktop" "$QTVERSION" "$QTARCH" -m "qtwebengine" "qtimageformats" "qtwebchannel" "qtmultimedia" "qt5compat" "qtpositioning" "qtserialport"
|
||||
aqt -c 'aqt/settings.ini' install-tool -O "$QTPATH" "$QTTARGET" "desktop" "tools_cmake"
|
||||
aqt -c 'aqt/settings.ini' install-tool -O "$QTPATH" "$QTTARGET" "desktop" "tools_ninja"
|
||||
|
||||
export QT_PLUGIN_PATH="$QTPATH/$QTVERSION/$QTOS/plugins"
|
||||
export PATH="$QTBIN:$QTPATH/Tools/CMake/CMake.app/Contents/bin:$QTPATH/Tools/Ninja:$PATH"
|
||||
|
@ -61,20 +61,20 @@ pip3 install -U pip
|
||||
pip3 install -I git+https://github.com/miurahr/aqtinstall
|
||||
|
||||
if ($is_qt_6) {
|
||||
aqt install-qt -O "$qt_path" windows desktop $qt_version win64_msvc2019_64 -m qtwebengine qtimageformats qtmultimedia qt5compat qtwebchannel qtpositioning
|
||||
aqt -c 'aqt\settings.ini' install-qt -O "$qt_path" windows desktop $qt_version win64_msvc2019_64 -m qtwebengine qtimageformats qtmultimedia qt5compat qtwebchannel qtpositioning
|
||||
}
|
||||
else {
|
||||
aqt install-qt -O "$qt_path" windows desktop $qt_version win64_msvc2019_64 -m qtwebengine
|
||||
aqt -c 'aqt\settings.ini' install-qt -O "$qt_path" windows desktop $qt_version win64_msvc2019_64 -m qtwebengine
|
||||
}
|
||||
|
||||
aqt install-src -O "$qt_path" windows desktop $qt_version --archives qtbase
|
||||
aqt -c 'aqt\settings.ini' install-src -O "$qt_path" windows desktop $qt_version --archives qtbase
|
||||
|
||||
$qt_qmake = "$qt_path\$qt_version\msvc2019_64\bin\qmake.exe"
|
||||
$env:PATH = "$qt_path\$qt_version\msvc2019_64\bin\;" + $env:PATH
|
||||
|
||||
if ($is_qt_6) {
|
||||
# Download openssl 3.x.
|
||||
aqt install-tool -O "$qt_path" windows desktop tools_opensslv3_x64 qt.tools.opensslv3.win_x64
|
||||
aqt -c 'aqt\settings.ini' install-tool -O "$qt_path" windows desktop tools_opensslv3_x64 qt.tools.opensslv3.win_x64
|
||||
$openssl_base_path = "$qt_path\Tools\OpenSSLv3\Win_x64"
|
||||
}
|
||||
else {
|
||||
|
@ -79,10 +79,11 @@ bool BaseToastNotification::eventFilter(QObject* watched, QEvent* event) {
|
||||
setupTimedClosing();
|
||||
}
|
||||
|
||||
if (event->type() == QEvent::Type::MouseButtonPress) {
|
||||
if (event->type() == QEvent::Type::MouseButtonPress || event->type() == QEvent::Type::MouseButtonRelease) {
|
||||
if (dynamic_cast<QMouseEvent*>(event)->button() == Qt::MouseButton::RightButton) {
|
||||
event->ignore();
|
||||
close();
|
||||
event->accept();
|
||||
QTimer::singleShot(100, this, &BaseToastNotification::close);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user