зеркало из https://github.com/mozilla/gecko-dev.git
Bug 639490 - Remove nsHTMLInputElement::GetNameIfExists. r=sicking
This commit is contained in:
Родитель
ad4633017a
Коммит
e8c7102fb1
|
@ -3002,7 +3002,7 @@ nsHTMLInputElement::SubmitNamesValues(nsFormSubmission* aFormSubmission)
|
|||
|
||||
// Get the name
|
||||
nsAutoString name;
|
||||
PRBool nameThere = GetNameIfExists(name);
|
||||
GetAttr(kNameSpaceID_None, nsGkAtoms::name, name);
|
||||
|
||||
// Submit .x, .y for input type=image
|
||||
if (mType == NS_FORM_INPUT_IMAGE) {
|
||||
|
@ -3040,7 +3040,7 @@ nsHTMLInputElement::SubmitNamesValues(nsFormSubmission* aFormSubmission)
|
|||
//
|
||||
|
||||
// If name not there, don't submit
|
||||
if (!nameThere) {
|
||||
if (name.IsEmpty()) {
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
|
|
@ -387,16 +387,6 @@ protected:
|
|||
|
||||
nsresult GetSelectionRange(PRInt32* aSelectionStart, PRInt32* aSelectionEnd);
|
||||
|
||||
/**
|
||||
* Get the name if it exists and return whether it did exist
|
||||
* @param aName the name returned [OUT]
|
||||
* @param true if the name is empty, false otherwise
|
||||
*/
|
||||
PRBool GetNameIfExists(nsAString& aName) {
|
||||
GetAttr(kNameSpaceID_None, nsGkAtoms::name, aName);
|
||||
return !aName.IsEmpty();
|
||||
}
|
||||
|
||||
/**
|
||||
* Called when an attribute is about to be changed
|
||||
*/
|
||||
|
|
Загрузка…
Ссылка в новой задаче