OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
3 * Copyright (C) 2013 Apple Inc. All rights reserved. | 3 * Copyright (C) 2013 Apple Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * | 8 * |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 556 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
567 | 567 |
568 String representation = externalRepresentation(element); | 568 String representation = externalRepresentation(element); |
569 if (representation.isEmpty()) { | 569 if (representation.isEmpty()) { |
570 exceptionState.throwDOMException(InvalidAccessError, "The element provid
ed has no external representation."); | 570 exceptionState.throwDOMException(InvalidAccessError, "The element provid
ed has no external representation."); |
571 return String(); | 571 return String(); |
572 } | 572 } |
573 | 573 |
574 return representation; | 574 return representation; |
575 } | 575 } |
576 | 576 |
577 size_t Internals::numberOfScopedHTMLStyleChildren(const Node* scope, ExceptionSt
ate& exceptionState) const | |
578 { | |
579 if (scope && (scope->isElementNode() || scope->isShadowRoot())) | |
580 return scope->numberOfScopedHTMLStyleChildren(); | |
581 | |
582 exceptionState.throwDOMException(InvalidAccessError, ExceptionMessages::argu
mentNullOrIncorrectType(1, "Node")); | |
583 return 0; | |
584 } | |
585 | |
586 PassRefPtrWillBeRawPtr<CSSComputedStyleDeclaration> Internals::computedStyleIncl
udingVisitedInfo(Node* node, ExceptionState& exceptionState) const | 577 PassRefPtrWillBeRawPtr<CSSComputedStyleDeclaration> Internals::computedStyleIncl
udingVisitedInfo(Node* node, ExceptionState& exceptionState) const |
587 { | 578 { |
588 if (!node) { | 579 if (!node) { |
589 exceptionState.throwDOMException(InvalidAccessError, ExceptionMessages::
argumentNullOrIncorrectType(1, "Node")); | 580 exceptionState.throwDOMException(InvalidAccessError, ExceptionMessages::
argumentNullOrIncorrectType(1, "Node")); |
590 return nullptr; | 581 return nullptr; |
591 } | 582 } |
592 | 583 |
593 bool allowVisitedStyle = true; | 584 bool allowVisitedStyle = true; |
594 return CSSComputedStyleDeclaration::create(node, allowVisitedStyle); | 585 return CSSComputedStyleDeclaration::create(node, allowVisitedStyle); |
595 } | 586 } |
(...skipping 1773 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2369 } else if (type == "none") { | 2360 } else if (type == "none") { |
2370 webtype = blink::ConnectionTypeNone; | 2361 webtype = blink::ConnectionTypeNone; |
2371 } else { | 2362 } else { |
2372 exceptionState.throwDOMException(NotFoundError, ExceptionMessages::faile
dToEnumerate("connection type", type)); | 2363 exceptionState.throwDOMException(NotFoundError, ExceptionMessages::faile
dToEnumerate("connection type", type)); |
2373 return; | 2364 return; |
2374 } | 2365 } |
2375 networkStateNotifier().setWebConnectionTypeForTest(webtype); | 2366 networkStateNotifier().setWebConnectionTypeForTest(webtype); |
2376 } | 2367 } |
2377 | 2368 |
2378 } // namespace WebCore | 2369 } // namespace WebCore |
OLD | NEW |