* Added new Playlist notification ImportFailed().
The PlaylistListView will trigger it when the import command failed (happens for example when none of the files are media files). * Moved displaying the according alert from the import fommand into the MainWindow. Show the window if necessary. This fixes MediaPlayer just idling in the Deskbar without any window in this case, since the MainWindow is shown after the first call to _SetupWindow() since some time. But _SetupWindow() is not invoked when no file could be opened. * Removed some meanwhile useless debug output. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38757 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -533,11 +533,9 @@ MainWin::MessageReceived(BMessage* msg)
|
||||
}
|
||||
|
||||
case B_REFS_RECEIVED:
|
||||
printf("MainWin::MessageReceived: B_REFS_RECEIVED\n");
|
||||
_RefsReceived(msg);
|
||||
break;
|
||||
case B_SIMPLE_DATA:
|
||||
printf("MainWin::MessageReceived: B_SIMPLE_DATA\n");
|
||||
if (msg->HasRef("refs"))
|
||||
_RefsReceived(msg);
|
||||
break;
|
||||
@@ -604,6 +602,15 @@ MainWin::MessageReceived(BMessage* msg)
|
||||
}
|
||||
break;
|
||||
}
|
||||
case MSG_PLAYLIST_IMPORT_FAILED:
|
||||
{
|
||||
BAlert* alert = new BAlert("Nothing to Play", "None of the files "
|
||||
"you wanted to play appear to be media files.", "OK");
|
||||
alert->Go();
|
||||
|
||||
_ShowIfNeeded();
|
||||
break;
|
||||
}
|
||||
|
||||
// ControllerObserver messages
|
||||
case MSG_CONTROLLER_FILE_FINISHED:
|
||||
|
||||
Reference in New Issue
Block a user