forked from qt-creator/qt-creator
Plugins: Fix that mimetype definition was not valid JSON
JSON officially does not support multiline strings, so we should use the same mechanism that we already use for the plugin description (i.e. additionally support arrays of strings which are interpreted as lines). This just happens to work because Qt's JSON parser eats it without choking. Change-Id: I25ef04600b209775c5a7af916c687fda4a8b1a4d Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -18,45 +18,45 @@
|
||||
\"Url\" : \"http://www.qt.io\",
|
||||
$$dependencyList,
|
||||
|
||||
\"Mimetypes\" : \"
|
||||
<?xml version=\'1.0\'?>
|
||||
<mime-info xmlns=\'http://www.freedesktop.org/standards/shared-mime-info\'>
|
||||
<mime-type type=\'text/x-qml\'>
|
||||
<alias type=\'application/x-qml\'/>
|
||||
<!-- sub class is missing in the freedesktop.org definition -->
|
||||
<sub-class-of type=\'text/plain\'/>
|
||||
<comment>QML file</comment>
|
||||
<glob pattern=\'*.qml\' weight=\'70\'/>
|
||||
</mime-type>
|
||||
<mime-type type=\'application/x-qt.qbs+qml\'>
|
||||
<alias type=\'text/x-qt.qbs+qml\'/>
|
||||
<sub-class-of type=\'text/x-qml\'/>
|
||||
<comment>Qt Build Suite file</comment>
|
||||
<glob pattern=\'*.qbs\' weight=\'70\'/>
|
||||
</mime-type>
|
||||
<mime-type type=\'application/x-qt.ui+qml\'>
|
||||
<alias type=\'text/x-qt.ui+qml\'/>
|
||||
<sub-class-of type=\'text/x-qml\'/>
|
||||
<comment>QtQuick Designer ui file</comment>
|
||||
<glob pattern=\'*.ui.qml\' weight=\'70\'/>
|
||||
</mime-type>
|
||||
<mime-type type=\'application/x-qmlproject\'>
|
||||
<alias type=\'text/x-qmlproject\'/>
|
||||
<sub-class-of type=\'text/x-qml\'/>
|
||||
<comment>Qt Creator Qt UI project file</comment>
|
||||
<glob pattern=\'*.qmlproject\' weight=\'70\'/>
|
||||
</mime-type>
|
||||
<mime-type type=\'application/x-qt.meta-info+qml\'>
|
||||
<alias type=\'text/x-qt.meta-info+qml\'/>
|
||||
<sub-class-of type=\'text/x-qml\'/>
|
||||
<comment>QML file</comment>
|
||||
<glob pattern=\'*.qmltypes\' weight=\'70\'/>
|
||||
</mime-type>
|
||||
<mime-type type=\'application/json\'>
|
||||
<sub-class-of type=\'text/plain\'/>
|
||||
<comment>JSON file</comment>
|
||||
<glob pattern=\'*.json\' weight=\'70\'/>
|
||||
</mime-type>
|
||||
</mime-info>
|
||||
\"
|
||||
\"Mimetypes\" : [
|
||||
\"<?xml version=\'1.0\'?>\",
|
||||
\"<mime-info xmlns=\'http://www.freedesktop.org/standards/shared-mime-info\'>\",
|
||||
\" <mime-type type=\'text/x-qml\'>\",
|
||||
\" <alias type=\'application/x-qml\'/>\",
|
||||
\" <!-- sub class is missing in the freedesktop.org definition -->\",
|
||||
\" <sub-class-of type=\'text/plain\'/>\",
|
||||
\" <comment>QML file</comment>\",
|
||||
\" <glob pattern=\'*.qml\' weight=\'70\'/>\",
|
||||
\" </mime-type>\",
|
||||
\" <mime-type type=\'application/x-qt.qbs+qml\'>\",
|
||||
\" <alias type=\'text/x-qt.qbs+qml\'/>\",
|
||||
\" <sub-class-of type=\'text/x-qml\'/>\",
|
||||
\" <comment>Qt Build Suite file</comment>\",
|
||||
\" <glob pattern=\'*.qbs\' weight=\'70\'/>\",
|
||||
\" </mime-type>\",
|
||||
\" <mime-type type=\'application/x-qt.ui+qml\'>\",
|
||||
\" <alias type=\'text/x-qt.ui+qml\'/>\",
|
||||
\" <sub-class-of type=\'text/x-qml\'/>\",
|
||||
\" <comment>QtQuick Designer ui file</comment>\",
|
||||
\" <glob pattern=\'*.ui.qml\' weight=\'70\'/>\",
|
||||
\" </mime-type>\",
|
||||
\" <mime-type type=\'application/x-qmlproject\'>\",
|
||||
\" <alias type=\'text/x-qmlproject\'/>\",
|
||||
\" <sub-class-of type=\'text/x-qml\'/>\",
|
||||
\" <comment>Qt Creator Qt UI project file</comment>\",
|
||||
\" <glob pattern=\'*.qmlproject\' weight=\'70\'/>\",
|
||||
\" </mime-type>\",
|
||||
\" <mime-type type=\'application/x-qt.meta-info+qml\'>\",
|
||||
\" <alias type=\'text/x-qt.meta-info+qml\'/>\",
|
||||
\" <sub-class-of type=\'text/x-qml\'/>\",
|
||||
\" <comment>QML file</comment>\",
|
||||
\" <glob pattern=\'*.qmltypes\' weight=\'70\'/>\",
|
||||
\" </mime-type>\",
|
||||
\" <mime-type type=\'application/json\'>\",
|
||||
\" <sub-class-of type=\'text/plain\'/>\",
|
||||
\" <comment>JSON file</comment>\",
|
||||
\" <glob pattern=\'*.json\' weight=\'70\'/>\",
|
||||
\" </mime-type>\",
|
||||
\"</mime-info>\"
|
||||
]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user