| Index: ui/gfx/color_space_mac.mm
|
| diff --git a/ui/gfx/color_profile_mac.mm b/ui/gfx/color_space_mac.mm
|
| similarity index 76%
|
| rename from ui/gfx/color_profile_mac.mm
|
| rename to ui/gfx/color_space_mac.mm
|
| index e8be1dfdc26d67cd7d00afef97d92160a30ad195..834760601171787ce93cbc553c930539bbf166e0 100644
|
| --- a/ui/gfx/color_profile_mac.mm
|
| +++ b/ui/gfx/color_space_mac.mm
|
| @@ -2,7 +2,7 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| -#include "ui/gfx/color_profile.h"
|
| +#include "ui/gfx/color_space.h"
|
|
|
| #import <Cocoa/Cocoa.h>
|
| #include <stddef.h>
|
| @@ -14,19 +14,19 @@
|
| namespace gfx {
|
|
|
| // static
|
| -ColorProfile ColorProfile::GetFromBestMonitor() {
|
| - ColorProfile profile;
|
| +ColorSpace ColorSpace::FromBestMonitor() {
|
| + ColorSpace color_space;
|
| CGColorSpaceRef monitor_color_space(base::mac::GetSystemColorSpace());
|
| base::ScopedCFTypeRef<CFDataRef> icc_profile(
|
| CGColorSpaceCopyICCProfile(monitor_color_space));
|
| if (!icc_profile)
|
| - return profile;
|
| + return color_space;
|
| size_t length = CFDataGetLength(icc_profile);
|
| if (!IsValidProfileLength(length))
|
| - return profile;
|
| + return color_space;
|
| const unsigned char* data = CFDataGetBytePtr(icc_profile);
|
| - profile.profile_.assign(data, data + length);
|
| - return profile;
|
| + color_space.icc_profile_.assign(data, data + length);
|
| + return color_space;
|
| }
|
|
|
| } // namespace gfx
|
|
|