Window Freeze

  • What would be the best way to prevent a window freeze the other windows?

    I tried to move my QMainWindow to a thread (QMainWindow::moveToThread), but this is not possible for the widgets can not be moved.

    I'd like to open a new window in a separate process.

    The reason is that if this new page has a script to freeze the window he ends up freezing all other windows.

    @class myWebPage : public QWebPage {
    QWebPage * createWindow(QWebPage::WebWindowType type) {
    QMainWindow *wx = new mBROWSERQT(NULL,true);
    QWebView wv = wx->findChild<QWebView>("mybrowsertest");

        return wv->page();



    ui->mybrowsertest->setPage(new myWebPage());@

  • Hi,

    you can run the freezing script in other thread.

  • [quote author="mcosta" date="1368775468"]Hi, you can run the freezing script in other thread.[/quote]

    Yes, but how do I do this with QWebPage::createWindow?

    I have to move QWebPage/QWebFrame to another thread (Well as you can see I need to return the QwebPage for the createWindow)?

    bq. Note: What can freeze the windows is the javascript on any website

Log in to reply

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.