Replies: 8 comments 11 replies
-
|
Is this just happening in an empty app? Do you add a listener for the back event handler at all? eg: NativeApplication.nativeApplication.addEventListener( KeyboardEvent.KEY_DOWN, keyDownHandler );
function keyDownHandler( event:KeyboardEvent ):void
{
trace( event.keyCode );
if (event.keyCode == Keyboard.BACK)
{
event.preventDefault();
}
}You wouldn't be using any of my legacy back button helpers at all would you? https://docs.airnativeextensions.com/docs/application/general-helpers#air-android-sdk-28-back-button |
Beta Was this translation helpful? Give feedback.
-
|
Hello,
I haven't created an empty app, due to I spent a couple of hours messing
around and then it worked fine on the older SDK, so something had to have
changed. It's the same code base I have been using for a long time.
Yep, I use the keyboard listener to handle backspace and preventdefault.
Worked like this for years. Just not working in the latest release.
It's a minor bug, because the app just minimizes the first time and from
then it works fine. So it may be overlooked by most devs and users.
No, I'm not using the legacy helper you mentioned.
Verified on 2 devices, tablet and phone.
Thanks.
…On Wed, Mar 11, 2026 at 7:54 PM Michael ***@***.***> wrote:
Is this just happening in an empty app? Do you add a listener for the back
event handler at all? eg:
NativeApplication.nativeApplication.addEventListener( KeyboardEvent.KEY_DOWN, keyDownHandler );
function keyDownHandler( event:KeyboardEvent ):void
{
trace( event.keyCode );
if (event.keyCode == Keyboard.BACK)
{
event.preventDefault();
}
}
You wouldn't be using any of my legacy back button helpers at all would
you?
https://docs.airnativeextensions.com/docs/application/general-helpers#air-android-sdk-28-back-button
—
Reply to this email directly, view it on GitHub
<#4180 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AK2UE4JTM2CDBXK7PZCNK3L4QIDDDAVCNFSM6AAAAACWO6CNLSVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTMMBZGA2TKMI>
.
You are receiving this because you authored the thread.Message ID:
<airsdk/Adobe-Runtime-Support/repo-discussions/4180/comments/16090551@
github.com>
|
Beta Was this translation helpful? Give feedback.
-
|
ok.. I just updated everything on my end to reflect the notes in the release... Platform Tools: 28.0.3 (I had to google that where to find it.) And the same thing happens. So the fact that it's not happening on your end is good. "Is there any chance there's a flow issue here and you're not attaching the listener on the first run? Perhaps something else has changed in the startup flow in 51.3?" Nothing has changed on the start up code at least. I'll keep trying a few things. In a worse case scenario it's a bug that isn't going to stop anyone from using the app. Thx. |
Beta Was this translation helpful? Give feedback.
-
|
No luck, but after doing extensive testing with an AI agent (Claude), it seems there could be an issue with this version of the SDK in regards to Stage3D which was not in the older SDK. I was able to write a simple non Stage3D test app and the back button worked fine the first time, but when utilizing my stage3D engine the back button does not work correctly the first time, but from the 2nd time on... it works fine. 51.1 works as expected. 51.3 does not. So since no one else has reported the issue, it very well could be with my custom Stage3D code base. I'm not too concerned to be honest, as the bug is a small one that most will never notice. But for a sanity check on the SDK 51.3, it would be great if someone has a stage3D mobile app using SDK 51.3 and can verify the back button is working fine the first time it's pressed. In my game for example, during the game you can press the back button to exit to the title screen. But with SDK 51.3, the app just minimizes instead of going to the title screen. With SDK 51.1, it exits back to the title screen. Thx! |
Beta Was this translation helpful? Give feedback.
-
|
"Any chance you can set some break points and check if your listener is actually getting added on the first launch?" Just to clear, I'm not re-launching the app and then it works. It's just going from a stopped state back to active. Launch the app. Start playing the game. During the game press the back button which should take it immediately to the title screen. Instead the app gets stopped. When tapped to be the active app again, the game is paused (correct behavior) and I can continue playing. But when I now press the back button (2nd time) it exits back to the title screen correctly. What causes me to continue to think it's not on my end is when using 51.1 to build the apk the app works as expect, but when building with 51.3 it does not. I'm not re-compiling the .swf between builds. Do you still think continued testing with my code base is relevant if it's not happening on such a close SDK revision to the current one? Hopefully someone else running stage 3D / 51.3 will chime in with their results. Thanks! |
Beta Was this translation helpful? Give feedback.
-
|
You made me go back a few years... lol.. I use FlashDevelop and the FlashDevelop debugger requires an older version of Java then what is installed. I'd have to switch to the newer java for building, switch to older java for debugging. ugh... lol.. I appreciate the back and forth. But it looks like I'm the only one reporting the issue, and I'm fine with the quirk as is. It's definitely not going to stop anyone from using the app. And it will only show up once per app run. Thanks! But let's keep this open for a while incase someone else has the same issue. ;) |
Beta Was this translation helpful? Give feedback.
-
|
"when the listener gets added" I did this earlier... in both SDK versions... with the same results for each SDK: (Added the keyboard listeners.... ) Are you suggesting there could be some kind of delay until the listeners are actually "listening for events" after I set them up and somehow the default Android handler is trapping them instead initially? If so.. that's exactly what my AI agent suggested and that's when I started placing the SetListeners in various locations to see what would happen. And then after that session, I tried the same things on the older SDK and realized it worked fine. If you could detail a little more what information you're seeking I could probably just set some flags/variable and display them on screen. I don't use Starling otherwise I'd just make a simple test with it and ask you to build it on your end and simply test to see how it functions. :) Would be the quickest way to see if it's just.... me. lol.. |
Beta Was this translation helpful? Give feedback.
-
|
Resolved. Turns out this bug is caused by using Distriqt's Application ANE. More specifically this line... Application.service.display.setDisplayMode(DisplayMode.IMMERSIVE, LayoutMode.CUTOUT_SHORT_EDGES); I will report the bug to them. ;) Thank you for the back and forth, I apologize for taking up your time. The latest release is solid. :) Thanks again. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Resolved. Turns out this bug is caused by using Distriqt's Application ANE. More specifically this line...
Application.service.display.setDisplayMode(DisplayMode.IMMERSIVE, LayoutMode.CUTOUT_SHORT_EDGES);
I will report the bug to them. ;)
Thank you for the back and forth, I apologize for taking up your time. The latest release is solid. :)
Thanks again.
Adobe AIR 51.1 SDK - Back button behavior works as expected.
Adobe AIR 51.3 SDK - Regardless where in the app, when the back button is pressed for the first time the app minimizes. After that the app behaves correctly.
enableOnBackInvokedCallback="false" in manifest does not fix it.
Anyone else?
Beta Was this translation helpful? Give feedback.
All reactions