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

Side by Side Diff: ui/gfx/color_profile.cc

Issue 10448110: Adds monitor ICC profile support for win and mac (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Missed one hwnd reference Created 8 years, 6 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "color_profile.h"
6
7 namespace gfx {
8
9 void ColorProfile::GetColorProfile(gfx::NativeViewId parent_window,
10 std::vector<char>* profile) {
11 // Force data to leak so exit time destructors are not called.
abarth-chromium 2012/06/19 20:36:50 It's interesting that this code is called on diffe
tpayne 2012/06/19 21:44:52 Done.
12 static std::map<gfx::NativeViewId, std::vector<char> >& data =
13 *new std::map<gfx::NativeViewId, std::vector<char> >();
14
15 profile->clear();
16 std::vector<char> stored_profile;
17 if (data.find(parent_window) == data.end()) {
18 ReadProfile(parent_window, &stored_profile);
19 data[parent_window] = stored_profile;
20 }
21
22 profile->assign(data[parent_window].begin(), data[parent_window].end());
23 }
24
25 } // namespace gfx
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698