Windows Mobile 5 - Maximized window



  • Hello,

    I started to develop application for win mobile 5 using QT 4.8.2. I am able to compile and run application but it is not maximized. I tried to set different flags and window states. Fullscreen is working as expected but maximizing isn't. The only option which works is to set flags Qt::Window | Qt::FramelessWindowHint. But in this case there is no application menu and close button does not work.

    Thanks



  • So I found the problem. I have to set window state after showing application (showMaximized somehow resets window state).

    Application is not maximized:
    @
    int main(int argc, char *argv[]) {
    QApplication a(argc, argv);
    HelloWorldApp w;
    w.setWindowState(Qt::WindowMaximized);
    w.showMaximized();
    return a.exec();
    }
    @

    Application is maximized:
    @
    int main(int argc, char *argv[]) {
    QApplication a(argc, argv);
    HelloWorldApp w;
    w.showMaximized();
    w.setWindowState(Qt::WindowMaximized);
    return a.exec();
    }
    @

    After executing showMaximized windowState is 0 and isMaximized is false.


Log in to reply
 

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