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

Side by Side Diff: third_party/WebKit/Source/modules/exported/WebDOMFileSystem.cpp

Issue 2874713002: Move many standalone files from web/ to (core|modules)/exported/. (Closed)
Patch Set: Rebase Created 3 years, 7 months 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * 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 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 v8::Local<v8::Value> WebDOMFileSystem::CreateV8Entry( 125 v8::Local<v8::Value> WebDOMFileSystem::CreateV8Entry(
126 const WebString& path, 126 const WebString& path,
127 EntryType entry_type, 127 EntryType entry_type,
128 v8::Local<v8::Object> creation_context, 128 v8::Local<v8::Object> creation_context,
129 v8::Isolate* isolate) { 129 v8::Isolate* isolate) {
130 // We no longer use |creationContext| because it's often misused and points 130 // We no longer use |creationContext| because it's often misused and points
131 // to a context faked by user script. 131 // to a context faked by user script.
132 DCHECK(creation_context->CreationContext() == isolate->GetCurrentContext()); 132 DCHECK(creation_context->CreationContext() == isolate->GetCurrentContext());
133 if (!private_.Get()) 133 if (!private_.Get())
134 return v8::Local<v8::Value>(); 134 return v8::Local<v8::Value>();
135 if (entry_type == kEntryTypeDirectory) 135 if (entry_type == kEntryTypeDirectory) {
136 return ToV8(DirectoryEntry::Create(private_.Get(), path), 136 return ToV8(DirectoryEntry::Create(private_.Get(), path),
137 isolate->GetCurrentContext()->Global(), isolate); 137 isolate->GetCurrentContext()->Global(), isolate);
138 }
138 DCHECK_EQ(entry_type, kEntryTypeFile); 139 DCHECK_EQ(entry_type, kEntryTypeFile);
139 return ToV8(FileEntry::Create(private_.Get(), path), 140 return ToV8(FileEntry::Create(private_.Get(), path),
140 isolate->GetCurrentContext()->Global(), isolate); 141 isolate->GetCurrentContext()->Global(), isolate);
141 } 142 }
142 143
143 WebDOMFileSystem::WebDOMFileSystem(DOMFileSystem* dom_file_system) 144 WebDOMFileSystem::WebDOMFileSystem(DOMFileSystem* dom_file_system)
144 : private_(dom_file_system) {} 145 : private_(dom_file_system) {}
145 146
146 WebDOMFileSystem& WebDOMFileSystem::operator=(DOMFileSystem* dom_file_system) { 147 WebDOMFileSystem& WebDOMFileSystem::operator=(DOMFileSystem* dom_file_system) {
147 private_ = dom_file_system; 148 private_ = dom_file_system;
148 return *this; 149 return *this;
149 } 150 }
150 151
151 } // namespace blink 152 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698