diff options
| author | Jesper K. Pedersen <jesper.pedersen@kdab.com> | 2013-04-17 12:09:57 +0200 |
|---|---|---|
| committer | Jesper K. Pedersen <jesper.pedersen@kdab.com> | 2013-04-17 20:50:24 +0200 |
| commit | 487770e422e4c55e128c210bb82b30ed99f3f401 (patch) | |
| tree | 2827f7ec704ea06cc4de858eaf56f4ce68a8b35c /scriptrunner.cpp | |
| parent | e793225595a8010d35506011ac2a915df8e21119 (diff) | |
Introduced the class TextEditor
This is to make it similar in heirarchy as the IEditor subclasses.
This commit also wraps QPoint and QRect so they are usable from the scripts
Change-Id: I214a7323cf6cc20cb9df509d0ea0515358248714
Reviewed-by: Nicolas Arnaud-Cormos <nicolas@kdab.com>
Diffstat (limited to 'scriptrunner.cpp')
| -rw-r--r-- | scriptrunner.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/scriptrunner.cpp b/scriptrunner.cpp index b982180..a02aaaf 100644 --- a/scriptrunner.cpp +++ b/scriptrunner.cpp @@ -41,6 +41,8 @@ #include <coreplugin/editormanager/ieditor.h> #include <wrap_helpers.h> +#include "scriptwrappers.h" +#include "enumwappers.h" using namespace Scripting; using namespace Scripting::Internal; @@ -75,6 +77,7 @@ bool ScriptRunner::runScript(const QString &sourceCode, const QString fileName) return !failed; } + ScriptRunner::QScriptEnginePtr ScriptRunner::ensureEngineInitialized() { if (!m_engine.isNull()) @@ -89,7 +92,8 @@ ScriptRunner::QScriptEnginePtr ScriptRunner::ensureEngineInitialized() registerGlobal(new Console, QLatin1String("console")); registerGlobal(new Editors, QLatin1String("editors")); - + registerWrappers(m_engine.data()); + registerEnums(m_engine.data()); return m_engine; } |
