Profile export now goes via the plugin system, and does the same filename checks as before.

Contributed to CURA-1667 Profile import/export
This commit is contained in:
Simon Edwards 2016-06-08 14:40:10 +02:00
parent d57e2b2e22
commit c03588c6e5
6 changed files with 9 additions and 6 deletions

View file

@ -294,6 +294,7 @@ class CuraApplication(QtApplication):
# \sa PluginRegistery
def _loadPlugins(self):
self._plugin_registry.addType("profile_reader", self._addProfileReader)
self._plugin_registry.addType("profile_writer", self._addProfileWriter)
self._plugin_registry.addPluginLocation(os.path.join(QtApplication.getInstallPrefix(), "lib", "cura"))
if not hasattr(sys, "frozen"):
self._plugin_registry.addPluginLocation(os.path.join(os.path.abspath(os.path.dirname(__file__)), "..", "plugins"))
@ -788,3 +789,6 @@ class CuraApplication(QtApplication):
def _addProfileReader(self, profile_reader):
# TODO: Add the profile reader to the list of plug-ins that can be used when importing profiles.
pass
def _addProfileWriter(self, profile_writer):
pass