Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
KCacheGrind
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
SDK
KCacheGrind
Commits
c5fe5de8
Commit
c5fe5de8
authored
Sep 21, 2020
by
Calvin Buckley
🤔
Committed by
Albert Astals Cid
Nov 06, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix dock menu only checking one specific item
parent
0df27b4a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletion
+7
-1
qcachegrind/qcgtoplevel.cpp
qcachegrind/qcgtoplevel.cpp
+7
-1
No files found.
qcachegrind/qcgtoplevel.cpp
View file @
c5fe5de8
...
...
@@ -1858,13 +1858,19 @@ void QCGTopLevel::partsUnhideAllSlot()
void
QCGTopLevel
::
insertWindowList
(
QMenu
*
menu
)
{
auto
windowList
=
QApplication
::
topLevelWidgets
();
auto
activeWindow
=
QApplication
::
activeWindow
();
// dock menu this corresponds to (IIRC) last window that installed one,
// so using it unless we have to is a bad idea
if
(
activeWindow
==
nullptr
)
{
activeWindow
=
this
;
}
for
(
int
i
=
0
;
i
<
windowList
.
size
();
i
++
)
{
QWidget
*
topLevelRaw
=
windowList
[
i
];
if
(
QCGTopLevel
*
topLevel
=
qobject_cast
<
QCGTopLevel
*>
(
topLevelRaw
))
{
QString
windowTitle
=
topLevel
->
windowTitle
();
QAction
*
windowItem
=
menu
->
addAction
(
windowTitle
);
windowItem
->
setData
(
QVariant
::
fromValue
(
topLevel
));
if
(
topLevel
==
this
)
{
if
(
topLevel
==
activeWindow
)
{
windowItem
->
setCheckable
(
true
);
windowItem
->
setChecked
(
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