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
Marco Bubke
flatpak-qt-creator
Commits
91eff020
Commit
91eff020
authored
Jun 22, 2010
by
Roberto Raggi
Browse files
Moved CppRefactoringChanges.
parent
a19f8025
Changes
6
Hide whitespace changes
Inline
Side-by-side
src/plugins/cppeditor/cppeditor.pro
View file @
91eff020
...
...
@@ -14,7 +14,8 @@ HEADERS += cppplugin.h \
cppeditorenums
.
h
\
cppeditor_global
.
h
\
cppclasswizard
.
h
\
cppquickfix
.
h
cppquickfix
.
h
\
cpprefactoringchanges
.
h
SOURCES
+=
cppplugin
.
cpp
\
cppeditor
.
cpp
\
...
...
@@ -22,7 +23,8 @@ SOURCES += cppplugin.cpp \
cpphoverhandler
.
cpp
\
cppfilewizard
.
cpp
\
cppclasswizard
.
cpp
\
cppquickfix
.
cpp
cppquickfix
.
cpp
\
cpprefactoringchanges
.
cpp
RESOURCES
+=
cppeditor
.
qrc
...
...
src/plugins/cppeditor/cppquickfix.cpp
View file @
91eff020
...
...
@@ -47,7 +47,7 @@
#include
<Name.h>
#include
<Literals.h>
#include
<cpp
tools
/cpprefactoringchanges.h>
#include
<cpp
editor
/cpprefactoringchanges.h>
#include
<cpptools/cpptoolsconstants.h>
#include
<cpptools/cppmodelmanagerinterface.h>
...
...
@@ -944,7 +944,7 @@ int CppQuickFixOperation::match(TextEditor::QuickFixState *state)
if
(
_refactoringChanges
)
delete
_refactoringChanges
;
CPPEditor
*
cppEditor
=
qobject_cast
<
CPPEditor
*>
(
editor
());
_refactoringChanges
=
new
CppTools
::
CppRefactoringChanges
(
s
->
info
.
snapshot
,
cppEditor
->
modelManager
());
_refactoringChanges
=
new
CppRefactoringChanges
(
s
->
info
.
snapshot
,
cppEditor
->
modelManager
());
return
match
(
s
->
path
);
}
...
...
@@ -956,7 +956,7 @@ void CppQuickFixOperation::apply()
cppRefactoringChanges
()
->
apply
();
}
Cpp
Tools
::
CppRefactoringChanges
*
CppQuickFixOperation
::
cppRefactoringChanges
()
const
Cpp
Editor
::
CppRefactoringChanges
*
CppQuickFixOperation
::
cppRefactoringChanges
()
const
{
return
_refactoringChanges
;
}
TextEditor
::
RefactoringChanges
*
CppQuickFixOperation
::
refactoringChanges
()
const
...
...
src/plugins/cppeditor/cppquickfix.h
View file @
91eff020
...
...
@@ -43,10 +43,11 @@
namespace
CppTools
{
class
CppModelManagerInterface
;
class
CppRefactoringChanges
;
}
// end of namespace CppTools
namespace
CppEditor
{
class
CppRefactoringChanges
;
namespace
Internal
{
class
CppQuickFixOperation
:
public
TextEditor
::
QuickFixOperation
...
...
@@ -68,7 +69,7 @@ protected:
QString
fileName
()
const
;
virtual
void
apply
();
virtual
CppTools
::
CppRefactoringChanges
*
cppRefactoringChanges
()
const
;
virtual
CppRefactoringChanges
*
cppRefactoringChanges
()
const
;
virtual
TextEditor
::
RefactoringChanges
*
refactoringChanges
()
const
;
const
CPlusPlus
::
Token
&
tokenAt
(
unsigned
index
)
const
;
...
...
@@ -101,7 +102,7 @@ protected:
QString
textOf
(
const
CPlusPlus
::
AST
*
ast
)
const
;
private:
CppTools
::
CppRefactoringChanges
*
_refactoringChanges
;
CppRefactoringChanges
*
_refactoringChanges
;
CPlusPlus
::
Document
::
Ptr
_document
;
CPlusPlus
::
AST
*
_topLevelNode
;
};
...
...
src/plugins/cpp
tools
/cpprefactoringchanges.cpp
→
src/plugins/cpp
editor
/cpprefactoringchanges.cpp
View file @
91eff020
...
...
@@ -32,6 +32,7 @@
using
namespace
CPlusPlus
;
using
namespace
CppTools
;
using
namespace
TextEditor
;
using
namespace
CppEditor
;
CppRefactoringChanges
::
CppRefactoringChanges
(
const
Snapshot
&
snapshot
,
CppModelManagerInterface
*
modelManager
)
...
...
src/plugins/cpp
tools
/cpprefactoringchanges.h
→
src/plugins/cpp
editor
/cpprefactoringchanges.h
View file @
91eff020
...
...
@@ -33,16 +33,16 @@
#include
<cplusplus/CppDocument.h>
#include
<cpptools/cppmodelmanagerinterface.h>
#include
<cpp
tools/cpptools
_global.h>
#include
<cpp
editor/cppeditor
_global.h>
#include
<texteditor/refactoringchanges.h>
namespace
Cpp
Tools
{
namespace
Cpp
Editor
{
class
CPP
TOOLS
_EXPORT
CppRefactoringChanges
:
public
TextEditor
::
RefactoringChanges
class
CPP
EDITOR
_EXPORT
CppRefactoringChanges
:
public
TextEditor
::
RefactoringChanges
{
public:
CppRefactoringChanges
(
const
CPlusPlus
::
Snapshot
&
snapshot
,
CppModelManagerInterface
*
modelManager
);
CppRefactoringChanges
(
const
CPlusPlus
::
Snapshot
&
snapshot
,
CppTools
::
CppModelManagerInterface
*
modelManager
);
virtual
QStringList
apply
();
...
...
@@ -53,10 +53,10 @@ public:
private:
CPlusPlus
::
Snapshot
m_snapshot
;
CppModelManagerInterface
*
m_modelManager
;
CppModelManagerInterface
::
WorkingCopy
m_workingCopy
;
CppTools
::
CppModelManagerInterface
*
m_modelManager
;
CppTools
::
CppModelManagerInterface
::
WorkingCopy
m_workingCopy
;
};
}
// namespace Cpp
Tools
}
// namespace Cpp
Editor
#endif // CPPREFACTORINGCHANGES_H
src/plugins/cpptools/cpptools.pro
View file @
91eff020
...
...
@@ -23,8 +23,7 @@ HEADERS += completionsettingspage.h \
searchsymbols
.
h
\
cppdoxygen
.
h
\
cppfilesettingspage
.
h
\
cppfindreferences
.
h
\
cpprefactoringchanges
.
h
cppfindreferences
.
h
SOURCES
+=
completionsettingspage
.
cpp
\
cppclassesfilter
.
cpp
\
...
...
@@ -39,8 +38,7 @@ SOURCES += completionsettingspage.cpp \
cppdoxygen
.
cpp
\
cppfilesettingspage
.
cpp
\
abstracteditorsupport
.
cpp
\
cppfindreferences
.
cpp
\
cpprefactoringchanges
.
cpp
cppfindreferences
.
cpp
FORMS
+=
completionsettingspage
.
ui
\
cppfilesettingspage
.
ui
...
...
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