[Android-development] Android: crash in qmessagebox

maitai maitai at virtual-winds.org
Sat Aug 13 20:42:40 CEST 2016

I didn't know that, a pity. The required permissions are just indicated 
in the manifest. What I do now is that if Android 6 is detected I call 
Activity::requestPermissions() in Java to ask specifically the user for 
critical permissions (in my case WRITE_EXTERNAL_STORAGE and 

Le 13-08-2016 19:37, Lou Meadows a écrit :
> Phillippe
> My crash was happening on Android 6, permissions got more restrictive.
> What I did was in Qt Creator under Projects
> Build Steps
>  Build Android APK (Expand the section)
>  Click Create Templates
> Now you can add and remove permissions
> Br
> Lou
> -----Original Message-----
> From: Android-development
> [mailto:android-development-bounces+louis.meadows=mobifoundry.com at qt-project.org]
> On Behalf Of maitai
> Sent: Saturday, August 13, 2016 9:13 AM
> To: Android Development <Android-development at qt-project.org>
> Subject: Re: [Android-development] Android: crash in qmessagebox
> Thanks Louis for replying
> Concerning permissions I have been there too it's something specific
> to Android 6, and I had to implement a requestPermission method in
> Java.
> But since it's Android 5 I don't think it is that case (plus I cannot
> imagine that QMessageBox would need a permission that QDialog don't
> have).
> I'll keep that in mind anyway
> Philippe.
> Le 13-08-2016 17:59, Louis Meadows a écrit :
>> Phillippe
>> An unexpected crash I have found to be caused by not having a
>> permission set.
>> I would have no idea why qmessagebox would need a permission.
>> However if the code runs else where I would start with looking at the
>> permissions I just got bit by the camera one day when it had been
>> working after an update.
>> Now my app was suddely craqshing for no reason on one android (6) and
>> not another(4)
>> Br
>> Lou
>> On 8/13/2016 7:23 AM, maitai wrote:
>>> Hello,
>>> I have a user equipped with a Lenovo Yoga Tablet2 1050F (Android
>>> 5.0.1). App is compiled with qt5.7 for Android X86.
>>> The app (QWidget-based) crashes each time a QMessageBox is called.
>>> Same thing happens if I compile with qt5.6. He is so far the only
>>> user with such a problem, out of 1000's. For some reason, I also
>>> never receive the crash reports he says he is sending me so I am
>>> completely in the dark here.
>>> Regular QDialogs, even very complex ones, displays normally, and the
>>> rest of the app (with a complex QMainWindow/QGraphicsScene/View etc.)
>>> works normally . It's just QMessageBox that crashes. The users tested
>>> all options, everything works except when a QMessageBox is called.
>>> I had a look at QMessageBox code but didn't find anything
>>> specifically related to Android.
>>> Maybe someone has a clever idea of what can possibly cause that? What
>>> QMessageBox is using that QDialog is not?
>>> Thanks
>>> Philippe Lelong
>>> _______________________________________________
>>> Android-development mailing list
>>> Android-development at qt-project.org
>>> http://lists.qt-project.org/mailman/listinfo/android-development
> _______________________________________________
> Android-development mailing list
> Android-development at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/android-development

More information about the Android-development mailing list