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

Side by Side Diff: chrome/browser/ui/views/frame/browser_view.h

Issue 11272015: DevTools: “Dock to right” broken after turning a tab into a window of its own. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Cocoa review comment addressed. Created 8 years, 1 month 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
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 CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ 6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 481 matching lines...) Expand 10 before | Expand all | Expand 10 after
492 // Browser type) and there should be a subsequent re-layout to show it. 492 // Browser type) and there should be a subsequent re-layout to show it.
493 // |contents| can be NULL. 493 // |contents| can be NULL.
494 bool MaybeShowBookmarkBar(TabContents* contents); 494 bool MaybeShowBookmarkBar(TabContents* contents);
495 495
496 // Prepare to show an Info Bar for the specified TabContents. Returns 496 // Prepare to show an Info Bar for the specified TabContents. Returns
497 // true if there is an Info Bar to show and one is supported for this Browser 497 // true if there is an Info Bar to show and one is supported for this Browser
498 // type, and there should be a subsequent re-layout to show it. 498 // type, and there should be a subsequent re-layout to show it.
499 // |contents| can be NULL. 499 // |contents| can be NULL.
500 bool MaybeShowInfoBar(TabContents* contents); 500 bool MaybeShowInfoBar(TabContents* contents);
501 501
502 // Updates devtools window for given contents. This method will show docked
503 // devtools window for inspected |tab_contents| that has docked devtools
504 // and hide it for NULL or not inspected |tab_contents|. It will also make
505 // sure devtools window size and position are restored for given tab.
Peter Kasting 2012/10/26 03:22:07 Nit: How about: // If |tab_contents| is non-NUL
506 void UpdateDevToolsForContents(TabContents* tab_contents);
507
502 // Shows docked devtools. 508 // Shows docked devtools.
503 void ShowDevToolsContainer(DevToolsDockSide side); 509 void ShowDevToolsContainer();
504 510
505 // Hides docked devtools. 511 // Hides docked devtools.
506 void HideDevToolsContainer(); 512 void HideDevToolsContainer();
507 513
508 // Updates devtools dock side. 514 // Reads split position from the current tab's devtools window and applies
509 void SetDevToolsDockSide(DevToolsDockSide side); 515 // it to the devtools split.
Peter Kasting 2012/10/26 03:22:07 Nit: How about: // Resets the splitter position
510 516 void UpdateDevToolsSplitPosition();
511 // Updated devtools window for given contents.
512 void UpdateDevToolsForContents(TabContents* tab_contents);
513 517
514 // Updates various optional child Views, e.g. Bookmarks Bar, Info Bar or the 518 // Updates various optional child Views, e.g. Bookmarks Bar, Info Bar or the
515 // Download Shelf in response to a change notification from the specified 519 // Download Shelf in response to a change notification from the specified
516 // |contents|. |contents| can be NULL. In this case, all optional UI will be 520 // |contents|. |contents| can be NULL. In this case, all optional UI will be
517 // removed. 521 // removed.
518 void UpdateUIForContents(TabContents* contents); 522 void UpdateUIForContents(TabContents* contents);
519 523
520 // Updates an optional child View, e.g. Bookmarks Bar, Info Bar, Download 524 // Updates an optional child View, e.g. Bookmarks Bar, Info Bar, Download
521 // Shelf. If |*old_view| differs from new_view, the old_view is removed and 525 // Shelf. If |*old_view| differs from new_view, the old_view is removed and
522 // the new_view is added. This is intended to be used when swapping in/out 526 // the new_view is added. This is intended to be used when swapping in/out
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after
652 // The view that contains devtools window for the selected WebContents. 656 // The view that contains devtools window for the selected WebContents.
653 views::WebView* devtools_container_; 657 views::WebView* devtools_container_;
654 658
655 // The view managing both the contents_container_ and 659 // The view managing both the contents_container_ and
656 // preview_controller_->preview_container_. 660 // preview_controller_->preview_container_.
657 ContentsContainer* contents_; 661 ContentsContainer* contents_;
658 662
659 // Split view containing the contents container and devtools container. 663 // Split view containing the contents container and devtools container.
660 views::SingleSplitView* contents_split_; 664 views::SingleSplitView* contents_split_;
661 665
662 // Side to dock devtools to 666 // Side to dock devtools to.
663 DevToolsDockSide devtools_dock_side_; 667 DevToolsDockSide devtools_dock_side_;
664 668
669 // Docked devtools window instance. NULL when current tab is not inspected
670 // or is inspected with undocked version of DevToolsWindow.
671 DevToolsWindow* devtools_window_;
672
665 // Tracks and stores the last focused view which is not the 673 // Tracks and stores the last focused view which is not the
666 // devtools_container_ or any of its children. Used to restore focus once 674 // devtools_container_ or any of its children. Used to restore focus once
667 // the devtools_container_ is hidden. 675 // the devtools_container_ is hidden.
668 scoped_ptr<views::ExternalFocusTracker> devtools_focus_tracker_; 676 scoped_ptr<views::ExternalFocusTracker> devtools_focus_tracker_;
669 677
670 // The Status information bubble that appears at the bottom of the window. 678 // The Status information bubble that appears at the bottom of the window.
671 scoped_ptr<StatusBubbleViews> status_bubble_; 679 scoped_ptr<StatusBubbleViews> status_bubble_;
672 680
673 // A mapping between accelerators and commands. 681 // A mapping between accelerators and commands.
674 std::map<ui::Accelerator, int> accelerator_table_; 682 std::map<ui::Accelerator, int> accelerator_table_;
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
723 scoped_ptr<SearchViewController> search_view_controller_; 731 scoped_ptr<SearchViewController> search_view_controller_;
724 732
725 scoped_ptr<InstantPreviewControllerViews> preview_controller_; 733 scoped_ptr<InstantPreviewControllerViews> preview_controller_;
726 734
727 mutable base::WeakPtrFactory<BrowserView> activate_modal_dialog_factory_; 735 mutable base::WeakPtrFactory<BrowserView> activate_modal_dialog_factory_;
728 736
729 DISALLOW_COPY_AND_ASSIGN(BrowserView); 737 DISALLOW_COPY_AND_ASSIGN(BrowserView);
730 }; 738 };
731 739
732 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ 740 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698