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

Side by Side Diff: public/web/WebFrameWidget.h

Issue 1310063002: Snapshot a pointer to the main frame when creating WebViewFrameWidget. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Futureproof Created 5 years, 4 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/WebViewFrameWidget.cpp ('k') | no next file » | 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) 2014 Google Inc. All rights reserved. 2 * Copyright (C) 2014 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 28 matching lines...) Expand all
39 39
40 class WebLocalFrame; 40 class WebLocalFrame;
41 class WebView; 41 class WebView;
42 class WebWidgetClient; 42 class WebWidgetClient;
43 43
44 class WebFrameWidget : public WebWidget { 44 class WebFrameWidget : public WebWidget {
45 public: 45 public:
46 BLINK_EXPORT static WebFrameWidget* create(WebWidgetClient*, WebLocalFrame*) ; 46 BLINK_EXPORT static WebFrameWidget* create(WebWidgetClient*, WebLocalFrame*) ;
47 // Creates a frame widget for a WebView. Temporary helper to help transition 47 // Creates a frame widget for a WebView. Temporary helper to help transition
48 // away from WebView inheriting WebWidget. 48 // away from WebView inheriting WebWidget.
49 BLINK_EXPORT static WebFrameWidget* create(WebView*); 49 // TODO(dcheng): Remove once transition is complete.
50 BLINK_EXPORT static WebFrameWidget* create(WebWidgetClient*, WebView*, WebLo calFrame* mainFrame);
50 51
51 // Sets the visibility of the WebFrameWidget. 52 // Sets the visibility of the WebFrameWidget.
52 // We still track page-level visibility, but additionally we need to notify a WebFrameWidget 53 // We still track page-level visibility, but additionally we need to notify a WebFrameWidget
53 // when its owning RenderWidget receives a Show or Hide directive, so that i t knows whether 54 // when its owning RenderWidget receives a Show or Hide directive, so that i t knows whether
54 // it needs to draw or not. 55 // it needs to draw or not.
55 virtual void setVisibilityState(WebPageVisibilityState visibilityState, bool isInitialState) { } 56 virtual void setVisibilityState(WebPageVisibilityState visibilityState, bool isInitialState) { }
56 57
57 // Temporary: there should only be one WebFrameWidget implementation but the 58 // Temporary: there should only be one WebFrameWidget implementation but the
58 // Blink API is currently in a transition state. See https://goo.gl/7yVrnb 59 // Blink API is currently in a transition state. See https://goo.gl/7yVrnb
59 virtual bool forSubframe() const { return true; } 60 virtual bool forSubframe() const { return true; }
60 }; 61 };
61 62
62 } // namespace blink 63 } // namespace blink
63 64
64 #endif 65 #endif
OLDNEW
« no previous file with comments | « Source/web/WebViewFrameWidget.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698