Disable the default function of the button 'Back' for Android.

Hello!

I tried SO MANY methods to PREVENT the default function of the previous button in Android, but without success

It is one of the codes that I have used without success:

stage.addEventListener (KeyboardEvent.KEY_UP, optionsKey, false, 0, true);

function optionsKey(ke:KeyboardEvent):void
{

If (ke.keyCode is Keyboard.BACK)
{

ke.preventDefault ();
ke.stopImmediatePropagation ();

Make my own code below...

}

}

I use Flash Cs6 , 3.2 Air for Android , testing on LG Google nexus 4.

When I use the flash Simulator, it works great! Means the back button, let the App back to the previous step (as I expect to do)

But after I publish the apk (picture format: Auto, auto orientation, rendering mode: GPU), as soon as I press RETURN, it minimizes my app!

(means that when I press the back button on my phone, the application to reduce to the minimum (not close!) to the bottom. when I reactivate / click on it, I see the app is actually passed a stage (I programmed and planned), but I just CANT STOP the default MITIGATIONaction /by disabling my application after pressing the back button.)

Anyone has any fileFla'I can see it in ACTION Please?

Because I used several several codes and no luck yet

Thanks and looking forward for your any kind of help...

Post edited by: Pouradam

I had my own answer with myself!

in the code above. KEY_UP should be replaced. KEY_DOWN.

simple!

Tags: Adobe Animate

Similar Questions

  • Zoom after using the button 'back' on Android

    Hello

    On Firefox Android, I have one on a web page and zoom using double-tap or pinch and then click on a link on the page. Firefox to display the page. Everything is good.

    If I use then the back button to return to the previous page, Firefox will not display the page as it was previosly zoomed in. It forces me to zoom in by double-tap or pinch.

    Is a framework or an add-on that will preserve the zoomed in State after his return to the previous page by using the back button?

    Thanks in advance.

    I submitted a bug report, and they quickly asked me to try the latest Nightly build. This bug is fixed in the latest nightly build!

  • Disable the button 'Start my camera' by default for rtc WebcamPublisher

    Hello

    I notice in the samples that webcam shows the cam. Is there an easy way to disable the button 'start my camera? " I want to this control of the application itself.

    <rtc:WebCamera width="65%" height="396" id="webCamPub"/>

    I noticed in the webcam sample realizes remove the button 'Start my camera' by default, giving the RTC webcam a width and a height of 1 and manipulation using the WebCamPublisher class, but I don't see anywhere a 'button' = disabled or something similar.

    Hello

    In situations like this, we recommend that you build your own

    a user interface customized using the WebcamPublisher / WebcamSubscriber. He got all the

    same features as the webcam pod, but with a LOT more flexibility.

    Nigel

  • Disable the buttons

    I have a page that I have 6 video clips that are treated as buttons. I have another page behind this page with an alpha of 0. One of the buttons on the home page brings the alpha of the last page 1 and greater than 0 page. My problem is that I turn off the hand cursor when the last page is at the front, but if I click where a button was it will execute the functions of the button. How can I disable the button functions when the page with all the buttons in the back? The other issue I have is as soon as I disable the hand cursor that he won't return. I try to turn the buttonMode back to true, but it doesn't seem to work. Hope that makes sense, and someone can help you. Thank you

    Thanks, that worked great!

  • Disable the button Wireless Laser Mouse PA3706E Alt + Tab?

    I have what I think, it's a mouse Toshiba PA3706E (it's the one in the picture below)

    It has a small button of Alt + Tab at the worst place in the fact that it could be, and I was wondering if anyone knows a way to disable? I installed the thing that comes with it to change the functions of the buttons, but for some reason, it is the only button you cannot not change or not. The only option for the Application Switch button is Alt + Tab.

    http://img340.imageshack.us/img340/8080/mousedriver.PNG

    Anyone? It's makes me absolutely crazy and things like TF2 happens to crash when it Alt + tabs; -

    > Is it possible to disable it, as pilot/configure CD software that comes with the mouse wont allow it.
    Well, if the software that came with the mouse, does not support this option, then I put t see any other possibility to disable the button ALT + TAB.

  • Disable the buttons before webservice response

    Hello

    How to disable the buttons until the webservice response came, but when came the web service respone it will allow all the button

    can you give me any suggestions...

    Thank you

    Learning by doing. I've attached an example that does what you want to do, disable the buttons x, where x in this example is 5 seconds to activate the buttons and where x for you would be availability of webservice response.

    All what you need to do is:

    • Add ID to your buttons (see the example input elements I used)
    • Add the source to remove the attribute "disabled" of these buttons (see the example of function that I have documented)

    She's.

  • Disable the button of the model

    Hello

    I m using Oracle 11 g and Apex - 4.0.2 version

    I m having a request to disable the button of the model based on the condition.

    Model name of the button 'enable '.

    Click the button for the first time he would execute a process and then it should disable the buttons.

    Is this possible?

    Kind regards

    VK.

    Hello

    When you inspect your via firebug or chrome or any other Inspector HTML button element, you see nay ID of the button? or button name?

    If so, you can use the jQuery selector by: #BTN_ACTIVATE (BTN_ACTIVE is the ID of the button) or [name = 'BUTTON_NAME'] is used instead of code name attribute here.

    You can choose the first option...

    First try a simple test with dynamic action like that.

    DA: Event: click on

    Selection type: jQuery Selector

    jQuery Selector: #BTN_ACTIVATE (or [name = 'BUTTON_NAME'])

    As a true action defined only the encrypted messages alert. If the message appears, the selector is written OK. If not try looking at the jQuery selectors

    Don't forget to put the when click the option button - send page by default.

    concerning

    J

  • disable the button if the table is filtered

    Hello
    I have a command button and a table of the adf on a jspx page.
    I keep the filtering enabled for the table.

    My requirement is I have to disable the button if the table is filtered and as soon as table becomes 'normal' or a filtered ' I should activate this button.
    can anyone suggest a way to implement this use case?

    Thank you.

    Just add a listener of the request at the table that is called whenever the query is filtered. Detect if the filter criteria list is empty and refresh your button accordingly

    public void queryListener (QueryEvent queryEvent)
    {
    FilterableQueryDescriptor desc = queryEvent.getDescriptor ((FilterableQueryDescriptor));

    Card filterCriteria = desc.getFilterCriteria ();

    Refresh your button here.

    call listener default query to run the query
    Object query = JSFUtils.resolveExpression ("#{bindings.") MyROViewQuery}");
    (Query) .processQuery (queryEvent) (FacesCtrlSearchBinding);
    }

    to avoid using the class FacesCtrlSearchBinding uses the example of
    http://www.Oracle.com/technetwork/developer-tools/ADF/learnmore/30-table-filter-queries-169172.PDF

    () invokeMethodExpression
    "#{bindings." DepartmentsView1Query.processQuery} «»
    Object.Class, QueryEvent.Class, queryEvent);
    }

    Published by: Don Kleppinger on June 4, 2013 12:02

  • Need to disable the button until all the elements of the array was posted

    Hello

    I get a lot of help from this Forum, thought about getting more out of it. I am very new to AS3 and to do my best to get as much as I can that are still a few problems to come through.

    I am trying to disable the button on a specific image until all the Clips of film in a table are bieng is displayed, otherwise it should show another clip from movie plurarite the message that all video Clips are not displayed.

    Here's the scenario-

    SUMMARY.

    There are three buttons on the stage, the next image button, button to load the 1st Movie Clip (note1), button to load the second film Clip (note2)

    I'm counting the Clips of film with the length of the array (I don't know if I'm doing things), but the idea is that once all the video clips are loaded, next picture button must be activated in the case otherwise he must remain inactive, rather would display another clip of film as notice that all Clips are not loaded)

    Here is my Code.

    import flash.events.MouseEvent;

    btnnxt.mouseEnabled = false;

    var note1:Mc_Notice1 = new Mc_Notice1;

    var note2:Mc_Notice2 = new Mc_Notice2;

    function next(Event:MouseEvent):void

    {

    if(Count.Length == 2)

    {

    btnnxt.mouseEnabled = true;

    nextFrame();

    trace ("mouse is on");

    }

    else {}

    btnnxt.mouseEnabled = false;

    }

    }

    notes of the var: Array = [note1, note 2, note3];

    var numbers: Array = new Array();

    btnnxt.addEventListener (MouseEvent.CLICK, next);

    btnload1.addEventListener (MouseEvent.CLICK, hearings1);

    btnload2.addEventListener (MouseEvent.CLICK, load2);

    function load1(Event:MouseEvent):void

    {

    addChild (notes [0]);

    Notes [0] .x = 100;

    Notes [0] there = 100;

    Count.push (1);

    trace ('Count' + count.length);

    }

    function load2(Event:MouseEvent):void {}

    addChild (notes [1]);

    Notes [0] .x = 100;

    Notes [0] there = 100;

    Count.push (1);

    trace (counting);

    count0 = 1;

    trace (count.length);

    }

    Please help in fixing this error that I do not receive the required results.

    Help, please.

    Best regards

    Part of the problem is that you try to count by clicking a disabled button to activate this button.  As long as the button is disabled you can not use it for himself.  Instead of adding an event listener to btnnxt immediately, just assign it when it is ready to be used.  Whenever you load you need to check the value of the counter and if it is equal to 2, then you can assign the event listener for the btnnxt.

    You do not have a (County) table for that since you're using only its length property... a simple integer value will suffice.

    As I do not see you create a variable named note3, you probably get an error for this.

    In your function load2 you always aim the remark 1 placement where it should be placed.

  • YouTube I have to press the button "back" twice to return to the previous page

    Hello!

    FF constantly and across operating systems (I use many for most Linux distributions) fails to simply go back to the previous page when I press the button 'back' of the browser. He did it for months. Completely reset FF does not work, or not to empty the cache then restarting it manually.

    It is a very irritating problem, especially since I prefer FF so strongly on another browser and do not want to hit back twice whenever I want to go to a play list/etc. To clarify, it reloads the page/video, I am currently on, then finally doing what I want to after 2 clicks the 'back' button For someone who needs YouTube to work, as well as for reasons a many great tutorials that needs resolution as soon as POSSIBLE.

    Thanks in advance for any help! In my opinion, I've isolated probably the question enough that it is very likely to be a problem with my OS or malicious software.

    What is the most likely culprit here?

    I should also mention that this is happening not only across operating systems, but also on a laptop Lenovo G770 and an AMD FX - 8350 16 GB RAM PC desktop I built very recently.

    If it works in Mode safe mode and normal mode with all extensions (Firefox/tools > Modules > Extensions) off and then try to find which extension is the cause by allowing an extension at a time until the problem reappears.

    Close and restart Firefox after each change via "Firefox > Exit ' (Windows: Firefox/file > quit;) Mac: Firefox > quit Firefox. Linux: Firefox/file > exit)

  • Can you is more middle - click on the buttons back and forward to open the most recent last/next page as a new tab?

    I use Firefox 26, and I remember at some point in the past you could middle - click on the buttons back and forward to open the most recent last/next page as a new tab. Now, it does not work. I have not changed anything else on Firefox I know works, so was it gradually as keyword.url or is this something else?

    ... OK, this is weird. I restarted Firefox in safe mode and the reworked for/back Middle-click, so I thought it was one of my modules. Yet once, I opened Firefox in normal mode... and Middle-click works.

    I have no idea.

  • What happened to the access of the button "back" to several pages past?

    What happened to the access of the button "back" to several pages past?

    The arrow to open the history tab of the previous buttons and following was removed in Firefox 4.

    Use one of the following methods to open the tab history list:

    • Right-click on the back or next button
    • Press and hold the left button of the mouse on the active back or forward button until the list opens

    You can watch this extension:

  • Apex - disable the button using PL/SQL code

    Hi all

    I use a PL/SQL code to get a DB value, depending on the value that I need to disable the buttons on the Page.

    I tried code below

    IF : P2_FLAG == ' not THEN

    HTP.script ("document.getElementById ("SUBMIT") .disabled = false;", "Javascript");

    END IF;

    It is said screw the page saying - the/apex/f requested URL was not found on this server

    I use Apex 5.0, please need your contributions.

    Hello

    However, if you want to show/hide the button, you can use conditions:

    Open the properties of the button and put Conditions such as "Item = value '.

    Point - P2_FLAG

    Value - N

    To turn on or off, you must run ajax with jquery to get the DB value before charge and then print button.

    It may be useful

    Sunil Bhatia

  • How to disable the button create and edit button in IMPORT environment for all the modules of 6.1.1.1?

    Hi all

    I am trying to disable some built-in options for all modules as well as all users in paragraph 6.1.1.1.

    How to disable the button create and edit button in IMPORT environment for all the modules of 6.1.1.1.?

    Please help me solve this problem.

    Thank you

    Nefertari

    Thank you Ivy, Yes.

    I made some changes more in environment settings that helped me to turn off the button the user create a user/edit.

    Thank you

    Nefertari

  • How can I disable the buttons next/previous slide show?

    Hi guys!

    I tried to play with a slide show earlier and wanted to change the colour or the next/previous buttons to image placement. But every time that you click on that it passes to the next photo! Is there a way to disable the buttons temporarily? It also appears that the buttons should be the same color for each photo. Am I wrong?

    Thanks in advance!

    Hello

    You cannot disable the buttons next and previous, you can hide them via the options menu flying if you want (select the widget > click the blue circle with the white arrow at the top right of the widget).

    However, even if the next/previous buttons will take you to another image, you can still change them, when they are selected, as the buttons remain same for all slides.

    In addition, the buttons should be the same color for each photo.

    It will be useful,

    Sonam

Maybe you are looking for

  • Lack of PCI device

    I bought a laptop HP ProBook 450 G1 in March 2014. I got Windows 7 but it has got some problems so I instlled 8.1 Win. Now, everything fine except the problem shown in the picture above. How can I solve this?

  • Cannot install the Scanner

    After the safety scanner download it will not be installed and there is a message that says that this version of the scanner has expired and does not work.  What should I do?

  • ISATAP problem

    MS ISATAP Adapter, MS ISATAP problem adjust # 2 Driver and driver MS Teredo Tunneling problems which could not be fixed automatically by the software. I use a wireless connection. I can't locate these adapters in my computer.

  • BlackBerry smartphone how to level of 9000 "BOLD"

    Hi all... I want to improve my Blackberry Bold 9000... How to upgrade my BB B 9000? My current v4.6.0.303

  • Marker-end of property defined in the css do not made

    Hello The end of the marker in scene.css: svg line.arrow {} stroke: #888888; stroke-width:1px; marker-end: url(#markerArrow); } "is not rendered in Firefox when browsing: