Bug 1120860 - Measure whether an <input type=password> is associated with a <form> in BindToTree. r=smaug

This commit is contained in:
Matthew Noorenberghe
2015-03-24 10:27:56 -07:00
parent 452fc40e2c
commit d2c7b9a63f
2 changed files with 12 additions and 0 deletions

View File

@@ -17,6 +17,7 @@
#include "nsIRadioVisitor.h"
#include "nsIPhonetic.h"
#include "mozilla/Telemetry.h"
#include "nsIControllers.h"
#include "nsIStringBundle.h"
#include "nsFocusManager.h"
@@ -4497,6 +4498,12 @@ HTMLInputElement::BindToTree(nsIDocument* aDocument, nsIContent* aParent,
// And now make sure our state is up to date
UpdateState(false);
#ifdef EARLY_BETA_OR_EARLIER
if (mType == NS_FORM_INPUT_PASSWORD) {
Telemetry::Accumulate(Telemetry::PWMGR_PASSWORD_INPUT_IN_FORM, !!mForm);
}
#endif
return rv;
}