summaryrefslogtreecommitdiff
path: root/plugins/HistoryPlusPlus/hpp_global.pas
diff options
context:
space:
mode:
authorAlexey Kulakov <panda75@bk.ru>2012-07-05 12:35:02 +0000
committerAlexey Kulakov <panda75@bk.ru>2012-07-05 12:35:02 +0000
commit3e577372cab9dde2981fb4ac143cacce0419b069 (patch)
treec08ee1d69b563c056d8facd7b45325a489972b77 /plugins/HistoryPlusPlus/hpp_global.pas
parentc78cb0fb36db5ac84fdc6f012074a6c1cea68b1e (diff)
m_api: hide hLangpack from interface part
History++ small cleanup git-svn-id: http://svn.miranda-ng.org/main/trunk@770 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/HistoryPlusPlus/hpp_global.pas')
-rw-r--r--plugins/HistoryPlusPlus/hpp_global.pas60
1 files changed, 27 insertions, 33 deletions
diff --git a/plugins/HistoryPlusPlus/hpp_global.pas b/plugins/HistoryPlusPlus/hpp_global.pas
index a247076bd6..cf6de81b39 100644
--- a/plugins/HistoryPlusPlus/hpp_global.pas
+++ b/plugins/HistoryPlusPlus/hpp_global.pas
@@ -107,7 +107,7 @@ type
TSendMethod = (smSend,smPost);
TUrlProto = record
- Proto: PWideChar;
+ Proto: PChar;
Idn: Boolean;
end;
@@ -270,10 +270,6 @@ const
var
hppCodepage: Cardinal;
- hppIconPack: String;
- hppProfileDir: String;
- hppPluginsDir: String;
- hppDllName: String;
hppRichEditVersion: Integer;
{$I m_historypp.inc}
@@ -435,7 +431,32 @@ begin
Result := True;
end;
-
+procedure OpenUrl(URLText: String; NewWindow: Boolean);
+var
+ URLTextW: String;
+ URLTextA: AnsiString;
+begin
+{
+ if EncodeURL(URLText, URLTextW) then
+ begin
+ URLTextA := WideToAnsiString(URLTextW, CP_ACP);
+ if not SameStr(URLTextW, AnsiToWideString(URLTextA, CP_ACP)) then
+ URLTextA := QuoteURL(URLTextW);
+ end
+ else
+ URLTextA := WideToAnsiString(URLText, CP_ACP);
+ CallService(MS_UTILS_OPENURL,WPARAM(NewWindow),LPARAM(@URLTextA[1]));
+}
+ if EncodeURL(URLText, URLTextW) then
+ begin
+ URLTextA := AnsiString(URLTextW);
+ if not SameStr(URLTextW, String(URLTextA)) then
+ URLTextA := QuoteURL(URLTextW);
+ end
+ else
+ URLTextA := AnsiString(URLText);
+ CallService(MS_UTILS_OPENURL,WPARAM(NewWindow),LPARAM(@URLTextA[1]));
+end;
function AnsiToWideString(const S: AnsiString; CodePage: Cardinal; InLength: Integer = -1): WideString;
var
@@ -605,33 +626,6 @@ begin
end;
end;
-procedure OpenUrl(URLText: String; NewWindow: Boolean);
-var
- URLTextW: String;
- URLTextA: AnsiString;
-begin
-{
- if EncodeURL(URLText, URLTextW) then
- begin
- URLTextA := WideToAnsiString(URLTextW, CP_ACP);
- if not SameStr(URLTextW, AnsiToWideString(URLTextA, CP_ACP)) then
- URLTextA := QuoteURL(URLTextW);
- end
- else
- URLTextA := WideToAnsiString(URLText, CP_ACP);
- CallService(MS_UTILS_OPENURL,WPARAM(NewWindow),LPARAM(@URLTextA[1]));
-}
- if EncodeURL(URLText, URLTextW) then
- begin
- URLTextA := AnsiString(URLTextW);
- if not SameStr(URLTextW, String(URLTextA)) then
- URLTextA := QuoteURL(URLTextW);
- end
- else
- URLTextA := AnsiString(URLText);
- CallService(MS_UTILS_OPENURL,WPARAM(NewWindow),LPARAM(@URLTextA[1]));
-end;
-
function HppMessageBox(Handle: THandle; const Text: String; const Caption: String; Flags: Integer): Integer;
begin
Result := MessageBox(Handle,PChar(Text),PChar(Caption),Flags);