Multiplex: propagating state of the fragments

Added getCurrentFragmentIndex() which is used in master.js to broadcast info when a fragment is shown or hidden.