forked from qt-creator/qt-creator
QmlJSDebugger: Change namespace from QmlObserver to QmlJSDebugger
The library not only contains the observer part, but also the javascript debugger. Reflect this in the namespace.
This commit is contained in:
@@ -37,7 +37,7 @@
|
|||||||
#include <QGraphicsItem>
|
#include <QGraphicsItem>
|
||||||
#include <QDeclarativeItem>
|
#include <QDeclarativeItem>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
AbstractFormEditorTool::AbstractFormEditorTool(QDeclarativeViewObserver *editorView)
|
AbstractFormEditorTool::AbstractFormEditorTool(QDeclarativeViewObserver *editorView)
|
||||||
: QObject(editorView), m_observer(editorView)
|
: QObject(editorView), m_observer(editorView)
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ class QWheelEvent;
|
|||||||
class QDeclarativeView;
|
class QDeclarativeView;
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class QDeclarativeViewObserver;
|
class QDeclarativeViewObserver;
|
||||||
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
|
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
const qreal AnimDelta = 0.025f;
|
const qreal AnimDelta = 0.025f;
|
||||||
const int AnimInterval = 30;
|
const int AnimInterval = 30;
|
||||||
@@ -238,4 +238,4 @@ void BoundingRectHighlighter::refresh()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ QT_FORWARD_DECLARE_CLASS(QWidget);
|
|||||||
QT_FORWARD_DECLARE_CLASS(QStyleOptionGraphicsItem);
|
QT_FORWARD_DECLARE_CLASS(QStyleOptionGraphicsItem);
|
||||||
QT_FORWARD_DECLARE_CLASS(QTimer);
|
QT_FORWARD_DECLARE_CLASS(QTimer);
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class QDeclarativeViewObserver;
|
class QDeclarativeViewObserver;
|
||||||
class BoundingBox;
|
class BoundingBox;
|
||||||
@@ -73,6 +73,6 @@ public:
|
|||||||
int type() const;
|
int type() const;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif // BOUNDINGRECTHIGHLIGHTER_H
|
#endif // BOUNDINGRECTHIGHLIGHTER_H
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
#include <QPalette>
|
#include <QPalette>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
ColorPickerTool::ColorPickerTool(QDeclarativeViewObserver *view) :
|
ColorPickerTool::ColorPickerTool(QDeclarativeViewObserver *view) :
|
||||||
AbstractFormEditorTool(view)
|
AbstractFormEditorTool(view)
|
||||||
@@ -86,4 +86,4 @@ void ColorPickerTool::pickColor(const QPoint &pos)
|
|||||||
emit selectedColorChanged(m_selectedColor);
|
emit selectedColorChanged(m_selectedColor);
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
QT_FORWARD_DECLARE_CLASS(QPoint);
|
QT_FORWARD_DECLARE_CLASS(QPoint);
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class ColorPickerTool : public AbstractFormEditorTool
|
class ColorPickerTool : public AbstractFormEditorTool
|
||||||
{
|
{
|
||||||
@@ -48,6 +48,6 @@ private:
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif // COLORPICKERTOOL_H
|
#endif // COLORPICKERTOOL_H
|
||||||
|
|||||||
@@ -32,7 +32,7 @@
|
|||||||
|
|
||||||
#include <QGraphicsScene>
|
#include <QGraphicsScene>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
LayerItem::LayerItem(QGraphicsScene* scene)
|
LayerItem::LayerItem(QGraphicsScene* scene)
|
||||||
: QGraphicsObject()
|
: QGraphicsObject()
|
||||||
@@ -75,4 +75,4 @@ QList<QGraphicsItem*> LayerItem::findAllChildItems(const QGraphicsItem *item) co
|
|||||||
return itemList;
|
return itemList;
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|||||||
@@ -33,7 +33,7 @@
|
|||||||
#include <QGraphicsObject>
|
#include <QGraphicsObject>
|
||||||
#include <QWeakPointer>
|
#include <QWeakPointer>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class FormEditorScene;
|
class FormEditorScene;
|
||||||
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
|
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
QmlToolbar::QmlToolbar(QWidget *parent)
|
QmlToolbar::QmlToolbar(QWidget *parent)
|
||||||
: QToolBar(parent)
|
: QToolBar(parent)
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
#include <QIcon>
|
#include <QIcon>
|
||||||
#include "qmlobserverconstants.h"
|
#include "qmlobserverconstants.h"
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class ToolBarColorBox;
|
class ToolBarColorBox;
|
||||||
|
|
||||||
|
|||||||
@@ -32,7 +32,7 @@
|
|||||||
|
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
RubberBandSelectionManipulator::RubberBandSelectionManipulator(QGraphicsObject *layerItem, QDeclarativeViewObserver *editorView)
|
RubberBandSelectionManipulator::RubberBandSelectionManipulator(QGraphicsObject *layerItem, QDeclarativeViewObserver *editorView)
|
||||||
: m_selectionRectangleElement(layerItem),
|
: m_selectionRectangleElement(layerItem),
|
||||||
|
|||||||
@@ -33,7 +33,7 @@
|
|||||||
|
|
||||||
#include "selectionrectangle.h"
|
#include "selectionrectangle.h"
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class QDeclarativeViewObserver;
|
class QDeclarativeViewObserver;
|
||||||
|
|
||||||
|
|||||||
@@ -36,7 +36,7 @@
|
|||||||
#include <QGraphicsScene>
|
#include <QGraphicsScene>
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
SelectionIndicator::SelectionIndicator(QDeclarativeViewObserver *editorView, QGraphicsObject *layerItem)
|
SelectionIndicator::SelectionIndicator(QDeclarativeViewObserver *editorView, QGraphicsObject *layerItem)
|
||||||
: m_layerItem(layerItem), m_view(editorView)
|
: m_layerItem(layerItem), m_view(editorView)
|
||||||
@@ -123,5 +123,5 @@ void SelectionIndicator::setItems(const QList<QWeakPointer<QGraphicsObject> > &i
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
} //namespace QmlObserver
|
} //namespace QmlJSDebugger
|
||||||
|
|
||||||
|
|||||||
@@ -34,7 +34,7 @@
|
|||||||
#include <QGraphicsPolygonItem>
|
#include <QGraphicsPolygonItem>
|
||||||
#include <QGraphicsObject>
|
#include <QGraphicsObject>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class QDeclarativeViewObserver;
|
class QDeclarativeViewObserver;
|
||||||
|
|
||||||
|
|||||||
@@ -36,7 +36,7 @@
|
|||||||
#include <cmath>
|
#include <cmath>
|
||||||
#include <QGraphicsScene>
|
#include <QGraphicsScene>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class SelectionRectShape : public QGraphicsRectItem
|
class SelectionRectShape : public QGraphicsRectItem
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -34,7 +34,7 @@
|
|||||||
#include <QGraphicsRectItem>
|
#include <QGraphicsRectItem>
|
||||||
#include <QGraphicsObject>
|
#include <QGraphicsObject>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class SelectionRectangle
|
class SelectionRectangle
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -46,7 +46,7 @@
|
|||||||
|
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
SelectionTool::SelectionTool(QDeclarativeViewObserver *editorView)
|
SelectionTool::SelectionTool(QDeclarativeViewObserver *editorView)
|
||||||
: AbstractFormEditorTool(editorView),
|
: AbstractFormEditorTool(editorView),
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ QT_FORWARD_DECLARE_CLASS(QGraphicsItem);
|
|||||||
QT_FORWARD_DECLARE_CLASS(QMouseEvent);
|
QT_FORWARD_DECLARE_CLASS(QMouseEvent);
|
||||||
QT_FORWARD_DECLARE_CLASS(QKeyEvent);
|
QT_FORWARD_DECLARE_CLASS(QKeyEvent);
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class SelectionTool : public AbstractFormEditorTool
|
class SelectionTool : public AbstractFormEditorTool
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -32,7 +32,7 @@
|
|||||||
#include "qdeclarativeviewobserver_p.h"
|
#include "qdeclarativeviewobserver_p.h"
|
||||||
#include <QtDebug>
|
#include <QtDebug>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
SingleSelectionManipulator::SingleSelectionManipulator(QDeclarativeViewObserver *editorView)
|
SingleSelectionManipulator::SingleSelectionManipulator(QDeclarativeViewObserver *editorView)
|
||||||
: m_editorView(editorView),
|
: m_editorView(editorView),
|
||||||
|
|||||||
@@ -35,7 +35,7 @@
|
|||||||
|
|
||||||
QT_FORWARD_DECLARE_CLASS(QGraphicsItem);
|
QT_FORWARD_DECLARE_CLASS(QGraphicsItem);
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class QDeclarativeViewObserver;
|
class QDeclarativeViewObserver;
|
||||||
|
|
||||||
|
|||||||
@@ -12,7 +12,7 @@
|
|||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
const qreal MaxOpacity = 0.5f;
|
const qreal MaxOpacity = 0.5f;
|
||||||
|
|
||||||
@@ -317,4 +317,4 @@ int SubcomponentEditorTool::contextIndex() const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ QT_FORWARD_DECLARE_CLASS(QGraphicsObject)
|
|||||||
QT_FORWARD_DECLARE_CLASS(QPoint)
|
QT_FORWARD_DECLARE_CLASS(QPoint)
|
||||||
QT_FORWARD_DECLARE_CLASS(QTimer)
|
QT_FORWARD_DECLARE_CLASS(QTimer)
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class SubcomponentMaskLayerItem;
|
class SubcomponentMaskLayerItem;
|
||||||
|
|
||||||
@@ -78,6 +78,6 @@ private:
|
|||||||
QTimer *m_animTimer;
|
QTimer *m_animTimer;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif // SUBCOMPONENTEDITORTOOL_H
|
#endif // SUBCOMPONENTEDITORTOOL_H
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
#include "qdeclarativeviewobserver.h"
|
#include "qdeclarativeviewobserver.h"
|
||||||
#include <QPolygonF>
|
#include <QPolygonF>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
SubcomponentMaskLayerItem::SubcomponentMaskLayerItem(QDeclarativeViewObserver *observer, QGraphicsItem *parentItem) :
|
SubcomponentMaskLayerItem::SubcomponentMaskLayerItem(QDeclarativeViewObserver *observer, QGraphicsItem *parentItem) :
|
||||||
QGraphicsPolygonItem(parentItem),
|
QGraphicsPolygonItem(parentItem),
|
||||||
@@ -77,4 +77,4 @@ QGraphicsItem *SubcomponentMaskLayerItem::currentItem() const
|
|||||||
return m_currentItem;
|
return m_currentItem;
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
#include <QGraphicsPolygonItem>
|
#include <QGraphicsPolygonItem>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class QDeclarativeViewObserver;
|
class QDeclarativeViewObserver;
|
||||||
|
|
||||||
@@ -24,6 +24,6 @@ private:
|
|||||||
QRectF m_itemPolyRect;
|
QRectF m_itemPolyRect;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif // SUBCOMPONENTMASKLAYERITEM_H
|
#endif // SUBCOMPONENTMASKLAYERITEM_H
|
||||||
|
|||||||
@@ -14,7 +14,7 @@
|
|||||||
|
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
ToolBarColorBox::ToolBarColorBox(QWidget *parent) :
|
ToolBarColorBox::ToolBarColorBox(QWidget *parent) :
|
||||||
QLabel(parent)
|
QLabel(parent)
|
||||||
@@ -93,4 +93,4 @@ void ToolBarColorBox::copyColorToClipboard()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
QT_FORWARD_DECLARE_CLASS(QContextMenuEvent);
|
QT_FORWARD_DECLARE_CLASS(QContextMenuEvent);
|
||||||
QT_FORWARD_DECLARE_CLASS(QAction);
|
QT_FORWARD_DECLARE_CLASS(QAction);
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class ToolBarColorBox : public QLabel
|
class ToolBarColorBox : public QLabel
|
||||||
{
|
{
|
||||||
@@ -36,6 +36,6 @@ private:
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif // ToolBarColorBox_H
|
#endif // ToolBarColorBox_H
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
|
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
ZoomTool::ZoomTool(QDeclarativeViewObserver *view) :
|
ZoomTool::ZoomTool(QDeclarativeViewObserver *view) :
|
||||||
AbstractFormEditorTool(view),
|
AbstractFormEditorTool(view),
|
||||||
@@ -284,4 +284,4 @@ qreal ZoomTool::nextZoomScale(ZoomDirection direction) const
|
|||||||
return 1.0f;
|
return 1.0f;
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
QT_FORWARD_DECLARE_CLASS(QAction);
|
QT_FORWARD_DECLARE_CLASS(QAction);
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class ZoomTool : public AbstractFormEditorTool
|
class ZoomTool : public AbstractFormEditorTool
|
||||||
{
|
{
|
||||||
@@ -60,6 +60,6 @@ private:
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif // ZOOMTOOL_H
|
#endif // ZOOMTOOL_H
|
||||||
|
|||||||
@@ -64,7 +64,7 @@
|
|||||||
|
|
||||||
QT_FORWARD_DECLARE_CLASS(QScriptContext);
|
QT_FORWARD_DECLARE_CLASS(QScriptContext);
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class JSAgentWatchData;
|
class JSAgentWatchData;
|
||||||
|
|
||||||
@@ -137,6 +137,6 @@ private:
|
|||||||
Q_DISABLE_COPY(JSDebuggerAgent)
|
Q_DISABLE_COPY(JSDebuggerAgent)
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ QT_FORWARD_DECLARE_CLASS(QDeclarativeContext)
|
|||||||
QT_FORWARD_DECLARE_CLASS(QDeclarativeWatcher)
|
QT_FORWARD_DECLARE_CLASS(QDeclarativeWatcher)
|
||||||
QT_FORWARD_DECLARE_CLASS(QDataStream)
|
QT_FORWARD_DECLARE_CLASS(QDataStream)
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class QMLJSDEBUGGER_EXPORT QDeclarativeObserverService : public QDeclarativeDebugService
|
class QMLJSDEBUGGER_EXPORT QDeclarativeObserverService : public QDeclarativeDebugService
|
||||||
{
|
{
|
||||||
@@ -66,7 +66,7 @@ public:
|
|||||||
void setDesignModeBehavior(bool inDesignMode);
|
void setDesignModeBehavior(bool inDesignMode);
|
||||||
void setCurrentObjects(QList<QObject*> items);
|
void setCurrentObjects(QList<QObject*> items);
|
||||||
void setAnimationSpeed(qreal slowdownFactor);
|
void setAnimationSpeed(qreal slowdownFactor);
|
||||||
void setCurrentTool(QmlObserver::Constants::DesignTool toolId);
|
void setCurrentTool(QmlJSDebugger::Constants::DesignTool toolId);
|
||||||
void reloaded();
|
void reloaded();
|
||||||
QString idStringForObject(QObject *obj) const;
|
QString idStringForObject(QObject *obj) const;
|
||||||
|
|
||||||
@@ -105,6 +105,6 @@ private:
|
|||||||
QHash<int, QString> m_stringIdForObjectId;
|
QHash<int, QString> m_stringIdForObjectId;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif // QDECLARATIVEDESIGNDEBUGSERVER_H
|
#endif // QDECLARATIVEDESIGNDEBUGSERVER_H
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ QT_FORWARD_DECLARE_CLASS(QDeclarativeItem);
|
|||||||
QT_FORWARD_DECLARE_CLASS(QMouseEvent);
|
QT_FORWARD_DECLARE_CLASS(QMouseEvent);
|
||||||
QT_FORWARD_DECLARE_CLASS(QToolBar);
|
QT_FORWARD_DECLARE_CLASS(QToolBar);
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class CrumblePath;
|
class CrumblePath;
|
||||||
class QDeclarativeViewObserverPrivate;
|
class QDeclarativeViewObserverPrivate;
|
||||||
@@ -124,6 +124,6 @@ private:
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
} //namespace QmlObserver
|
} //namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif // QDECLARATIVEVIEWOBSERVER_H
|
#endif // QDECLARATIVEVIEWOBSERVER_H
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#ifndef QMLOBSERVERCONSTANTS_H
|
#ifndef QMLOBSERVERCONSTANTS_H
|
||||||
#define QMLOBSERVERCONSTANTS_H
|
#define QMLOBSERVERCONSTANTS_H
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
namespace Constants {
|
namespace Constants {
|
||||||
|
|
||||||
enum DesignTool {
|
enum DesignTool {
|
||||||
@@ -34,6 +34,6 @@ enum GraphicsItemTypes {
|
|||||||
|
|
||||||
|
|
||||||
} // namespace Constants
|
} // namespace Constants
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif // QMLOBSERVERCONSTANTS_H
|
#endif // QMLOBSERVERCONSTANTS_H
|
||||||
|
|||||||
@@ -50,7 +50,7 @@
|
|||||||
#include <QtCore/QDateTime>
|
#include <QtCore/QDateTime>
|
||||||
#include <QtScript/qscriptvalueiterator.h>
|
#include <QtScript/qscriptvalueiterator.h>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class JSDebuggerAgent::SetupExecEnv {
|
class JSDebuggerAgent::SetupExecEnv {
|
||||||
JSDebuggerAgent* agent;
|
JSDebuggerAgent* agent;
|
||||||
@@ -510,4 +510,4 @@ void JSDebuggerAgent::enabledChanged(bool on)
|
|||||||
QDeclarativeDebugService::enabledChanged(on);
|
QDeclarativeDebugService::enabledChanged(on);
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|||||||
@@ -46,7 +46,7 @@
|
|||||||
|
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
Q_GLOBAL_STATIC(QDeclarativeObserverService, serviceInstance)
|
Q_GLOBAL_STATIC(QDeclarativeObserverService, serviceInstance)
|
||||||
|
|
||||||
@@ -174,7 +174,7 @@ void QDeclarativeObserverService::setCurrentObjects(QList<QObject*> objects)
|
|||||||
sendMessage(message);
|
sendMessage(message);
|
||||||
}
|
}
|
||||||
|
|
||||||
void QDeclarativeObserverService::setCurrentTool(QmlObserver::Constants::DesignTool toolId)
|
void QDeclarativeObserverService::setCurrentTool(QmlJSDebugger::Constants::DesignTool toolId)
|
||||||
{
|
{
|
||||||
QByteArray message;
|
QByteArray message;
|
||||||
QDataStream ds(&message, QIODevice::WriteOnly);
|
QDataStream ds(&message, QIODevice::WriteOnly);
|
||||||
@@ -236,4 +236,4 @@ QString QDeclarativeObserverService::idStringForObject(QObject *obj) const
|
|||||||
return idString;
|
return idString;
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|||||||
@@ -52,7 +52,7 @@
|
|||||||
#include <private/qdeclarativeengine_p.h>
|
#include <private/qdeclarativeengine_p.h>
|
||||||
#include <private/qabstractanimation_p.h>
|
#include <private/qabstractanimation_p.h>
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
const int SceneChangeUpdateInterval = 5000;
|
const int SceneChangeUpdateInterval = 5000;
|
||||||
|
|
||||||
@@ -799,6 +799,6 @@ void QDeclarativeViewObserver::setDebugMode(bool isDebugMode)
|
|||||||
data->jsDebuggerAgent = new JSDebuggerAgent(QDeclarativeEnginePrivate::getScriptEngine(data->view->engine()));
|
data->jsDebuggerAgent = new JSDebuggerAgent(QDeclarativeEnginePrivate::getScriptEngine(data->view->engine()));
|
||||||
}
|
}
|
||||||
|
|
||||||
} //namespace QmlObserver
|
} //namespace QmlJSDebugger
|
||||||
|
|
||||||
#include <moc_qdeclarativeviewobserver.cpp>
|
#include <moc_qdeclarativeviewobserver.cpp>
|
||||||
|
|||||||
@@ -37,7 +37,7 @@
|
|||||||
#include "qdeclarativeviewobserver.h"
|
#include "qdeclarativeviewobserver.h"
|
||||||
#include "qdeclarativeobserverservice.h"
|
#include "qdeclarativeobserverservice.h"
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
|
|
||||||
class JSDebuggerAgent;
|
class JSDebuggerAgent;
|
||||||
class QDeclarativeViewObserver;
|
class QDeclarativeViewObserver;
|
||||||
@@ -136,6 +136,6 @@ public:
|
|||||||
static QDeclarativeViewObserverPrivate *get(QDeclarativeViewObserver *v) { return v->d_func(); }
|
static QDeclarativeViewObserverPrivate *get(QDeclarativeViewObserver *v) { return v->d_func(); }
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace QmlObserver
|
} // namespace QmlJSDebugger
|
||||||
|
|
||||||
#endif // QDECLARATIVEDESIGNVIEW_P_H
|
#endif // QDECLARATIVEDESIGNVIEW_P_H
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ QmlApplicationViewer::QmlApplicationViewer(QWidget *parent) :
|
|||||||
connect(engine(), SIGNAL(quit()), SLOT(close()));
|
connect(engine(), SIGNAL(quit()), SLOT(close()));
|
||||||
setResizeMode(QDeclarativeView::SizeRootObjectToView);
|
setResizeMode(QDeclarativeView::SizeRootObjectToView);
|
||||||
#ifdef QMLOBSERVER
|
#ifdef QMLOBSERVER
|
||||||
new QmlObserver::QDeclarativeViewObserver(this, parent);
|
new QmlJSDebugger::QDeclarativeViewObserver(this, parent);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -614,7 +614,7 @@ QDeclarativeViewer::QDeclarativeViewer(QWidget *parent, Qt::WindowFlags flags)
|
|||||||
}
|
}
|
||||||
|
|
||||||
canvas = new QDeclarativeView(this);
|
canvas = new QDeclarativeView(this);
|
||||||
observer = new QmlObserver::QDeclarativeViewObserver(canvas, this);
|
observer = new QmlJSDebugger::QDeclarativeViewObserver(canvas, this);
|
||||||
if (!(flags & Qt::FramelessWindowHint)) {
|
if (!(flags & Qt::FramelessWindowHint)) {
|
||||||
m_crumblePathWidget = new Utils::CrumblePath(canvas);
|
m_crumblePathWidget = new Utils::CrumblePath(canvas);
|
||||||
#ifndef Q_WS_MAC
|
#ifndef Q_WS_MAC
|
||||||
@@ -794,10 +794,10 @@ void QDeclarativeViewer::createMenu()
|
|||||||
designModeBehaviorAction->setShortcut(QKeySequence("Ctrl+D"));
|
designModeBehaviorAction->setShortcut(QKeySequence("Ctrl+D"));
|
||||||
designModeBehaviorAction->setCheckable(true);
|
designModeBehaviorAction->setCheckable(true);
|
||||||
designModeBehaviorAction->setChecked(observer->designModeBehavior());
|
designModeBehaviorAction->setChecked(observer->designModeBehavior());
|
||||||
designModeBehaviorAction->setEnabled(QmlObserver::QDeclarativeObserverService::hasDebuggingClient());
|
designModeBehaviorAction->setEnabled(QmlJSDebugger::QDeclarativeObserverService::hasDebuggingClient());
|
||||||
connect(designModeBehaviorAction, SIGNAL(triggered(bool)), this, SLOT(setDesignModeBehavior(bool)));
|
connect(designModeBehaviorAction, SIGNAL(triggered(bool)), this, SLOT(setDesignModeBehavior(bool)));
|
||||||
connect(observer, SIGNAL(designModeBehaviorChanged(bool)), designModeBehaviorAction, SLOT(setChecked(bool)));
|
connect(observer, SIGNAL(designModeBehaviorChanged(bool)), designModeBehaviorAction, SLOT(setChecked(bool)));
|
||||||
connect(QmlObserver::QDeclarativeObserverService::instance(), SIGNAL(debuggingClientChanged(bool)), designModeBehaviorAction, SLOT(setEnabled(bool)));
|
connect(QmlJSDebugger::QDeclarativeObserverService::instance(), SIGNAL(debuggingClientChanged(bool)), designModeBehaviorAction, SLOT(setEnabled(bool)));
|
||||||
|
|
||||||
QAction *proxyAction = new QAction(tr("HTTP &Proxy..."), this);
|
QAction *proxyAction = new QAction(tr("HTTP &Proxy..."), this);
|
||||||
connect(proxyAction, SIGNAL(triggered()), this, SLOT(showProxySettings()));
|
connect(proxyAction, SIGNAL(triggered()), this, SLOT(showProxySettings()));
|
||||||
|
|||||||
@@ -49,7 +49,7 @@
|
|||||||
|
|
||||||
#include "loggerwidget.h"
|
#include "loggerwidget.h"
|
||||||
|
|
||||||
namespace QmlObserver {
|
namespace QmlJSDebugger {
|
||||||
class QDeclarativeViewObserver;
|
class QDeclarativeViewObserver;
|
||||||
}
|
}
|
||||||
namespace Utils {
|
namespace Utils {
|
||||||
@@ -168,7 +168,7 @@ private:
|
|||||||
LoggerWidget *loggerWindow;
|
LoggerWidget *loggerWindow;
|
||||||
|
|
||||||
QDeclarativeView *canvas;
|
QDeclarativeView *canvas;
|
||||||
QmlObserver::QDeclarativeViewObserver *observer;
|
QmlJSDebugger::QDeclarativeViewObserver *observer;
|
||||||
QSize initialSize;
|
QSize initialSize;
|
||||||
QString currentFileOrUrl;
|
QString currentFileOrUrl;
|
||||||
QTimer recordTimer;
|
QTimer recordTimer;
|
||||||
|
|||||||
Reference in New Issue
Block a user