Bug 595922 - tooltips should not show form validation message if the form element has @novalidate. r+a=sicking

This commit is contained in:
Mounir Lamouri
2010-12-17 09:47:30 -08:00
parent 419b542789
commit d9f3f5b5fb
3 changed files with 20 additions and 3 deletions

View File

@@ -2816,7 +2816,8 @@ function FillInHTMLTooltip(tipElement)
tipElement instanceof HTMLTextAreaElement ||
tipElement instanceof HTMLSelectElement ||
tipElement instanceof HTMLButtonElement) &&
!tipElement.hasAttribute('title')) {
!tipElement.hasAttribute('title') &&
(!tipElement.form || !tipElement.form.noValidate)) {
// If the element is barred from constraint validation or valid,
// the validation message will be the empty string.
titleText = tipElement.validationMessage;