format previously missed chromium_src .cc files

This commit is contained in:
Shelley Vohr 2018-04-17 21:57:05 -04:00
parent 8cc81509d7
commit f7d4437b3f
No known key found for this signature in database
GPG key ID: F13993A75599653C
58 changed files with 688 additions and 898 deletions

View file

@ -4,11 +4,11 @@
#include "chrome/common/chrome_paths_internal.h"
#include <windows.h>
#include <knownfolders.h>
#include <shellapi.h>
#include <shlobj.h>
#include <shobjidl.h>
#include <windows.h>
#include "base/files/file_path.h"
#include "base/path_service.h"
@ -28,8 +28,8 @@ bool GetUserDirectory(int csidl_folder, base::FilePath* result) {
// so we don't bother handling it.
wchar_t path_buf[MAX_PATH];
path_buf[0] = 0;
if (FAILED(SHGetFolderPath(NULL, csidl_folder, NULL,
SHGFP_TYPE_CURRENT, path_buf))) {
if (FAILED(SHGetFolderPath(NULL, csidl_folder, NULL, SHGFP_TYPE_CURRENT,
path_buf))) {
return false;
}
*result = base::FilePath(path_buf);
@ -68,8 +68,8 @@ bool GetUserDownloadsDirectorySafe(base::FilePath* result) {
// relocated to point to a "dangerous" folder, callers should validate that the
// returned path is not dangerous before using it.
bool GetUserDownloadsDirectory(base::FilePath* result) {
typedef HRESULT (WINAPI *GetKnownFolderPath)(
REFKNOWNFOLDERID, DWORD, HANDLE, PWSTR*);
typedef HRESULT(WINAPI * GetKnownFolderPath)(REFKNOWNFOLDERID, DWORD, HANDLE,
PWSTR*);
GetKnownFolderPath f = reinterpret_cast<GetKnownFolderPath>(
GetProcAddress(GetModuleHandle(L"shell32.dll"), "SHGetKnownFolderPath"));
base::win::ScopedCoMem<wchar_t> path_buf;