Yeah, the buttons are not behaving quite right. I've put that on the 'will
fix during beta' list. But, since you already dove into it, I'll check it
out tomorrow. But, I need to take the day off. I've been pounding out
freeamp code for waaay too many days straight.
Plus its already 90 degrees outside. :-)
--ruaok Freezerburn! All else is only icing. -- Soul Coughing
Robert Kaye -- [EMAIL PROTECTED] http://moon.eorbit.net/~robert
----- Original Message -----
From: Valters Vingolds <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, October 08, 1999 4:07 PM
Subject: theme.ui glitch: play button turns to 'pause' inappropriately
> When 'Play' is pressed, it turns to pause.
> If song does not play (file not found or pmo/pmi error) the button should
not
> become 'pause' really.
> It should remain as 'play'.
>
> Perhaps good solution would be not to do as:
> [from HandleControlMessage()]
> if (oControlName == string("Play") && eMesg == CM_Pressed)
> {
> int iState = 0;
>
> // get control state
> m_pWindow->ControlIntValue(oControlName, false, iState);
> if (iState == 0) // PLAY
> {
> // set button state to PAUSE
> iState = 1;
> m_pWindow->ControlIntValue(oControlName, true, iState);
> m_pContext->target->AcceptEvent(new Event(CMD_Play));
> m_bPlayShown = false;
> }
> else // PAUSE
> {
> // set button state to PLAY
> iState = 0;
> m_pWindow->ControlIntValue(oControlName, true, iState);
> m_pContext->target->AcceptEvent(new Event(CMD_Pause));
> m_bPlayShown = true;
> }
> return kError_NoErr;
> }
>
>
>
> but to remove the above button manipulations and leave button state
> transitions to code that already is under AcceptEvent():
>
> case INFO_Playing:
> {
> int iState = 1;
> m_pWindow->ControlIntValue(string("Play"), true, iState);
> m_bPlayShown = true;
> break;
> }
> case INFO_Paused:
> case INFO_Stopped:
> {
> int iState = 0;
> m_pWindow->ControlIntValue(string("Play"), true, iState);
> m_bPlayShown = true;
> break;
> }
> case INFO_DoneOutputting:
>
>
> other:
> [from HandeControlMessage()]
> if (oControlName == string("Stop") && eMesg == CM_Pressed)
> {
> int iState = 0;
> m_pWindow->ControlIntValue(oControlName, true, iState);
> m_pContext->target->AcceptEvent(new Event(CMD_Stop));
> m_bPlayShown = true;
> return kError_NoErr;
> }
> what does code for Stop button do? My guess is disable it, but
> how do I know? I could not find where these transitons/states are
> defined/documented... aarrgh.
>
> --
> Valters "WaTT" Vingolds
>