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
79413eda
Commit
79413eda
authored
Feb 20, 2001
by
Guy L. Albertelli
Committed by
Alexandre Julliard
Feb 20, 2001
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Restructure PaintText code to remove FillRect from owner-drawn path.
- Change SetFocus to indicate focus set only after Notify is sent to owner. - Get more info in a trace.
parent
0a788579
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
15 deletions
+23
-15
combo.c
controls/combo.c
+23
-15
No files found.
controls/combo.c
View file @
79413eda
...
@@ -778,22 +778,16 @@ static void CBPaintText(
...
@@ -778,22 +778,16 @@ static void CBPaintText(
*/
*/
InflateRect
(
&
rectEdit
,
-
1
,
-
1
);
InflateRect
(
&
rectEdit
,
-
1
,
-
1
);
if
(
(
lphc
->
wState
&
CBF_FOCUSED
)
&&
!
(
lphc
->
wState
&
CBF_DROPPED
)
)
{
/* highlight */
FillRect
(
hdc
,
&
rectEdit
,
GetSysColorBrush
(
COLOR_HIGHLIGHT
)
);
SetBkColor
(
hdc
,
GetSysColor
(
COLOR_HIGHLIGHT
)
);
SetTextColor
(
hdc
,
GetSysColor
(
COLOR_HIGHLIGHTTEXT
)
);
itemState
|=
ODS_SELECTED
|
ODS_FOCUS
;
}
if
(
CB_OWNERDRAWN
(
lphc
)
)
if
(
CB_OWNERDRAWN
(
lphc
)
)
{
{
DRAWITEMSTRUCT
dis
;
DRAWITEMSTRUCT
dis
;
HRGN
clipRegion
;
HRGN
clipRegion
;
/* setup state for DRAWITEM message. Owner will highlight */
if
(
(
lphc
->
wState
&
CBF_FOCUSED
)
&&
!
(
lphc
->
wState
&
CBF_DROPPED
)
)
itemState
|=
ODS_SELECTED
|
ODS_FOCUS
;
/*
/*
* Save the current clip region.
* Save the current clip region.
* To retrieve the clip region, we need to create one "dummy"
* To retrieve the clip region, we need to create one "dummy"
...
@@ -838,7 +832,17 @@ static void CBPaintText(
...
@@ -838,7 +832,17 @@ static void CBPaintText(
}
}
else
else
{
{
static
const
WCHAR
empty_stringW
[]
=
{
0
};
static
const
WCHAR
empty_stringW
[]
=
{
0
};
if
(
(
lphc
->
wState
&
CBF_FOCUSED
)
&&
!
(
lphc
->
wState
&
CBF_DROPPED
)
)
{
/* highlight */
FillRect
(
hdc
,
&
rectEdit
,
GetSysColorBrush
(
COLOR_HIGHLIGHT
)
);
SetBkColor
(
hdc
,
GetSysColor
(
COLOR_HIGHLIGHT
)
);
SetTextColor
(
hdc
,
GetSysColor
(
COLOR_HIGHLIGHTTEXT
)
);
}
ExtTextOutW
(
hdc
,
ExtTextOutW
(
hdc
,
rectEdit
.
left
+
1
,
rectEdit
.
left
+
1
,
rectEdit
.
top
+
1
,
rectEdit
.
top
+
1
,
...
@@ -1197,19 +1201,21 @@ static void CBRollUp( LPHEADCOMBO lphc, BOOL ok, BOOL bButton )
...
@@ -1197,19 +1201,21 @@ static void CBRollUp( LPHEADCOMBO lphc, BOOL ok, BOOL bButton )
{
{
HWND
hWnd
=
lphc
->
self
->
hwndSelf
;
HWND
hWnd
=
lphc
->
self
->
hwndSelf
;
TRACE
(
"[%04x]: sel ok? [%i] dropped? [%i]
\n
"
,
CB_HWND
(
lphc
),
(
INT
)
ok
,
(
INT
)(
lphc
->
wState
&
CBF_DROPPED
));
CB_NOTIFY
(
lphc
,
(
ok
)
?
CBN_SELENDOK
:
CBN_SELENDCANCEL
);
CB_NOTIFY
(
lphc
,
(
ok
)
?
CBN_SELENDOK
:
CBN_SELENDCANCEL
);
if
(
IsWindow
(
hWnd
)
&&
CB_GETTYPE
(
lphc
)
!=
CBS_SIMPLE
)
if
(
IsWindow
(
hWnd
)
&&
CB_GETTYPE
(
lphc
)
!=
CBS_SIMPLE
)
{
{
TRACE
(
"[%04x]: roll up [%i]
\n
"
,
CB_HWND
(
lphc
),
(
INT
)
ok
);
if
(
lphc
->
wState
&
CBF_DROPPED
)
if
(
lphc
->
wState
&
CBF_DROPPED
)
{
{
RECT
rect
;
RECT
rect
;
lphc
->
wState
&=
~
CBF_DROPPED
;
lphc
->
wState
&=
~
CBF_DROPPED
;
ShowWindow
(
lphc
->
hWndLBox
,
SW_HIDE
);
ShowWindow
(
lphc
->
hWndLBox
,
SW_HIDE
);
if
(
GetCapture
()
==
lphc
->
hWndLBox
)
if
(
GetCapture
()
==
lphc
->
hWndLBox
)
{
{
ReleaseCapture
();
ReleaseCapture
();
...
@@ -1277,7 +1283,9 @@ static void COMBO_SetFocus( LPHEADCOMBO lphc )
...
@@ -1277,7 +1283,9 @@ static void COMBO_SetFocus( LPHEADCOMBO lphc )
if
(
CB_GETTYPE
(
lphc
)
==
CBS_DROPDOWNLIST
)
if
(
CB_GETTYPE
(
lphc
)
==
CBS_DROPDOWNLIST
)
SendMessageW
(
lphc
->
hWndLBox
,
LB_CARETON
,
0
,
0
);
SendMessageW
(
lphc
->
hWndLBox
,
LB_CARETON
,
0
,
0
);
lphc
->
wState
|=
CBF_FOCUSED
;
/* This is wrong. Message sequences seem to indicate that this
is set *after* the notify. */
/* lphc->wState |= CBF_FOCUSED; */
if
(
!
(
lphc
->
wState
&
CBF_EDIT
)
)
if
(
!
(
lphc
->
wState
&
CBF_EDIT
)
)
InvalidateRect
(
CB_HWND
(
lphc
),
&
lphc
->
textRect
,
TRUE
);
InvalidateRect
(
CB_HWND
(
lphc
),
&
lphc
->
textRect
,
TRUE
);
...
...
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