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

Side by Side Diff: chrome/browser/ui/views/profiles/profile_chooser_view.cc

Issue 1865213004: Convert //chrome/browser/ui from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/profiles/profile_chooser_view.h" 5 #include "chrome/browser/ui/views/profiles/profile_chooser_view.h"
6 6
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "base/metrics/user_metrics.h" 8 #include "base/metrics/user_metrics.h"
9 #include "base/strings/utf_string_conversions.h" 9 #include "base/strings/utf_string_conversions.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 215
216 void Initialize(views::View* title_view, views::View* main_view); 216 void Initialize(views::View* title_view, views::View* main_view);
217 217
218 private: 218 private:
219 // views::View: 219 // views::View:
220 void ViewHierarchyChanged( 220 void ViewHierarchyChanged(
221 const ViewHierarchyChangedDetails& details) override; 221 const ViewHierarchyChangedDetails& details) override;
222 222
223 // The title itself and the overlaped widget that contains it. 223 // The title itself and the overlaped widget that contains it.
224 views::View* title_view_ = nullptr; // Not owned. 224 views::View* title_view_ = nullptr; // Not owned.
225 scoped_ptr<views::Widget> title_widget_; 225 std::unique_ptr<views::Widget> title_widget_;
226 226
227 DISALLOW_COPY_AND_ASSIGN(HostView); 227 DISALLOW_COPY_AND_ASSIGN(HostView);
228 }; 228 };
229 229
230 void HostView::Initialize(views::View* title_view, views::View* main_view) { 230 void HostView::Initialize(views::View* title_view, views::View* main_view) {
231 title_view_ = title_view; 231 title_view_ = title_view;
232 AddChildView(main_view); 232 AddChildView(main_view);
233 SetLayoutManager(new views::FillLayout()); 233 SetLayoutManager(new views::FillLayout());
234 } 234 }
235 235
(...skipping 1642 matching lines...) Expand 10 before | Expand all | Expand 10 after
1878 IncognitoModePrefs::GetAvailability(browser_->profile()->GetPrefs()) != 1878 IncognitoModePrefs::GetAvailability(browser_->profile()->GetPrefs()) !=
1879 IncognitoModePrefs::DISABLED; 1879 IncognitoModePrefs::DISABLED;
1880 return incognito_available && !browser_->profile()->IsGuestSession(); 1880 return incognito_available && !browser_->profile()->IsGuestSession();
1881 } 1881 }
1882 1882
1883 void ProfileChooserView::PostActionPerformed( 1883 void ProfileChooserView::PostActionPerformed(
1884 ProfileMetrics::ProfileDesktopMenu action_performed) { 1884 ProfileMetrics::ProfileDesktopMenu action_performed) {
1885 ProfileMetrics::LogProfileDesktopMenu(action_performed, gaia_service_type_); 1885 ProfileMetrics::LogProfileDesktopMenu(action_performed, gaia_service_type_);
1886 gaia_service_type_ = signin::GAIA_SERVICE_TYPE_NONE; 1886 gaia_service_type_ = signin::GAIA_SERVICE_TYPE_NONE;
1887 } 1887 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698