Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
41342a32
Commit
41342a32
authored
May 02, 2007
by
Andrey Turkin
Committed by
Alexandre Julliard
May 03, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
hhctrl.ocx: Update HtmlHelp and its commands definitions, and partially…
hhctrl.ocx: Update HtmlHelp and its commands definitions, and partially implement data A->W translation.
parent
5bb4ed2d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
53 additions
and
9 deletions
+53
-9
hhctrl.c
dlls/hhctrl.ocx/hhctrl.c
+50
-7
htmlhelp.h
include/htmlhelp.h
+3
-2
No files found.
dlls/hhctrl.ocx/hhctrl.c
View file @
41342a32
...
...
@@ -78,6 +78,7 @@ static const char *command_to_string(UINT command)
X
(
HH_SET_EXCLUSIVE_FILTER
);
X
(
HH_INITIALIZE
);
X
(
HH_UNINITIALIZE
);
X
(
HH_SAFE_DISPLAY_TOPIC
);
X
(
HH_PRETRANSLATEMESSAGE
);
X
(
HH_SET_GLOBAL_PROPERTY
);
default:
return
"???"
;
...
...
@@ -88,9 +89,9 @@ static const char *command_to_string(UINT command)
/******************************************************************
* HtmlHelpW (hhctrl.ocx.15)
*/
HWND
WINAPI
HtmlHelpW
(
HWND
caller
,
LPCWSTR
filename
,
UINT
command
,
DWORD
data
)
HWND
WINAPI
HtmlHelpW
(
HWND
caller
,
LPCWSTR
filename
,
UINT
command
,
DWORD
_PTR
data
)
{
TRACE
(
"(%p, %s, command=%s, data=%
d
)
\n
"
,
TRACE
(
"(%p, %s, command=%s, data=%
lx
)
\n
"
,
caller
,
debugstr_w
(
filename
),
command_to_string
(
command
),
data
);
...
...
@@ -139,22 +140,64 @@ HWND WINAPI HtmlHelpW(HWND caller, LPCWSTR filename, UINT command, DWORD data)
/******************************************************************
* HtmlHelpA (hhctrl.ocx.14)
*/
HWND
WINAPI
HtmlHelpA
(
HWND
caller
,
LPCSTR
filename
,
UINT
command
,
DWORD
data
)
HWND
WINAPI
HtmlHelpA
(
HWND
caller
,
LPCSTR
filename
,
UINT
command
,
DWORD
_PTR
data
)
{
WCHAR
*
wfile
=
NULL
;
WCHAR
*
wfile
=
NULL
,
*
wdata
=
NULL
;
DWORD
len
;
HWND
result
;
if
(
filename
)
{
DWORD
len
=
MultiByteToWideChar
(
CP_ACP
,
0
,
filename
,
-
1
,
NULL
,
0
);
len
=
MultiByteToWideChar
(
CP_ACP
,
0
,
filename
,
-
1
,
NULL
,
0
);
wfile
=
hhctrl_alloc
(
len
*
sizeof
(
WCHAR
));
MultiByteToWideChar
(
CP_ACP
,
0
,
filename
,
-
1
,
wfile
,
len
);
}
result
=
HtmlHelpW
(
caller
,
wfile
,
command
,
data
);
if
(
data
)
{
switch
(
command
)
{
case
HH_ALINK_LOOKUP
:
case
HH_DISPLAY_SEARCH
:
case
HH_DISPLAY_TEXT_POPUP
:
case
HH_GET_LAST_ERROR
:
case
HH_GET_WIN_TYPE
:
case
HH_KEYWORD_LOOKUP
:
case
HH_SET_WIN_TYPE
:
case
HH_SYNC
:
FIXME
(
"structures not handled yet
\n
"
);
break
;
case
HH_DISPLAY_INDEX
:
case
HH_DISPLAY_TOPIC
:
case
HH_DISPLAY_TOC
:
case
HH_GET_WIN_HANDLE
:
case
HH_SAFE_DISPLAY_TOPIC
:
len
=
MultiByteToWideChar
(
CP_ACP
,
0
,
(
const
char
*
)
data
,
-
1
,
NULL
,
0
);
wdata
=
hhctrl_alloc
(
len
*
sizeof
(
WCHAR
));
MultiByteToWideChar
(
CP_ACP
,
0
,
(
const
char
*
)
data
,
-
1
,
wdata
,
len
);
break
;
case
HH_CLOSE_ALL
:
case
HH_HELP_CONTEXT
:
case
HH_INITIALIZE
:
case
HH_PRETRANSLATEMESSAGE
:
case
HH_TP_HELP_CONTEXTMENU
:
case
HH_TP_HELP_WM_HELP
:
case
HH_UNINITIALIZE
:
/* either scalar or pointer to scalar - do nothing */
break
;
default:
FIXME
(
"Unknown command: %s (%d)
\n
"
,
command_to_string
(
command
),
command
);
break
;
}
}
result
=
HtmlHelpW
(
caller
,
wfile
,
command
,
wdata
?
(
DWORD_PTR
)
wdata
:
data
);
hhctrl_free
(
wfile
);
hhctrl_free
(
wdata
);
return
result
;
}
...
...
include/htmlhelp.h
View file @
41342a32
...
...
@@ -48,6 +48,7 @@
#define HH_SET_EXCLUSIVE_FILTER 0x19
#define HH_INITIALIZE 0x1C
#define HH_UNINITIALIZE 0x1D
#define HH_SAFE_DISPLAY_TOPIC 0x20
#define HH_PRETRANSLATEMESSAGE 0xFD
#define HH_SET_GLOBAL_PROPERTY 0xFC
...
...
@@ -419,8 +420,8 @@ typedef struct tagHH_NTRACKW {
DECL_WINELIB_TYPE_AW
(
HH_NTRACK
)
HWND
WINAPI
HtmlHelpA
(
HWND
,
LPCSTR
,
UINT
,
DWORD
);
HWND
WINAPI
HtmlHelpW
(
HWND
,
LPCWSTR
,
UINT
,
DWORD
);
HWND
WINAPI
HtmlHelpA
(
HWND
,
LPCSTR
,
UINT
,
DWORD
_PTR
);
HWND
WINAPI
HtmlHelpW
(
HWND
,
LPCWSTR
,
UINT
,
DWORD
_PTR
);
#define HtmlHelp WINELIB_NAME_AW(HtmlHelp)
#define ATOM_HTMLHELP_API_ANSI (LPTSTR)14
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment