Commit aea49188 authored by Jan Möbius's avatar Jan Möbius

Fixed bug in saveObject function(scripting part), where supported type was not correctly detected

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@9118 383ad7c9-94d9-4d36-a494-682f7c89f535
parent a5b70862
......@@ -60,8 +60,8 @@ bool Core::saveObject( int _id, QString _filename ) {
BaseObjectData* object;
PluginFunctions::getObject(_id,object);
for (int i=0; i < (int)supportedTypes_.size(); i++)
if (object->dataType() == supportedTypes_[i].type) {
for (int i=0; i < (int)supportedTypes_.size(); i++) {
if ( supportedTypes_[i].type.contains(object->dataType())) {
if ( OpenFlipper::Options::gui() ) {
coreWidget_->statusMessage( tr("Saving ") + _filename + " ...");
......@@ -91,7 +91,8 @@ bool Core::saveObject( int _id, QString _filename ) {
return ok;
}
}
// no plugin found
if ( OpenFlipper::Options::gui() ){
emit log(LOGERR, tr("Unable to save '%1'. No plugin found. DataType %2").arg(_filename, dataTypeName(object->dataType()) ) );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment