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

Side by Side Diff: chrome/browser/ui/views/content_setting_bubble_contents.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 (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 "chrome/browser/ui/views/content_setting_bubble_contents.h" 5 #include "chrome/browser/ui/views/content_setting_bubble_contents.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 } 111 }
112 112
113 113
114 // ContentSettingBubbleContents::MediaMenuParts ------------------------------- 114 // ContentSettingBubbleContents::MediaMenuParts -------------------------------
115 115
116 struct ContentSettingBubbleContents::MediaMenuParts { 116 struct ContentSettingBubbleContents::MediaMenuParts {
117 explicit MediaMenuParts(content::MediaStreamType type); 117 explicit MediaMenuParts(content::MediaStreamType type);
118 ~MediaMenuParts(); 118 ~MediaMenuParts();
119 119
120 content::MediaStreamType type; 120 content::MediaStreamType type;
121 scoped_ptr<ui::SimpleMenuModel> menu_model; 121 std::unique_ptr<ui::SimpleMenuModel> menu_model;
122 122
123 private: 123 private:
124 DISALLOW_COPY_AND_ASSIGN(MediaMenuParts); 124 DISALLOW_COPY_AND_ASSIGN(MediaMenuParts);
125 }; 125 };
126 126
127 ContentSettingBubbleContents::MediaMenuParts::MediaMenuParts( 127 ContentSettingBubbleContents::MediaMenuParts::MediaMenuParts(
128 content::MediaStreamType type) 128 content::MediaStreamType type)
129 : type(type) {} 129 : type(type) {}
130 130
131 ContentSettingBubbleContents::MediaMenuParts::~MediaMenuParts() {} 131 ContentSettingBubbleContents::MediaMenuParts::~MediaMenuParts() {}
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
488 // Make sure the width is at least kMinMediaMenuButtonWidth. The 488 // Make sure the width is at least kMinMediaMenuButtonWidth. The
489 // maximum width will be clamped by kMaxContentsWidth of the view. 489 // maximum width will be clamped by kMaxContentsWidth of the view.
490 menu_width = std::max(kMinMediaMenuButtonWidth, menu_width + margins); 490 menu_width = std::max(kMinMediaMenuButtonWidth, menu_width + margins);
491 491
492 for (MediaMenuPartsMap::const_iterator i = media_menus_.begin(); 492 for (MediaMenuPartsMap::const_iterator i = media_menus_.begin();
493 i != media_menus_.end(); ++i) { 493 i != media_menus_.end(); ++i) {
494 i->first->SetMinSize(gfx::Size(menu_width, 0)); 494 i->first->SetMinSize(gfx::Size(menu_width, 0));
495 i->first->SetMaxSize(gfx::Size(menu_width, 0)); 495 i->first->SetMaxSize(gfx::Size(menu_width, 0));
496 } 496 }
497 } 497 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/content_setting_bubble_contents.h ('k') | chrome/browser/ui/views/create_application_shortcut_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698