Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
e0f1444d
Commit
e0f1444d
authored
Oct 25, 2004
by
Robert Shearman
Committed by
Alexandre Julliard
Oct 25, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Don't fill in any more information than native does for notifications.
- Store hit code in a signed integer so that we can see whether it is less than zero.
parent
acfd725d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
24 deletions
+9
-24
toolbar.c
dlls/comctl32/toolbar.c
+9
-24
No files found.
dlls/comctl32/toolbar.c
View file @
e0f1444d
...
@@ -5632,11 +5632,9 @@ TOOLBAR_LButtonDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
...
@@ -5632,11 +5632,9 @@ TOOLBAR_LButtonDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
RedrawWindow
(
hwnd
,
&
btnPtr
->
rect
,
0
,
RedrawWindow
(
hwnd
,
&
btnPtr
->
rect
,
0
,
RDW_ERASE
|
RDW_INVALIDATE
|
RDW_UPDATENOW
);
RDW_ERASE
|
RDW_INVALIDATE
|
RDW_UPDATENOW
);
memset
(
&
nmtb
,
0
,
sizeof
(
nmtb
));
nmtb
.
iItem
=
btnPtr
->
idCommand
;
nmtb
.
iItem
=
btnPtr
->
idCommand
;
memset
(
&
nmtb
.
tbButton
,
0
,
sizeof
(
TBBUTTON
));
nmtb
.
rcButton
=
btnPtr
->
rect
;
nmtb
.
cchText
=
0
;
nmtb
.
pszText
=
0
;
CopyRect
(
&
nmtb
.
rcButton
,
&
btnPtr
->
rect
);
res
=
TOOLBAR_SendNotify
((
NMHDR
*
)
&
nmtb
,
infoPtr
,
res
=
TOOLBAR_SendNotify
((
NMHDR
*
)
&
nmtb
,
infoPtr
,
TBN_DROPDOWN
);
TBN_DROPDOWN
);
TRACE
(
"TBN_DROPDOWN responded with %ld
\n
"
,
res
);
TRACE
(
"TBN_DROPDOWN responded with %ld
\n
"
,
res
);
...
@@ -5686,22 +5684,15 @@ TOOLBAR_LButtonDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
...
@@ -5686,22 +5684,15 @@ TOOLBAR_LButtonDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
if
(
nHit
>=
0
)
if
(
nHit
>=
0
)
{
{
memset
(
&
nmtb
,
0
,
sizeof
(
nmtb
));
nmtb
.
iItem
=
btnPtr
->
idCommand
;
nmtb
.
iItem
=
btnPtr
->
idCommand
;
nmtb
.
tbButton
.
iBitmap
=
btnPtr
->
iBitmap
;
nmtb
.
tbButton
.
idCommand
=
btnPtr
->
idCommand
;
nmtb
.
tbButton
.
fsState
=
btnPtr
->
fsState
;
nmtb
.
tbButton
.
fsStyle
=
btnPtr
->
fsStyle
;
nmtb
.
tbButton
.
dwData
=
btnPtr
->
dwData
;
nmtb
.
tbButton
.
iString
=
btnPtr
->
iString
;
nmtb
.
cchText
=
0
;
/* !!! not correct */
nmtb
.
pszText
=
0
;
/* !!! not correct */
TOOLBAR_SendNotify
((
NMHDR
*
)
&
nmtb
,
infoPtr
,
TBN_BEGINDRAG
);
TOOLBAR_SendNotify
((
NMHDR
*
)
&
nmtb
,
infoPtr
,
TBN_BEGINDRAG
);
}
}
nmmouse
.
dwHitInfo
=
nHit
;
nmmouse
.
dwHitInfo
=
nHit
;
/* !!! Undocumented - sends NM_LDOWN with the NMMOUSE structure. */
/* !!! Undocumented - sends NM_LDOWN with the NMMOUSE structure. */
if
(
n
mmouse
.
dwHitInfo
<
0
)
if
(
n
Hit
<
0
)
nmmouse
.
dwItemSpec
=
-
1
;
nmmouse
.
dwItemSpec
=
-
1
;
else
else
{
{
...
@@ -5847,15 +5838,8 @@ TOOLBAR_LButtonUp (HWND hwnd, WPARAM wParam, LPARAM lParam)
...
@@ -5847,15 +5838,8 @@ TOOLBAR_LButtonUp (HWND hwnd, WPARAM wParam, LPARAM lParam)
/* native issues TBN_ENDDRAG here, if _LBUTTONDOWN issued the
/* native issues TBN_ENDDRAG here, if _LBUTTONDOWN issued the
* TBN_BEGINDRAG
* TBN_BEGINDRAG
*/
*/
memset
(
&
nmtb
,
0
,
sizeof
(
nmtb
));
nmtb
.
iItem
=
btnPtr
->
idCommand
;
nmtb
.
iItem
=
btnPtr
->
idCommand
;
nmtb
.
tbButton
.
iBitmap
=
btnPtr
->
iBitmap
;
nmtb
.
tbButton
.
idCommand
=
btnPtr
->
idCommand
;
nmtb
.
tbButton
.
fsState
=
btnPtr
->
fsState
;
nmtb
.
tbButton
.
fsStyle
=
btnPtr
->
fsStyle
;
nmtb
.
tbButton
.
dwData
=
btnPtr
->
dwData
;
nmtb
.
tbButton
.
iString
=
btnPtr
->
iString
;
nmtb
.
cchText
=
0
;
/* !!! not correct */
nmtb
.
pszText
=
0
;
/* !!! not correct */
TOOLBAR_SendNotify
((
NMHDR
*
)
&
nmtb
,
infoPtr
,
TOOLBAR_SendNotify
((
NMHDR
*
)
&
nmtb
,
infoPtr
,
TBN_ENDDRAG
);
TBN_ENDDRAG
);
...
@@ -5891,16 +5875,17 @@ static LRESULT
...
@@ -5891,16 +5875,17 @@ static LRESULT
TOOLBAR_RButtonUp
(
HWND
hwnd
,
WPARAM
wParam
,
LPARAM
lParam
)
TOOLBAR_RButtonUp
(
HWND
hwnd
,
WPARAM
wParam
,
LPARAM
lParam
)
{
{
TOOLBAR_INFO
*
infoPtr
=
TOOLBAR_GetInfoPtr
(
hwnd
);
TOOLBAR_INFO
*
infoPtr
=
TOOLBAR_GetInfoPtr
(
hwnd
);
INT
nHit
;
NMMOUSE
nmmouse
;
NMMOUSE
nmmouse
;
POINT
pt
;
POINT
pt
;
pt
.
x
=
LOWORD
(
lParam
);
pt
.
x
=
LOWORD
(
lParam
);
pt
.
y
=
HIWORD
(
lParam
);
pt
.
y
=
HIWORD
(
lParam
);
nmmouse
.
dwHitInfo
=
TOOLBAR_InternalHitTest
(
hwnd
,
&
pt
);
nHit
=
TOOLBAR_InternalHitTest
(
hwnd
,
&
pt
);
nmmouse
.
dwHitInfo
=
nHit
;
if
(
n
mmouse
.
dwHitInfo
<
0
)
{
if
(
n
Hit
<
0
)
{
nmmouse
.
dwItemSpec
=
-
1
;
nmmouse
.
dwItemSpec
=
-
1
;
}
else
{
}
else
{
nmmouse
.
dwItemSpec
=
infoPtr
->
buttons
[
nmmouse
.
dwHitInfo
].
idCommand
;
nmmouse
.
dwItemSpec
=
infoPtr
->
buttons
[
nmmouse
.
dwHitInfo
].
idCommand
;
...
...
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