summaryrefslogtreecommitdiff
path: root/plugins/Watrack/popup/popups.pas
diff options
context:
space:
mode:
authorAlexey Kulakov <panda75@bk.ru>2014-04-24 14:55:20 +0000
committerAlexey Kulakov <panda75@bk.ru>2014-04-24 14:55:20 +0000
commitc3a168743616db6606702db5ad0fecab4dfee3da (patch)
tree523ef1399093917f3565d769826ceecb7eb2ef6c /plugins/Watrack/popup/popups.pas
parent90ad600cb38a04c9272a3599c72d6559c822b155 (diff)
Miranda API update
Watrack refactoring, API changes git-svn-id: http://svn.miranda-ng.org/main/trunk@9068 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Watrack/popup/popups.pas')
-rw-r--r--plugins/Watrack/popup/popups.pas39
1 files changed, 10 insertions, 29 deletions
diff --git a/plugins/Watrack/popup/popups.pas b/plugins/Watrack/popup/popups.pas
index eda32a07ce..67ac946579 100644
--- a/plugins/Watrack/popup/popups.pas
+++ b/plugins/Watrack/popup/popups.pas
@@ -150,16 +150,10 @@ var
Icon:HICON;
sec:integer;
cb,ct:TCOLORREF;
- line:boolean;
tmp:pAnsiChar;
begin
- line:=CallService(MS_POPUP_ISSECONDLINESHOWN,0,0)<>0;
-
descr:=PWideChar(CallService(MS_WAT_REPLACETEXT,0,lparam(PopText)));
- if line then
- title:=PWideChar(CallService(MS_WAT_REPLACETEXT,0,lparam(PopTitle)))
- else
- title:=nil;
+ title:=PWideChar(CallService(MS_WAT_REPLACETEXT,0,lparam(PopTitle)));
if (descr<>nil) or (title<>nil) then
begin
@@ -204,13 +198,8 @@ begin
colorText :=ct;
PluginWindowProc:=@DumbPopupDlgProc;
- if line then
- begin
- pzTitle.w:=title;
- pzText .w:=descr;
- end
- else
- pzTitle.w:=descr;
+ pzTitle.w:=title;
+ pzText .w:=descr;
if ActionList=nil then
flag:=0
@@ -245,22 +234,14 @@ begin
FillChar(ppdu^,SizeOf(TPOPUPDATAW),0);
with ppdu^ do
begin
- if line then
- begin
- if title<>nil then
- StrCopyW(lpwzContactName,title,MAX_CONTACTNAME-1)
- else
- lpwzContactName[0]:=' ';
- if descr<>nil then
- StrCopyW(lpwzText,descr,MAX_SECONDLINE-1)
- else
- lpwzText[0]:=' ';
- end
+ if title<>nil then
+ StrCopyW(lpwzContactName,title,MAX_CONTACTNAME-1)
+ else
+ lpwzContactName[0]:=' ';
+ if descr<>nil then
+ StrCopyW(lpwzText,descr,MAX_SECONDLINE-1)
else
- begin
- StrCopyW(ppdu^.lpwzContactName,title,MAX_CONTACTNAME-1);
lpwzText[0]:=' ';
- end;
lchIcon :=Icon;
PluginWindowProc:=@DumbPopupDlgProc;
@@ -301,7 +282,7 @@ begin
result:=0;
if DisablePlugin<>dsEnabled then
exit;
- if CallService(MS_WAT_GETMUSICINFO,0,tlparam(@si))=WAT_PLS_NORMAL then
+ if CallService(MS_WAT_GETMUSICINFO,0,tlparam(@si))=WAT_RES_OK then
begin
if PopupPresent then
ShowPopup(si)