OLD | NEW |
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 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
365 virtual void FindReply(WebContents* tab, | 365 virtual void FindReply(WebContents* tab, |
366 int request_id, | 366 int request_id, |
367 int number_of_matches, | 367 int number_of_matches, |
368 const gfx::Rect& selection_rect, | 368 const gfx::Rect& selection_rect, |
369 int active_match_ordinal, | 369 int active_match_ordinal, |
370 bool final_update) {} | 370 bool final_update) {} |
371 | 371 |
372 // Notification that a plugin has crashed. | 372 // Notification that a plugin has crashed. |
373 virtual void CrashedPlugin(WebContents* tab, const FilePath& plugin_path) {} | 373 virtual void CrashedPlugin(WebContents* tab, const FilePath& plugin_path) {} |
374 | 374 |
| 375 // Notication that the given plugin has hung or become unhung. This |
| 376 // notification is only for Pepper plugins. |
| 377 // |
| 378 // The plugin_child_id is the unique child process ID from the plugin. Note |
| 379 // that this ID is supplied by the renderer, so should be validated before |
| 380 // it's used for anything in case there's an exploited renderer. |
| 381 virtual void PluginHungStatusChanged(WebContents* tab, |
| 382 int plugin_child_id, |
| 383 const FilePath& plugin_path, |
| 384 bool is_hung) {} |
| 385 |
375 // Invoked when the preferred size of the contents has been changed. | 386 // Invoked when the preferred size of the contents has been changed. |
376 virtual void UpdatePreferredSize(WebContents* tab, | 387 virtual void UpdatePreferredSize(WebContents* tab, |
377 const gfx::Size& pref_size) {} | 388 const gfx::Size& pref_size) {} |
378 | 389 |
379 // Invoked when the contents auto-resized and the container should match it. | 390 // Invoked when the contents auto-resized and the container should match it. |
380 virtual void ResizeDueToAutoResize(WebContents* tab, | 391 virtual void ResizeDueToAutoResize(WebContents* tab, |
381 const gfx::Size& new_size) {} | 392 const gfx::Size& new_size) {} |
382 | 393 |
383 // Notification message from HTML UI. | 394 // Notification message from HTML UI. |
384 virtual void WebUISend(WebContents* tab, | 395 virtual void WebUISend(WebContents* tab, |
(...skipping 21 matching lines...) Expand all Loading... |
406 // Called when |this| is no longer the WebContentsDelegate for |source|. | 417 // Called when |this| is no longer the WebContentsDelegate for |source|. |
407 void Detach(WebContents* source); | 418 void Detach(WebContents* source); |
408 | 419 |
409 // The WebContents that this is currently a delegate for. | 420 // The WebContents that this is currently a delegate for. |
410 std::set<WebContents*> attached_contents_; | 421 std::set<WebContents*> attached_contents_; |
411 }; | 422 }; |
412 | 423 |
413 } // namespace content | 424 } // namespace content |
414 | 425 |
415 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ | 426 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ |
OLD | NEW |