MacOSX compilation fixes.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15295 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Abdelrazak Younes 2006-10-10 15:56:41 +00:00
parent 4add252628
commit 4803b5be6c

View File

@ -79,10 +79,11 @@ FileDialog::Result const FileDialog::save(docstring const & path,
result.first = FileDialog::Chosen;
#ifdef USE_NATIVE_FILEDIALOG
docstring const startsWith = makeAbsPath(suggested, path);
docstring const startsWith
= lyx::from_utf8(makeAbsPath(lyx::to_utf8(suggested), lyx::to_utf8(path)));
result.second = qstring_to_ucs4(QFileDialog::getSaveFileName(
qApp->focusWidget(),
title_.c_str(), toqstr(startsWith), toqstr(filters.as_string()) ));
toqstr(title_), toqstr(startsWith), toqstr(filters.as_string()) ));
#else
LyXFileDialog dlg(title_, path, filters, private_->b1, private_->b2);
dlg.setFileMode(QFileDialog::AnyFile);
@ -113,10 +114,11 @@ FileDialog::Result const FileDialog::open(docstring const & path,
result.first = FileDialog::Chosen;
#ifdef USE_NATIVE_FILEDIALOG
docstring const startsWith = makeAbsPath(suggested, path);
docstring const startsWith =
lyx::from_utf8(makeAbsPath(lyx::to_utf8(suggested), lyx::to_utf8(path)));
result.second = qstring_to_ucs4(QFileDialog::getOpenFileName(
qApp->focusWidget(),
title_.c_str(), toqstr(startsWith), toqstr(filters.as_string()) ));
toqstr(title_), toqstr(startsWith), toqstr(filters.as_string()) ));
#else
LyXFileDialog dlg(title_, path, filters, private_->b1, private_->b2);
@ -143,10 +145,11 @@ FileDialog::Result const FileDialog::opendir(docstring const & path,
result.first = FileDialog::Chosen;
#ifdef USE_NATIVE_FILEDIALOG
docstring const startsWith = makeAbsPath(suggested, path);
docstring const startsWith
= lyx::from_utf8(makeAbsPath(lyx::to_utf8(suggested), lyx::to_utf8(path)));
result.second = qstring_to_ucs4(QFileDialog::getExistingDirectory(
qApp->focusWidget(),
title_.c_str(),toqstr(startsWith) ));
toqstr(title_),toqstr(startsWith) ));
#else
FileFilterList const filter(_("Directories"));