Browse Source

Allowing profile readers to read multiple file types per plugin

Both of these plugins only read one file type, but it's allowed now.

Contributes to issue CURA-34.
Ghostkeeper 9 years ago
parent
commit
984a8efe1e
2 changed files with 12 additions and 8 deletions
  1. 6 4
      plugins/CuraProfileReader/__init__.py
  2. 6 4
      plugins/GCodeProfileReader/__init__.py

+ 6 - 4
plugins/CuraProfileReader/__init__.py

@@ -15,10 +15,12 @@ def getMetaData():
             "description": catalog.i18nc("@info:whatsthis", "Provides support for importing Cura profiles."),
             "api": 2
         },
-        "profile_reader": {
-            "extension": "curaprofile",
-            "description": catalog.i18nc("@item:inlistbox", "Cura Profile")
-        }
+        "profile_reader": [
+            {
+                "extension": "curaprofile",
+                "description": catalog.i18nc("@item:inlistbox", "Cura Profile")
+            }
+         ]
     }
 
 def register(app):

+ 6 - 4
plugins/GCodeProfileReader/__init__.py

@@ -15,10 +15,12 @@ def getMetaData():
             "description": catalog.i18nc("@info:whatsthis", "Provides support for importing profiles from g-code files."),
             "api": 2
         },
-        "profile_reader": {
-            "extension": "gcode",
-            "description": catalog.i18nc("@item:inlistbox", "G-code File")
-        }
+        "profile_reader": [
+            {
+                "extension": "gcode",
+                "description": catalog.i18nc("@item:inlistbox", "G-code File")
+            }
+        ]
     }
 
 def register(app):