fix: possible crash (#836)

* fix: possible crash when show statusbar message

* windows qt upgrade to qt6.5.1

* Update src/ui/mainstatusbar.cc

---------

Co-authored-by: YiFang Xiao <yifang.xiao@noreply.com>
This commit is contained in:
xiaoyifang 2023-06-10 22:26:24 +08:00 committed by GitHub
parent dfd3a86c7f
commit ca4664f209
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 8 additions and 6 deletions

View file

@ -22,7 +22,7 @@ jobs:
strategy:
matrix:
os: [macos-11,macos-12]
qt_ver: [6.4.3]
qt_ver: [ 6.5.1 ]
qt_arch: [clang_64]
env:
targetName: GoldenDict

View file

@ -26,7 +26,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
qt_ver: [6.4.3]
qt_ver: [ 6.5.1 ]
qt_arch: [gcc_64]
env:
version: 23.06.02

View file

@ -27,7 +27,7 @@ jobs:
strategy:
matrix:
os: [windows-2019]
qt_ver: [6.4.3]
qt_ver: [6.5.1]
qt_arch: [win64_msvc2019_64]
env:
targetName: GoldenDict.exe

View file

@ -85,9 +85,11 @@ void MainStatusBar::showMessage(const QString & str, int timeout, const QPixmap
{
timer->start( timeout );
}
raise();
show();
move( QPoint( 0, parentWidget()->height() - height() ) );
if ( parentWidget() && parentWidget()->isVisible() ) {
raise();
show();
move( QPoint( 0, parentWidget()->height() - height() ) );
}
}
void MainStatusBar::mousePressEvent ( QMouseEvent * )