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

Side by Side Diff: content/public/browser/web_contents_delegate.h

Issue 964403003: Make it possible to set the display mode from Chromium (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Decouple getting display mode and renderer-initiated fullscreen mode code paths Created 5 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_
6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 10
11 #include "base/basictypes.h" 11 #include "base/basictypes.h"
12 #include "base/callback.h" 12 #include "base/callback.h"
13 #include "base/strings/string16.h" 13 #include "base/strings/string16.h"
14 #include "content/common/content_export.h" 14 #include "content/common/content_export.h"
15 #include "content/public/browser/invalidate_type.h" 15 #include "content/public/browser/invalidate_type.h"
16 #include "content/public/browser/navigation_type.h" 16 #include "content/public/browser/navigation_type.h"
17 #include "content/public/common/media_stream_request.h" 17 #include "content/public/common/media_stream_request.h"
18 #include "content/public/common/window_container_type.h" 18 #include "content/public/common/window_container_type.h"
19 #include "third_party/WebKit/public/platform/WebDisplayMode.h"
19 #include "third_party/WebKit/public/web/WebDragOperation.h" 20 #include "third_party/WebKit/public/web/WebDragOperation.h"
20 #include "third_party/skia/include/core/SkColor.h" 21 #include "third_party/skia/include/core/SkColor.h"
21 #include "ui/base/window_open_disposition.h" 22 #include "ui/base/window_open_disposition.h"
22 #include "ui/gfx/geometry/rect_f.h" 23 #include "ui/gfx/geometry/rect_f.h"
23 #include "ui/gfx/native_widget_types.h" 24 #include "ui/gfx/native_widget_types.h"
24 25
25 class GURL; 26 class GURL;
26 27
27 namespace base { 28 namespace base {
28 class FilePath; 29 class FilePath;
(...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after
373 // URL's origin should be used. 374 // URL's origin should be used.
374 virtual void EnterFullscreenModeForTab(WebContents* web_contents, 375 virtual void EnterFullscreenModeForTab(WebContents* web_contents,
375 const GURL& origin) {} 376 const GURL& origin) {}
376 377
377 // Called when the renderer puts a tab out of fullscreen mode. 378 // Called when the renderer puts a tab out of fullscreen mode.
378 virtual void ExitFullscreenModeForTab(WebContents*) {} 379 virtual void ExitFullscreenModeForTab(WebContents*) {}
379 380
380 virtual bool IsFullscreenForTabOrPending( 381 virtual bool IsFullscreenForTabOrPending(
381 const WebContents* web_contents) const; 382 const WebContents* web_contents) const;
382 383
384 virtual blink::WebDisplayMode GetDisplayMode(
385 const WebContents* web_contents) const;
386
383 // Register a new handler for URL requests with the given scheme. 387 // Register a new handler for URL requests with the given scheme.
384 // |user_gesture| is true if the registration is made in the context of a user 388 // |user_gesture| is true if the registration is made in the context of a user
385 // gesture. 389 // gesture.
386 virtual void RegisterProtocolHandler(WebContents* web_contents, 390 virtual void RegisterProtocolHandler(WebContents* web_contents,
387 const std::string& protocol, 391 const std::string& protocol,
388 const GURL& url, 392 const GURL& url,
389 bool user_gesture) {} 393 bool user_gesture) {}
390 394
391 // Unregister the registered handler for URL requests with the given scheme. 395 // Unregister the registered handler for URL requests with the given scheme.
392 // |user_gesture| is true if the registration is made in the context of a user 396 // |user_gesture| is true if the registration is made in the context of a user
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
507 // Called when |this| is no longer the WebContentsDelegate for |source|. 511 // Called when |this| is no longer the WebContentsDelegate for |source|.
508 void Detach(WebContents* source); 512 void Detach(WebContents* source);
509 513
510 // The WebContents that this is currently a delegate for. 514 // The WebContents that this is currently a delegate for.
511 std::set<WebContents*> attached_contents_; 515 std::set<WebContents*> attached_contents_;
512 }; 516 };
513 517
514 } // namespace content 518 } // namespace content
515 519
516 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ 520 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698