diff options
Diffstat (limited to 'src/exceptions.cc')
| -rw-r--r-- | src/exceptions.cc | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/src/exceptions.cc b/src/exceptions.cc index 48da4fcd..28846e16 100644 --- a/src/exceptions.cc +++ b/src/exceptions.cc @@ -47,4 +47,24 @@ TimeFormatError::TimeFormatError (string bad_time) } - +MissingAssetError::MissingAssetError (boost::filesystem::path path, AssetType type) + : _path (path) + , _type (type) +{ + string type_name; + switch (_type) { + case MAIN_PICTURE: + type_name = " for main picture"; + break; + case MAIN_SOUND: + type_name = " for main sound"; + break; + case MAIN_SUBTITLE: + type_name = " for main subtitle"; + break; + case UNKNOWN: + break; + } + + _message = String::compose ("Missing asset %1%2", path.string(), type_name); +} |
