diff options
Diffstat (limited to 'watrack_mpd/main.c')
-rwxr-xr-x | watrack_mpd/main.c | 38 |
1 files changed, 23 insertions, 15 deletions
diff --git a/watrack_mpd/main.c b/watrack_mpd/main.c index 108db8b..2904918 100755 --- a/watrack_mpd/main.c +++ b/watrack_mpd/main.c @@ -21,15 +21,18 @@ LPINITPROC Init()
{
+ return 0;
}
LPDEINITPROC DeInit()
{
+ return 0;
}
LPCHECKPROC CheckPlayer(HWND wnd, int flags)
{
}
LPGETSTATUSPROC GetStatus()
{
+ return 0;
}
LPNAMEPROC GetFileName(HWND wnd, int flags)
{
@@ -44,20 +47,25 @@ LPCOMMANDPROC SendCommand(HWND wnd, int command, int value) void RegisterPlayer()
{
- struct tPlayerCell player;
- player.Desc = "MPD desc";
-// player.Check = CheckPlayer(;
- player.Init = Init();
- player.DeInit = DeInit();
- player.GetStatus = GetStatus();
-// player.Command = SendCommand(;
-// player.flags = ;
-// player.GetName = GetFileName(;
-// player.GetInfo = GetPlayerInfo(;
-// player.Icon =
- player.Notes = _T("123");
- player.URL = "http:// ?";
- CallService(MS_WAT_PLAYER, (WPARAM)0, (LPARAM)&player);
+ if(!bWatrackService)
+ return;
+ else //для красоты
+ {
+ struct tPlayerCell player;
+ player.Desc = "MPD desc";
+// player.Check = CheckPlayer(;
+ player.Init = Init();
+ player.DeInit = DeInit();
+ player.GetStatus = GetStatus();
+// player.Command = SendCommand(;
+// player.flags = ;
+// player.GetName = GetFileName(;
+// player.GetInfo = GetPlayerInfo(;
+// player.Icon =
+ player.Notes = _T("123");
+ player.URL = "http:// ?";
+ CallService(MS_WAT_PLAYER, (WPARAM)0, (LPARAM)&player);
+ }
}
DWORD __stdcall Reciever(LPVOID lp)
@@ -67,7 +75,7 @@ DWORD __stdcall Reciever(LPVOID lp) nloc.flags = 0;
nloc.szHost = (char*)mir_u2a(UniGetContactSettingUtf(NULL, szModuleName, "Host", _T("127.0.0.1")));
nloc.wPort = DBGetContactSettingWord(NULL, szModuleName, "Port", 6600);
- NetLib_CreateConnection(ghNetlibUser, &nloc);
+ ghConnection = NetLib_CreateConnection(ghNetlibUser, &nloc);
ghPacketReciever = CreatePacketReciever();
return 0;
|