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
4ebf2e45
Commit
4ebf2e45
authored
Mar 28, 2009
by
Nikolay Sivov
Committed by
Alexandre Julliard
Mar 30, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32/tab: Fix highlighted tabs painting.
parent
4b2ea6f4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
27 additions
and
4 deletions
+27
-4
tab.c
dlls/comctl32/tab.c
+27
-4
No files found.
dlls/comctl32/tab.c
View file @
4ebf2e45
...
...
@@ -1496,6 +1496,18 @@ TAB_EraseTabInterior(const TAB_INFO *infoPtr, HDC hdc, INT iItem, RECT *drawRect
FillRect
(
hdc
,
&
rTemp
,
hbr
);
}
/* highlighting is drawn on top of previous fills */
if
(
TAB_GetItem
(
infoPtr
,
iItem
)
->
dwState
&
TCIS_HIGHLIGHTED
)
{
if
(
deleteBrush
)
{
DeleteObject
(
hbr
);
deleteBrush
=
FALSE
;
}
hbr
=
GetSysColorBrush
(
COLOR_HIGHLIGHT
);
FillRect
(
hdc
,
&
rTemp
,
hbr
);
}
/* Cleanup */
if
(
deleteBrush
)
DeleteObject
(
hbr
);
}
...
...
@@ -1649,10 +1661,15 @@ TAB_DrawItemInterior(const TAB_INFO *infoPtr, HDC hdc, INT iItem, RECT *drawRect
*/
oldBkMode
=
SetBkMode
(
hdc
,
TRANSPARENT
);
if
(
!
GetWindowTheme
(
infoPtr
->
hwnd
)
||
(
lStyle
&
TCS_BUTTONS
))
SetTextColor
(
hdc
,
(((
lStyle
&
TCS_HOTTRACK
)
&&
(
iItem
==
infoPtr
->
iHotTracked
)
&&
!
(
lStyle
&
TCS_FLATBUTTONS
))
|
(
TAB_GetItem
(
infoPtr
,
iItem
)
->
dwState
&
TCIS_HIGHLIGHTED
))
?
comctl32_color
.
clrHighlight
:
comctl32_color
.
clrBtnText
);
{
if
((
lStyle
&
TCS_HOTTRACK
)
&&
(
iItem
==
infoPtr
->
iHotTracked
)
&&
!
(
lStyle
&
TCS_FLATBUTTONS
))
SetTextColor
(
hdc
,
comctl32_color
.
clrHighlight
);
else
if
(
TAB_GetItem
(
infoPtr
,
iItem
)
->
dwState
&
TCIS_HIGHLIGHTED
)
SetTextColor
(
hdc
,
comctl32_color
.
clrHighlightText
);
else
SetTextColor
(
hdc
,
comctl32_color
.
clrBtnText
);
}
/*
* if owner draw, tell the owner to draw
...
...
@@ -2698,6 +2715,8 @@ static inline LRESULT
TAB_HighlightItem
(
TAB_INFO
*
infoPtr
,
INT
iItem
,
BOOL
fHighlight
)
{
LPDWORD
lpState
;
DWORD
oldState
;
RECT
r
;
TRACE
(
"(%p,%d,%s)
\n
"
,
infoPtr
,
iItem
,
fHighlight
?
"true"
:
"false"
);
...
...
@@ -2705,12 +2724,16 @@ TAB_HighlightItem (TAB_INFO *infoPtr, INT iItem, BOOL fHighlight)
return
FALSE
;
lpState
=
&
TAB_GetItem
(
infoPtr
,
iItem
)
->
dwState
;
oldState
=
*
lpState
;
if
(
fHighlight
)
*
lpState
|=
TCIS_HIGHLIGHTED
;
else
*
lpState
&=
~
TCIS_HIGHLIGHTED
;
if
((
oldState
!=
*
lpState
)
&&
TAB_InternalGetItemRect
(
infoPtr
,
iItem
,
&
r
,
NULL
))
InvalidateRect
(
infoPtr
->
hwnd
,
&
r
,
TRUE
);
return
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