Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Modal dialogs not working on Android
QtWS25 Last Chance

Modal dialogs not working on Android

Scheduled Pinned Locked Moved General and Desktop
1 Posts 1 Posters 839 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    SteveG
    wrote on last edited by
    #1

    I have a modal dialog box MDBox.qml that contains
    @
    // . .
    Window{
    id: root
    modality: Qt.ApplicationModal
    flags: Qt.Dialog | Qt.WindowStaysOnTopHint
    // Properties
    signal buttonSelected(string name)
    // Various components, such as Rectangle, Text and Button
    }
    @

    This is referenced in MyScreen.qml with id mdbox and I set mdbox.visible = true. mdbox.visible = false is set when the OnButtonSelected signal is received by MyScreen.qml from mdbox. MyScreen contains
    @
    // . . .
    mdbox.visible = true;
    // . . .
    MDBox{
    id: mdbox
    visible: false
    // . . .
    OnButtonSelected: {
    // . . .
    mdbox.visible = false;
    }
    }
    // . . .
    @

    When I run this in QT Creator with Qt 5.4 on Windows 8 64 bit, the modal dialog box appears and disappears as expected. However, when it's run on an Android device or emulator, it appears but never disappears. Does anyone know why this happens and how to fix this problem?

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved