OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
3 * Copyright (C) 2012 Motorola Mobility Inc. | 3 * Copyright (C) 2012 Motorola Mobility Inc. |
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 "core/fileapi/Blob.h" | 35 #include "core/fileapi/Blob.h" |
36 #include "core/html/PublicURLManager.h" | 36 #include "core/html/PublicURLManager.h" |
37 #include "platform/blob/BlobURL.h" | 37 #include "platform/blob/BlobURL.h" |
38 #include "platform/weborigin/SecurityOrigin.h" | 38 #include "platform/weborigin/SecurityOrigin.h" |
39 #include "wtf/MainThread.h" | 39 #include "wtf/MainThread.h" |
40 | 40 |
41 namespace blink { | 41 namespace blink { |
42 | 42 |
43 DOMURL::DOMURL(const String& url, const KURL& base, ExceptionState& exceptionSta
te) | 43 DOMURL::DOMURL(const String& url, const KURL& base, ExceptionState& exceptionSta
te) |
44 { | 44 { |
45 ScriptWrappable::init(this); | |
46 if (!base.isValid()) | 45 if (!base.isValid()) |
47 exceptionState.throwDOMException(SyntaxError, "Invalid base URL"); | 46 exceptionState.throwDOMException(SyntaxError, "Invalid base URL"); |
48 | 47 |
49 m_url = KURL(base, url); | 48 m_url = KURL(base, url); |
50 if (!m_url.isValid()) | 49 if (!m_url.isValid()) |
51 exceptionState.throwDOMException(SyntaxError, "Invalid URL"); | 50 exceptionState.throwDOMException(SyntaxError, "Invalid URL"); |
52 } | 51 } |
53 | 52 |
54 void DOMURL::setInput(const String& value) | 53 void DOMURL::setInput(const String& value) |
55 { | 54 { |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 | 96 |
98 void DOMURL::revokeObjectUUID(ExecutionContext* executionContext, const String&
uuid) | 97 void DOMURL::revokeObjectUUID(ExecutionContext* executionContext, const String&
uuid) |
99 { | 98 { |
100 if (!executionContext) | 99 if (!executionContext) |
101 return; | 100 return; |
102 | 101 |
103 executionContext->publicURLManager().revoke(uuid); | 102 executionContext->publicURLManager().revoke(uuid); |
104 } | 103 } |
105 | 104 |
106 } // namespace blink | 105 } // namespace blink |
OLD | NEW |