diff options
author | Eike Ziller <eike.ziller@qt.io> | 2018-09-27 15:00:08 +0200 |
---|---|---|
committer | Eike Ziller <eike.ziller@qt.io> | 2018-09-28 07:31:36 +0000 |
commit | 3412dc563119221bd730c1487937519df0761792 (patch) | |
tree | d738ea0a24c1013e589e69240d6fc91ae13ed999 /plugins/pythonextensions/pythonextensionsplugin.cpp | |
parent | 3c4cafdf834c9b683501efca72dbbe1093cf6f9a (diff) |
Clean up import hierarchy
PythonExtension.QtCreator.*
-> QtCreator.*
PythonExtension.PluginInstance
-> QtCreator.PythonExtensions
Also enables imports of the form "from QtCreator import Core" it is no
longer necessary to write QtCreator.Core....
Change-Id: Ib9b433868dcc3fc7d1d534c6023bae7bf6d05fec
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Diffstat (limited to 'plugins/pythonextensions/pythonextensionsplugin.cpp')
-rw-r--r-- | plugins/pythonextensions/pythonextensionsplugin.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/pythonextensions/pythonextensionsplugin.cpp b/plugins/pythonextensions/pythonextensionsplugin.cpp index 893819c..59b32a1 100644 --- a/plugins/pythonextensions/pythonextensionsplugin.cpp +++ b/plugins/pythonextensions/pythonextensionsplugin.cpp @@ -188,13 +188,13 @@ void PythonExtensionsPlugin::initializePythonBindings() QDir().mkpath(pythonPackagePath()); PyUtil::addToSysPath(pythonPackagePath().toStdString()); // Initialize the Python context and register global Qt Creator variable - if (!PyUtil::bindShibokenModuleObject("PythonExtension", "QtCreator")) { + if (!PyUtil::bindCoreModules()) { qWarning() << "Python bindings could not be initialized"; Core::MessageManager::write(Constants::MESSAGE_MANAGER_PREFIX + tr("Python bindings could not be initialized")); return; } // Bind the plugin instance - PyUtil::bindObject("PythonExtension", "PluginInstance", PyUtil::PythonExtensionsPluginType, this); + PyUtil::bindObject("QtCreator", "PythonExtensions", PyUtil::PythonExtensionsPluginType, this); } void PythonExtensionsPlugin::initializeOptionalBindings() |