#include "std.mi"

Global Group   grpMain;
Global Group   grpPlay;
Global Button  play;
Global Button  pause;

System.onScriptLoaded() {

	grpMain		= getScriptGroup();
        grpPlay		= grpMain.findObject("PlayButton.Group");
        play		= grpPlay.findObject("play");
        pause		= grpPlay.findObject("pause");

        if (getStatus() == 1){

                play.hide();
        }
        else if (getStatus() == -1 || getStatus() == 0){

                pause.hide();
        }
}

system.onplay() {

        play.hide();
        pause.show();
}

system.onstop() {

        pause.hide();
        play.show();
}

system.onpause() {

        pause.hide();
        play.show();
}

system.onResume() {

        play.hide();
        pause.show();
}

