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
Kate
Commits
bcfc2d4f
Commit
bcfc2d4f
authored
Feb 18, 2022
by
Christoph Cullmann
🍨
Committed by
Waqar Ahmed
Feb 18, 2022
Browse files
highlight open documents in file list
parent
181ef922
Pipeline
#139530
passed with stage
in 2 minutes and 53 seconds
Changes
1
Pipelines
3
Hide whitespace changes
Inline
Side-by-side
kate/kateurlbar.cpp
View file @
bcfc2d4f
...
...
@@ -2,14 +2,18 @@
SPDX-FileCopyrightText: 2022 Waqar Ahmed <waqar.17a@gmail.com>
SPDX-License-Identifier: LGPL-2.0-or-later
*/
#include
"kateurlbar.h"
#include
"kateapp.h"
#include
"kateviewmanager.h"
#include
"kateviewspace.h"
#include
<KTextEditor/Document>
#include
<KTextEditor/View>
#include
<KColorScheme>
#include
<KLocalizedString>
#include
<QAbstractListModel>
#include
<QAction>
#include
<QApplication>
...
...
@@ -62,6 +66,11 @@ public:
}
}
else
if
(
role
==
FileInfo
)
{
return
QVariant
::
fromValue
(
fi
);
}
else
if
(
role
==
Qt
::
ForegroundRole
)
{
// highlight already open documents
if
(
KateApp
::
self
()
->
documentManager
()
->
findDocument
(
QUrl
::
fromLocalFile
(
fi
.
absoluteFilePath
())))
{
return
KColorScheme
().
foreground
(
KColorScheme
::
PositiveText
).
color
();
}
}
return
{};
...
...
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