Replace lyxerr based warnings and errors with Alert::error() and Alert::warning().

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16826 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Abdelrazak Younes 2007-01-23 13:30:30 +00:00
parent 76ad6628fd
commit 6823d09f6b

View File

@ -22,6 +22,9 @@
#include "support/path.h" #include "support/path.h"
#include "debug.h" #include "debug.h"
#include "gettext.h"
#include "frontends/Alert.h"
#include <boost/assert.hpp> #include <boost/assert.hpp>
@ -343,16 +346,16 @@ GetFolderPath::GetFolderPath()
{ {
folder_module_ = LoadLibrary("shfolder.dll"); folder_module_ = LoadLibrary("shfolder.dll");
if (!folder_module_) { if (!folder_module_) {
lyxerr << "Unable to load shfolder.dll\nPlease install." frontend::Alert::error(_("System file not found"),
<< std::endl; _("Unable to load shfolder.dll\nPlease install."));
bail_out(); bail_out();
} }
folder_path_func_ = reinterpret_cast<function_pointer>(::GetProcAddress(folder_module_, "SHGetFolderPathA")); folder_path_func_ = reinterpret_cast<function_pointer>(::GetProcAddress(folder_module_, "SHGetFolderPathA"));
if (folder_path_func_ == 0) { if (folder_path_func_ == 0) {
lyxerr << "Unable to find SHGetFolderPathA in shfolder.dll\n" frontend::Alert::error(_("System function not found"),
"Don't know how to proceed. Sorry." _("Unable to find SHGetFolderPathA in shfolder.dll\n"
<< std::endl; "Don't know how to proceed. Sorry."));
bail_out(); bail_out();
} }
} }