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
bfa999ea
Commit
bfa999ea
authored
Apr 23, 2008
by
Eric Pouech
Committed by
Alexandre Julliard
Apr 24, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winhelp: Allow links inside popups to work properly.
parent
9d92b761
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
8 deletions
+18
-8
winhelp.c
programs/winhelp/winhelp.c
+18
-8
No files found.
programs/winhelp/winhelp.c
View file @
bfa999ea
...
@@ -771,28 +771,28 @@ static HLPFILE_LINK* WINHELP_FindLink(WINHELP_WINDOW* win, LPARAM pos)
...
@@ -771,28 +771,28 @@ static HLPFILE_LINK* WINHELP_FindLink(WINHELP_WINDOW* win, LPARAM pos)
* WINHELP_HandleTextMouse
* WINHELP_HandleTextMouse
*
*
*/
*/
static
BOOL
WINHELP_HandleTextMouse
(
WINHELP_WINDOW
*
win
,
const
MSGFILTER
*
msgf
)
static
BOOL
WINHELP_HandleTextMouse
(
WINHELP_WINDOW
*
win
,
UINT
msg
,
LPARAM
lParam
)
{
{
HLPFILE
*
hlpfile
;
HLPFILE
*
hlpfile
;
HLPFILE_LINK
*
link
;
HLPFILE_LINK
*
link
;
BOOL
ret
=
FALSE
;
BOOL
ret
=
FALSE
;
switch
(
msg
f
->
msg
)
switch
(
msg
)
{
{
case
WM_MOUSEMOVE
:
case
WM_MOUSEMOVE
:
if
(
WINHELP_FindLink
(
win
,
msgf
->
lParam
))
if
(
WINHELP_FindLink
(
win
,
lParam
))
SetCursor
(
win
->
hHandCur
);
SetCursor
(
win
->
hHandCur
);
else
else
SetCursor
(
LoadCursor
(
0
,
IDC_ARROW
));
SetCursor
(
LoadCursor
(
0
,
IDC_ARROW
));
break
;
break
;
case
WM_LBUTTONDOWN
:
case
WM_LBUTTONDOWN
:
if
((
win
->
current_link
=
WINHELP_FindLink
(
win
,
msgf
->
lParam
)))
if
((
win
->
current_link
=
WINHELP_FindLink
(
win
,
lParam
)))
ret
=
TRUE
;
ret
=
TRUE
;
break
;
break
;
case
WM_LBUTTONUP
:
case
WM_LBUTTONUP
:
if
((
link
=
WINHELP_FindLink
(
win
,
msgf
->
lParam
))
&&
link
==
win
->
current_link
)
if
((
link
=
WINHELP_FindLink
(
win
,
lParam
))
&&
link
==
win
->
current_link
)
{
{
HLPFILE_WINDOWINFO
*
wi
;
HLPFILE_WINDOWINFO
*
wi
;
...
@@ -816,7 +816,7 @@ static BOOL WINHELP_HandleTextMouse(WINHELP_WINDOW* win, const MSGFILTER* msgf)
...
@@ -816,7 +816,7 @@ static BOOL WINHELP_HandleTextMouse(WINHELP_WINDOW* win, const MSGFILTER* msgf)
case
hlp_link_popup
:
case
hlp_link_popup
:
if
((
hlpfile
=
WINHELP_LookupHelpFile
(
link
->
string
)))
if
((
hlpfile
=
WINHELP_LookupHelpFile
(
link
->
string
)))
WINHELP_OpenHelpWindow
(
HLPFILE_PageByHash
,
hlpfile
,
link
->
hash
,
WINHELP_OpenHelpWindow
(
HLPFILE_PageByHash
,
hlpfile
,
link
->
hash
,
WINHELP_GetPopupWindowInfo
(
hlpfile
,
win
,
msgf
->
lParam
),
WINHELP_GetPopupWindowInfo
(
hlpfile
,
win
,
lParam
),
SW_NORMAL
);
SW_NORMAL
);
break
;
break
;
case
hlp_link_macro
:
case
hlp_link_macro
:
...
@@ -955,8 +955,13 @@ static LRESULT CALLBACK WINHELP_MainWndProc(HWND hWnd, UINT msg, WPARAM wParam,
...
@@ -955,8 +955,13 @@ static LRESULT CALLBACK WINHELP_MainWndProc(HWND hWnd, UINT msg, WPARAM wParam,
switch
(((
NMHDR
*
)
lParam
)
->
code
)
switch
(((
NMHDR
*
)
lParam
)
->
code
)
{
{
case
EN_MSGFILTER
:
case
EN_MSGFILTER
:
{
const
MSGFILTER
*
msgf
=
(
const
MSGFILTER
*
)
lParam
;
return
WINHELP_HandleTextMouse
((
WINHELP_WINDOW
*
)
GetWindowLong
(
hWnd
,
0
),
return
WINHELP_HandleTextMouse
((
WINHELP_WINDOW
*
)
GetWindowLong
(
hWnd
,
0
),
(
const
MSGFILTER
*
)
lParam
);
msgf
->
msg
,
msgf
->
lParam
);
}
break
;
case
EN_REQUESTRESIZE
:
case
EN_REQUESTRESIZE
:
rc
=
((
REQRESIZE
*
)
lParam
)
->
rc
;
rc
=
((
REQRESIZE
*
)
lParam
)
->
rc
;
win
=
(
WINHELP_WINDOW
*
)
GetWindowLong
(
hWnd
,
0
);
win
=
(
WINHELP_WINDOW
*
)
GetWindowLong
(
hWnd
,
0
);
...
@@ -2001,13 +2006,18 @@ static BOOL WINHELP_CheckPopup(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam
...
@@ -2001,13 +2006,18 @@ static BOOL WINHELP_CheckPopup(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam
break
;
break
;
case
WM_COMMAND
:
case
WM_COMMAND
:
if
(
use_richedit
)
break
;
if
(
use_richedit
)
break
;
/* fall through */
goto
doit
;
case
WM_LBUTTONUP
:
case
WM_LBUTTONDOWN
:
case
WM_LBUTTONDOWN
:
if
(
WINHELP_HandleTextMouse
(
Globals
.
active_popup
,
msg
,
lParam
)
&&
msg
==
WM_LBUTTONDOWN
)
return
FALSE
;
/* fall through */
case
WM_MBUTTONDOWN
:
case
WM_MBUTTONDOWN
:
case
WM_RBUTTONDOWN
:
case
WM_RBUTTONDOWN
:
case
WM_NCLBUTTONDOWN
:
case
WM_NCLBUTTONDOWN
:
case
WM_NCMBUTTONDOWN
:
case
WM_NCMBUTTONDOWN
:
case
WM_NCRBUTTONDOWN
:
case
WM_NCRBUTTONDOWN
:
doit:
hPopup
=
Globals
.
active_popup
->
hMainWnd
;
hPopup
=
Globals
.
active_popup
->
hMainWnd
;
Globals
.
active_popup
=
NULL
;
Globals
.
active_popup
=
NULL
;
DestroyWindow
(
hPopup
);
DestroyWindow
(
hPopup
);
...
...
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