Don't repeat the plug-in name

If it changes, this will crash Cura.
This commit is contained in:
Ghostkeeper 2019-01-24 17:31:08 +01:00
parent aac82a0852
commit d535008e08
No known key found for this signature in database
GPG key ID: 86BEF881AE2CF276

View file

@ -68,7 +68,7 @@ class DrivePluginExtension(QObject, Extension):
def showDriveWindow(self) -> None: def showDriveWindow(self) -> None:
if not self._drive_window: if not self._drive_window:
plugin_dir_path = CuraApplication.getInstance().getPluginRegistry().getPluginPath("CuraDrive") plugin_dir_path = CuraApplication.getInstance().getPluginRegistry().getPluginPath(self.getPluginId())
path = os.path.join(plugin_dir_path, "src", "qml", "main.qml") path = os.path.join(plugin_dir_path, "src", "qml", "main.qml")
self._drive_window = CuraApplication.getInstance().createQmlComponent(path, {"CuraDrive": self}) self._drive_window = CuraApplication.getInstance().createQmlComponent(path, {"CuraDrive": self})
self.refreshBackups() self.refreshBackups()