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

Side by Side Diff: chrome/browser/infobars/infobar_container.cc

Issue 10843071: Create chrome/browser/api directory. Move infobar delegates used by Autofill to the directory. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address review comments. Created 8 years, 4 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 | « chrome/browser/infobars/infobar.cc ('k') | chrome/browser/infobars/infobar_delegate.h » ('j') | 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "build/build_config.h" 5 #include "build/build_config.h"
6 6
7 // TODO(pkasting): Port Mac to use this. 7 // TODO(pkasting): Port Mac to use this.
8 #if defined(TOOLKIT_VIEWS) || defined(TOOLKIT_GTK) 8 #if defined(TOOLKIT_VIEWS) || defined(TOOLKIT_GTK)
9 9
10 #include "chrome/browser/infobars/infobar_container.h" 10 #include "chrome/browser/infobars/infobar_container.h"
11 11
12 #include <algorithm> 12 #include <algorithm>
13 13
14 #include "base/logging.h" 14 #include "base/logging.h"
15 #include "chrome/browser/api/infobars/infobar_delegate.h"
15 #include "chrome/browser/infobars/infobar.h" 16 #include "chrome/browser/infobars/infobar.h"
16 #include "chrome/browser/infobars/infobar_delegate.h"
17 #include "chrome/browser/infobars/infobar_tab_helper.h" 17 #include "chrome/browser/infobars/infobar_tab_helper.h"
18 #include "chrome/common/chrome_notification_types.h" 18 #include "chrome/common/chrome_notification_types.h"
19 #include "content/public/browser/notification_details.h" 19 #include "content/public/browser/notification_details.h"
20 #include "content/public/browser/notification_source.h" 20 #include "content/public/browser/notification_source.h"
21 #include "ui/base/animation/slide_animation.h" 21 #include "ui/base/animation/slide_animation.h"
22 22
23 InfoBarContainer::Delegate::~Delegate() { 23 InfoBarContainer::Delegate::~Delegate() {
24 } 24 }
25 25
26 InfoBarContainer::InfoBarContainer(Delegate* delegate) 26 InfoBarContainer::InfoBarContainer(Delegate* delegate)
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 return InfoBar::kDefaultArrowTargetHeight; 211 return InfoBar::kDefaultArrowTargetHeight;
212 // When the first infobar is animating closed, we animate the second infobar's 212 // When the first infobar is animating closed, we animate the second infobar's
213 // arrow target height from the default to the top target height. Note that 213 // arrow target height from the default to the top target height. Note that
214 // the animation values here are going from 1.0 -> 0.0 as the top bar closes. 214 // the animation values here are going from 1.0 -> 0.0 as the top bar closes.
215 return top_arrow_target_height_ + static_cast<int>( 215 return top_arrow_target_height_ + static_cast<int>(
216 (InfoBar::kDefaultArrowTargetHeight - top_arrow_target_height_) * 216 (InfoBar::kDefaultArrowTargetHeight - top_arrow_target_height_) *
217 first_infobar_animation.GetCurrentValue()); 217 first_infobar_animation.GetCurrentValue());
218 } 218 }
219 219
220 #endif // TOOLKIT_VIEWS || defined(TOOLKIT_GTK) 220 #endif // TOOLKIT_VIEWS || defined(TOOLKIT_GTK)
OLDNEW
« no previous file with comments | « chrome/browser/infobars/infobar.cc ('k') | chrome/browser/infobars/infobar_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698