Commit 7fac110d authored by Kai Koehne's avatar Kai Koehne
Browse files

QmlOutline: Move QmlOutlineTreeView into it's own file

parent 7a1c1a37
......@@ -27,7 +27,8 @@ HEADERS += \
qmljsoutline.h \
qmloutlinemodel.h \
qmltaskmanager.h \
qmljseditorcodeformatter.h
qmljseditorcodeformatter.h \
qmljsoutlinetreeview.h
SOURCES += \
qmljscodecompletion.cpp \
......@@ -48,7 +49,8 @@ SOURCES += \
qmloutlinemodel.cpp \
qmltaskmanager.cpp \
qmljsquickfixes.cpp \
qmljseditorcodeformatter.cpp
qmljseditorcodeformatter.cpp \
qmljsoutlinetreeview.cpp
RESOURCES += qmljseditor.qrc
OTHER_FILES += QmlJSEditor.pluginspec QmlJSEditor.mimetypes.xml
#include "qmljsoutline.h"
#include "qmloutlinemodel.h"
#include "qmljsoutlinetreeview.h"
#include <coreplugin/icore.h>
#include <coreplugin/ifile.h>
......@@ -19,18 +20,6 @@ enum {
namespace QmlJSEditor {
namespace Internal {
QmlJSOutlineTreeView::QmlJSOutlineTreeView(QWidget *parent) :
Utils::NavigationTreeView(parent)
{
// see also CppOutlineTreeView
setFocusPolicy(Qt::NoFocus);
setExpandsOnDoubleClick(false);
setDragEnabled(true);
viewport()->setAcceptDrops(true);
setDropIndicatorShown(true);
setDragDropMode(InternalMove);
}
QmlJSOutlineFilterModel::QmlJSOutlineFilterModel(QObject *parent) :
QSortFilterProxyModel(parent)
......
......@@ -3,10 +3,8 @@
#include "qmljseditor.h"
#include <utils/navigationtreeview.h>
#include <texteditor/ioutlinewidget.h>
#include <QtGui/QTreeView>
#include <QtGui/QSortFilterProxyModel>
namespace Core {
......@@ -20,12 +18,7 @@ class Editor;
namespace QmlJSEditor {
namespace Internal {
class QmlJSOutlineTreeView : public Utils::NavigationTreeView
{
Q_OBJECT
public:
QmlJSOutlineTreeView(QWidget *parent = 0);
};
class QmlJSOutlineTreeView;
class QmlJSOutlineFilterModel : public QSortFilterProxyModel
{
......
#include "qmljsoutlinetreeview.h"
namespace QmlJSEditor {
namespace Internal {
QmlJSOutlineTreeView::QmlJSOutlineTreeView(QWidget *parent) :
Utils::NavigationTreeView(parent)
{
// see also CppOutlineTreeView
setFocusPolicy(Qt::NoFocus);
setExpandsOnDoubleClick(false);
setDragEnabled(true);
viewport()->setAcceptDrops(true);
setDropIndicatorShown(true);
setDragDropMode(InternalMove);
}
} // namespace Internal
} // namespace QmlJSEditor
#ifndef QMLJSOUTLINETREEVIEW_H
#define QMLJSOUTLINETREEVIEW_H
#include <utils/navigationtreeview.h>
namespace QmlJSEditor {
namespace Internal {
class QmlJSOutlineTreeView : public Utils::NavigationTreeView
{
Q_OBJECT
public:
QmlJSOutlineTreeView(QWidget *parent = 0);
};
} // namespace Internal
} // namespace QmlJSEditor
#endif // QMLJSOUTLINETREEVIEW_H
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment