Android openglwindow no dialog, messagbox problem



  • Hi,

    in the example gui/openglwindow i added some MessageBoxes and a Dialog, but only QMessageBox::information(..) is shown correctly :

    @//! [2]
    int main(int argc, char **argv)
    {
    //QGuiApplication app(argc, argv);
    QApplication app(argc, argv);

    QSurfaceFormat format;
    format.setSamples(16);
    format.setDepthBufferSize(24);
    
    
    TriangleWindow window;
    window.setFormat(format);
    window.resize(640, 480);
    window.show();
    window.setAnimating(true);
    
    //works android, linux+osx desktop, ios
    QMessageBox::information(0,"Title","Text");
    
    // works linux+osx desktop, ios  / android button missing
    QMessageBox box;
    box.setText("?????");
    box.addButton("Click",QMessageBox::AcceptRole);
    box.exec();
    
    //works linux+osx desktop, ios /android not showing
    MyDialog md;
    md.setWindowTitle("Dialog from ui file");
    md.exec();
    
    return app.exec();
    

    }
    //! [2]@

    I get this errors (android only. desktop, ios works):

    W/Qt (21829): kernel/qwidget_qpa.cpp:998 (virtual QPaintEngine* QWidget::paintEngine() const): QWidget::paintEngine: Should no longer be called
    W/Qt (21829): painting/qpainter.cpp:1734 (bool QPainter::begin(QPaintDevice*)): QPainter::begin: Paint device returned engine == 0, type: 1
    W/Qt (21829): painting/qpainter.cpp:8164 (const QTransform& QPainter::deviceTransform() const): QPainter::deviceTransform: Painter not active
    W/Qt (21829): painting/qpainter.cpp:8237 (const QTransform& QPainter::worldTransform() const): QPainter::worldTransform: Painter not active
    W/Qt (21829): painting/qpainter.cpp:3932 (const QPen& QPainter::pen() const): QPainter::pen: Painter not active
    W/Qt (21829): painting/qpainter.cpp:3875 (void QPainter::setPen(const QPen&)): QPainter::setPen: Painter not
    W/Qt (21829): painting/qpainter.cpp:3875 (void QPainter::setPen(const QPen&)): QPainter::setPen: Painter not active

    Why ? How do i solve this ?


Log in to reply
 

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