Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
F
flatpak-qt-creator
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
Environments
Packages & Registries
Packages & Registries
Container Registry
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
Marco Bubke
flatpak-qt-creator
Commits
02488eeb
Commit
02488eeb
authored
Dec 08, 2008
by
Roberto Raggi
Committed by
Roberto Raggi
Dec 08, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More cleanup in the CppPreprocessor.
parent
14ddfc45
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
16 deletions
+16
-16
src/plugins/cpptools/cppmodelmanager.cpp
src/plugins/cpptools/cppmodelmanager.cpp
+12
-12
src/plugins/cpptools/cppmodelmanager.h
src/plugins/cpptools/cppmodelmanager.h
+4
-4
No files found.
src/plugins/cpptools/cppmodelmanager.cpp
View file @
02488eeb
...
@@ -115,7 +115,6 @@ public:
...
@@ -115,7 +115,6 @@ public:
void
setWorkingCopy
(
const
QMap
<
QString
,
QByteArray
>
&
workingCopy
);
void
setWorkingCopy
(
const
QMap
<
QString
,
QByteArray
>
&
workingCopy
);
void
setIncludePaths
(
const
QStringList
&
includePaths
);
void
setIncludePaths
(
const
QStringList
&
includePaths
);
void
setFrameworkPaths
(
const
QStringList
&
frameworkPaths
);
void
setFrameworkPaths
(
const
QStringList
&
frameworkPaths
);
void
addIncludePath
(
const
QString
&
path
);
void
setProjectFiles
(
const
QStringList
&
files
);
void
setProjectFiles
(
const
QStringList
&
files
);
void
run
(
QString
&
fileName
);
void
run
(
QString
&
fileName
);
void
operator
()(
QString
&
fileName
);
void
operator
()(
QString
&
fileName
);
...
@@ -170,9 +169,6 @@ void CppPreprocessor::setIncludePaths(const QStringList &includePaths)
...
@@ -170,9 +169,6 @@ void CppPreprocessor::setIncludePaths(const QStringList &includePaths)
void
CppPreprocessor
::
setFrameworkPaths
(
const
QStringList
&
frameworkPaths
)
void
CppPreprocessor
::
setFrameworkPaths
(
const
QStringList
&
frameworkPaths
)
{
m_frameworkPaths
=
frameworkPaths
;
}
{
m_frameworkPaths
=
frameworkPaths
;
}
void
CppPreprocessor
::
addIncludePath
(
const
QString
&
path
)
{
m_includePaths
.
append
(
path
);
}
void
CppPreprocessor
::
setProjectFiles
(
const
QStringList
&
files
)
void
CppPreprocessor
::
setProjectFiles
(
const
QStringList
&
files
)
{
m_projectFiles
=
files
;
}
{
m_projectFiles
=
files
;
}
...
@@ -488,14 +484,14 @@ void CppModelManager::ensureUpdated()
...
@@ -488,14 +484,14 @@ void CppModelManager::ensureUpdated()
if
(
!
m_dirty
)
if
(
!
m_dirty
)
return
;
return
;
m_projectFiles
=
update
ProjectFiles
();
m_projectFiles
=
internal
ProjectFiles
();
m_includePaths
=
update
IncludePaths
();
m_includePaths
=
internal
IncludePaths
();
m_frameworkPaths
=
update
FrameworkPaths
();
m_frameworkPaths
=
internal
FrameworkPaths
();
m_definedMacros
=
update
DefinedMacros
();
m_definedMacros
=
internal
DefinedMacros
();
m_dirty
=
false
;
m_dirty
=
false
;
}
}
QStringList
CppModelManager
::
update
ProjectFiles
()
const
QStringList
CppModelManager
::
internal
ProjectFiles
()
const
{
{
QStringList
files
;
QStringList
files
;
QMapIterator
<
ProjectExplorer
::
Project
*
,
ProjectInfo
>
it
(
m_projects
);
QMapIterator
<
ProjectExplorer
::
Project
*
,
ProjectInfo
>
it
(
m_projects
);
...
@@ -504,10 +500,11 @@ QStringList CppModelManager::updateProjectFiles() const
...
@@ -504,10 +500,11 @@ QStringList CppModelManager::updateProjectFiles() const
ProjectInfo
pinfo
=
it
.
value
();
ProjectInfo
pinfo
=
it
.
value
();
files
+=
pinfo
.
sourceFiles
;
files
+=
pinfo
.
sourceFiles
;
}
}
files
.
removeDuplicates
();
return
files
;
return
files
;
}
}
QStringList
CppModelManager
::
update
IncludePaths
()
const
QStringList
CppModelManager
::
internal
IncludePaths
()
const
{
{
QStringList
includePaths
;
QStringList
includePaths
;
QMapIterator
<
ProjectExplorer
::
Project
*
,
ProjectInfo
>
it
(
m_projects
);
QMapIterator
<
ProjectExplorer
::
Project
*
,
ProjectInfo
>
it
(
m_projects
);
...
@@ -516,10 +513,11 @@ QStringList CppModelManager::updateIncludePaths() const
...
@@ -516,10 +513,11 @@ QStringList CppModelManager::updateIncludePaths() const
ProjectInfo
pinfo
=
it
.
value
();
ProjectInfo
pinfo
=
it
.
value
();
includePaths
+=
pinfo
.
includePaths
;
includePaths
+=
pinfo
.
includePaths
;
}
}
includePaths
.
removeDuplicates
();
return
includePaths
;
return
includePaths
;
}
}
QStringList
CppModelManager
::
update
FrameworkPaths
()
const
QStringList
CppModelManager
::
internal
FrameworkPaths
()
const
{
{
QStringList
frameworkPaths
;
QStringList
frameworkPaths
;
QMapIterator
<
ProjectExplorer
::
Project
*
,
ProjectInfo
>
it
(
m_projects
);
QMapIterator
<
ProjectExplorer
::
Project
*
,
ProjectInfo
>
it
(
m_projects
);
...
@@ -528,10 +526,11 @@ QStringList CppModelManager::updateFrameworkPaths() const
...
@@ -528,10 +526,11 @@ QStringList CppModelManager::updateFrameworkPaths() const
ProjectInfo
pinfo
=
it
.
value
();
ProjectInfo
pinfo
=
it
.
value
();
frameworkPaths
+=
pinfo
.
frameworkPaths
;
frameworkPaths
+=
pinfo
.
frameworkPaths
;
}
}
frameworkPaths
.
removeDuplicates
();
return
frameworkPaths
;
return
frameworkPaths
;
}
}
QByteArray
CppModelManager
::
update
DefinedMacros
()
const
QByteArray
CppModelManager
::
internal
DefinedMacros
()
const
{
{
QByteArray
macros
;
QByteArray
macros
;
QMapIterator
<
ProjectExplorer
::
Project
*
,
ProjectInfo
>
it
(
m_projects
);
QMapIterator
<
ProjectExplorer
::
Project
*
,
ProjectInfo
>
it
(
m_projects
);
...
@@ -588,6 +587,7 @@ void CppModelManager::updateProjectInfo(const ProjectInfo &pinfo)
...
@@ -588,6 +587,7 @@ void CppModelManager::updateProjectInfo(const ProjectInfo &pinfo)
return
;
return
;
m_projects
.
insert
(
pinfo
.
project
,
pinfo
);
m_projects
.
insert
(
pinfo
.
project
,
pinfo
);
m_dirty
=
true
;
}
}
QFuture
<
void
>
CppModelManager
::
refreshSourceFiles
(
const
QStringList
&
sourceFiles
)
QFuture
<
void
>
CppModelManager
::
refreshSourceFiles
(
const
QStringList
&
sourceFiles
)
...
...
src/plugins/cpptools/cppmodelmanager.h
View file @
02488eeb
...
@@ -133,10 +133,10 @@ private:
...
@@ -133,10 +133,10 @@ private:
}
}
void
ensureUpdated
();
void
ensureUpdated
();
QStringList
update
ProjectFiles
()
const
;
QStringList
internal
ProjectFiles
()
const
;
QStringList
update
IncludePaths
()
const
;
QStringList
internal
IncludePaths
()
const
;
QStringList
update
FrameworkPaths
()
const
;
QStringList
internal
FrameworkPaths
()
const
;
QByteArray
update
DefinedMacros
()
const
;
QByteArray
internal
DefinedMacros
()
const
;
static
void
parse
(
QFutureInterface
<
void
>
&
future
,
static
void
parse
(
QFutureInterface
<
void
>
&
future
,
CppPreprocessor
*
preproc
,
CppPreprocessor
*
preproc
,
...
...
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