forked from KolibriOS/kolibrios
ac97snd: try to fix '-h' key, force player to close itself when the song ends
git-svn-id: svn://kolibrios.org@7174 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
d9a1d7b212
commit
25e9e48413
@ -449,9 +449,9 @@ void update_dynamic_content() //Asper +
|
|||||||
|
|
||||||
void draw_window()
|
void draw_window()
|
||||||
{
|
{
|
||||||
BeginDraw();
|
|
||||||
if (!hidden)
|
if (!hidden)
|
||||||
{
|
{
|
||||||
|
BeginDraw();
|
||||||
DrawWindow(100,100,299,main_wh,main_wc,4,0,0,0); //Asper+
|
DrawWindow(100,100,299,main_wh,main_wc,4,0,0,0); //Asper+
|
||||||
|
|
||||||
make_button(7,24,45,13, 0x10|BT_NORMAL,main_bc);
|
make_button(7,24,45,13, 0x10|BT_NORMAL,main_bc);
|
||||||
@ -474,8 +474,8 @@ void draw_window()
|
|||||||
write_text(276,74,main_wc|FONT0,button_PL,sizeof(button_PL)-1); //Asper+ PL button text
|
write_text(276,74,main_wc|FONT0,button_PL,sizeof(button_PL)-1); //Asper+ PL button text
|
||||||
write_text(275,73,0xA0FFA0|FONT0,button_PL,sizeof(button_PL)-1); //Asper+
|
write_text(275,73,0xA0FFA0|FONT0,button_PL,sizeof(button_PL)-1); //Asper+
|
||||||
redraw_R_button();
|
redraw_R_button();
|
||||||
}
|
|
||||||
EndDraw();
|
EndDraw();
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
void draw_progress_bar()
|
void draw_progress_bar()
|
||||||
@ -705,6 +705,7 @@ int main(int argc, char *argv[])
|
|||||||
switch(status)
|
switch(status)
|
||||||
{ case ST_TRACK:
|
{ case ST_TRACK:
|
||||||
StopBuffer(hBuff);
|
StopBuffer(hBuff);
|
||||||
|
if (hidden) ExitInHiddenMode();
|
||||||
if (LoadTrack(++currActive))
|
if (LoadTrack(++currActive))
|
||||||
{
|
{
|
||||||
if (LoadFile(full_filename))
|
if (LoadFile(full_filename))
|
||||||
@ -733,6 +734,7 @@ int main(int argc, char *argv[])
|
|||||||
case ST_STOP:
|
case ST_STOP:
|
||||||
StopBuffer(hBuff);
|
StopBuffer(hBuff);
|
||||||
status = ST_DONE;
|
status = ST_DONE;
|
||||||
|
if (hidden) ExitInHiddenMode();
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
case ST_EXIT:
|
case ST_EXIT:
|
||||||
@ -1106,6 +1108,14 @@ void _stdcall thread_proc(void *param)
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
void ExitInHiddenMode()
|
||||||
|
{
|
||||||
|
uFMOD_StopSong();
|
||||||
|
StopBuffer(hBuff);
|
||||||
|
DestroyBuffer(hBuff);
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
|
||||||
void delay (int val)
|
void delay (int val)
|
||||||
{
|
{
|
||||||
_asm
|
_asm
|
||||||
|
Loading…
Reference in New Issue
Block a user