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
0bcadfa8
Commit
0bcadfa8
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: Layout the toolbar after a potential resize.
parent
9d218048
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
18 deletions
+14
-18
toolbar.c
dlls/comctl32/toolbar.c
+14
-18
No files found.
dlls/comctl32/toolbar.c
View file @
0bcadfa8
...
...
@@ -3015,12 +3015,15 @@ TOOLBAR_AddStringA (TOOLBAR_INFO *infoPtr, HINSTANCE hInstance, LPARAM lParam)
static
LRESULT
TOOLBAR_AutoSize
(
TOOLBAR_INFO
*
infoPtr
)
{
RECT
parent_rect
;
HWND
parent
;
INT
x
,
y
;
INT
cx
,
cy
;
TRACE
(
"auto sizing, style=%x!
\n
"
,
infoPtr
->
dwStyle
);
TRACE
(
"nRows: %d, infoPtr->nButtonHeight: %d
\n
"
,
infoPtr
->
nRows
,
infoPtr
->
nButtonHeight
);
if
(
!
(
infoPtr
->
dwStyle
&
CCS_NORESIZE
))
{
RECT
window_rect
,
parent_rect
;
UINT
uPosFlags
=
SWP_NOZORDER
|
SWP_NOACTIVATE
;
HWND
parent
;
INT
x
,
y
,
cx
,
cy
;
parent
=
GetParent
(
infoPtr
->
hwndSelf
);
...
...
@@ -3032,22 +3035,9 @@ TOOLBAR_AutoSize (TOOLBAR_INFO *infoPtr)
x
=
parent_rect
.
left
;
y
=
parent_rect
.
top
;
TRACE
(
"nRows: %d, infoPtr->nButtonHeight: %d
\n
"
,
infoPtr
->
nRows
,
infoPtr
->
nButtonHeight
);
cy
=
TOP_BORDER
+
infoPtr
->
nRows
*
infoPtr
->
nButtonHeight
+
BOTTOM_BORDER
;
cx
=
parent_rect
.
right
-
parent_rect
.
left
;
if
((
infoPtr
->
dwStyle
&
TBSTYLE_WRAPABLE
)
||
(
infoPtr
->
dwExStyle
&
TBSTYLE_EX_VERTICAL
))
{
TOOLBAR_LayoutToolbar
(
infoPtr
);
InvalidateRect
(
infoPtr
->
hwndSelf
,
NULL
,
TRUE
);
}
if
(
!
(
infoPtr
->
dwStyle
&
CCS_NORESIZE
))
{
RECT
window_rect
;
UINT
uPosFlags
=
SWP_NOZORDER
|
SWP_NOACTIVATE
;
if
((
infoPtr
->
dwStyle
&
CCS_BOTTOM
)
==
CCS_NOMOVEY
)
{
GetWindowRect
(
infoPtr
->
hwndSelf
,
&
window_rect
);
...
...
@@ -3075,6 +3065,12 @@ TOOLBAR_AutoSize (TOOLBAR_INFO *infoPtr)
SetWindowPos
(
infoPtr
->
hwndSelf
,
NULL
,
x
,
y
,
cx
,
cy
,
uPosFlags
);
}
if
((
infoPtr
->
dwStyle
&
TBSTYLE_WRAPABLE
)
||
(
infoPtr
->
dwExStyle
&
TBSTYLE_EX_VERTICAL
))
{
TOOLBAR_LayoutToolbar
(
infoPtr
);
InvalidateRect
(
infoPtr
->
hwndSelf
,
NULL
,
TRUE
);
}
return
0
;
}
...
...
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