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

Side by Side Diff: Source/web/FrameLoaderClientImpl.cpp

Issue 241303002: Rename WebFrameImpl to WebLocalFrameImpl. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix Mac too Created 6 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « Source/web/FrameLoaderClientImpl.h ('k') | Source/web/IndexedDBClientImpl.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved.
3 * Copyright (C) 2011 Apple Inc. All rights reserved. 3 * Copyright (C) 2011 Apple 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 are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 26 matching lines...) Expand all
37 #include "SharedWorkerRepositoryClientImpl.h" 37 #include "SharedWorkerRepositoryClientImpl.h"
38 #include "WebAutocompleteParams.h" 38 #include "WebAutocompleteParams.h"
39 #include "WebAutofillClient.h" 39 #include "WebAutofillClient.h"
40 #include "WebCachedURLRequest.h" 40 #include "WebCachedURLRequest.h"
41 #include "WebDOMEvent.h" 41 #include "WebDOMEvent.h"
42 #include "WebDataSourceImpl.h" 42 #include "WebDataSourceImpl.h"
43 #include "WebDevToolsAgentPrivate.h" 43 #include "WebDevToolsAgentPrivate.h"
44 #include "WebDocument.h" 44 #include "WebDocument.h"
45 #include "WebFormElement.h" 45 #include "WebFormElement.h"
46 #include "WebFrameClient.h" 46 #include "WebFrameClient.h"
47 #include "WebFrameImpl.h" 47 #include "WebLocalFrameImpl.h"
48 #include "WebNode.h" 48 #include "WebNode.h"
49 #include "WebPermissionClient.h" 49 #include "WebPermissionClient.h"
50 #include "WebPlugin.h" 50 #include "WebPlugin.h"
51 #include "WebPluginContainerImpl.h" 51 #include "WebPluginContainerImpl.h"
52 #include "WebPluginLoadObserver.h" 52 #include "WebPluginLoadObserver.h"
53 #include "WebPluginParams.h" 53 #include "WebPluginParams.h"
54 #include "WebSecurityOrigin.h" 54 #include "WebSecurityOrigin.h"
55 #include "WebViewClient.h" 55 #include "WebViewClient.h"
56 #include "WebViewImpl.h" 56 #include "WebViewImpl.h"
57 #include "bindings/v8/Dictionary.h" 57 #include "bindings/v8/Dictionary.h"
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 #include "public/platform/WebVector.h" 96 #include "public/platform/WebVector.h"
97 #include "wtf/StringExtras.h" 97 #include "wtf/StringExtras.h"
98 #include "wtf/text/CString.h" 98 #include "wtf/text/CString.h"
99 #include "wtf/text/WTFString.h" 99 #include "wtf/text/WTFString.h"
100 #include <v8.h> 100 #include <v8.h>
101 101
102 using namespace WebCore; 102 using namespace WebCore;
103 103
104 namespace blink { 104 namespace blink {
105 105
106 FrameLoaderClientImpl::FrameLoaderClientImpl(WebFrameImpl* frame) 106 FrameLoaderClientImpl::FrameLoaderClientImpl(WebLocalFrameImpl* frame)
107 : m_webFrame(frame) 107 : m_webFrame(frame)
108 { 108 {
109 } 109 }
110 110
111 FrameLoaderClientImpl::~FrameLoaderClientImpl() 111 FrameLoaderClientImpl::~FrameLoaderClientImpl()
112 { 112 {
113 } 113 }
114 114
115 void FrameLoaderClientImpl::dispatchDidClearWindowObjectInWorld(DOMWrapperWorld& world) 115 void FrameLoaderClientImpl::dispatchDidClearWindowObjectInWorld(DOMWrapperWorld& world)
116 { 116 {
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 235
236 } 236 }
237 237
238 bool FrameLoaderClientImpl::hasWebView() const 238 bool FrameLoaderClientImpl::hasWebView() const
239 { 239 {
240 return m_webFrame->viewImpl(); 240 return m_webFrame->viewImpl();
241 } 241 }
242 242
243 Frame* FrameLoaderClientImpl::opener() const 243 Frame* FrameLoaderClientImpl::opener() const
244 { 244 {
245 WebFrameImpl* opener = toWebFrameImpl(m_webFrame->opener()); 245 WebLocalFrameImpl* opener = toWebLocalFrameImpl(m_webFrame->opener());
246 return opener ? opener->frame() : 0; 246 return opener ? opener->frame() : 0;
247 } 247 }
248 248
249 void FrameLoaderClientImpl::setOpener(Frame* opener) 249 void FrameLoaderClientImpl::setOpener(Frame* opener)
250 { 250 {
251 // FIXME: Temporary hack to stage converting locations that really should be Frame. 251 // FIXME: Temporary hack to stage converting locations that really should be Frame.
252 m_webFrame->setOpener(WebFrameImpl::fromFrame(toLocalFrame(opener))); 252 m_webFrame->setOpener(WebLocalFrameImpl::fromFrame(toLocalFrame(opener)));
253 } 253 }
254 254
255 Frame* FrameLoaderClientImpl::parent() const 255 Frame* FrameLoaderClientImpl::parent() const
256 { 256 {
257 WebFrameImpl* frame = toWebFrameImpl(m_webFrame->parent()); 257 WebLocalFrameImpl* frame = toWebLocalFrameImpl(m_webFrame->parent());
258 return frame ? frame->frame() : 0; 258 return frame ? frame->frame() : 0;
259 } 259 }
260 260
261 Frame* FrameLoaderClientImpl::top() const 261 Frame* FrameLoaderClientImpl::top() const
262 { 262 {
263 WebFrameImpl* frame = toWebFrameImpl(m_webFrame->top()); 263 WebLocalFrameImpl* frame = toWebLocalFrameImpl(m_webFrame->top());
264 return frame ? frame->frame() : 0; 264 return frame ? frame->frame() : 0;
265 } 265 }
266 266
267 Frame* FrameLoaderClientImpl::previousSibling() const 267 Frame* FrameLoaderClientImpl::previousSibling() const
268 { 268 {
269 WebFrameImpl* frame = toWebFrameImpl(m_webFrame->previousSibling()); 269 WebLocalFrameImpl* frame = toWebLocalFrameImpl(m_webFrame->previousSibling() );
270 return frame ? frame->frame() : 0; 270 return frame ? frame->frame() : 0;
271 } 271 }
272 272
273 Frame* FrameLoaderClientImpl::nextSibling() const 273 Frame* FrameLoaderClientImpl::nextSibling() const
274 { 274 {
275 WebFrameImpl* frame = toWebFrameImpl(m_webFrame->nextSibling()); 275 WebLocalFrameImpl* frame = toWebLocalFrameImpl(m_webFrame->nextSibling());
276 return frame ? frame->frame() : 0; 276 return frame ? frame->frame() : 0;
277 } 277 }
278 278
279 Frame* FrameLoaderClientImpl::firstChild() const 279 Frame* FrameLoaderClientImpl::firstChild() const
280 { 280 {
281 WebFrameImpl* frame = toWebFrameImpl(m_webFrame->firstChild()); 281 WebLocalFrameImpl* frame = toWebLocalFrameImpl(m_webFrame->firstChild());
282 return frame ? frame->frame() : 0; 282 return frame ? frame->frame() : 0;
283 } 283 }
284 284
285 Frame* FrameLoaderClientImpl::lastChild() const 285 Frame* FrameLoaderClientImpl::lastChild() const
286 { 286 {
287 WebFrameImpl* frame = toWebFrameImpl(m_webFrame->lastChild()); 287 WebLocalFrameImpl* frame = toWebLocalFrameImpl(m_webFrame->lastChild());
288 return frame ? frame->frame() : 0; 288 return frame ? frame->frame() : 0;
289 } 289 }
290 290
291 void FrameLoaderClientImpl::detachedFromParent() 291 void FrameLoaderClientImpl::detachedFromParent()
292 { 292 {
293 // Alert the client that the frame is being detached. This is the last 293 // Alert the client that the frame is being detached. This is the last
294 // chance we have to communicate with the client. 294 // chance we have to communicate with the client.
295 RefPtr<WebFrameImpl> protector(m_webFrame); 295 RefPtr<WebLocalFrameImpl> protector(m_webFrame);
296 296
297 WebFrameClient* client = m_webFrame->client(); 297 WebFrameClient* client = m_webFrame->client();
298 if (!client) 298 if (!client)
299 return; 299 return;
300 300
301 m_webFrame->willDetachParent(); 301 m_webFrame->willDetachParent();
302 302
303 // Signal that no further communication with WebFrameClient should take 303 // Signal that no further communication with WebFrameClient should take
304 // place at this point since we are no longer associated with the Page. 304 // place at this point since we are no longer associated with the Page.
305 m_webFrame->setClient(0); 305 m_webFrame->setClient(0);
(...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after
723 } 723 }
724 724
725 bool FrameLoaderClientImpl::willCheckAndDispatchMessageEvent( 725 bool FrameLoaderClientImpl::willCheckAndDispatchMessageEvent(
726 SecurityOrigin* target, MessageEvent* event) const 726 SecurityOrigin* target, MessageEvent* event) const
727 { 727 {
728 if (!m_webFrame->client()) 728 if (!m_webFrame->client())
729 return false; 729 return false;
730 730
731 WebLocalFrame* source = 0; 731 WebLocalFrame* source = 0;
732 if (event && event->source() && event->source()->toDOMWindow() && event->sou rce()->toDOMWindow()->document()) 732 if (event && event->source() && event->source()->toDOMWindow() && event->sou rce()->toDOMWindow()->document())
733 source = WebFrameImpl::fromFrame(event->source()->toDOMWindow()->documen t()->frame()); 733 source = WebLocalFrameImpl::fromFrame(event->source()->toDOMWindow()->do cument()->frame());
734 return m_webFrame->client()->willCheckAndDispatchMessageEvent( 734 return m_webFrame->client()->willCheckAndDispatchMessageEvent(
735 source, m_webFrame, WebSecurityOrigin(target), WebDOMMessageEvent(event) ); 735 source, m_webFrame, WebSecurityOrigin(target), WebDOMMessageEvent(event) );
736 } 736 }
737 737
738 void FrameLoaderClientImpl::didChangeName(const String& name) 738 void FrameLoaderClientImpl::didChangeName(const String& name)
739 { 739 {
740 if (!m_webFrame->client()) 740 if (!m_webFrame->client())
741 return; 741 return;
742 m_webFrame->client()->didChangeName(m_webFrame, name); 742 m_webFrame->client()->didChangeName(m_webFrame, name);
743 } 743 }
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
800 return adoptPtr(m_webFrame->client()->createApplicationCacheHost(m_webFrame, client)); 800 return adoptPtr(m_webFrame->client()->createApplicationCacheHost(m_webFrame, client));
801 } 801 }
802 802
803 void FrameLoaderClientImpl::didStopAllLoaders() 803 void FrameLoaderClientImpl::didStopAllLoaders()
804 { 804 {
805 if (m_webFrame->client()) 805 if (m_webFrame->client())
806 m_webFrame->client()->didAbortLoading(m_webFrame); 806 m_webFrame->client()->didAbortLoading(m_webFrame);
807 } 807 }
808 808
809 } // namespace blink 809 } // namespace blink
OLDNEW
« no previous file with comments | « Source/web/FrameLoaderClientImpl.h ('k') | Source/web/IndexedDBClientImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698