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

Side by Side Diff: Source/core/css/MediaList.cpp

Issue 72363002: Rename es => exceptionState in other than bindings/ (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Retry Created 7 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/css/FontFaceSet.cpp ('k') | Source/core/css/PropertySetCSSStyleDeclaration.cpp » ('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 * (C) 1999-2003 Lars Knoll (knoll@kde.org) 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org)
3 * Copyright (C) 2004, 2006, 2010, 2012 Apple Inc. All rights reserved. 3 * Copyright (C) 2004, 2006, 2010, 2012 Apple Inc. All rights reserved.
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 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 } 189 }
190 190
191 String MediaList::item(unsigned index) const 191 String MediaList::item(unsigned index) const
192 { 192 {
193 const Vector<OwnPtr<MediaQuery> >& queries = m_mediaQueries->queryVector(); 193 const Vector<OwnPtr<MediaQuery> >& queries = m_mediaQueries->queryVector();
194 if (index < queries.size()) 194 if (index < queries.size())
195 return queries[index]->cssText(); 195 return queries[index]->cssText();
196 return String(); 196 return String();
197 } 197 }
198 198
199 void MediaList::deleteMedium(const String& medium, ExceptionState& es) 199 void MediaList::deleteMedium(const String& medium, ExceptionState& exceptionStat e)
200 { 200 {
201 CSSStyleSheet::RuleMutationScope mutationScope(m_parentRule); 201 CSSStyleSheet::RuleMutationScope mutationScope(m_parentRule);
202 202
203 bool success = m_mediaQueries->remove(medium); 203 bool success = m_mediaQueries->remove(medium);
204 if (!success) { 204 if (!success) {
205 es.throwUninformativeAndGenericDOMException(NotFoundError); 205 exceptionState.throwUninformativeAndGenericDOMException(NotFoundError);
206 return; 206 return;
207 } 207 }
208 if (m_parentStyleSheet) 208 if (m_parentStyleSheet)
209 m_parentStyleSheet->didMutate(); 209 m_parentStyleSheet->didMutate();
210 } 210 }
211 211
212 void MediaList::appendMedium(const String& medium, ExceptionState& es) 212 void MediaList::appendMedium(const String& medium, ExceptionState& exceptionStat e)
213 { 213 {
214 CSSStyleSheet::RuleMutationScope mutationScope(m_parentRule); 214 CSSStyleSheet::RuleMutationScope mutationScope(m_parentRule);
215 215
216 bool success = m_mediaQueries->add(medium); 216 bool success = m_mediaQueries->add(medium);
217 if (!success) { 217 if (!success) {
218 es.throwUninformativeAndGenericDOMException(InvalidCharacterError); 218 exceptionState.throwUninformativeAndGenericDOMException(InvalidCharacter Error);
219 return; 219 return;
220 } 220 }
221 221
222 if (m_parentStyleSheet) 222 if (m_parentStyleSheet)
223 m_parentStyleSheet->didMutate(); 223 m_parentStyleSheet->didMutate();
224 } 224 }
225 225
226 void MediaList::reattach(MediaQuerySet* mediaQueries) 226 void MediaList::reattach(MediaQuerySet* mediaQueries)
227 { 227 {
228 ASSERT(mediaQueries); 228 ASSERT(mediaQueries);
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
285 CSSPrimitiveValue* primitiveValue = toCSSPrimitiveValue(cssV alue); 285 CSSPrimitiveValue* primitiveValue = toCSSPrimitiveValue(cssV alue);
286 if (primitiveValue->isDotsPerInch() || primitiveValue->isDot sPerCentimeter()) 286 if (primitiveValue->isDotsPerInch() || primitiveValue->isDot sPerCentimeter())
287 addResolutionWarningMessageToConsole(document, mediaQuer ySet->mediaText(), primitiveValue); 287 addResolutionWarningMessageToConsole(document, mediaQuer ySet->mediaText(), primitiveValue);
288 } 288 }
289 } 289 }
290 } 290 }
291 } 291 }
292 } 292 }
293 293
294 } 294 }
OLDNEW
« no previous file with comments | « Source/core/css/FontFaceSet.cpp ('k') | Source/core/css/PropertySetCSSStyleDeclaration.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698