OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 CHROME_BROWSER_VIEWS_LOCATION_BAR_VIEW_H_ | 5 #ifndef CHROME_BROWSER_VIEWS_LOCATION_BAR_VIEW_H_ |
6 #define CHROME_BROWSER_VIEWS_LOCATION_BAR_VIEW_H_ | 6 #define CHROME_BROWSER_VIEWS_LOCATION_BAR_VIEW_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <map> | 9 #include <map> |
10 #include <vector> | 10 #include <vector> |
(...skipping 421 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
432 | 432 |
433 // Overridden from view. | 433 // Overridden from view. |
434 virtual void OnMouseMoved(const views::MouseEvent& event); | 434 virtual void OnMouseMoved(const views::MouseEvent& event); |
435 virtual bool OnMousePressed(const views::MouseEvent& event); | 435 virtual bool OnMousePressed(const views::MouseEvent& event); |
436 virtual void OnMouseReleased(const views::MouseEvent& event, bool canceled); | 436 virtual void OnMouseReleased(const views::MouseEvent& event, bool canceled); |
437 | 437 |
438 // Overridden from LocationBarImageView. | 438 // Overridden from LocationBarImageView. |
439 virtual void ShowInfoBubble(); | 439 virtual void ShowInfoBubble(); |
440 | 440 |
441 // Overridden from ImageLoadingTracker. | 441 // Overridden from ImageLoadingTracker. |
442 virtual void OnImageLoaded(SkBitmap* image, size_t index); | 442 virtual void OnImageLoaded( |
| 443 SkBitmap* image, ExtensionResource resource, int index); |
443 | 444 |
444 // Overridden from ExtensionContextMenuModelModel::Delegate | 445 // Overridden from ExtensionContextMenuModelModel::Delegate |
445 virtual void InspectPopup(ExtensionAction* action); | 446 virtual void InspectPopup(ExtensionAction* action); |
446 | 447 |
447 // Overriden from ExtensionPopup::Observer | 448 // Overridden from ExtensionPopup::Observer |
448 virtual void ExtensionPopupClosed(ExtensionPopup* popup); | 449 virtual void ExtensionPopupClosed(ExtensionPopup* popup); |
449 | 450 |
450 // Called to notify the PageAction that it should determine whether to be | 451 // Called to notify the PageAction that it should determine whether to be |
451 // visible or hidden. |contents| is the TabContents that is active, |url| | 452 // visible or hidden. |contents| is the TabContents that is active, |url| |
452 // is the current page URL. | 453 // is the current page URL. |
453 void UpdateVisibility(TabContents* contents, const GURL& url); | 454 void UpdateVisibility(TabContents* contents, const GURL& url); |
454 | 455 |
455 // Either notify listeners or show a popup depending on the page action. | 456 // Either notify listeners or show a popup depending on the page action. |
456 void ExecuteAction(int button, bool inspect_with_devtools); | 457 void ExecuteAction(int button, bool inspect_with_devtools); |
457 | 458 |
(...skipping 14 matching lines...) Expand all Loading... |
472 // A cache of bitmaps the page actions might need to show, mapped by path. | 473 // A cache of bitmaps the page actions might need to show, mapped by path. |
473 typedef std::map<std::string, SkBitmap> PageActionMap; | 474 typedef std::map<std::string, SkBitmap> PageActionMap; |
474 PageActionMap page_action_icons_; | 475 PageActionMap page_action_icons_; |
475 | 476 |
476 // The context menu for this page action. | 477 // The context menu for this page action. |
477 scoped_ptr<ExtensionContextMenuModel> context_menu_contents_; | 478 scoped_ptr<ExtensionContextMenuModel> context_menu_contents_; |
478 scoped_ptr<views::Menu2> context_menu_menu_; | 479 scoped_ptr<views::Menu2> context_menu_menu_; |
479 | 480 |
480 // The object that is waiting for the image loading to complete | 481 // The object that is waiting for the image loading to complete |
481 // asynchronously. | 482 // asynchronously. |
482 ImageLoadingTracker* tracker_; | 483 ImageLoadingTracker tracker_; |
483 | 484 |
484 // The tab id we are currently showing the icon for. | 485 // The tab id we are currently showing the icon for. |
485 int current_tab_id_; | 486 int current_tab_id_; |
486 | 487 |
487 // The URL we are currently showing the icon for. | 488 // The URL we are currently showing the icon for. |
488 GURL current_url_; | 489 GURL current_url_; |
489 | 490 |
490 // The string to show for a tooltip; | 491 // The string to show for a tooltip; |
491 std::string tooltip_; | 492 std::string tooltip_; |
492 | 493 |
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
648 // The positioner that places the omnibox and info bubbles. | 649 // The positioner that places the omnibox and info bubbles. |
649 const BubblePositioner* bubble_positioner_; | 650 const BubblePositioner* bubble_positioner_; |
650 | 651 |
651 // Storage of string needed for accessibility. | 652 // Storage of string needed for accessibility. |
652 std::wstring accessible_name_; | 653 std::wstring accessible_name_; |
653 | 654 |
654 DISALLOW_COPY_AND_ASSIGN(LocationBarView); | 655 DISALLOW_COPY_AND_ASSIGN(LocationBarView); |
655 }; | 656 }; |
656 | 657 |
657 #endif // CHROME_BROWSER_VIEWS_LOCATION_BAR_VIEW_H_ | 658 #endif // CHROME_BROWSER_VIEWS_LOCATION_BAR_VIEW_H_ |
OLD | NEW |