Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 24d248ac authored by Wink Saville's avatar Wink Saville
Browse files

Add new StateMachine constructor with name and handler params.

Change-Id: Ic252de6cac24a043050b37d81767d19e2739b2fc
parent 261f82ca
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -1256,6 +1256,15 @@ public class StateMachine {
        initStateMachine(name, looper);
    }

    /**
     * Constructor creates a StateMachine using the handler.
     *
     * @param name of the state machine
     */
    protected StateMachine(String name, Handler handler) {
        initStateMachine(name, handler.getLooper());
    }

    /**
     * Add a new state to the state machine
     * @param state the state to add