How to remove a Controller from the router backstack in Conductor?

2k Views Asked by At

I'm using Conductor and Mosby to implement MVP-MVC architecture in an android app.
What I need to do is remove a Controller from the backstack of a router so that upon onBackPressed that controller is no longer brought back up to the front.

1

There are 1 best solutions below

0
On BEST ANSWER

If you want to remove current controller, do like @sockeqwe said: call router.popCurrentController().

If you want to remove some specific controller from the backstack, you could try calling router.popController(your_controller).