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

Side by Side Diff: Source/core/html/HTMLInputElement.h

Issue 225853005: Add support for setting password value gated on user's gesture in a page (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2004, 2005, 2006, 2007, 2010 Apple Inc. All rights reserved. 5 * Copyright (C) 2004, 2005, 2006, 2007, 2010 Apple Inc. All rights reserved.
6 * Copyright (C) 2012 Samsung Electronics. All rights reserved. 6 * Copyright (C) 2012 Samsung Electronics. All rights reserved.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 130
131 int size() const; 131 int size() const;
132 bool sizeShouldIncludeDecoration(int& preferredSize) const; 132 bool sizeShouldIncludeDecoration(int& preferredSize) const;
133 133
134 void setType(const AtomicString&); 134 void setType(const AtomicString&);
135 135
136 virtual String value() const OVERRIDE; 136 virtual String value() const OVERRIDE;
137 void setValue(const String&, ExceptionState&, TextFieldEventBehavior = Dispa tchNoEvent); 137 void setValue(const String&, ExceptionState&, TextFieldEventBehavior = Dispa tchNoEvent);
138 void setValue(const String&, TextFieldEventBehavior = DispatchNoEvent); 138 void setValue(const String&, TextFieldEventBehavior = DispatchNoEvent);
139 void setValueForUser(const String&); 139 void setValueForUser(const String&);
140 void setValueAfterUserGesture(const String&);
140 // Checks if the specified string would be a valid value. 141 // Checks if the specified string would be a valid value.
141 // We should not call this for types with no string value such as CHECKBOX a nd RADIO. 142 // We should not call this for types with no string value such as CHECKBOX a nd RADIO.
142 bool isValidValue(const String&) const; 143 bool isValidValue(const String&) const;
143 bool hasDirtyValue() const { return !m_valueIfDirty.isNull(); }; 144 bool hasDirtyValue() const { return !m_valueIfDirty.isNull(); };
144 145
145 String sanitizeValue(const String&) const; 146 String sanitizeValue(const String&) const;
146 147
147 String localizeValue(const String&) const; 148 String localizeValue(const String&) const;
148 149
149 const String& suggestedValue() const; 150 const String& suggestedValue() const;
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after
372 RadioButtonGroupScope* radioButtonGroupScope() const; 373 RadioButtonGroupScope* radioButtonGroupScope() const;
373 void addToRadioButtonGroup(); 374 void addToRadioButtonGroup();
374 void removeFromRadioButtonGroup(); 375 void removeFromRadioButtonGroup();
375 #if ENABLE(INPUT_MULTIPLE_FIELDS_UI) 376 #if ENABLE(INPUT_MULTIPLE_FIELDS_UI)
376 virtual PassRefPtr<RenderStyle> customStyleForRenderer() OVERRIDE; 377 virtual PassRefPtr<RenderStyle> customStyleForRenderer() OVERRIDE;
377 #endif 378 #endif
378 379
379 AtomicString m_name; 380 AtomicString m_name;
380 String m_valueIfDirty; 381 String m_valueIfDirty;
381 String m_suggestedValue; 382 String m_suggestedValue;
383 String m_valueGatedOnUserGesture;
382 int m_size; 384 int m_size;
383 int m_maxLength; 385 int m_maxLength;
384 short m_maxResults; 386 short m_maxResults;
385 bool m_isChecked : 1; 387 bool m_isChecked : 1;
386 bool m_reflectsCheckedAttribute : 1; 388 bool m_reflectsCheckedAttribute : 1;
387 bool m_isIndeterminate : 1; 389 bool m_isIndeterminate : 1;
388 bool m_isActivatedSubmit : 1; 390 bool m_isActivatedSubmit : 1;
389 unsigned m_autocomplete : 2; // AutoCompleteSetting 391 unsigned m_autocomplete : 2; // AutoCompleteSetting
390 bool m_hasNonEmptyList : 1; 392 bool m_hasNonEmptyList : 1;
391 bool m_stateRestored : 1; 393 bool m_stateRestored : 1;
392 bool m_parsingInProgress : 1; 394 bool m_parsingInProgress : 1;
393 bool m_valueAttributeWasUpdatedAfterParsing : 1; 395 bool m_valueAttributeWasUpdatedAfterParsing : 1;
394 bool m_canReceiveDroppedFiles : 1; 396 bool m_canReceiveDroppedFiles : 1;
395 bool m_hasTouchEventHandler : 1; 397 bool m_hasTouchEventHandler : 1;
396 bool m_shouldRevealPassword : 1; 398 bool m_shouldRevealPassword : 1;
397 bool m_needsToUpdateViewValue : 1; 399 bool m_needsToUpdateViewValue : 1;
398 RefPtr<InputType> m_inputType; 400 RefPtr<InputType> m_inputType;
399 RefPtr<InputTypeView> m_inputTypeView; 401 RefPtr<InputTypeView> m_inputTypeView;
400 // The ImageLoader must be owned by this element because the loader code ass umes 402 // The ImageLoader must be owned by this element because the loader code ass umes
401 // that it lives as long as its owning element lives. If we move the loader into 403 // that it lives as long as its owning element lives. If we move the loader into
402 // the ImageInput object we may delete the loader while this element lives o n. 404 // the ImageInput object we may delete the loader while this element lives o n.
403 OwnPtr<HTMLImageLoader> m_imageLoader; 405 OwnPtr<HTMLImageLoader> m_imageLoader;
404 OwnPtr<ListAttributeTargetObserver> m_listAttributeTargetObserver; 406 OwnPtr<ListAttributeTargetObserver> m_listAttributeTargetObserver;
405 }; 407 };
406 408
407 } //namespace 409 } //namespace
408 #endif 410 #endif
OLDNEW
« no previous file with comments | « LayoutTests/fast/forms/user-gesture-gated-value-expected.txt ('k') | Source/core/html/HTMLInputElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698