-
Notifications
You must be signed in to change notification settings - Fork 0
/
PlayerTest2.cpp
41 lines (30 loc) · 1.13 KB
/
PlayerTest2.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
//---------------------------------------------------------------------------
#include <vector>
#include <string>
#include <vcl.h>
#include <winbase.h>
#include "Player.h"
#include "WindowsMediaPlayer.h"
#include "ConcretePlayerFacade.h"
#include "PlayerFacade.h"
//---------------------------------------------------------------------------
#pragma argsused
int main(int argc, char* argv[])
{
PlayerFacade *pf = new ConcretePlayerFacade();
pf->setPlayer("WMP9", "C:\\Program Files\\Windows Media Player\\wmplayer.exe");
std::vector<std::string> songlist;
std::string song;
song = "E:\\MP3\\Klassiskt\\Johann Strauss - The Blue Danube.mp3";
songlist.push_back(song);
song = "E:\\MP3\\Klassiskt\\Carl Orff - Fortuna Imperatix Mundi.mp3";
songlist.push_back(song);
song = "E:\\MP3\\Folkmusik\\Orsa spelmän - Brudmarsch från Delsbo.mp3";
songlist.push_back(song);
song = "E:\\MP3\\Reggae\\UB40 - Can't Help Falling in Love.mp3";
songlist.push_back(song);
pf->playMultiple(songlist);
delete pf;
return 0;
}
//---------------------------------------------------------------------------