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

Side by Side Diff: chrome/browser/ui/webui/favicon_source.cc

Issue 1731483003: chrome: Add out-of-line copy ctors for complex classes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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/webui/favicon_source.h" 5 #include "chrome/browser/ui/webui/favicon_source.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 24 matching lines...) Expand all
35 const content::URLDataSource::GotDataCallback& cb, 35 const content::URLDataSource::GotDataCallback& cb,
36 const GURL& path, 36 const GURL& path,
37 int size, 37 int size,
38 float scale) 38 float scale)
39 : callback(cb), 39 : callback(cb),
40 request_path(path), 40 request_path(path),
41 size_in_dip(size), 41 size_in_dip(size),
42 device_scale_factor(scale) { 42 device_scale_factor(scale) {
43 } 43 }
44 44
45 FaviconSource::IconRequest::IconRequest(const IconRequest& other) = default;
46
45 FaviconSource::IconRequest::~IconRequest() { 47 FaviconSource::IconRequest::~IconRequest() {
46 } 48 }
47 49
48 FaviconSource::FaviconSource(Profile* profile, IconType type) 50 FaviconSource::FaviconSource(Profile* profile, IconType type)
49 : profile_(profile->GetOriginalProfile()), 51 : profile_(profile->GetOriginalProfile()),
50 icon_types_(type == FAVICON ? favicon_base::FAVICON 52 icon_types_(type == FAVICON ? favicon_base::FAVICON
51 : favicon_base::TOUCH_PRECOMPOSED_ICON | 53 : favicon_base::TOUCH_PRECOMPOSED_ICON |
52 favicon_base::TOUCH_ICON | 54 favicon_base::TOUCH_ICON |
53 favicon_base::FAVICON) {} 55 favicon_base::FAVICON) {}
54 56
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
202 ui::ScaleFactor resource_scale_factor = 204 ui::ScaleFactor resource_scale_factor =
203 ui::GetSupportedScaleFactor(icon_request.device_scale_factor); 205 ui::GetSupportedScaleFactor(icon_request.device_scale_factor);
204 default_favicon = 206 default_favicon =
205 ResourceBundle::GetSharedInstance().LoadDataResourceBytesForScale( 207 ResourceBundle::GetSharedInstance().LoadDataResourceBytesForScale(
206 resource_id, resource_scale_factor); 208 resource_id, resource_scale_factor);
207 default_favicons_[favicon_index] = default_favicon; 209 default_favicons_[favicon_index] = default_favicon;
208 } 210 }
209 211
210 icon_request.callback.Run(default_favicon); 212 icon_request.callback.Run(default_favicon);
211 } 213 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698