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
9d218048
Commit
9d218048
authored
May 19, 2015
by
Huw Davies
Committed by
Alexandre Julliard
May 19, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32: Don't store the width in the toolbar info structure.
It's only set and used by a single function.
parent
d030c5ad
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
10 deletions
+7
-10
toolbar.c
dlls/comctl32/toolbar.c
+7
-10
No files found.
dlls/comctl32/toolbar.c
View file @
9d218048
...
...
@@ -119,7 +119,6 @@ typedef struct
typedef
struct
{
DWORD
dwStructSize
;
/* size of TBBUTTON struct */
INT
nWidth
;
/* width of the toolbar */
RECT
client_rect
;
RECT
rcBound
;
/* bounding rectangle */
INT
nButtonHeight
;
...
...
@@ -1282,7 +1281,7 @@ static void
TOOLBAR_WrapToolbar
(
TOOLBAR_INFO
*
infoPtr
)
{
TBUTTON_INFO
*
btnPtr
;
INT
x
,
cx
,
i
,
j
;
INT
x
,
cx
,
i
,
j
,
width
;
RECT
rc
;
BOOL
bButtonWrap
;
...
...
@@ -1302,18 +1301,18 @@ TOOLBAR_WrapToolbar(TOOLBAR_INFO *infoPtr)
* toolbars in a rebar control
*/
GetClientRect
(
GetParent
(
infoPtr
->
hwndSelf
),
&
rc
);
infoPtr
->
nW
idth
=
rc
.
right
-
rc
.
left
;
w
idth
=
rc
.
right
-
rc
.
left
;
}
else
{
GetWindowRect
(
infoPtr
->
hwndSelf
,
&
rc
);
infoPtr
->
nW
idth
=
rc
.
right
-
rc
.
left
;
w
idth
=
rc
.
right
-
rc
.
left
;
}
bButtonWrap
=
FALSE
;
TRACE
(
"start ButtonWidth=%d, BitmapWidth=%d,
nW
idth=%d, nIndent=%d
\n
"
,
infoPtr
->
nButtonWidth
,
infoPtr
->
nBitmapWidth
,
infoPtr
->
nW
idth
,
TRACE
(
"start ButtonWidth=%d, BitmapWidth=%d,
w
idth=%d, nIndent=%d
\n
"
,
infoPtr
->
nButtonWidth
,
infoPtr
->
nBitmapWidth
,
w
idth
,
infoPtr
->
nIndent
);
for
(
i
=
0
;
i
<
infoPtr
->
nNumButtons
;
i
++
)
...
...
@@ -1351,9 +1350,8 @@ TOOLBAR_WrapToolbar(TOOLBAR_INFO *infoPtr)
/* The layout makes sure the bitmap is visible, but not the button. */
/* Test added to also wrap after a button that starts a row but */
/* is bigger than the area. - GA 8/01 */
if
((
x
+
cx
-
(
infoPtr
->
nButtonWidth
-
infoPtr
->
nBitmapWidth
)
/
2
>
infoPtr
->
nWidth
)
||
((
x
==
infoPtr
->
nIndent
)
&&
(
cx
>
infoPtr
->
nWidth
)))
if
((
x
+
cx
-
(
infoPtr
->
nButtonWidth
-
infoPtr
->
nBitmapWidth
)
/
2
>
width
)
||
((
x
==
infoPtr
->
nIndent
)
&&
(
cx
>
width
)))
{
BOOL
bFound
=
FALSE
;
...
...
@@ -5946,7 +5944,6 @@ TOOLBAR_NCCreate (HWND hwnd, WPARAM wParam, const CREATESTRUCTW *lpcs)
/* paranoid!! */
infoPtr
->
dwStructSize
=
sizeof
(
TBBUTTON
);
infoPtr
->
nRows
=
1
;
infoPtr
->
nWidth
=
0
;
/* initialize info structure */
infoPtr
->
nButtonWidth
=
23
;
...
...
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