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

Side by Side Diff: chrome/browser/ui/touch/frame/touch_browser_frame_view.cc

Issue 7003097: Reduce the duration of the keyboard animation. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge fix Created 9 years, 6 months 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "chrome/browser/ui/touch/frame/touch_browser_frame_view.h" 5 #include "chrome/browser/ui/touch/frame/touch_browser_frame_view.h"
6 6
7 #include "chrome/browser/profiles/profile.h" 7 #include "chrome/browser/profiles/profile.h"
8 #include "chrome/browser/renderer_host/render_widget_host_view_views.h" 8 #include "chrome/browser/renderer_host/render_widget_host_view_views.h"
9 #include "chrome/browser/tabs/tab_strip_model.h" 9 #include "chrome/browser/tabs/tab_strip_model.h"
10 #include "chrome/browser/ui/browser.h" 10 #include "chrome/browser/ui/browser.h"
(...skipping 11 matching lines...) Expand all
22 #include "ui/base/animation/slide_animation.h" 22 #include "ui/base/animation/slide_animation.h"
23 #include "ui/gfx/rect.h" 23 #include "ui/gfx/rect.h"
24 #include "ui/gfx/transform.h" 24 #include "ui/gfx/transform.h"
25 #include "views/controls/button/image_button.h" 25 #include "views/controls/button/image_button.h"
26 #include "views/controls/textfield/textfield.h" 26 #include "views/controls/textfield/textfield.h"
27 #include "views/focus/focus_manager.h" 27 #include "views/focus/focus_manager.h"
28 28
29 namespace { 29 namespace {
30 30
31 const int kDefaultKeyboardHeight = 300; 31 const int kDefaultKeyboardHeight = 300;
32 const int kKeyboardSlideDuration = 500; // In milliseconds 32 const int kKeyboardSlideDuration = 300; // In milliseconds
33 33
34 PropertyAccessor<bool>* GetFocusedStateAccessor() { 34 PropertyAccessor<bool>* GetFocusedStateAccessor() {
35 static PropertyAccessor<bool> state; 35 static PropertyAccessor<bool> state;
36 return &state; 36 return &state;
37 } 37 }
38 38
39 bool TabContentsHasFocus(const TabContents* contents) { 39 bool TabContentsHasFocus(const TabContents* contents) {
40 views::View* view = static_cast<TabContentsViewTouch*>(contents->view()); 40 views::View* view = static_cast<TabContentsViewTouch*>(contents->view());
41 return view->Contains(view->GetFocusManager()->GetFocusedView()); 41 return view->Contains(view->GetFocusManager()->GetFocusedView());
42 } 42 }
(...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after
333 RenderViewHost* host = 333 RenderViewHost* host =
334 browser_view()->browser()->GetSelectedTabContents()->render_view_host(); 334 browser_view()->browser()->GetSelectedTabContents()->render_view_host();
335 host->Send(new ViewMsg_ScrollFocusedEditableNodeIntoView( 335 host->Send(new ViewMsg_ScrollFocusedEditableNodeIntoView(
336 host->routing_id())); 336 host->routing_id()));
337 } else { 337 } else {
338 // Notify the keyboard that it is hidden now. 338 // Notify the keyboard that it is hidden now.
339 keyboard_->SetVisible(false); 339 keyboard_->SetVisible(false);
340 } 340 }
341 SchedulePaint(); 341 SchedulePaint();
342 } 342 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698