Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Utilities
Konsole
Commits
4503e7ef
Commit
4503e7ef
authored
Dec 29, 2021
by
Tomaz Canabrava
Browse files
Do not delete the Open With action
But change the title so it matches what we want to do
parent
38bb7aa2
Pipeline
#115836
passed with stage
in 1 minute and 51 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/session/SessionController.cpp
View file @
4503e7ef
...
...
@@ -1852,12 +1852,15 @@ void SessionController::showDisplayContextMenu(const QPoint &position)
popup
->
addAction
(
contentSeparator
);
toRemove
=
hotSpot
->
setupMenu
(
popup
.
data
());
// Can happen if we click on a right click, on a folder.
// if this happens, we need to remove this action as we have
// already added the action before this if.
if
(
toRemove
[
0
]
->
text
()
==
i18n
(
"&Open Folder With"
))
{
delete
toRemove
[
0
];
toRemove
.
removeFirst
();
// The action above can create an action for Open Folder With,
// for the selected folder, but then we have two different
// Open Folder With - with different folders on each.
// Change the text of the second one, that points to the
// current folder.
for
(
auto
*
action
:
neu
)
{
if
(
action
->
objectName
()
==
QStringLiteral
(
"openWith_submenu"
))
{
action
->
setText
(
i18n
(
"Open Current Folder With"
));
}
}
toRemove
=
toRemove
+
neu
;
}
else
{
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment