Anti-pop help

I am trying to create a ' back' button that will pop the screen current and the first screen under it in the stack. I learned how to pushScreens (thanks guys!) and I assumed anti-pop would work pretty much the same way. Could someone please point what is wrong with this code, could not find it in my books thank you! Oh and eclipse says 'this' inside the square brackets is the problem

ButtonField backBut = new ButtonField ("Back", Field.FIELD_HCENTER) {}
protected boolean trackwheelClick (int status, int time) {}
           
UiApplication.getUiApplication () .popScreen (this);
Returns true;
}
};

additional code

Hi question man... popup on the current screen try the following code...

It does not work... If any problem answer me...

UiApplication.getUiApplication () .popScreen (Ui.getUiEngine () .getActiveScreen ());

Tags: BlackBerry Developers

Similar Questions

  • How to freeze the application waits for a response from anti-pop

    Well I was developed a custom pop filter and I want to know how to stop my request until the anti-pop filter return a response something like Dialog.Ask () anyone have an idea how I can start to do, thank you for your time.

    Ivan

    After some time to read the documentation, I find the solution instead of pushScreen() user to user pushModalScreen(). This method does not return until you call popScreen (Screen). You must call this method on the event thread thank you for your time.

  • Addition of DEFAULT_MENU to anti-pop leads all buttonfields have DEFAULT_MENU

    It's weird!  At least it is to me.

    I added the MENU DEFAULTS to an anti-pop and each ButtonField on this screen now displays a MENU by DEFAULT when I click it.

    ButtonField testbutton = new ButtonField ("test");

    left a listener changes on purpose, for the test.  Other buttons use setChangeListener
    settingsvfm. Add (TestButton);

    settingsps = new PopupScreen (settingsvfm, Screen.DEFAULT_MENU);

    If I change this

    settingsps = new PopupScreen (settingsvfm);

    No DEFAULT_MENU on the buttons.

    Try to add the CONSUME_CLICK style to your buttonfields.

  • Anti-pop Directions

    Hello

    In my pop class:

    private static final int DEFAULT_ORIENTATION = Display.DIRECTION_NORTH; //

    public PopScreen() {}

    Super (new VerticalFieldManager());

    / * shake anti-ecran * /.

    Ui.getUiEngineInstance () .setAcceptableDirections (DEFAULT_ORIENTATION) ;//

    Add (sliderField);

    }

    I want to ban the change of direction of screen, but it will not work in os 6.0!

    someone help me?

    Thank you.

    Thank you for what you have done. I must say that you're a serious and good man.

    If you can't reproduce by following the path, then I'll accept this as resolved, then do it myself.

  • my safari no longer works and anti-pop filter appears permanently

    Bodyguard windows Microsoft popping up saying safari is not working properly... How can I stop.

    Hello Gail,

    I would recommend that you seek here a solution to your problem of Safari:
  • BB10 - bbUI.js - pushScreen + anti-pop question

    Hi everone.

    I'm running into a problem with the functionality of pushScreen (.) and popScreen() bbUI.js. If I have an application with 3-4 + screen and push them to the screen and then try to blow up one by one I'm not able to return to the first screen, the soft seems to not respond. I have already tabled a question in bbUI.js repo but Tim has not yet responded. I have attached a small application that contains 7 screens (0-6, as the screen-table of bb.screens aura) and you can go on screen 0 to 6, then back, but if you go back 2-3 screen using the popScreen() function, it seems to freeze the app.

    I also thought that some things the listener to 'webkitAnimationEnd' is not called and thanks to this, the domReady event is not raised in bbUI.js.

    I hope you can help getting it fixed and get these use cases to work. THX

    Developer benefits other follow-up.  It seems that this problem has been fixed in the /next/ branch of bbui.js:

    https://github.com/BlackBerry/bbUI.js/issues/262

  • Dialog box and anti-pop

    I'm developing a blackberry app in which I need to POP from the screen on the basis of a user; s choice via a dialog box.

    While I've used without success the syntax is the following:

    D = new dialog box dialog box (Dialog.D_OK, "the record updated successfully", Dialog.D_OK, null, 0 ");

    If (d.getSelectedValue () == Dialog.D_OK) {}
    UiApplication.getUiApplication () .popScreen (homeScreen).
    }

    homeScreen is the instance of the form, which is declared and defined in the current class. I also tried to "this". The screen appears when I clicked OK.

    Thanks in advance.

    I agree with Simon.

    InvokeLater Code sample

    UiApplication application = UiApplication.getUiApplication();
    application.invokeLater( new Runnable() {
      public void run() {
         //pop your screen in here
      }
    });
    
  • Why do I get this exception - anti-pop: UiEngine is null! = net.rim.device.api.ui.UiEngineImpl@1ee2b551

    It happens when this code is run:

    public void popMyScreen(){  if (screen != null){    Application.getApplication().invokeLater( new Runnable(){        public void run() {           try{          UiEngine ui = Ui.getUiEngine();           ui.popScreen(screen);     }catch(Throwable e){      if (TasteMyCity.getDebug())TasteMyCity.writelog("******* TasteMyCity popMyScreen  ",e);       screen=null;  }    }});}}
    

    The method is called from a number of places in my code - but sine I put everything in the Ui thread, I thought it would work like this.

    PS: This error message, what is happening in my journal it's track of the stack also has this:

    GraphicsInternal.updateDisplayFromBackBuffer (int, int, int, int, int, int) line: 1132
    UiEngineImpl.removeScreenInternal (Screen) line: 2001

    Most, if not all of them actually run on the thread of events, so you work for yourself.  In addition, given that you have placed the code one invokeLater, you don't need to use the UiEngine looking for the current UiApplication approach - you can use UiApplication.getUiApplication ()...

    Can I ask you to change the code as follows, but put to debug the instructions in the "exceptions" I note so that we can understand what exceptions occur.  You can throw a RuntimeException to each point, if you wanted to, that would get us an at least Stack Trace.

    public void popMyScreen() {}
    If (display! = null) {}
    Application screenApp = screen.getApplication ();
    If (screenApp == null) {}
    Believe that this means that the screen has already been jumped
    return;
    }
    final UiApplication runningApp = UiApplication.getUiApplication ();
    If (runningApp! = screenApp) {}
    This application cannot jump the screen anyway!
    return;
    }
    If (!) () runningApp instanceof )) {}
    Works do not our application!
    Should we be popping screen of others?
    return;
    }
    If {(UiApplication.isEventDispatchThread ())}
    runningApp.popScreen (screen);
    screen = null;
    return;
    }
    runningApp.invokeLater (new Runnable() {}
    public void run() {}
    try {}
    runningApp.popScreen (screen);
    } catch (Throwable e) {}
    If (TasteMyCity.getDebug ()) TasteMyCity.writelog("*** TasteMyCity popMyScreen",e);
    screen = null;
    }
    }
    });
    }
    }

  • push an anti-pop outside the application

    Hi all

    My application has a timer running on the background, I want to raise a popupScreen after 2 minutes off the screen of the application. Do you have an idea to do?

    Thanks for the help

    read this:

    http://www.BlackBerry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/800505/800608/...

  • my programs folder opens upward at the beginning, I tried to fix this in regedit in the typing in. and it always pop. help thank you

    I typed in c:\WINDOWS\system32\userinet.exe,userinet.exe, and it still appears

    Check that nothing in the startup folder in the start menu > programs

    Check also in the config, start > run > msconfig
    then click on the Startup tab

  • Anti-pop BB10 resets form data

    I use bbui.js and ripple 0.9.10 tests I am new to bbui.js so I learn that I will.

    Here's my problem.  I have an application that uses multiple screens.  From the main screen, I push a screen on top that allows the user put in some data.  If the user needs more information they can navigate to another screen that is pushed up.  Now, we have the main screen, a second screen for entry and a third of the screen.  This third screen the user gets what they need, the on-screen and ends at their entrance on the second screen.  Problem is, when the third screen is skipped, any input the user set the second screen before you navigate to the third screen disappeared.  Now I don't know if it's a bug or expected behavior.  If this is the expected behavior is there a people model typical use so the user when the user navigates to other screens of entry on a screen?

    Not even necessary... See examples of code at the beginning of my index.html: