ResourceItem: added TypePluginSpecificPreset

Added another type TypePluginSpecificPreset in Types enumeration. This
allows handling for example XIZ files (ZynAddSubFX presets) properly.
This commit is contained in:
Tobias Doerffel
2009-06-07 16:28:54 +02:00
parent 46bd9f51cf
commit 6fabe26620
4 changed files with 5 additions and 0 deletions

View File

@@ -54,6 +54,7 @@ public:
TypeSample,
TypeSoundFont,
TypePreset,
TypePluginSpecificPreset,
TypeProject,
TypeMidiFile,
TypeForeignProject,

View File

@@ -157,6 +157,8 @@ ResourceItem::Type ResourceItem::guessType( void ) const
typeMap["xpf"] = TypePreset;
typeMap["cs.xml"] = TypePreset;
typeMap["xiz"] = TypePluginSpecificPreset;
typeMap["mmp"] = TypeProject;
typeMap["mmpz"] = TypeProject;

View File

@@ -84,6 +84,7 @@ case ResourceItem::TypeDirectory:
case ResourceItem::TypeSample:
return embed::getIconPixmap( "mimetypes/sample", 24, 24 );
case ResourceItem::TypePreset:
case ResourceItem::TypePluginSpecificPreset:
return embed::getIconPixmap( "mimetypes/preset", 24, 24 );
case ResourceItem::TypeProject:
return embed::getIconPixmap( "project_file", 24, 24 );

View File

@@ -159,6 +159,7 @@ void ResourceBrowser::showContextMenu( const QPoint & _pos )
case ResourceItem::TypeSample:
case ResourceItem::TypeSoundFont:
case ResourceItem::TypePreset:
case ResourceItem::TypePluginSpecificPreset:
case ResourceItem::TypePlugin:
m.addAction( m_actions[LoadInNewTrackSongEditor] );
m.addAction( m_actions[LoadInNewTrackBBEditor] );