FramelessWindowHint freezes form with QAxWidget
-
@mrjj hmm
i do this:void MainWindow::on_pushButton_clicked() { QAxWidget *Test = new QAxWidget(this); Test->setControl("{8856f961-340a-11d0-a96b-00c04fd705a2}"); Test->dynamicCall("Navigate(const QString&)","http://vk.com/"); Test->show(); }
And work! this bug work when i create QAxWidget in Disigner...
Hmm when i creat not in on_pushButton_clicked also this bug...
-
well my "theory" is that
if QAxWidget is assigned to a parent before FramelessWindowHint
then bug comes. -
Well I assume u tested that ?
Create it after setupUI and FramelessWindowHint does not make it work ?If no, you can try with the showEvent
void maiwinxx::showEvent( QShowEvent* event ) {
QMainwindxx::showEvent( event );// create it here.
}
-
@mrjj i create:
void MainWindow::showEvent( QShowEvent* event ) { QAxWidget *Test = new QAxWidget(this); Test->setControl("{8856f961-340a-11d0-a96b-00c04fd705a2}"); Test->dynamicCall("Navigate(const QString&)","http://vk.com/"); Test->show(); }
Not help...
Excuse me, I find it hard to understand you, because I'm Russian ... -
@Tikitko
very strange!
I though showEvent would been same as clicked.
Try timer so that we first create after window fully shown.// in constructor
QTimer *timer = new QTimer(this);
connect(timer, SIGNAL(timeout()), this, SLOT(nowcreate()));
timer->start(4000);
}void MainWindow::nowcreate() << add this to .h also
{
qDebug() << "nowcreate";
// create here
QAxWidget *Test = new QAxWidget(this);
..
}