QmlJSDebuggerLib: Place all classes in QmlObserver namespace

This commit is contained in:
Kai Koehne
2010-09-16 16:39:09 +02:00
parent c9395b45a2
commit 78b175c523
6 changed files with 22 additions and 18 deletions
@@ -62,13 +62,15 @@
#include "qmljsdebugger_global.h"
QT_BEGIN_NAMESPACE
QT_FORWARD_DECLARE_CLASS(QScriptContext);
namespace QmlObserver {
class JSAgentWatchData;
class QScriptContext;
class QMLJSDEBUGGER_EXPORT JSDebuggerAgent : public QDeclarativeDebugService , public QScriptEngineAgent
{ Q_OBJECT
{
Q_OBJECT
public:
JSDebuggerAgent(QScriptEngine *engine);
~JSDebuggerAgent();
@@ -135,6 +137,6 @@ private:
Q_DISABLE_COPY(JSDebuggerAgent)
};
QT_END_NAMESPACE
} // namespace QmlObserver
#endif
@@ -48,13 +48,13 @@
#include <QHash>
QT_BEGIN_NAMESPACE
QT_FORWARD_DECLARE_CLASS(QColor)
QT_FORWARD_DECLARE_CLASS(QDeclarativeEngine)
QT_FORWARD_DECLARE_CLASS(QDeclarativeContext)
QT_FORWARD_DECLARE_CLASS(QDeclarativeWatcher)
QT_FORWARD_DECLARE_CLASS(QDataStream)
class QColor;
class QDeclarativeEngine;
class QDeclarativeContext;
class QDeclarativeWatcher;
class QDataStream;
namespace QmlObserver {
class QMLJSDEBUGGER_EXPORT QDeclarativeObserverService : public QDeclarativeDebugService
{
@@ -105,6 +105,6 @@ private:
QHash<int, QString> m_stringIdForObjectId;
};
QT_END_NAMESPACE
} // namespace QmlObserver
#endif // QDECLARATIVEDESIGNDEBUGSERVER_H
@@ -50,7 +50,7 @@
#include <QtCore/QDateTime>
#include <QtScript/qscriptvalueiterator.h>
QT_BEGIN_NAMESPACE
namespace QmlObserver {
class JSDebuggerAgent::SetupExecEnv {
JSDebuggerAgent* agent;
@@ -510,4 +510,4 @@ void JSDebuggerAgent::enabledChanged(bool on)
QDeclarativeDebugService::enabledChanged(on);
}
QT_END_NAMESPACE
} // namespace QmlObserver
@@ -46,6 +46,8 @@
#include <QDebug>
namespace QmlObserver {
Q_GLOBAL_STATIC(QDeclarativeObserverService, serviceInstance)
QDeclarativeObserverService::QDeclarativeObserverService()
@@ -233,3 +235,5 @@ QString QDeclarativeObserverService::idStringForObject(QObject *obj) const
QString idString = m_stringIdForObjectId.value(id, QString());
return idString;
}
} // namespace QmlObserver
@@ -37,10 +37,9 @@
#include "qdeclarativeviewobserver.h"
#include "qdeclarativeobserverservice.h"
QT_FORWARD_DECLARE_CLASS(JSDebuggerAgent)
namespace QmlObserver {
class JSDebuggerAgent;
class QDeclarativeViewObserver;
class SelectionTool;
class ZoomTool;
@@ -54,7 +53,6 @@ class AbstractFormEditorTool;
class QDeclarativeViewObserverPrivate
{
public:
enum ContextFlags {
+2 -2
View File
@@ -794,10 +794,10 @@ void QDeclarativeViewer::createMenu()
designModeBehaviorAction->setShortcut(QKeySequence("Ctrl+D"));
designModeBehaviorAction->setCheckable(true);
designModeBehaviorAction->setChecked(observer->designModeBehavior());
designModeBehaviorAction->setEnabled(QDeclarativeObserverService::hasDebuggingClient());
designModeBehaviorAction->setEnabled(QmlObserver::QDeclarativeObserverService::hasDebuggingClient());
connect(designModeBehaviorAction, SIGNAL(triggered(bool)), this, SLOT(setDesignModeBehavior(bool)));
connect(observer, SIGNAL(designModeBehaviorChanged(bool)), designModeBehaviorAction, SLOT(setChecked(bool)));
connect(QDeclarativeObserverService::instance(), SIGNAL(debuggingClientChanged(bool)), designModeBehaviorAction, SLOT(setEnabled(bool)));
connect(QmlObserver::QDeclarativeObserverService::instance(), SIGNAL(debuggingClientChanged(bool)), designModeBehaviorAction, SLOT(setEnabled(bool)));
QAction *proxyAction = new QAction(tr("HTTP &Proxy..."), this);
connect(proxyAction, SIGNAL(triggered()), this, SLOT(showProxySettings()));