summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorAlexey Kulakov <panda75@bk.ru>2012-11-21 19:42:22 +0000
committerAlexey Kulakov <panda75@bk.ru>2012-11-21 19:42:22 +0000
commitfe95e19dc7743834b53c82afcf04c233e40db8db (patch)
treef571518f1c40cd4b945e64a675ee2a7a29335f16 /plugins
parenta8f0df159c82d4e1b7d610f302dbc2a09479c341 (diff)
xstatus api fixes
mradio frame button fix api updates git-svn-id: http://svn.miranda-ng.org/main/trunk@2420 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins')
-rw-r--r--plugins/Actman/i_contact.inc2
-rw-r--r--plugins/ExternalAPI/delphi/m_extraicons.inc87
-rw-r--r--plugins/QuickSearch/qs.rc8
-rw-r--r--plugins/QuickSearch/quicksearch.dpr2
-rw-r--r--plugins/QuickSearch/sr_window.pas8
-rw-r--r--plugins/Utils.pas/cbex.pas6
-rw-r--r--plugins/Utils.pas/protocols.pas39
-rw-r--r--plugins/Watrack/status/i_opt_11.inc2
8 files changed, 34 insertions, 120 deletions
diff --git a/plugins/Actman/i_contact.inc b/plugins/Actman/i_contact.inc
index 40cd6f18f7..afbbcd6800 100644
--- a/plugins/Actman/i_contact.inc
+++ b/plugins/Actman/i_contact.inc
@@ -64,7 +64,7 @@ begin
else
begin
uid:=pAnsiChar(CallProtoService(acc,PS_GETCAPS,PFLAG_UNIQUEIDSETTING,0));
- if uint_ptr(uid)<>CALLSERVICE_NOTFOUND then
+ if int_ptr(uid)<>CALLSERVICE_NOTFOUND then
begin
if DBReadSetting(hContact,acc,uid,@ldbv)=0 then
begin
diff --git a/plugins/ExternalAPI/delphi/m_extraicons.inc b/plugins/ExternalAPI/delphi/m_extraicons.inc
deleted file mode 100644
index b6c1a028df..0000000000
--- a/plugins/ExternalAPI/delphi/m_extraicons.inc
+++ /dev/null
@@ -1,87 +0,0 @@
-{
- Copyright (C) 2009 Ricardo Pescuma Domenecci
-
- This is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public
- License along with this file; see the file license.txt. If
- not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- Boston, MA 02111-1307, USA.
-}
-
-{$IFNDEF M_EXTRAICONS}
-{$DEFINE M_EXTRAICONS}
-
-const
- EXTRAICON_TYPE_CALLBACK = 0; // Similar to old clist callbacks, it fires 2 notifications
- EXTRAICON_TYPE_ICOLIB = 1; // This extra icon will use only icons registered with icolib.
- // No callbacks needed. Just call MS_EXTRAICON_SET_ICON passing the name of the
- // extraicon to set one.
-
-type
- TEXTRAICON_INFO = record
- cbSize:int;
- _type :int; // One of EXTRAICON_TYPE_*
- name :PAnsiChar; // Internal name. More than one plugin can register extra icons
- // with the same name if both have the same type. In this case,
- // both will be handled as one. This is usefull for ex for extra
- // status, where icq and jabber can share the same slot.
- // If the types are different the second one will be denied.
- description:PAnsiChar; // [Translated by plugin] Description to be used in GUI
- descIcon :PAnsiChar; // [Optional] Name of an icon registered with icolib to be used in GUI.
-
- // If type == EXTRAICON_TYPE_CALLBACK this two must be set
-
- // Callback to add icons to clist, calling MS_CLIST_EXTRA_ADD_ICON
- // wParam=lParam=0
- RebuildIcons:TMIRANDAHOOK;
-
- // Callback to set the icon to clist, calling MS_CLIST_EXTRA_SET_ICON or MS_EXTRAICON_SET_ICON
- // wParam = HANDLE hContact
- // lParam = int slot
- ApplyIcon:TMIRANDAHOOK;
-
- // Other optional callbacks
-
- // [Optional] Callback called when extra icon was clicked
- // wParam = HANDLE hContact
- // lParam = int slot
- // param = onClickParam
- OnClick:TMIRANDAHOOKPARAM;
-
- onClickParam:LPARAM;
- end;
-
-const
-// Register an extra icon
-// wParam = (EXTRAICON_INFO *) Extra icon info
-// lParam = 0
-// Return: (HANDLE) id of extra icon on success, 0 on error
- MS_EXTRAICON_REGISTER:PAnsiChar = 'ExtraIcon/Register';
-
-type
- TEXTRAICON = record
- cbSize :int;
- hExtraIcon:THANDLE; // Value returned by MS_EXTRAICON_REGISTER
- hContact :THANDLE; // Contact to set the extra icon
- // The icon to be set. This depends on the type of the extra icon:
- case boolean of
- false:(hImage :THANDLE); // Value returned by MS_CLIST_EXTRA_ADD_ICON (if EXTRAICON_TYPE_CALLBACK)
- true :(icoName:PAnsiChar); // Name of the icon registered with icolib (if EXTRAICON_TYPE_ICOLIB)
- end;
-
-const
-// Set an extra icon icon
-// wParam = (EXTRAICON *) Extra icon
-// Return: 0 on success
- MS_EXTRAICON_SET_ICON:PAnsiChar = 'ExtraIcon/SetIcon';
-
-{$ENDIF}
diff --git a/plugins/QuickSearch/qs.rc b/plugins/QuickSearch/qs.rc
index d22a32c57d..0f4e27d46a 100644
--- a/plugins/QuickSearch/qs.rc
+++ b/plugins/QuickSearch/qs.rc
@@ -163,12 +163,12 @@ BEGIN
VALUE "CompanyName",""
VALUE "Comments", "Plugin to quick search for nickname, firstname, lastname, email, uin in your contact list"0
VALUE "FileDescription", "Quick info search plugin for Miranda NG"0
- VALUE "FileVersion", "1, 4, 1, 18 "0
- VALUE "InternalName", "QuickSearchMod"0
+ VALUE "FileVersion", "1, 4, 1, 19 "0
+ VALUE "InternalName", "QuickSearch"0
VALUE "OriginalFilename", "quicksearch.dll"0
- VALUE "ProductName", "QuickSearchMod Dynamic Link Library (DLL)"0
+ VALUE "ProductName", "QuickSearch Dynamic Link Library (DLL)"0
VALUE "ProductVersion", "0, 8, 0, 0 "0
- VALUE "SpecialBuild", "2.07.2010 "0
+ VALUE "SpecialBuild", "12.09.2012 "0
END
END
BLOCK "VarFileInfo"
diff --git a/plugins/QuickSearch/quicksearch.dpr b/plugins/QuickSearch/quicksearch.dpr
index 699472b7b1..80901724d6 100644
--- a/plugins/QuickSearch/quicksearch.dpr
+++ b/plugins/QuickSearch/quicksearch.dpr
@@ -36,7 +36,7 @@ function MirandaPluginInfoEx(mirandaVersion:DWORD):PPLUGININFOEX; cdecl;
begin
result:=@PluginInfo;
PluginInfo.cbSize :=SizeOf(TPLUGININFOEX);
- PluginInfo.shortName :='Quick Search Mod';
+ PluginInfo.shortName :='Quick Search';
PluginInfo.version :=$01040112;
PluginInfo.description:=
'This Plugin allow you to quick search for nickname,'+
diff --git a/plugins/QuickSearch/sr_window.pas b/plugins/QuickSearch/sr_window.pas
index 5df340f575..517ab736ad 100644
--- a/plugins/QuickSearch/sr_window.pas
+++ b/plugins/QuickSearch/sr_window.pas
@@ -527,7 +527,7 @@ begin
if wparam._type=ptCurrent then wparam.n:=hContact;
if lparam._type=ptCurrent then lparam.n:=hContact;
tmp:=CallService(protov,wparam.n,lparam.n);
- if int_ptr(tmp)=int_ptr(CALLSERVICE_NOTFOUND) then exit;
+ if tmp=CALLSERVICE_NOTFOUND then exit;
case setting_cnftype of
ptString: begin
AnsiToWide(PAnsiChar(tmp),res.text);
@@ -1464,7 +1464,7 @@ var
i,num,cnt:integer;
pinfo:LV_HITTESTINFO;
TI:TToolInfoW;
- ics:TICQ_CUSTOM_STATUS;
+ ics:TCUSTOM_STATUS;
info:TCLCINFOTIP;
// qsr:tQSRec;
@@ -1686,7 +1686,7 @@ end;
StrCopyW(buf,MainBuf[i,OldHSubItem].text);
ics.flags:=CSSF_DEFAULT_NAME or CSSF_MASK_NAME or CSSF_UNICODE;
- StrCopy(StrCopyE(buf1,GetProtoName(FlagBuf[i].proto)),PS_ICQ_GETCUSTOMSTATUSEX);
+ StrCopy(StrCopyE(buf1,GetProtoName(FlagBuf[i].proto)),PS_GETCUSTOMSTATUSEX);
i:=StrToInt(buf);
ics.wParam:=@i;
@@ -1926,7 +1926,7 @@ begin
j:=StrToInt(MainBuf[i,sub].text);
if j>0 then
begin
- StrCopy(StrCopyE(buf,GetProtoName(FlagBuf[i].proto)),PS_ICQ_GETCUSTOMSTATUSICON);
+ StrCopy(StrCopyE(buf,GetProtoName(FlagBuf[i].proto)),PS_GETCUSTOMSTATUSICON);
if ServiceExists(buf)<>0 then
begin
h:=CallService(buf,j,LR_SHARED);
diff --git a/plugins/Utils.pas/cbex.pas b/plugins/Utils.pas/cbex.pas
index 1c683dd3b8..9805b76634 100644
--- a/plugins/Utils.pas/cbex.pas
+++ b/plugins/Utils.pas/cbex.pas
@@ -19,11 +19,11 @@ var
icon:HICON;
buf,buf1:array [0..127] of AnsiChar;
b:array [0..63] of WideChar;
- ics:TICQ_CUSTOM_STATUS;
+ ics:TCUSTOM_STATUS;
begin
result:=0;
SendMessage(wnd,CB_RESETCONTENT,0,0);
- StrCopy(StrCopyE(buf,proto),PS_ICQ_GETCUSTOMSTATUSICON);
+ StrCopy(StrCopyE(buf,proto),PS_GETCUSTOMSTATUSICON);
if ServiceExists(@buf)=0 then
exit;
@@ -32,7 +32,7 @@ begin
if il=0 then exit;
cnt:=0;
- StrCopy(StrCopyE(buf1,proto),PS_ICQ_GETCUSTOMSTATUSEX);
+ StrCopy(StrCopyE(buf1,proto),PS_GETCUSTOMSTATUSEX);
cbei.mask:=CBEIF_IMAGE or CBEIF_SELECTEDIMAGE or CBEIF_TEXT; //!!
ics.cbSize :=SizEOf(ics);
diff --git a/plugins/Utils.pas/protocols.pas b/plugins/Utils.pas/protocols.pas
index 8b585c39b4..842eb53e85 100644
--- a/plugins/Utils.pas/protocols.pas
+++ b/plugins/Utils.pas/protocols.pas
@@ -415,7 +415,6 @@ begin
end;
for i:=1 to protoCount do
begin
- // active and switched off (but not deleted)
inc(NumProto);
with protos^[NumProto] do
begin
@@ -424,7 +423,7 @@ begin
enabled:=psf_all;//psf_enabled;
status :=0;
-// xstat :=-1;
+// xstat :=-1;
flag:=CallProtoService(name,PS_GETCAPS,PFLAGNUM_2,0);
if (flag and PF2_ONLINE) <>0 then status:=status or psf_online;
if (flag and PF2_INVISIBLE) <>0 then status:=status or psf_invisible;
@@ -440,18 +439,19 @@ begin
if ((flag and PF1_CHAT)<>0) or
(DBReadByte(0,name,'CtcpChatAccept',13)<>13) or // IRC
(DBReadByte(0,name,'Jud',13)<>13) then // Jabber
-// flag:=CallProtoService(name,PS_GETCAPS,PFLAGNUM_1,0);
-// if (flag and PF1_CHAT)<>0 then
+// flag:=CallProtoService(name,PS_GETCAPS,PFLAGNUM_1,0);
+// if (flag and PF1_CHAT)<>0 then
status:=status or psf_chat;
+
p:=StrCopyE(buf,name);
- StrCopy(p,PS_ICQ_GETCUSTOMSTATUS);
+ StrCopy(p,PS_GETCUSTOMSTATUSEX);
if ServiceExists(buf)<>0 then
status:=status or psf_icq;
StrCopy(p,PS_SET_LISTENINGTO);
if ServiceExists(buf)<>0 then
status:=status or psf_tunes;
-
+
end;
inc(proto);
end;
@@ -519,7 +519,7 @@ end;
function SetXStatus(proto:PAnsiChar;newstatus:integer;
txt:pWideChar=nil;title:pWideChar=nil):integer;
var
- ics:TICQ_CUSTOM_STATUS;
+ ics:TCUSTOM_STATUS;
begin
result:=0;
if IsXStatusSupported(uint_ptr(proto)) then
@@ -544,23 +544,24 @@ begin
szMessage.w:=txt;
end;
end;
- result:=CallProtoService(proto,PS_ICQ_SETCUSTOMSTATUSEX,0,lparam(@ics));
+ result:=CallProtoService(proto,PS_SETCUSTOMSTATUSEX,0,lparam(@ics));
end;
end;
function GetXStatus(proto:PAnsiChar;txt:pointer=nil;title:pointer=nil):integer;
var
+{
buf:array [0..127] of AnsiChar;
pc:PAnsiChar;
param:array [0..63] of AnsiChar;
-
-// ics:TICQ_CUSTOM_STATUS;
-// i,j:integer;
+}
+ ics:TCUSTOM_STATUS;
+ i,j:integer;
begin
result:=0;
if IsXStatusSupported(uint_ptr(proto)) then
begin
-{
+
with ics do
begin
cbSize:=SizeOf(ics);
@@ -568,7 +569,7 @@ begin
wParam:=@i;
lParam:=@j;
end;
- CallProtoService(0,PS_ICQ_GETCUSTOMSTATUSEX,0,dword(@ics));
+ CallProtoService(proto,PS_GETCUSTOMSTATUSEX,0,dword(@ics));
if title<>nil then
mGetMem(title^,(i+1)*SizeOf(WideChar));
if txt<>nil then
@@ -579,14 +580,14 @@ begin
cbSize:=SizeOf(ics);
flags:=CSSF_MASK_STATUS or CSSF_MASK_NAME or CSSF_MASK_MESSAGE or CSSF_UNICODE;
status:=@result;
- szName.w :=pdword(title)^;
- szMessage.w:=pdword(txt)^;
+ szName.w :=pWideChar(title);
+ szMessage.w:=pWideChar(txt);
end;
- CallProtoService(0,PS_ICQ_GETCUSTOMSTATUSEX,0,dword(@ics));
-}
+ CallProtoService(proto,PS_GETCUSTOMSTATUSEX,0,dword(@ics));
+{
StrCopy(buf,proto);
- StrCat (buf,PS_ICQ_GETCUSTOMSTATUS);
+ StrCat (buf,PS_GETCUSTOMSTATUS);
result:=CallService(buf,0,0);
if (txt<>nil) or (title<>nil) then
begin
@@ -603,7 +604,7 @@ begin
StrCopy(pc,'Name'); pWideChar(title^):=DBReadUnicode(0,proto,param,nil);
end;
end;
-
+}
end;
end;
diff --git a/plugins/Watrack/status/i_opt_11.inc b/plugins/Watrack/status/i_opt_11.inc
index 55279d3156..1e6e3ab8e9 100644
--- a/plugins/Watrack/status/i_opt_11.inc
+++ b/plugins/Watrack/status/i_opt_11.inc
@@ -141,7 +141,7 @@ begin
// ListView_GetItemTextA(wnd,CurProto,0,@buf,SizeOf(buf));
StrCopy(buf,GetProtoName(CurProto));
- StrCat(buf,PS_ICQ_GETCUSTOMSTATUSICON);
+ StrCat(buf,PS_GETCUSTOMSTATUSICON);
endis:=ServiceExists(buf)<>0;
EnableWindow(GetDlgItem(Dialog,IDC_CBEX ),endis);