Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jason Beetham
wine
Commits
aebda22e
Commit
aebda22e
authored
25 years ago
by
Jim Aston
Committed by
Alexandre Julliard
25 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fixed the height of the ComboBox drop list.
parent
edb77973
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
controls/combo.c
+32
-31
32 additions, 31 deletions
controls/combo.c
with
32 additions
and
31 deletions
controls/combo.c
+
32
−
31
View file @
aebda22e
...
...
@@ -153,37 +153,6 @@ static LRESULT COMBO_NCDestroy( LPHEADCOMBO lphc )
return
0
;
}
/***********************************************************************
* CBForceDummyResize
*
* The dummy resize is used for listboxes that have a popup to trigger
* a re-arranging of the contents of the combobox and the recalculation
* of the size of the "real" control window.
*/
static
void
CBForceDummyResize
(
LPHEADCOMBO
lphc
)
{
RECT
windowRect
;
GetWindowRect
(
CB_HWND
(
lphc
),
&
windowRect
);
/*
* We have to be careful, resizing a combobox also has the meaning that the
* dropped rect will be resized. In this case, we want to trigger a resize
* to recalculate layout but we don't want to change the dropped rectangle
* So, we add the size of the dropped rectangle to the size of the control.
* this will cancel-out in the processing of the WM_WINDOWPOSCHANGING
* message.
*/
SetWindowPos
(
CB_HWND
(
lphc
),
(
HWND
)
NULL
,
0
,
0
,
windowRect
.
right
-
windowRect
.
left
,
windowRect
.
bottom
-
windowRect
.
top
+
lphc
->
droppedRect
.
bottom
-
lphc
->
droppedRect
.
top
,
SWP_NOMOVE
|
SWP_NOZORDER
|
SWP_NOACTIVATE
);
}
/***********************************************************************
* CBGetTextAreaHeight
*
...
...
@@ -291,6 +260,38 @@ static INT CBGetTextAreaHeight(
return
iTextItemHeight
;
}
/***********************************************************************
* CBForceDummyResize
*
* The dummy resize is used for listboxes that have a popup to trigger
* a re-arranging of the contents of the combobox and the recalculation
* of the size of the "real" control window.
*/
static
void
CBForceDummyResize
(
LPHEADCOMBO
lphc
)
{
RECT
windowRect
;
int
newComboHeight
;
newComboHeight
=
CBGetTextAreaHeight
(
CB_HWND
(
lphc
),
lphc
)
+
2
*
COMBO_YBORDERSIZE
();
GetWindowRect
(
CB_HWND
(
lphc
),
&
windowRect
);
/*
* We have to be careful, resizing a combobox also has the meaning that the
* dropped rect will be resized. In this case, we want to trigger a resize
* to recalculate layout but we don't want to change the dropped rectangle
* So, we pass the height of text area of control as the height.
* this will cancel-out in the processing of the WM_WINDOWPOSCHANGING
* message.
*/
SetWindowPos
(
CB_HWND
(
lphc
),
(
HWND
)
NULL
,
0
,
0
,
windowRect
.
right
-
windowRect
.
left
,
newComboHeight
,
SWP_NOMOVE
|
SWP_NOZORDER
|
SWP_NOACTIVATE
);
}
/***********************************************************************
* CBCalcPlacement
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment