| 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 24 matching lines...) Expand all Loading... |
| 35 #include "bindings/core/v8/SerializedScriptValue.h" | 35 #include "bindings/core/v8/SerializedScriptValue.h" |
| 36 #include "bindings/core/v8/V8ThrowException.h" | 36 #include "bindings/core/v8/V8ThrowException.h" |
| 37 #include "core/InternalRuntimeFlags.h" | 37 #include "core/InternalRuntimeFlags.h" |
| 38 #include "core/animation/AnimationTimeline.h" | 38 #include "core/animation/AnimationTimeline.h" |
| 39 #include "core/css/StyleSheetContents.h" | 39 #include "core/css/StyleSheetContents.h" |
| 40 #include "core/css/resolver/StyleResolver.h" | 40 #include "core/css/resolver/StyleResolver.h" |
| 41 #include "core/css/resolver/StyleResolverStats.h" | 41 #include "core/css/resolver/StyleResolverStats.h" |
| 42 #include "core/css/resolver/ViewportStyleResolver.h" | 42 #include "core/css/resolver/ViewportStyleResolver.h" |
| 43 #include "core/dom/ClientRect.h" | 43 #include "core/dom/ClientRect.h" |
| 44 #include "core/dom/ClientRectList.h" | 44 #include "core/dom/ClientRectList.h" |
| 45 #include "core/dom/DOMArrayBuffer.h" |
| 45 #include "core/dom/DOMPoint.h" | 46 #include "core/dom/DOMPoint.h" |
| 46 #include "core/dom/DOMStringList.h" | 47 #include "core/dom/DOMStringList.h" |
| 47 #include "core/dom/Document.h" | 48 #include "core/dom/Document.h" |
| 48 #include "core/dom/DocumentMarker.h" | 49 #include "core/dom/DocumentMarker.h" |
| 49 #include "core/dom/DocumentMarkerController.h" | 50 #include "core/dom/DocumentMarkerController.h" |
| 50 #include "core/dom/Element.h" | 51 #include "core/dom/Element.h" |
| 51 #include "core/dom/ExceptionCode.h" | 52 #include "core/dom/ExceptionCode.h" |
| 52 #include "core/dom/Iterator.h" | 53 #include "core/dom/Iterator.h" |
| 53 #include "core/dom/NodeRenderStyle.h" | 54 #include "core/dom/NodeRenderStyle.h" |
| 54 #include "core/dom/PseudoElement.h" | 55 #include "core/dom/PseudoElement.h" |
| (...skipping 1908 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1963 } | 1964 } |
| 1964 if (cursor.imageScaleFactor() != 1) { | 1965 if (cursor.imageScaleFactor() != 1) { |
| 1965 result.appendLiteral(" scale="); | 1966 result.appendLiteral(" scale="); |
| 1966 NumberToStringBuffer buffer; | 1967 NumberToStringBuffer buffer; |
| 1967 result.append(numberToFixedPrecisionString(cursor.imageScaleFactor(), 8,
buffer, true)); | 1968 result.append(numberToFixedPrecisionString(cursor.imageScaleFactor(), 8,
buffer, true)); |
| 1968 } | 1969 } |
| 1969 | 1970 |
| 1970 return result.toString(); | 1971 return result.toString(); |
| 1971 } | 1972 } |
| 1972 | 1973 |
| 1973 PassRefPtr<ArrayBuffer> Internals::serializeObject(PassRefPtr<SerializedScriptVa
lue> value) const | 1974 PassRefPtr<DOMArrayBuffer> Internals::serializeObject(PassRefPtr<SerializedScrip
tValue> value) const |
| 1974 { | 1975 { |
| 1975 String stringValue = value->toWireString(); | 1976 String stringValue = value->toWireString(); |
| 1976 RefPtr<ArrayBuffer> buffer = ArrayBuffer::createUninitialized(stringValue.le
ngth(), sizeof(UChar)); | 1977 RefPtr<ArrayBuffer> buffer = ArrayBuffer::createUninitialized(stringValue.le
ngth(), sizeof(UChar)); |
| 1977 stringValue.copyTo(static_cast<UChar*>(buffer->data()), 0, stringValue.lengt
h()); | 1978 stringValue.copyTo(static_cast<UChar*>(buffer->data()), 0, stringValue.lengt
h()); |
| 1978 return buffer.release(); | 1979 return DOMArrayBuffer::create(buffer.release()); |
| 1979 } | 1980 } |
| 1980 | 1981 |
| 1981 PassRefPtr<SerializedScriptValue> Internals::deserializeBuffer(PassRefPtr<ArrayB
uffer> buffer) const | 1982 PassRefPtr<SerializedScriptValue> Internals::deserializeBuffer(PassRefPtr<DOMArr
ayBuffer> buffer) const |
| 1982 { | 1983 { |
| 1983 String value(static_cast<const UChar*>(buffer->data()), buffer->byteLength()
/ sizeof(UChar)); | 1984 String value(static_cast<const UChar*>(buffer->data()), buffer->byteLength()
/ sizeof(UChar)); |
| 1984 return SerializedScriptValue::createFromWire(value); | 1985 return SerializedScriptValue::createFromWire(value); |
| 1985 } | 1986 } |
| 1986 | 1987 |
| 1987 void Internals::forceReload(bool endToEnd) | 1988 void Internals::forceReload(bool endToEnd) |
| 1988 { | 1989 { |
| 1989 frame()->loader().reload(endToEnd ? EndToEndReload : NormalReload); | 1990 frame()->loader().reload(endToEnd ? EndToEndReload : NormalReload); |
| 1990 } | 1991 } |
| 1991 | 1992 |
| (...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2289 | 2290 |
| 2290 toHTMLPlugInElement(element)->setUsePlaceholderContent(true); | 2291 toHTMLPlugInElement(element)->setUsePlaceholderContent(true); |
| 2291 } | 2292 } |
| 2292 | 2293 |
| 2293 Iterator* Internals::iterator(ScriptState* scriptState, ExceptionState& exceptio
nState) | 2294 Iterator* Internals::iterator(ScriptState* scriptState, ExceptionState& exceptio
nState) |
| 2294 { | 2295 { |
| 2295 return new InternalsIterator; | 2296 return new InternalsIterator; |
| 2296 } | 2297 } |
| 2297 | 2298 |
| 2298 } // namespace blink | 2299 } // namespace blink |
| OLD | NEW |