summaryrefslogtreecommitdiffstats
path: root/chrome/browser/browser_window.h
diff options
context:
space:
mode:
authorfinnur@google.com <finnur@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-24 00:10:29 +0000
committerfinnur@google.com <finnur@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-24 00:10:29 +0000
commit4f3dc3751d69f9db1f8ef533a3335201b3bc78bc (patch)
treee37efecf992ddd4e901c894273cbb1e5bf4260cc /chrome/browser/browser_window.h
parent5e7f161f73f1817b8a0c422c0e4b5eceae6954e7 (diff)
downloadchromium_src-4f3dc3751d69f9db1f8ef533a3335201b3bc78bc.zip
chromium_src-4f3dc3751d69f9db1f8ef533a3335201b3bc78bc.tar.gz
chromium_src-4f3dc3751d69f9db1f8ef533a3335201b3bc78bc.tar.bz2
The find bar should be owned and managed from the BrowserView, not the WebContentsView, since it's part of the "chrome".
Design Doc: http://dev.chromium.org/developers/design-documents/find-bar Things done: - Pulled all of the find bar stuff out of WebContentsView* since it's no longer needed. - Moved OnFindReply delegate method from RenderViewHostDelegate::View to RenderViewHostDelegate, since it's no longer implemented on the view. - Moved find control methods to WebContents. - Added recent find result state to WebContents. - Updated the UI tests to accommodate the changes in the state that is broadcast when results are discovered. - Updated the find bar layout to obtain its bounding box from the BrowserView, which knows about toolbars, bookmark bars etc. - Updated the find bar itself to handle the fact that it can be displayed for multiple different tabs. - Moved the find bar manipulation methods for testing from TabProxy to BrowserProxy, since the find bar is now a feature of the window, not the tab. - view.h: Don't lay out child views again if they have a layout manager, it already updated them. TEST=Find box should work as before. BUG=3245 Review URL: http://codereview.chromium.org/27025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10231 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser_window.h')
-rw-r--r--chrome/browser/browser_window.h15
1 files changed, 14 insertions, 1 deletions
diff --git a/chrome/browser/browser_window.h b/chrome/browser/browser_window.h
index be21a1a..8a5ff21 100644
--- a/chrome/browser/browser_window.h
+++ b/chrome/browser/browser_window.h
@@ -16,6 +16,7 @@ class StatusBubble;
class TabContents;
namespace gfx {
+class Point;
class Rect;
}
@@ -123,6 +124,9 @@ class BrowserWindow {
// Shows or hides the bookmark bar depending on its current visibility.
virtual void ToggleBookmarkBar() = 0;
+ // Shows the Find Bar.
+ virtual void ShowFindBar() = 0;
+
// Shows the About Chrome dialog box.
virtual void ShowAboutChromeDialog() = 0;
@@ -182,7 +186,16 @@ class BrowserWindowTesting {
// Returns the LocationBarView.
virtual LocationBarView* GetLocationBarView() const = 0;
+
+ // Computes the location of the find bar and whether it is fully visible in
+ // its parent window. The return value indicates if the window is visible at
+ // all. Both out arguments are required.
+ //
+ // This is used for UI tests of the find bar. If the find bar is not currently
+ // shown (return value of false), the out params will be {(0, 0), false}.
+ virtual bool GetFindBarWindowInfo(gfx::Point* position,
+ bool* fully_visible) const = 0;
#endif
};
-#endif // CHROME_BROWSER_BROWSER_WINDOW_H__
+#endif // CHROME_BROWSER_BROWSER_WINDOW_H_