| OLD | NEW |
| 1 /* | 1 /* |
| 2 * CSS Media Query | 2 * CSS Media Query |
| 3 * | 3 * |
| 4 * Copyright (C) 2006 Kimmo Kinnunen <kimmo.t.kinnunen@nokia.com>. | 4 * Copyright (C) 2006 Kimmo Kinnunen <kimmo.t.kinnunen@nokia.com>. |
| 5 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). | 5 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). |
| 6 * Copyright (C) 2013 Apple Inc. All rights reserved. | 6 * Copyright (C) 2013 Apple Inc. All rights reserved. |
| 7 * | 7 * |
| 8 * Redistribution and use in source and binary forms, with or without | 8 * Redistribution and use in source and binary forms, with or without |
| 9 * modification, are permitted provided that the following conditions | 9 * modification, are permitted provided that the following conditions |
| 10 * are met: | 10 * are met: |
| (...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 280 && ((!other.m_expValue.isValid() && !m_expValue.isValid()) | 280 && ((!other.m_expValue.isValid() && !m_expValue.isValid()) |
| 281 || (other.m_expValue.isValid() && m_expValue.isValid() && other.m_ex
pValue.equals(m_expValue))); | 281 || (other.m_expValue.isValid() && m_expValue.isValid() && other.m_ex
pValue.equals(m_expValue))); |
| 282 } | 282 } |
| 283 | 283 |
| 284 String MediaQueryExp::serialize() const | 284 String MediaQueryExp::serialize() const |
| 285 { | 285 { |
| 286 StringBuilder result; | 286 StringBuilder result; |
| 287 result.append('('); | 287 result.append('('); |
| 288 result.append(m_mediaFeature.lower()); | 288 result.append(m_mediaFeature.lower()); |
| 289 if (m_expValue.isValid()) { | 289 if (m_expValue.isValid()) { |
| 290 result.appendLiteral(": "); | 290 result.append(": "); |
| 291 result.append(m_expValue.cssText()); | 291 result.append(m_expValue.cssText()); |
| 292 } | 292 } |
| 293 result.append(')'); | 293 result.append(')'); |
| 294 | 294 |
| 295 return result.toString(); | 295 return result.toString(); |
| 296 } | 296 } |
| 297 | 297 |
| 298 static inline String printNumber(double number) | 298 static inline String printNumber(double number) |
| 299 { | 299 { |
| 300 return Decimal::fromDouble(number).toString(); | 300 return Decimal::fromDouble(number).toString(); |
| (...skipping 10 matching lines...) Expand all Loading... |
| 311 output.append('/'); | 311 output.append('/'); |
| 312 output.append(printNumber(denominator)); | 312 output.append(printNumber(denominator)); |
| 313 } else if (isID) { | 313 } else if (isID) { |
| 314 output.append(getValueName(id)); | 314 output.append(getValueName(id)); |
| 315 } | 315 } |
| 316 | 316 |
| 317 return output.toString(); | 317 return output.toString(); |
| 318 } | 318 } |
| 319 | 319 |
| 320 } // namespace blink | 320 } // namespace blink |
| OLD | NEW |