Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Alternate button text in Android QMessageBox
Forum Updated to NodeBB v4.3 + New Features

Alternate button text in Android QMessageBox

Scheduled Pinned Locked Moved Mobile and Embedded
1 Posts 1 Posters 526 Views 1 Watching
  • 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.
  • SeeLookS Offline
    SeeLookS Offline
    SeeLook
    wrote on last edited by
    #1

    Hi!
    Under desktop (any Mac/Lin/Win) the following code just works:

    auto msg = new QMessageBox(someParent);
    msg->setText(tr("Are you monkey or donkey?"));
    msg->setStandardButtons(QMessageBox::Ok | QMessageBox::Cancel);
    auto donkeyButton = msg->button(QMessageBox::Ok);
    donkeyButton->setText(tr("Donkey"));
    msg->button(QMessageBox::Cancel)->setText(tr("Monkey"));
    

    but under Android the native Message Box is invoked, so those texts are not respected.

    Is there any other way to have control on QMessageBox texts under Android?

    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