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
kdevelop
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
0
Merge Requests
0
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
Thomas Schöps
kdevelop
Commits
e4c27511
Commit
e4c27511
authored
Aug 22, 2019
by
Friedrich W. H. Kossebau
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '5.4'
parents
aad2c49e
bc06b109
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
24 additions
and
17 deletions
+24
-17
app/org.kde.kdevelop_ps.desktop
app/org.kde.kdevelop_ps.desktop
+1
-0
kdevplatform/shell/mainwindow.cpp
kdevplatform/shell/mainwindow.cpp
+17
-15
org.kde.kdevelop.appdata.xml
org.kde.kdevelop.appdata.xml
+1
-1
plugins/clang/util/clangutils.cpp
plugins/clang/util/clangutils.cpp
+5
-1
No files found.
app/org.kde.kdevelop_ps.desktop
View file @
e4c27511
...
...
@@ -67,3 +67,4 @@ GenericName[x-test]=xxIntegrated Development Environment (Pick Session to start
GenericName[zh_CN]=集成开发环境(选择要启动的会话)
GenericName[zh_TW]=整合開發環境(選擇要開始的工作階段)
Categories=Qt;KDE;Development;IDE;
X-AppStream-Ignore=true
kdevplatform/shell/mainwindow.cpp
View file @
e4c27511
...
...
@@ -38,7 +38,6 @@ Boston, MA 02110-1301, USA.
#include <KTextEditor/View>
#include <KWindowSystem>
#include <KXMLGUIFactory>
#include <kparts_version.h>
#include <sublime/area.h>
#include "shellextension.h"
...
...
@@ -95,18 +94,8 @@ void MainWindow::applyMainWindowSettings(const KConfigGroup& config)
void
MainWindow
::
createGUI
(
KParts
::
Part
*
part
)
{
//TODO remove if-clause once KF5 >= 5.24 is required
#if KPARTS_VERSION_MINOR >= 24
Sublime
::
MainWindow
::
setWindowTitleHandling
(
false
);
Sublime
::
MainWindow
::
createGUI
(
part
);
#else
Sublime
::
MainWindow
::
createGUI
(
part
);
if
(
part
)
{
// Don't let the Part control the main window caption -- we take care of that
disconnect
(
part
,
SIGNAL
(
setWindowCaption
(
QString
)),
this
,
SLOT
(
setCaption
(
QString
)));
}
#endif
}
void
MainWindow
::
initializeCorners
()
...
...
@@ -397,6 +386,7 @@ void MainWindow::initialize()
connect
(
Core
::
self
()
->
documentController
(),
&
IDocumentController
::
documentClosed
,
this
,
&
MainWindow
::
updateCaption
,
Qt
::
QueuedConnection
);
connect
(
Core
::
self
()
->
documentController
(),
&
IDocumentController
::
documentUrlChanged
,
this
,
&
MainWindow
::
updateCaption
,
Qt
::
QueuedConnection
);
connect
(
Core
::
self
()
->
documentController
(),
&
IDocumentController
::
documentStateChanged
,
this
,
&
MainWindow
::
updateCaption
,
Qt
::
QueuedConnection
);
connect
(
Core
::
self
()
->
sessionController
()
->
activeSession
(),
&
ISession
::
sessionUpdated
,
this
,
&
MainWindow
::
updateCaption
);
connect
(
Core
::
self
()
->
documentController
(),
&
IDocumentController
::
documentOpened
,
this
,
&
MainWindow
::
updateTabColor
);
...
...
@@ -444,6 +434,7 @@ void MainWindow::updateCaption()
const
auto
activeSession
=
Core
::
self
()
->
sessionController
()
->
activeSession
();
QString
title
=
activeSession
?
activeSession
->
description
()
:
QString
();
QString
localFilePath
;
bool
isDocumentModified
=
false
;
if
(
area
()
->
activeView
())
{
...
...
@@ -462,15 +453,26 @@ void MainWindow::updateCaption()
else
title
+=
doc
->
title
();
auto
activeDocument
=
Core
::
self
()
->
documentController
()
->
activeDocument
(
);
if
(
activeDocument
&&
activeDocument
->
textDocument
()
&&
!
activeDocument
->
textDocument
()
->
isReadWrite
())
auto
iDoc
=
qobject_cast
<
IDocument
*>
(
doc
);
if
(
iDoc
&&
iDoc
->
textDocument
()
&&
!
iDoc
->
textDocument
()
->
isReadWrite
())
{
title
+=
i18n
(
" (read only)"
);
}
title
+=
QLatin1String
(
" ]"
);
title
+=
QLatin1String
(
" [*]]"
);
// [*] is placeholder for modifed state, cmp. QWidget::windowModified
isDocumentModified
=
iDoc
&&
(
iDoc
->
state
()
!=
IDocument
::
Clean
);
}
setWindowFilePath
(
localFilePath
);
// Workaround for a bug observed on macOS with Qt 5.9.8 (TODO: test with newer Qt, report bug):
// Ensure to call setCaption() (thus implicitly setWindowTitle()) before
// setWindowModified() & setWindowFilePath().
// Otherwise, if the state will change "modifed" from true to false as well change the title string,
// calling setWindowTitle() last results in the "modified" indicator==asterisk becoming part of the
// displayed window title somehow.
// Other platforms so far not known to be affected, any order of calls seems fine.
setCaption
(
title
);
setWindowModified
(
isDocumentModified
);
setWindowFilePath
(
localFilePath
);
}
void
MainWindow
::
updateAllTabColors
()
...
...
org.kde.kdevelop.appdata.xml
View file @
e4c27511
...
...
@@ -140,7 +140,7 @@
<provides>
<binary>
kdevelop
</binary>
</provides>
<launchable
type=
"desktop-id"
>
org.kde.kdevelop
_ps
.desktop
</launchable>
<launchable
type=
"desktop-id"
>
org.kde.kdevelop.desktop
</launchable>
<icon
type=
"stock"
>
kdevelop
</icon>
<categories>
<category>
Development
</category>
...
...
plugins/clang/util/clangutils.cpp
View file @
e4c27511
...
...
@@ -187,7 +187,11 @@ QVector<QString> ClangUtils::getDefaultArguments(CXCursor cursor, DefaultArgumen
info
.
stringParts
.
removeFirst
();
}
//Clang seems to include the , or ) at the end of the param, so delete that
if
(
!
info
.
stringParts
.
isEmpty
()
&&
(
info
.
stringParts
.
last
()
==
QLatin1String
(
","
)
||
info
.
stringParts
.
last
()
==
QLatin1String
(
")"
)))
{
if
(
!
info
.
stringParts
.
isEmpty
()
&&
((
info
.
stringParts
.
last
()
==
QLatin1String
(
","
))
||
(
info
.
stringParts
.
last
()
==
QLatin1String
(
")"
)
&&
// assuming otherwise matching "(" & ")" tokens
info
.
stringParts
.
count
(
QStringLiteral
(
"("
))
!=
info
.
stringParts
.
count
(
QStringLiteral
(
")"
)))))
{
info
.
stringParts
.
removeLast
();
}
...
...
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