diff options
author | George Hazan <george.hazan@gmail.com> | 2015-06-17 17:03:45 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-06-17 17:03:45 +0000 |
commit | a75ce08f5ea46237b73e5052a956829c0e272678 (patch) | |
tree | 60a238c3b4c0487317f3836d83acbe022c865115 /include/delphi/m_utils.inc | |
parent | d6964f7bb1c2afc8d67905fa38ac9a3df766b807 (diff) |
minus MS_UTILS_SAVEWINDOWPOSITION & MS_UTILS_RESTOREWINDOWPOSITION
git-svn-id: http://svn.miranda-ng.org/main/trunk@14238 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'include/delphi/m_utils.inc')
-rw-r--r-- | include/delphi/m_utils.inc | 142 |
1 files changed, 69 insertions, 73 deletions
diff --git a/include/delphi/m_utils.inc b/include/delphi/m_utils.inc index dea6497f48..23e4d240b7 100644 --- a/include/delphi/m_utils.inc +++ b/include/delphi/m_utils.inc @@ -154,10 +154,10 @@ const //******************************* Window lists *******************************
- {
- Affect : Allocate a window list
- Returns: A handle to the new window list
- }
+{
+ Affect : Allocate a window list
+ Returns: A handle to the new window list
+}
function WindowList_Create() : Thandle; stdcall;
external CoreDLL name 'WindowList_Create';
@@ -165,109 +165,105 @@ function WindowList_Create() : Thandle; stdcall; procedure WindowList_Destroy(hList:Thandle); stdcall;
external CoreDLL name 'WindowList_Destroy';
- {
- Affect : Add a window to a given window list handle
- Returns: 0 on success, [non zero] on failure
- }
+{
+ Affect : Add a window to a given window list handle
+ Returns: 0 on success, [non zero] on failure
+}
function WindowList_Add(hList:Thandle; hwnd:HWND; hContact:TMCONTACT) : int; stdcall;
external CoreDLL name 'WindowList_Add';
- {
- Affect : Remove a window from the specified window list
- Returns: 0 on success, [non zero] on failure
- }
+{
+ Affect : Remove a window from the specified window list
+ Returns: 0 on success, [non zero] on failure
+}
function WindowList_Remove(hList:Thandle; hwnd:HWND) : int; stdcall;
external CoreDLL name 'WindowList_Remove';
- {
- Affect : Find a window handle given the hContact
- Returns: The found window handle or NULL(0) on failure
- }
+{
+ Affect : Find a window handle given the hContact
+ Returns: The found window handle or NULL(0) on failure
+}
function WindowList_Find(hList:Thandle; hContact:TMCONTACT) : HWND; stdcall;
external CoreDLL name 'WindowList_Find';
- {
- Affect : sends a message to all windows in a list using SendMessage
- Returns: 0 on success, [non zero] on failure
- }
+{
+ Affect : sends a message to all windows in a list using SendMessage
+ Returns: 0 on success, [non zero] on failure
+}
function WindowList_Broadcast(hList:Thandle; message:UINT; wParam:TWPARAM; lParam:TLPARAM) : int; stdcall;
external CoreDLL name 'WindowList_Broadcast';
- {
- Affect : Sends a message to all windows in a list using PostMessage
- Returns: 0 on success, nonzero on failure, this service does not fail,
- even if PostMessage() fails for whatever reason
- }
+{
+ Affect : Sends a message to all windows in a list using PostMessage
+ Returns: 0 on success, nonzero on failure, this service does not fail,
+ even if PostMessage() fails for whatever reason
+}
function WindowList_BroadcastAsync(hList:Thandle; message:UINT; wParam:TWPARAM; lParam:TLPARAM) : int; stdcall;
external CoreDLL name 'WindowList_BroadcastAsync';
- {
- There aren't any services here, there's no need for them, the control class
- will obey the SS_LEFT (0), SS_CENTER (1), SS_RIGHT(2) styles
- the control will send STN_CLICKED via WM_COMMAND when the link itself is clicked
- -
- These are defined by STATIC controls and STN_CLICKED is sent to standard
- STATIC classes when they're clicked -- look at WINAPI docs for more info
- }
+{
+ There aren't any services here, there's no need for them, the control class
+ will obey the SS_LEFT (0), SS_CENTER (1), SS_RIGHT(2) styles
+ the control will send STN_CLICKED via WM_COMMAND when the link itself is clicked
+ -
+ These are defined by STATIC controls and STN_CLICKED is sent to standard
+ STATIC classes when they're clicked -- look at WINAPI docs for more info
+}
const
WNDCLASS_HYPERLINK = 'Hyperlink';
- {
- wParam : 0
- lParam : Pointer to a initialised TSAVEWINDOWPOS structure
- Affect :
- Returns: 0 on success, [non zero] on failure
- Notes :
- Version: v0.1.1.0+
- }
- MS_UTILS_SAVEWINDOWPOSITION:PAnsiChar = 'Utils/SaveWindowPos';
+{
+ Returns: 0 on success, [non zero] on failure
+}
- {
- wParam : see RWPF_* flags
- lParam : Pointer to a initalised TSAVEWINDOWPOS
- Affect : Restores the position of a window from the database, see notes
- Returns: 0 on success, [non zero] on failure
- Notes : If no position info was found, the service will return 1.
- The NoSize version won't use stored information size, the window
- is left the same size
- -
- See Utils_RestoreWindowPosition() Helper function, this function is
- a bit different from the C function (which can be inlined too! dammit)
- that there's only one function and not three (which just passed different flags)
- Version: v0.1.1.0+
- }
- MS_UTILS_RESTOREWINDOWPOSITION:PAnsiChar = 'Utils/RestoreWindowPos';
+function Utils_SaveWindowPosition(hwnd:HWND; hContact:TMCONTACT; const szModule,szNamePrefix:PAnsiChar) : int; stdcall;
+ external CoreDLL name 'Utils_SaveWindowPosition';
+
+{
+ Affect : Restores the position of a window from the database, see notes
+ Returns: 0 on success, [non zero] on failure
+ Notes : If no position info was found, the service will return 1.
+ The NoSize version won't use stored information size, the window
+ is left the same size
+ -
+ See Utils_RestoreWindowPosition() Helper function, this function is
+ a bit different from the C function (which can be inlined too! dammit)
+ that there's only one function and not three (which just passed different flags)
+}
+
+function Utils_RestoreWindowPosition(hwnd:HWND; hContact:TMCONTACT; const szModule,szNamePrefix:PAnsiChar; flags:int) : int; stdcall;
+ external CoreDLL name 'Utils_RestoreWindowPosition';
{
- wParam : pointer to RECT
- lParam : 0
Affect : Moves a RECT inside screen if it is outside.It works with multiple monitors (v0.9.0.4+)
Returns: <0 on error, 0 if not changed the rect, 1 if changed the rect
}
- MS_UTILS_ASSERTINSIDESCREEN:PAnsiChar = 'Utils/AssertInsideScreen';
- {
- wParam : 0
- lParam : Pointer to a null terminated string containing filename
- Affect : Loads a bitmap (or other graphic type, see Notes
- Returns: HBITMAP on success, NULL(0) on failure
- Notes : This function also supports JPEG, GIF (and maybe PNG too)
- For speed, if the file extention is .bmp or .rle it will use LoadImage()
- and not load OLE for the extra image support
- -
- Remember to delete the returned handle with DeleteObject (see GDI documentation for WINAPI)
- Version: v0.1.2.1+
- }
+function Utils_AssertInsideScreen(var rc:RECT) : int; stdcall;
+ external CoreDLL name 'Utils_AssertInsideScreen';
+
+{
+ wParam : 0
+ lParam : Pointer to a null terminated string containing filename
+ Affect : Loads a bitmap (or other graphic type, see Notes
+ Returns: HBITMAP on success, NULL(0) on failure
+ Notes : This function also supports JPEG, GIF (and maybe PNG too)
+ For speed, if the file extention is .bmp or .rle it will use LoadImage()
+ and not load OLE for the extra image support
+ -
+ Remember to delete the returned handle with DeleteObject (see GDI documentation for WINAPI)
+}
+
+const
MS_UTILS_LOADBITMAP :PAnsiChar = 'Utils/LoadBitmap';
MS_UTILS_LOADBITMAPW:PAnsiChar = 'Utils/LoadBitmapW';
-
{
Affect : Saves a path to a relative path (from the miranda directory)
Only saves as a relative path if the file is in the miranda
|