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
b5081dac
Commit
b5081dac
authored
Dec 15, 2008
by
Andrew Talbot
Committed by
Alexandre Julliard
Dec 16, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32: Sign-compare warnings fix.
parent
72ffe1da
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
9 deletions
+10
-9
menu.c
dlls/user32/menu.c
+7
-7
spy.c
dlls/user32/spy.c
+3
-2
No files found.
dlls/user32/menu.c
View file @
b5081dac
...
@@ -1111,7 +1111,7 @@ static void MENU_PopupMenuCalcSize( LPPOPUPMENU lppop )
...
@@ -1111,7 +1111,7 @@ static void MENU_PopupMenuCalcSize( LPPOPUPMENU lppop )
{
{
MENUITEM
*
lpitem
;
MENUITEM
*
lpitem
;
HDC
hdc
;
HDC
hdc
;
int
start
,
i
;
UINT
start
,
i
;
int
orgX
,
orgY
,
maxX
,
maxTab
,
maxTabWidth
,
maxHeight
;
int
orgX
,
orgY
,
maxX
,
maxTab
,
maxTabWidth
,
maxHeight
;
lppop
->
Width
=
lppop
->
Height
=
0
;
lppop
->
Width
=
lppop
->
Height
=
0
;
...
@@ -1199,7 +1199,8 @@ static void MENU_MenuBarCalcSize( HDC hdc, LPRECT lprect,
...
@@ -1199,7 +1199,8 @@ static void MENU_MenuBarCalcSize( HDC hdc, LPRECT lprect,
LPPOPUPMENU
lppop
,
HWND
hwndOwner
)
LPPOPUPMENU
lppop
,
HWND
hwndOwner
)
{
{
MENUITEM
*
lpitem
;
MENUITEM
*
lpitem
;
int
start
,
i
,
orgX
,
orgY
,
maxY
,
helpPos
;
UINT
start
,
i
,
helpPos
;
int
orgX
,
orgY
,
maxY
;
if
((
lprect
==
NULL
)
||
(
lppop
==
NULL
))
return
;
if
((
lprect
==
NULL
)
||
(
lppop
==
NULL
))
return
;
if
(
lppop
->
nItems
==
0
)
return
;
if
(
lppop
->
nItems
==
0
)
return
;
...
@@ -1208,7 +1209,7 @@ static void MENU_MenuBarCalcSize( HDC hdc, LPRECT lprect,
...
@@ -1208,7 +1209,7 @@ static void MENU_MenuBarCalcSize( HDC hdc, LPRECT lprect,
lppop
->
Height
=
0
;
lppop
->
Height
=
0
;
maxY
=
lprect
->
top
+
1
;
maxY
=
lprect
->
top
+
1
;
start
=
0
;
start
=
0
;
helpPos
=
-
1
;
helpPos
=
~
0U
;
lppop
->
maxBmpSize
.
cx
=
0
;
lppop
->
maxBmpSize
.
cx
=
0
;
lppop
->
maxBmpSize
.
cy
=
0
;
lppop
->
maxBmpSize
.
cy
=
0
;
while
(
start
<
lppop
->
nItems
)
while
(
start
<
lppop
->
nItems
)
...
@@ -1220,7 +1221,7 @@ static void MENU_MenuBarCalcSize( HDC hdc, LPRECT lprect,
...
@@ -1220,7 +1221,7 @@ static void MENU_MenuBarCalcSize( HDC hdc, LPRECT lprect,
/* Parse items until line break or end of menu */
/* Parse items until line break or end of menu */
for
(
i
=
start
;
i
<
lppop
->
nItems
;
i
++
,
lpitem
++
)
for
(
i
=
start
;
i
<
lppop
->
nItems
;
i
++
,
lpitem
++
)
{
{
if
((
helpPos
==
-
1
)
&&
(
lpitem
->
fType
&
MF_RIGHTJUSTIFY
))
helpPos
=
i
;
if
((
helpPos
==
~
0U
)
&&
(
lpitem
->
fType
&
MF_RIGHTJUSTIFY
))
helpPos
=
i
;
if
((
i
!=
start
)
&&
if
((
i
!=
start
)
&&
(
lpitem
->
fType
&
(
MF_MENUBREAK
|
MF_MENUBARBREAK
)))
break
;
(
lpitem
->
fType
&
(
MF_MENUBREAK
|
MF_MENUBARBREAK
)))
break
;
...
@@ -1246,12 +1247,11 @@ static void MENU_MenuBarCalcSize( HDC hdc, LPRECT lprect,
...
@@ -1246,12 +1247,11 @@ static void MENU_MenuBarCalcSize( HDC hdc, LPRECT lprect,
/* Flush right all items between the MF_RIGHTJUSTIFY and */
/* Flush right all items between the MF_RIGHTJUSTIFY and */
/* the last item (if several lines, only move the last line) */
/* the last item (if several lines, only move the last line) */
if
(
helpPos
==
~
0U
)
return
;
lpitem
=
&
lppop
->
items
[
lppop
->
nItems
-
1
];
lpitem
=
&
lppop
->
items
[
lppop
->
nItems
-
1
];
orgY
=
lpitem
->
rect
.
top
;
orgY
=
lpitem
->
rect
.
top
;
orgX
=
lprect
->
right
;
orgX
=
lprect
->
right
;
for
(
i
=
lppop
->
nItems
-
1
;
i
>=
helpPos
;
i
--
,
lpitem
--
)
{
for
(
i
=
lppop
->
nItems
-
1
;
i
>=
helpPos
;
i
--
,
lpitem
--
)
{
if
(
(
helpPos
==-
1
)
||
(
helpPos
>
i
)
)
break
;
/* done */
if
(
lpitem
->
rect
.
top
!=
orgY
)
break
;
/* Other line */
if
(
lpitem
->
rect
.
top
!=
orgY
)
break
;
/* Other line */
if
(
lpitem
->
rect
.
right
>=
orgX
)
break
;
/* Too far right already */
if
(
lpitem
->
rect
.
right
>=
orgX
)
break
;
/* Too far right already */
lpitem
->
rect
.
left
+=
orgX
-
lpitem
->
rect
.
right
;
lpitem
->
rect
.
left
+=
orgX
-
lpitem
->
rect
.
right
;
...
@@ -2671,7 +2671,7 @@ static LRESULT MENU_DoNextMenu( MTRACKER* pmt, UINT vk, UINT wFlags )
...
@@ -2671,7 +2671,7 @@ static LRESULT MENU_DoNextMenu( MTRACKER* pmt, UINT vk, UINT wFlags )
icons such as MDI maximize, restore or close) */
icons such as MDI maximize, restore or close) */
else
if
((
vk
==
VK_RIGHT
)
&&
!
IS_SYSTEM_MENU
(
menu
))
else
if
((
vk
==
VK_RIGHT
)
&&
!
IS_SYSTEM_MENU
(
menu
))
{
{
int
i
=
menu
->
FocusedItem
+
1
;
UINT
i
=
menu
->
FocusedItem
+
1
;
while
(
i
<
menu
->
nItems
)
{
while
(
i
<
menu
->
nItems
)
{
if
((
menu
->
items
[
i
].
wID
>=
SC_SIZE
&&
if
((
menu
->
items
[
i
].
wID
>=
SC_SIZE
&&
menu
->
items
[
i
].
wID
<=
SC_RESTORE
))
{
menu
->
items
[
i
].
wID
<=
SC_RESTORE
))
{
...
...
dlls/user32/spy.c
View file @
b5081dac
...
@@ -2653,7 +2653,8 @@ void SPY_ExitMessage( INT iFlag, HWND hWnd, UINT msg, LRESULT lReturn,
...
@@ -2653,7 +2653,8 @@ void SPY_ExitMessage( INT iFlag, HWND hWnd, UINT msg, LRESULT lReturn,
*/
*/
int
SPY_Init
(
void
)
int
SPY_Init
(
void
)
{
{
int
i
,
j
;
int
i
;
UINT
j
;
char
buffer
[
1024
];
char
buffer
[
1024
];
const
SPY_NOTIFY
*
p
;
const
SPY_NOTIFY
*
p
;
const
USER_MSG
*
q
;
const
USER_MSG
*
q
;
...
@@ -2700,7 +2701,7 @@ int SPY_Init(void)
...
@@ -2700,7 +2701,7 @@ int SPY_Init(void)
p
=
&
spnfy_array
[
0
];
p
=
&
spnfy_array
[
0
];
j
=
0xffffffff
;
j
=
0xffffffff
;
while
(
p
->
name
)
{
while
(
p
->
name
)
{
if
(
(
UINT
)
p
->
value
>
(
UINT
)
j
)
{
if
(
p
->
value
>
j
)
{
ERR
(
"Notify message array out of order
\n
"
);
ERR
(
"Notify message array out of order
\n
"
);
ERR
(
" between values [%08x] %s and [%08x] %s
\n
"
,
ERR
(
" between values [%08x] %s and [%08x] %s
\n
"
,
j
,
(
p
-
1
)
->
name
,
p
->
value
,
p
->
name
);
j
,
(
p
-
1
)
->
name
,
p
->
value
,
p
->
name
);
...
...
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