diff options
author | whiteshark0 <whiteshark0@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2007-06-08 16:23:40 +0000 |
---|---|---|
committer | whiteshark0 <whiteshark0@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2007-06-08 16:23:40 +0000 |
commit | 4131257e42ceb88fa4fb2849b5c40011e8b5635d (patch) | |
tree | c283788511d166d0ddd0cd876d0edeb3e98f3039 /Game | |
parent | 18579e1d865dc0fbd9c179fc5d45b1fff2b9033b (diff) | |
download | usdx-4131257e42ceb88fa4fb2849b5c40011e8b5635d.tar.gz usdx-4131257e42ceb88fa4fb2849b5c40011e8b5635d.tar.xz usdx-4131257e42ceb88fa4fb2849b5c40011e8b5635d.zip |
Added ability to delete a Playlist within the Menu
Language Files updated
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@248 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to 'Game')
-rw-r--r-- | Game/Code/Classes/UPlaylist.pas | 2 | ||||
-rw-r--r-- | Game/Code/Screens/UScreenSongMenu.pas | 55 |
2 files changed, 50 insertions, 7 deletions
diff --git a/Game/Code/Classes/UPlaylist.pas b/Game/Code/Classes/UPlaylist.pas index 55cf90ff..e3f68239 100644 --- a/Game/Code/Classes/UPlaylist.pas +++ b/Game/Code/Classes/UPlaylist.pas @@ -327,9 +327,11 @@ begin if (CatSongs.CatNumShow = -3) and (Index = CurPlaylist) then
begin
ScreenSong.UnLoadDetailedCover;
+ ScreenSong.HideCatTL;
CatSongs.SetFilter('', 0);
ScreenSong.Interaction := 0;
ScreenSong.FixSelected;
+ ScreenSong.ChangeMusic;
end;
end;
diff --git a/Game/Code/Screens/UScreenSongMenu.pas b/Game/Code/Screens/UScreenSongMenu.pas index 3814334c..06b8f183 100644 --- a/Game/Code/Screens/UScreenSongMenu.pas +++ b/Game/Code/Screens/UScreenSongMenu.pas @@ -27,9 +27,10 @@ const SM_Playlist_Add = 64 or 2;
SM_Playlist_New = 64 or 3;
- SM_Playlist_Del = 64 or 5;
+ SM_Playlist_DelItem = 64 or 5;
SM_Playlist_Load = 64 or 8 or 1;
+ SM_Playlist_Del = 64 or 8 or 5;
SM_Party_Main = 128 or 1;
@@ -42,7 +43,7 @@ var implementation
-uses UGraphic, UMain, UIni, UTexture, ULanguage, UParty, UPlaylist;
+uses UGraphic, UMain, UIni, UTexture, ULanguage, UParty, UPlaylist, USongs;
function TScreenSongMenu.ParseInput(PressedKey: Cardinal; ScanCode: byte; PressedDown: Boolean): Boolean;
begin
@@ -265,10 +266,10 @@ begin Button[3].Text[0].Text := Language.Translate('SONG_MENU_CANCEL');
end;
- SM_PlayList_Del:
+ SM_Playlist_DelItem:
begin
CurMenu := sMenu;
- Text[0].Text := Language.Translate('SONG_MENU_NAME_PLAYLIST_DEL');
+ Text[0].Text := Language.Translate('SONG_MENU_NAME_PLAYLIST_DELITEM');
Button[0].Visible := True;
Button[1].Visible := False;
@@ -285,12 +286,15 @@ begin CurMenu := sMenu;
Text[0].Text := Language.Translate('SONG_MENU_NAME_PLAYLIST_LOAD');
- Button[0].Visible := False;
+ //Show Delete Curent Playlist Button when Playlist is opened
+ Button[0].Visible := (CatSongs.CatNumShow = -3);
+
Button[1].Visible := False;
Button[2].Visible := False;
Button[3].Visible := True;
SelectsS[0].Visible := True;
+ Button[0].Text[0].Text := Language.Translate('SONG_MENU_PLAYLIST_DELCURRENT');
Button[3].Text[0].Text := Language.Translate('SONG_MENU_PLAYLIST_LOAD');
SetLength(ISelections, Length(PlaylistMan.Playlists));
@@ -311,6 +315,21 @@ begin end;
end;
+ SM_Playlist_Del:
+ begin
+ CurMenu := sMenu;
+ Text[0].Text := Language.Translate('SONG_MENU_NAME_PLAYLIST_DEL');
+
+ Button[0].Visible := True;
+ Button[1].Visible := False;
+ Button[2].Visible := False;
+ Button[3].Visible := True;
+ SelectsS[0].Visible := False;
+
+ Button[0].Text[0].Text := Language.Translate('SONG_MENU_YES');
+ Button[3].Text[0].Text := Language.Translate('SONG_MENU_CANCEL');
+ end;
+
SM_Party_Main:
begin
@@ -421,7 +440,7 @@ begin 2: //Button 3
begin
//Show add to Playlist Menu
- MenuShow(SM_Playlist_Del);
+ MenuShow(SM_Playlist_DelItem);
end;
3: //SelectSlide 3
@@ -488,7 +507,7 @@ begin end;
end;
- SM_PlayList_Del:
+ SM_Playlist_DelItem:
begin
Visible := False;
Case Interaction of
@@ -509,6 +528,10 @@ begin SM_Playlist_Load:
begin
Case Interaction of
+ 0: //Button 1 (Delete Playlist)
+ begin
+ MenuShow(SM_Playlist_Del);
+ end;
4: //Button 4
begin
//Load Playlist
@@ -518,6 +541,24 @@ begin end;
end;
+ SM_Playlist_Del:
+ begin
+ Visible := False;
+ Case Interaction of
+ 0: //Button 1
+ begin
+ //Delete
+ PlayListMan.DelPlaylist(PlaylistMan.CurPlayList);
+ Visible := False;
+ end;
+
+ 4: //Button 4
+ begin
+ MenuShow(SM_Playlist_Load);
+ end;
+ end;
+ end;
+
SM_Party_Main:
begin
Case Interaction of
|