blob: 3f58b9cc0b4232de582ee526db2b4c9d47d804a8 [file] [log] [blame]
[email protected]feb3cf72009-01-22 22:57:191// Copyright (c) 2009 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef CHROME_BROWSER_STATUS_BUBBLE_H_
6#define CHROME_BROWSER_STATUS_BUBBLE_H_
7
[email protected]51096b32009-01-22 23:09:448#include <string>
9
[email protected]feb3cf72009-01-22 22:57:1910class GURL;
11
12////////////////////////////////////////////////////////////////////////////////
13// StatusBubble interface
14// An interface implemented by an object providing the status display area of
15// the browser window.
16//
17class StatusBubble {
18 public:
[email protected]c9b0cbd2009-04-13 12:53:0319 virtual ~StatusBubble() { };
20
[email protected]feb3cf72009-01-22 22:57:1921 // Sets the bubble contents to a specific string and causes the bubble
22 // to display immediately. Subsequent empty SetURL calls (typically called
23 // when the cursor exits a link) will set the status bubble back to its
24 // status text. To hide the status bubble again, either call SetStatus
25 // with an empty string, or call Hide().
26 virtual void SetStatus(const std::wstring& status) = 0;
27
28 // Sets the bubble text to a URL - if given a non-empty URL, this will cause
29 // the bubble to fade in and remain open until given an empty URL or until
30 // the Hide() method is called. languages is the value of Accept-Language
31 // to determine what characters are understood by a user.
32 virtual void SetURL(const GURL& url, const std::wstring& languages) = 0;
33
34 // Skip the fade and instant-hide the bubble.
35 virtual void Hide() = 0;
36
37 // Called when the user's mouse has moved over web content. This is used to
38 // determine when the status area should move out of the way of the user's
39 // mouse. This may be windows specific pain due to the way messages are
40 // processed for child HWNDs.
41 virtual void MouseMoved() = 0;
42};
43
[email protected]be06a75b2009-02-19 03:37:1244#endif // #ifndef CHROME_BROWSER_STATUS_BUBBLE_H_