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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutThemeMac.mm

Issue 2309593002: Factor code from ThemeMac into ThemeMacPainter. (Closed)
Patch Set: none Created 4 years, 3 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/paint/ThemePainter.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
3 * Copyright (C) 2008, 2009 Google, Inc. 3 * Copyright (C) 2008, 2009 Google, Inc.
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 return false; 125 return false;
126 } 126 }
127 127
128 } // namespace 128 } // namespace
129 129
130 using namespace HTMLNames; 130 using namespace HTMLNames;
131 131
132 LayoutThemeMac::LayoutThemeMac() 132 LayoutThemeMac::LayoutThemeMac()
133 : LayoutTheme(platformTheme()) 133 : LayoutTheme(platformTheme())
134 , m_notificationObserver(AdoptNS, [[BlinkLayoutThemeNotificationObserver all oc] initWithTheme:this]) 134 , m_notificationObserver(AdoptNS, [[BlinkLayoutThemeNotificationObserver all oc] initWithTheme:this])
135 , m_painter(*this, platformTheme()) 135 , m_painter(*this)
136 { 136 {
137 [[NSNotificationCenter defaultCenter] addObserver:m_notificationObserver.get () 137 [[NSNotificationCenter defaultCenter] addObserver:m_notificationObserver.get ()
138 selector:@selector(systemColorsDidC hange:) 138 selector:@selector(systemColorsDidC hange:)
139 name:NSSystemColorsDidChangeNot ification 139 name:NSSystemColorsDidChangeNot ification
140 object:nil]; 140 object:nil];
141 } 141 }
142 142
143 LayoutThemeMac::~LayoutThemeMac() 143 LayoutThemeMac::~LayoutThemeMac()
144 { 144 {
145 [[NSNotificationCenter defaultCenter] removeObserver:m_notificationObserver. get()]; 145 [[NSNotificationCenter defaultCenter] removeObserver:m_notificationObserver. get()];
(...skipping 960 matching lines...) Expand 10 before | Expand all | Expand 10 after
1106 1106
1107 bool LayoutThemeMac::shouldUseFallbackTheme(const ComputedStyle& style) const 1107 bool LayoutThemeMac::shouldUseFallbackTheme(const ComputedStyle& style) const
1108 { 1108 {
1109 ControlPart part = style.appearance(); 1109 ControlPart part = style.appearance();
1110 if (part == CheckboxPart || part == RadioPart) 1110 if (part == CheckboxPart || part == RadioPart)
1111 return style.effectiveZoom() != 1; 1111 return style.effectiveZoom() != 1;
1112 return false; 1112 return false;
1113 } 1113 }
1114 1114
1115 } // namespace blink 1115 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/paint/ThemePainter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698