Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(363)

Side by Side Diff: Source/modules/filesystem/WorkerGlobalScopeFileSystem.cpp

Issue 54053006: Move weborigin/ under platform/ so that it may someday call platform APIs (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved.
3 * Copyright (C) 2009, 2011 Google Inc. All Rights Reserved. 3 * Copyright (C) 2009, 2011 Google Inc. All Rights Reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 25 matching lines...) Expand all
36 #include "modules/filesystem/DOMFileSystemBase.h" 36 #include "modules/filesystem/DOMFileSystemBase.h"
37 #include "modules/filesystem/DOMFileSystemSync.h" 37 #include "modules/filesystem/DOMFileSystemSync.h"
38 #include "modules/filesystem/DirectoryEntrySync.h" 38 #include "modules/filesystem/DirectoryEntrySync.h"
39 #include "modules/filesystem/ErrorCallback.h" 39 #include "modules/filesystem/ErrorCallback.h"
40 #include "modules/filesystem/FileEntrySync.h" 40 #include "modules/filesystem/FileEntrySync.h"
41 #include "modules/filesystem/FileSystemCallback.h" 41 #include "modules/filesystem/FileSystemCallback.h"
42 #include "modules/filesystem/FileSystemCallbacks.h" 42 #include "modules/filesystem/FileSystemCallbacks.h"
43 #include "modules/filesystem/SyncCallbackHelper.h" 43 #include "modules/filesystem/SyncCallbackHelper.h"
44 #include "modules/filesystem/WorkerLocalFileSystem.h" 44 #include "modules/filesystem/WorkerLocalFileSystem.h"
45 #include "platform/FileSystemType.h" 45 #include "platform/FileSystemType.h"
46 #include "weborigin/SecurityOrigin.h" 46 #include "platform/weborigin/SecurityOrigin.h"
47 47
48 namespace WebCore { 48 namespace WebCore {
49 49
50 void WorkerGlobalScopeFileSystem::webkitRequestFileSystem(WorkerGlobalScope* wor ker, int type, long long size, PassRefPtr<FileSystemCallback> successCallback, P assRefPtr<ErrorCallback> errorCallback) 50 void WorkerGlobalScopeFileSystem::webkitRequestFileSystem(WorkerGlobalScope* wor ker, int type, long long size, PassRefPtr<FileSystemCallback> successCallback, P assRefPtr<ErrorCallback> errorCallback)
51 { 51 {
52 ExecutionContext* secureContext = worker->executionContext(); 52 ExecutionContext* secureContext = worker->executionContext();
53 if (!secureContext->securityOrigin()->canAccessFileSystem()) { 53 if (!secureContext->securityOrigin()->canAccessFileSystem()) {
54 DOMFileSystem::scheduleCallback(worker, errorCallback, FileError::create (FileError::SECURITY_ERR)); 54 DOMFileSystem::scheduleCallback(worker, errorCallback, FileError::create (FileError::SECURITY_ERR));
55 return; 55 return;
56 } 56 }
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 RefPtr<EntrySync> entry = resolveURLHelper.getResult(es); 126 RefPtr<EntrySync> entry = resolveURLHelper.getResult(es);
127 if (!entry) 127 if (!entry)
128 return 0; 128 return 0;
129 return entry.release(); 129 return entry.release();
130 } 130 }
131 131
132 COMPILE_ASSERT(static_cast<int>(WorkerGlobalScopeFileSystem::TEMPORARY) == stati c_cast<int>(FileSystemTypeTemporary), enum_mismatch); 132 COMPILE_ASSERT(static_cast<int>(WorkerGlobalScopeFileSystem::TEMPORARY) == stati c_cast<int>(FileSystemTypeTemporary), enum_mismatch);
133 COMPILE_ASSERT(static_cast<int>(WorkerGlobalScopeFileSystem::PERSISTENT) == stat ic_cast<int>(FileSystemTypePersistent), enum_mismatch); 133 COMPILE_ASSERT(static_cast<int>(WorkerGlobalScopeFileSystem::PERSISTENT) == stat ic_cast<int>(FileSystemTypePersistent), enum_mismatch);
134 134
135 } // namespace WebCore 135 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698