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

Unified Diff: chrome/browser/ui/views/location_bar/location_bar_view.h

Issue 1036173002: Animate showing / hiding the location bar for bookmark apps. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix stuffup Created 5 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/location_bar/location_bar_view.h
diff --git a/chrome/browser/ui/views/location_bar/location_bar_view.h b/chrome/browser/ui/views/location_bar/location_bar_view.h
index 22b01ef973a90152c394d77680cf256dadb4d1e6..7fd4b4ae0acd7398e06aaddadd9c825c921320a8 100644
--- a/chrome/browser/ui/views/location_bar/location_bar_view.h
+++ b/chrome/browser/ui/views/location_bar/location_bar_view.h
@@ -22,6 +22,7 @@
#include "components/search_engines/template_url_service_observer.h"
#include "components/ui/zoom/zoom_event_manager_observer.h"
#include "ui/gfx/animation/animation_delegate.h"
+#include "ui/gfx/animation/slide_animation.h"
#include "ui/gfx/font.h"
#include "ui/gfx/geometry/rect.h"
#include "ui/views/controls/button/button.h"
@@ -74,6 +75,7 @@ class LocationBarView : public LocationBar,
public views::View,
public views::ButtonListener,
public views::DragController,
+ public gfx::AnimationDelegate,
public OmniboxEditController,
public DropdownBarHostDelegate,
public TemplateURLServiceObserver,
@@ -347,6 +349,7 @@ class LocationBarView : public LocationBar,
void UpdateManagePasswordsIconAndBubble() override;
void UpdatePageActions() override;
void UpdateBookmarkStarVisibility() override;
+ void UpdateLocationBarVisibility(bool visible, bool animation) override;
bool ShowPageActionPopup(const extensions::Extension* extension,
bool grant_active_tab) override;
void UpdateOpenPDFInReaderPrompt() override;
@@ -382,6 +385,10 @@ class LocationBarView : public LocationBar,
const gfx::Point& press_pt,
const gfx::Point& p) override;
+ // gfx::AnimationDelegate:
+ void AnimationProgressed(const gfx::Animation* animation) override;
+ void AnimationEnded(const gfx::Animation* animation) override;
+
// OmniboxEditController:
void OnChanged() override;
void OnSetFocus() override;
@@ -467,6 +474,9 @@ class LocationBarView : public LocationBar,
// The star.
StarView* star_view_;
+ // Animation to control showing / hiding the location bar.
+ gfx::SlideAnimation size_animation_;
+
// Whether we're in popup mode. This value also controls whether the location
// bar is read-only.
const bool is_popup_mode_;
« no previous file with comments | « chrome/browser/ui/views/frame/browser_view.cc ('k') | chrome/browser/ui/views/location_bar/location_bar_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698