diff options
author | George Hazan <george.hazan@gmail.com> | 2013-03-10 19:12:33 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2013-03-10 19:12:33 +0000 |
commit | 6ad65c4d4fce1d5ce1a1873ee84feaff753c9d48 (patch) | |
tree | 94e232bdd680291eb7192851d71935f89b196fd2 /plugins/Watrack/srv_player.pas | |
parent | 9a4be1a673e76cb205a11076b7d8162eb593feab (diff) |
Watrack:
- event hooks wiped out;
- icons & menus optimization;
- merge of memory leak fix
git-svn-id: http://svn.miranda-ng.org/main/trunk@3963 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Watrack/srv_player.pas')
-rw-r--r-- | plugins/Watrack/srv_player.pas | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/plugins/Watrack/srv_player.pas b/plugins/Watrack/srv_player.pas index 69bac628fd..07db406a8a 100644 --- a/plugins/Watrack/srv_player.pas +++ b/plugins/Watrack/srv_player.pas @@ -550,9 +550,15 @@ begin UTF8ToWide(GetParamSectionStr(sec,'notes'),rec.Notes);
- ServicePlayer(WAT_ACT_REGISTER,lparam(@rec));
+ if ServicePlayer(WAT_ACT_REGISTER,lparam(@rec))=WAT_RES_ERROR then
+ begin
+ ClearTemplate(pcell);
+// mFreeMem(rec.URL);
+ mFreeMem(rec.Notes);
+ end
+ else
+ inc(NumPlayers);
- inc(NumPlayers);
while ptr^<>#0 do inc(ptr);
inc(ptr);
end;
@@ -740,7 +746,7 @@ var begin
result:=WAT_RES_ERROR;
wnd:=CheckAllPlayers(flags,lstat,dummy);
- if wnd<>dword(WAT_RES_NOTFOUND) then
+ if wnd<>THANDLE(WAT_RES_NOTFOUND) then
if plyLink^[0].Command<>nil then
result:=tCommandProc(plyLink^[0].Command)(wnd,wParam,lParam)
else if (plyLink^[0].flags and WAT_OPT_WINAMPAPI)<>0 then
|