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

Side by Side Diff: third_party/WebKit/Source/web/WebInputElement.cpp

Issue 1865813002: Remove RawPtr from Source/web/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased Created 4 years, 8 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 int WebInputElement::defaultMaxLength() 137 int WebInputElement::defaultMaxLength()
138 { 138 {
139 return HTMLInputElement::maximumLength; 139 return HTMLInputElement::maximumLength;
140 } 140 }
141 141
142 void WebInputElement::setShouldRevealPassword(bool value) 142 void WebInputElement::setShouldRevealPassword(bool value)
143 { 143 {
144 unwrap<HTMLInputElement>()->setShouldRevealPassword(value); 144 unwrap<HTMLInputElement>()->setShouldRevealPassword(value);
145 } 145 }
146 146
147 WebInputElement::WebInputElement(const RawPtr<HTMLInputElement>& elem) 147 WebInputElement::WebInputElement(HTMLInputElement* elem)
148 : WebFormControlElement(elem) 148 : WebFormControlElement(elem)
149 { 149 {
150 } 150 }
151 151
152 DEFINE_WEB_NODE_TYPE_CASTS(WebInputElement, isHTMLInputElement(constUnwrap<Node> ())); 152 DEFINE_WEB_NODE_TYPE_CASTS(WebInputElement, isHTMLInputElement(constUnwrap<Node> ()));
153 153
154 WebInputElement& WebInputElement::operator=(const RawPtr<HTMLInputElement>& elem ) 154 WebInputElement& WebInputElement::operator=(HTMLInputElement* elem)
155 { 155 {
156 m_private = elem; 156 m_private = elem;
157 return *this; 157 return *this;
158 } 158 }
159 159
160 WebInputElement::operator RawPtr<HTMLInputElement>() const 160 WebInputElement::operator HTMLInputElement*() const
161 { 161 {
162 return toHTMLInputElement(m_private.get()); 162 return toHTMLInputElement(m_private.get());
163 } 163 }
164 164
165 WebInputElement* toWebInputElement(WebElement* webElement) 165 WebInputElement* toWebInputElement(WebElement* webElement)
166 { 166 {
167 if (!isHTMLInputElement(*webElement->unwrap<Element>())) 167 if (!isHTMLInputElement(*webElement->unwrap<Element>()))
168 return 0; 168 return 0;
169 169
170 return static_cast<WebInputElement*>(webElement); 170 return static_cast<WebInputElement*>(webElement);
171 } 171 }
172 } // namespace blink 172 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/WebHitTestResult.cpp ('k') | third_party/WebKit/Source/web/WebLabelElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698