forked from qt-creator/qt-creator
Utils: Replace FileChooser::path() by filePath().toString()
Keep the old method for now to ease downstream porting. The change is kept mechanical, there's a lot of cleanup possible now on the user code side. Change-Id: I936baedd45b7ba057f1c789a1bec896886f48eff Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
@@ -295,9 +295,9 @@ FilePath PathChooser::baseDirectory() const
|
||||
|
||||
void PathChooser::setEnvironment(const Environment &env)
|
||||
{
|
||||
QString oldExpand = path();
|
||||
QString oldExpand = filePath().toString();
|
||||
d->m_environment = env;
|
||||
if (path() != oldExpand) {
|
||||
if (filePath().toString() != oldExpand) {
|
||||
triggerChanged();
|
||||
emit rawPathChanged(rawPath());
|
||||
}
|
||||
@@ -308,11 +308,6 @@ QString PathChooser::rawPath() const
|
||||
return rawFileName().toString();
|
||||
}
|
||||
|
||||
QString PathChooser::path() const
|
||||
{
|
||||
return filePath().toString();
|
||||
}
|
||||
|
||||
FilePath PathChooser::rawFileName() const
|
||||
{
|
||||
return FilePath::fromString(QDir::fromNativeSeparators(d->m_lineEdit->text()));
|
||||
@@ -364,7 +359,7 @@ void PathChooser::slotBrowse()
|
||||
{
|
||||
emit beforeBrowsing();
|
||||
|
||||
QString predefined = path();
|
||||
QString predefined = filePath().toString();
|
||||
QFileInfo fi(predefined);
|
||||
|
||||
if (!predefined.isEmpty() && !fi.isDir()) {
|
||||
|
||||
Reference in New Issue
Block a user