Skip to content Skip to sidebar Skip to footer

Unable To Call Powermanager.wakelock.newwakelock Using Qandroidjniobject

I'm trying to execute this Java code: PowerManager pm = (PowerManager) getSystemService(Context.POWER_SERVICE); PowerManager.WakeLock wl = pm.newWakeLock(PowerManager.SCREEN_DIM_WA

Solution 1:

Nested class names requires a special syntax:

Landroid/os/PowerManager/WakeLock

Should be:

Landroid/os/PowerManager$WakeLock

And it works!

Post a Comment for "Unable To Call Powermanager.wakelock.newwakelock Using Qandroidjniobject"