forked from qt-creator/qt-creator
check if Android sdk folder is writable
Fixes: QTCREATORBUG-21943 Change-Id: Ic20ed4c24c567b0b08269b7ad07014eb4248b214 Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -768,6 +768,13 @@ bool FilePath::exists() const
|
||||
return !isEmpty() && QFileInfo::exists(m_data);
|
||||
}
|
||||
|
||||
/// \returns a bool indicating whether a path is writable.
|
||||
bool FilePath::isWritablePath() const
|
||||
{
|
||||
const QFileInfo fi{m_data};
|
||||
return exists() && fi.isDir() && fi.isWritable();
|
||||
}
|
||||
|
||||
/// Find the parent directory of a given directory.
|
||||
|
||||
/// Returns an empty FilePath if the current directory is already
|
||||
|
||||
Reference in New Issue
Block a user