Button clicked not working on Big Sur.
-
If you set the background of all pushbuttons of a window they all no longer trigger connected clicked events but if one of them doesn't have a background set they all work. This behaviour only seems to happen when using Big Sur. Is this an issue on my end or do I need to submit a bug report?
I have a minimal example that shows this behaviour if needed.
-
Hi
Im not sure Qt is supported on Big Sur yet.
https://bugreports.qt.io/browse/QTBUG-85546 -
I have the same issue. About half of all buttons in our app do not work but only under Big Sur. I agree Qt needs to get on this. We are close to Apple's release and they are pushing hard on the whole Silicon + universal apps thing. We have Silicon running Big Sur dev kits already and the issue is obviously within Qt.
-
Hi
I think they are "on it"
https://bugreports.qt.io/browse/QTBUG-85279
https://bugreports.qt.io/browse/QTBUG-85546 -
@mrjj said in Button clicked not working on Big Sur.:
Hi
I think they are "on it"
https://bugreports.qt.io/browse/QTBUG-85279
https://bugreports.qt.io/browse/QTBUG-85546Thanks, that's great! That's just the ARM part though. 5.15 needs to be fixed for the interim because Qt also said (in their mailing list) that they expected things to work as is (since Apple has the new layer that emulates existing Intel apps). Also, I was mistaken. This is a 5.15 issue, happens on Catalina too, so it's not just Big Sur (the button issue).
-
@mrjj I can try to put together a test app but our app is way too large to figure that out from it. We have a ton of buttons. The app is themed so we use qss for everything (user picks their theme, we apply a qss set). What I can say is that not all buttons no longer send the click (maybe half), buttons that still work also have qss including a background applied, and that this app worked fine through multiple versions of Mac OS + Qt including 5.14.2. As soon as it's built with 5.15, this happens on both Catalina and Big Sur.
-
Qt 5.15.0 , has this issue but apps launch
Qt 5.14.2/5.13.2 test app doesn't even display anything I haven't looked into whyCurrently my "solution" is to use Qt 5.12.9 since it displays and doesn't seem to have this issue and unlike 5.12.5 doesn't crash on mouse move event but I haven't investigated that behaviour much.
#include "mainwindow.h" #include "ui_mainwindow.h" #include <QDebug> #include <QKeyEvent> MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent) , ui(new Ui::MainWindow) { ui->setupUi(this); ui->pushButton->setStyleSheet("border-image: url(:/cc.xlarge.png) 0 0 0 0 stretch stretch;"); ui->pushButton_2->setStyleSheet("background: rgb(255,0,0);"); connect(ui->pushButton,&QPushButton::clicked,this,[](){ qDebug()<<"clacked"; }); connect(ui->pushButton_2,&QPushButton::clicked,this,[](){ qDebug()<<"clacked2"; }); } MainWindow::~MainWindow() { delete ui; } void MainWindow::keyPressEvent(QKeyEvent *event){ if(event->key() == Qt::Key_Shift){ ui->pushButton_2->setStyleSheet(""); } }
is my minimal test app main window code all it needs is a ui form with 2 pushbuttons with the given tokens names and a image since I was testing if that was the cause