QmlJSEditor: General editor related code consolidation

Merge editor files, sort #includes, namespaces.
This does not yet use the new editor construction scheme.

Change-Id: Idb1171389858c4470d7a4ec9441fb25e6d157400
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
This commit is contained in:
hjk
2014-08-20 01:47:42 +02:00
parent ba51240524
commit 3ac0668d5c
13 changed files with 150 additions and 354 deletions

View File

@@ -34,41 +34,32 @@
#include <qmljs/qmljsscanner.h>
#include <qmljstools/qmljssemanticinfo.h>
#include <coreplugin/editormanager/ieditorfactory.h>
#include <texteditor/basetexteditor.h>
#include <texteditor/quickfix.h>
#include <texteditor/texteditorconstants.h>
#include <utils/uncommentselection.h>
#include <QSharedPointer>
#include <QModelIndex>
#include <QTextLayout>
#include <QVector>
QT_BEGIN_NAMESPACE
class QComboBox;
class QTimer;
QT_END_NAMESPACE
namespace Core { class ICore; }
namespace QmlJS {
class ModelManagerInterface;
class IContextPane;
class LookupContext;
namespace AST { class UiObjectMember; }
}
/*!
The top-level namespace of the QmlJSEditor plug-in.
*/
namespace QmlJSEditor {
class QmlJSEditorDocument;
class FindReferences;
namespace Internal {
class QmlJSEditor;
class QmlOutlineModel;
class QmlJSTextEditorWidget : public TextEditor::BaseTextEditorWidget
{
Q_OBJECT
@@ -147,6 +138,29 @@ private:
FindReferences *m_findReferences;
};
class QmlJSEditor : public TextEditor::BaseTextEditor
{
Q_OBJECT
public:
QmlJSEditor();
Core::IEditor *duplicate();
bool open(QString *errorString, const QString &fileName, const QString &realFileName);
bool isDesignModePreferred() const;
};
class QmlJSEditorFactory : public Core::IEditorFactory
{
Q_OBJECT
public:
QmlJSEditorFactory();
Core::IEditor *createEditor();
};
} // namespace Internal
} // namespace QmlJSEditor