Add strings alerts in recent files/folders to en.ini

This commit is contained in:
David Capello 2018-03-14 12:33:15 -03:00
parent 0426582e0e
commit 8e6bd1a8dc
2 changed files with 5 additions and 2 deletions

View File

@ -111,6 +111,8 @@ Update Extension
END
update_extension_downgrade = downgrade
update_extension_upgrade = upgrade
recent_file_doesnt_exist = Aseprite<<The selected file doesn't exist||&OK
recent_folder_doesnt_exist = Aseprite<<The selected folder doesn't exist||&OK
restart_by_preferences = <<<END
Aseprite
<<You must restart the program to see your changes to:{0}

View File

@ -13,6 +13,7 @@
#include "app/app.h"
#include "app/commands/commands.h"
#include "app/commands/params.h"
#include "app/i18n/strings.h"
#include "app/pref/preferences.h"
#include "app/recent_files.h"
#include "app/ui/skin/skin_theme.h"
@ -148,7 +149,7 @@ void RecentFilesListBox::onRebuildList()
void RecentFilesListBox::onClick(const std::string& path)
{
if (!base::is_file(path)) {
ui::Alert::show("Problem<<The selected file doesn't exist||&OK");
ui::Alert::show(Strings::alerts_recent_file_doesnt_exist());
App::instance()->recentFiles()->removeRecentFile(path);
return;
}
@ -179,7 +180,7 @@ void RecentFoldersListBox::onRebuildList()
void RecentFoldersListBox::onClick(const std::string& path)
{
if (!base::is_directory(path)) {
ui::Alert::show("Problem<<The selected folder doesn't exist||&OK");
ui::Alert::show(Strings::alerts_recent_folder_doesnt_exist());
App::instance()->recentFiles()->removeRecentFolder(path);
return;
}