diff options
author | stanguturi@google.com <stanguturi@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-07-30 22:05:33 +0000 |
---|---|---|
committer | stanguturi@google.com <stanguturi@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-07-30 22:05:33 +0000 |
commit | 8287a0b5dada39ec40fd7311b0d314cf1538bff3 (patch) | |
tree | bd19db7159534bbfc8a8f5fefa6008aa14ebded6 /chrome/views/tooltip_manager.h | |
parent | a9da16d0e7aa10ad2f4ee3290edc361b862e6314 (diff) | |
download | chromium_src-8287a0b5dada39ec40fd7311b0d314cf1538bff3.zip chromium_src-8287a0b5dada39ec40fd7311b0d314cf1538bff3.tar.gz chromium_src-8287a0b5dada39ec40fd7311b0d314cf1538bff3.tar.bz2 |
Made changes to display tooltip window when user navigates through the icons in the toolbar using keyboard arrow keys.
I have already fixed this issue. (Issue:801). I have got LGTM also. But, I have checked in the code when tree was closed. So, all my changes were reverted. So, this new issue is created to upload the same changes.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@139 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/views/tooltip_manager.h')
-rw-r--r-- | chrome/views/tooltip_manager.h | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/chrome/views/tooltip_manager.h b/chrome/views/tooltip_manager.h index 9c77f91..c229b52 100644 --- a/chrome/views/tooltip_manager.h +++ b/chrome/views/tooltip_manager.h @@ -92,6 +92,12 @@ class TooltipManager { // Invoked when the tooltip text changes for the specified views. void TooltipTextChanged(View* view); + // Invoked when toolbar icon gets focus. + void ShowKeyboardTooltip(View* view); + + // Invoked when toolbar loses focus. + void HideKeyboardTooltip(); + // Message handlers. These forward to the tooltip control. virtual void OnMouse(UINT u_msg, WPARAM w_param, LPARAM l_param); LRESULT OnNotify(int w_param, NMHDR* l_param, bool* handled); @@ -132,7 +138,13 @@ class TooltipManager { // of text in the tooltip. void TrimTooltipToFit(std::wstring* text, int* width, - int* line_count); + int* line_count, + int position_x, + int position_y, + HWND window); + + // Invoked when the timer elapses and tooltip has to be destroyed. + void DestroyKeyboardTooltipWindow(HWND window_to_destroy); // Hosting view container. ViewContainer* view_container_; @@ -161,6 +173,13 @@ class TooltipManager { // Height for a tooltip; lazily calculated. static int tooltip_height_; + // control window for tooltip displayed using keyboard. + HWND keyboard_tooltip_hwnd_; + + // Used to register DestroyTooltipWindow function with postdelayedtask + // function. + ScopedRunnableMethodFactory<TooltipManager> keyboard_tooltip_factory_; + DISALLOW_EVIL_CONSTRUCTORS(TooltipManager); }; |