| 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 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 50 exceptionState.throwTypeError("Invalid URL"); | 50 exceptionState.throwTypeError("Invalid URL"); |
| 51 } | 51 } |
| 52 | 52 |
| 53 DOMURL::~DOMURL() {} | 53 DOMURL::~DOMURL() {} |
| 54 | 54 |
| 55 DEFINE_TRACE(DOMURL) { | 55 DEFINE_TRACE(DOMURL) { |
| 56 visitor->trace(m_searchParams); | 56 visitor->trace(m_searchParams); |
| 57 } | 57 } |
| 58 | 58 |
| 59 void DOMURL::setInput(const String& value) { | 59 void DOMURL::setInput(const String& value) { |
| 60 KURL url(blankURL(), value); | 60 KURL url(KURL(ParsedURLString, kAboutBlankUrl), value); |
| 61 if (url.isValid()) { | 61 if (url.isValid()) { |
| 62 m_url = url; | 62 m_url = url; |
| 63 m_input = String(); | 63 m_input = String(); |
| 64 } else { | 64 } else { |
| 65 m_url = KURL(); | 65 m_url = KURL(); |
| 66 m_input = value; | 66 m_input = value; |
| 67 } | 67 } |
| 68 update(); | 68 update(); |
| 69 } | 69 } |
| 70 | 70 |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 return; | 107 return; |
| 108 | 108 |
| 109 AutoReset<bool> scope(&m_isInUpdate, true); | 109 AutoReset<bool> scope(&m_isInUpdate, true); |
| 110 #if DCHECK_IS_ON() | 110 #if DCHECK_IS_ON() |
| 111 DCHECK_EQ(m_searchParams->urlObject(), this); | 111 DCHECK_EQ(m_searchParams->urlObject(), this); |
| 112 #endif | 112 #endif |
| 113 m_searchParams->setInput(queryString); | 113 m_searchParams->setInput(queryString); |
| 114 } | 114 } |
| 115 | 115 |
| 116 } // namespace blink | 116 } // namespace blink |
| OLD | NEW |