| Index: chrome/browser/ui/infobar.cc
|
| ===================================================================
|
| --- chrome/browser/ui/infobar.cc (revision 0)
|
| +++ chrome/browser/ui/infobar.cc (revision 0)
|
| @@ -0,0 +1,33 @@
|
| +// Copyright (c) 2011 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#include "chrome/browser/ui/infobar.h"
|
| +
|
| +namespace infobar {
|
| +
|
| +SkColor GetTopColor(InfoBarDelegate::Type infobar_type) {
|
| + // Yellow
|
| + static const SkColor kWarningBackgroundColorTop =
|
| + SkColorSetRGB(255, 242, 183);
|
| + // Gray
|
| + static const SkColor kPageActionBackgroundColorTop =
|
| + SkColorSetRGB(237, 237, 237);
|
| +
|
| + return (infobar_type == InfoBarDelegate::WARNING_TYPE) ?
|
| + kWarningBackgroundColorTop : kPageActionBackgroundColorTop;
|
| +}
|
| +
|
| +SkColor GetBottomColor(InfoBarDelegate::Type infobar_type) {
|
| + // Yellow
|
| + static const SkColor kWarningBackgroundColorBottom =
|
| + SkColorSetRGB(250, 230, 145);
|
| + // Gray
|
| + static const SkColor kPageActionBackgroundColorBottom =
|
| + SkColorSetRGB(217, 217, 217);
|
| +
|
| + return (infobar_type == InfoBarDelegate::WARNING_TYPE) ?
|
| + kWarningBackgroundColorBottom : kPageActionBackgroundColorBottom;
|
| +}
|
| +
|
| +} // namespace infobar
|
|
|