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

Side by Side Diff: chrome/browser/ui/views/bookmarks/bookmark_sync_promo_view.cc

Issue 1407093007: Autofill: Add legal message footer to save credit card bubble. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Change interface for retrieving lines + give each line its own StyledLabel. Created 5 years, 1 month 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/views/bookmarks/bookmark_sync_promo_view.h" 5 #include "chrome/browser/ui/views/bookmarks/bookmark_sync_promo_view.h"
6 6
7 #include "base/strings/string16.h" 7 #include "base/strings/string16.h"
8 #include "chrome/browser/ui/bookmarks/bookmark_bubble_delegate.h" 8 #include "chrome/browser/ui/bookmarks/bookmark_bubble_delegate.h"
9 #include "chrome/grit/generated_resources.h" 9 #include "chrome/grit/generated_resources.h"
10 #include "third_party/skia/include/core/SkColor.h" 10 #include "third_party/skia/include/core/SkColor.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 promo_label->AddStyleRange(after_link_range, promo_style); 63 promo_label->AddStyleRange(after_link_range, promo_style);
64 64
65 views::BoxLayout* layout = new views::BoxLayout(views::BoxLayout::kVertical, 65 views::BoxLayout* layout = new views::BoxLayout(views::BoxLayout::kVertical,
66 views::kButtonHEdgeMarginNew, 66 views::kButtonHEdgeMarginNew,
67 views::kPanelVertMargin, 67 views::kPanelVertMargin,
68 0); 68 0);
69 SetLayoutManager(layout); 69 SetLayoutManager(layout);
70 AddChildView(promo_label); 70 AddChildView(promo_label);
71 } 71 }
72 72
73 void BookmarkSyncPromoView::StyledLabelLinkClicked(const gfx::Range& range, 73 void BookmarkSyncPromoView::StyledLabelLinkClicked(views::StyledLabel& label,
74 const gfx::Range& range,
74 int event_flags) { 75 int event_flags) {
75 delegate_->OnSignInLinkClicked(); 76 delegate_->OnSignInLinkClicked();
76 } 77 }
77 78
78 const char* BookmarkSyncPromoView::GetClassName() const { 79 const char* BookmarkSyncPromoView::GetClassName() const {
79 return "BookmarkSyncPromoView"; 80 return "BookmarkSyncPromoView";
80 } 81 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698