Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Miguel Lopez
Krita
Commits
3f30e39f
Commit
3f30e39f
authored
Jan 10, 2015
by
Halla Rempt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix painting in workspace chooser
parent
4a10bc1c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
krita/ui/widgets/kis_workspace_chooser.cpp
krita/ui/widgets/kis_workspace_chooser.cpp
+6
-5
No files found.
krita/ui/widgets/kis_workspace_chooser.cpp
View file @
3f30e39f
...
...
@@ -55,18 +55,20 @@ public:
void
KisWorkspaceDelegate
::
paint
(
QPainter
*
painter
,
const
QStyleOptionViewItem
&
option
,
const
QModelIndex
&
index
)
const
{
if
(
!
index
.
isValid
())
if
(
!
index
.
isValid
())
return
;
KisWorkspaceResource
*
workspace
=
static_cast
<
KisWorkspaceResource
*>
(
index
.
internalPointer
());
QPalette
::
ColorGroup
cg
=
(
option
.
state
&
QStyle
::
State_Enabled
)
?
QPalette
::
Active
:
QPalette
::
Disabled
;
QPalette
::
ColorRole
cr
=
(
option
.
state
&
QStyle
::
State_Selected
)
?
QPalette
::
HighlightedText
:
QPalette
::
Text
;
painter
->
setPen
(
option
.
palette
.
color
(
cg
,
cr
));
if
(
option
.
state
&
QStyle
::
State_Selected
)
{
painter
->
setPen
(
QPen
(
option
.
palette
.
highlight
(),
2.0
));
painter
->
fillRect
(
option
.
rect
,
option
.
palette
.
highlight
());
painter
->
setBrush
(
option
.
palette
.
highlightedText
());
}
else
{
painter
->
setBrush
(
option
.
palette
.
text
());
painter
->
fillRect
(
option
.
rect
,
option
.
palette
.
base
());
}
...
...
@@ -155,7 +157,6 @@ void KisWorkspaceChooser::resourceSelected(KoResource* resource)
m_view
->
resourceProvider
()
->
notifyLoadingWorkspace
(
workspace
);
foreach
(
QDockWidget
*
docker
,
dockWidgetMap
.
keys
())
{
qDebug
()
<<
docker
<<
docker
->
isVisible
()
<<
docker
->
property
(
"Locked"
);
if
(
docker
->
isVisible
())
{
docker
->
setProperty
(
"Locked"
,
dockWidgetMap
[
docker
]);
docker
->
updateGeometry
();
...
...
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