mirror of
https://github.com/WerWolv/ImHex.git
synced 2026-04-01 21:17:44 -05:00
impr: Show an error message when ImHex can't open a file (#1050)
This PR does two correlated things: - Show a generic error message (Failed to open provider) rather than a file-specific message (Failed to open file) when a provider fails to open - Set the error to something more specific when opening a file fails
This commit is contained in:
@@ -180,7 +180,7 @@ namespace hex::plugin::builtin {
|
||||
provider->loadSettings(recentProvider.data);
|
||||
|
||||
if (!provider->open() || !provider->isAvailable()) {
|
||||
PopupError::open("hex.builtin.popup.error.open"_lang);
|
||||
PopupError::open(hex::format("hex.builtin.provider.error.open"_lang, provider->getErrorMessage()));
|
||||
TaskManager::doLater([provider] { ImHexApi::Provider::remove(provider); });
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user