Bug in Firefox 3.0.5 Auto-Complete
"Cannot modify properties of a WrappedNative" exceptions appeared in the error console of Firefox 3.0.5 for Windows XP while working on a form input box inside a jQuery modal window.
It is generated when you cause the auto-complete pop-up to appear with a list of possible keywords that matched the first few characters typed into an input box, hover your mouse over the choices, and click somewhere on the page to close the pop-up.
Open the "error console" from the tools menu and there you will see the error like below:
Error: uncaught exception: [Exception... "Cannot modify properties of a WrappedNative" nsresult: "0x80570034 (NS_ERROR_XPC_CANT_MODIFY_PROP_ON_WN)" location: "JS frame :: chrome://global/content/bindings/autocomplete.xml :: onxblpopuphiding :: line 834" data: no]
Line number may differ in various builds and platforms but points to same code in "popuphiding" function as in below:
831 // If the list was being navigated and then closed, make sure
832 // we fire accessible focus event back to textbox
833 if (isListActive) {
834 this.mInput.mIgnoreFocus = true;
835 this.mInput._focus();
836 this.mInput.mIgnoreFocus = false;
837 }
The reason: the function always assumes that "mInput" property is an input box. But when form auto-complete is active, the input box is wrapped or proxied by a form fill controller so it's no longer the input box the code is interacting with.
Fortunately, the error does not cause any harm or interfere with scripts on a web page so it is safe to ignore it.
In case you find it annoying or alarming especially while debugging scripts on a web page, you can turn off form auto-complete by unchecking "Remember what I enter in forms and the search bar" check box in Tools --> options --> privacy tab.
Alternatively, when you need auto-complete functionality, comment out line 834 with double slashes.
To do that, you need a software that can open and update jar files.
Locate your Mozilla Firefox chrome folder, open toolkit.jar, then open and update "content/global/bindings/autocomplete.xml" file.
This error was reported in bugzilla.mozilla.org as Bug 428602.
Comments















