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

Side by Side Diff: sky/engine/core/dom/DOMURL.cpp

Issue 1214513003: Remove references into sky/engine/core/fetch (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 5 months 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
« no previous file with comments | « sky/engine/core/css/resolver/StyleResourceLoader.cpp ('k') | sky/engine/core/dom/Document.h » ('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 * 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 12 matching lines...) Expand all
23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 */ 25 */
26 26
27 #include "sky/engine/core/dom/DOMURL.h" 27 #include "sky/engine/core/dom/DOMURL.h"
28 28
29 #include "sky/engine/bindings/exception_messages.h" 29 #include "sky/engine/bindings/exception_messages.h"
30 #include "sky/engine/bindings/exception_state.h" 30 #include "sky/engine/bindings/exception_state.h"
31 #include "sky/engine/core/dom/ExceptionCode.h" 31 #include "sky/engine/core/dom/ExceptionCode.h"
32 #include "sky/engine/core/dom/ExecutionContext.h" 32 #include "sky/engine/core/dom/ExecutionContext.h"
33 #include "sky/engine/core/fetch/MemoryCache.h"
34 #include "sky/engine/wtf/MainThread.h" 33 #include "sky/engine/wtf/MainThread.h"
35 34
36 namespace blink { 35 namespace blink {
37 36
38 DOMURL::DOMURL(const String& url, const KURL& base, ExceptionState& exceptionSta te) 37 DOMURL::DOMURL(const String& url, const KURL& base, ExceptionState& exceptionSta te)
39 { 38 {
40 if (!base.isValid()) 39 if (!base.isValid())
41 exceptionState.ThrowDOMException(SyntaxError, "Invalid base URL"); 40 exceptionState.ThrowDOMException(SyntaxError, "Invalid base URL");
42 41
43 m_url = KURL(base, url); 42 m_url = KURL(base, url);
44 if (!m_url.isValid()) 43 if (!m_url.isValid())
45 exceptionState.ThrowDOMException(SyntaxError, "Invalid URL"); 44 exceptionState.ThrowDOMException(SyntaxError, "Invalid URL");
46 } 45 }
47 46
48 void DOMURL::setInput(const String& value) 47 void DOMURL::setInput(const String& value)
49 { 48 {
50 KURL url(blankURL(), value); 49 KURL url(blankURL(), value);
51 if (url.isValid()) { 50 if (url.isValid()) {
52 m_url = url; 51 m_url = url;
53 m_input = String(); 52 m_input = String();
54 } else { 53 } else {
55 m_url = KURL(); 54 m_url = KURL();
56 m_input = value; 55 m_input = value;
57 } 56 }
58 } 57 }
59 58
60 } // namespace blink 59 } // namespace blink
OLDNEW
« no previous file with comments | « sky/engine/core/css/resolver/StyleResourceLoader.cpp ('k') | sky/engine/core/dom/Document.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698