Home | History | Annotate | Download | only in base

Lines Matching refs:from_path

115 bool ReplaceFile(const FilePath& from_path,
121 if (::MoveFile(from_path.value().c_str(), to_path.value().c_str()))
127 if (::ReplaceFile(to_path.value().c_str(), from_path.value().c_str(), NULL,
136 bool CopyDirectory(const FilePath& from_path, const FilePath& to_path,
147 if (from_path.value().length() >= MAX_PATH ||
163 FilePath real_from_path = MakeAbsoluteFilePath(from_path);
175 FileEnumerator traversal(from_path, recursive, traverse_type);
177 if (!PathExists(from_path)) {
179 << from_path.value().c_str();
183 DCHECK(recursive || DirectoryExists(from_path));
185 FilePath current = from_path;
186 bool from_is_dir = DirectoryExists(from_path);
188 FilePath from_path_base = from_path;
192 from_path_base = from_path.DirName();
196 // current is the source path, including from_path, so append
197 // the suffix after from_path to to_path to create the target_path.
731 bool MoveUnsafe(const FilePath& from_path, const FilePath& to_path) {
736 if (from_path.value().length() >= MAX_PATH ||
740 if (MoveFileEx(from_path.value().c_str(), to_path.value().c_str(),
749 if (DirectoryExists(from_path)) {
752 // from_path and to_path are indeed in different volumes.
753 ret = internal::CopyAndDeleteDirectory(from_path, to_path);
765 bool CopyFileUnsafe(const FilePath& from_path, const FilePath& to_path) {
770 if (from_path.value().length() >= MAX_PATH ||
780 if (!::CopyFile(from_path.value().c_str(), dest, false)) {
794 bool CopyAndDeleteDirectory(const FilePath& from_path,
797 if (CopyDirectory(from_path, to_path, true)) {
798 if (DeleteFile(from_path, true))
802 // leave the copied bits behind if deleting from_path fails.