| Index: ui/gfx/color_profile.cc
|
| diff --git a/ui/gfx/color_profile.cc b/ui/gfx/color_profile.cc
|
| index 220d993599d09cfb4ed20a0b2433562db663de85..42d6967a056a4161d54e75fca80b4a8d78cba635 100644
|
| --- a/ui/gfx/color_profile.cc
|
| +++ b/ui/gfx/color_profile.cc
|
| @@ -7,23 +7,27 @@
|
|
|
| namespace gfx {
|
|
|
| -#if defined(OS_WIN) || (defined(OS_MACOSX) && !defined(OS_IOS))
|
| -void ReadColorProfile(std::vector<char>* profile);
|
| -#else
|
| -void ReadColorProfile(std::vector<char>* profile) { }
|
| -GFX_EXPORT bool GetDisplayColorProfile(const gfx::Rect& bounds,
|
| - std::vector<char>* profile) {
|
| - // TODO(port): consider screen color profile support.
|
| - return false;
|
| +namespace {
|
| +static const size_t kMinProfileLength = 128;
|
| +static const size_t kMaxProfileLength = 4 * 1024 * 1024;
|
| }
|
| -#endif
|
|
|
| -ColorProfile::ColorProfile() {
|
| - // TODO: support multiple monitors.
|
| - ReadColorProfile(&profile_);
|
| +ColorProfile::ColorProfile() = default;
|
| +ColorProfile::ColorProfile(ColorProfile&& other) = default;
|
| +ColorProfile::ColorProfile(const ColorProfile& other) = default;
|
| +ColorProfile& ColorProfile::operator=(const ColorProfile& other) = default;
|
| +ColorProfile::~ColorProfile() = default;
|
| +
|
| +#if !defined(OS_WIN) && !defined(OS_MACOSX)
|
| +// static
|
| +ColorProfile ColorProfile::GetFromBestMonitor() {
|
| + return ColorProfile();
|
| }
|
| +#endif
|
|
|
| -ColorProfile::~ColorProfile() {
|
| +// static
|
| +bool ColorProfile::IsValidProfileLength(size_t length) {
|
| + return length >= kMinProfileLength && length <= kMaxProfileLength;
|
| }
|
|
|
| } // namespace gfx
|
|
|