Наши волонтёры ещё не перевели данную статью на Русский. Присоединяйтесь к нам и помогите сделать эту работу!
Вы можете также прочитать эту статью на English (US).
Firefox 12 was shipped on April 24, 2012. This page summarizes the changes in Firefox 12 that affect developers. This article provides information about the new features and key bugs fixed in this release, as well as links to more detailed documentation for both web developers and add-on developers.
Changes for Web developers
titleattribute now supports newline characters to allow multi-line tooltips.
<canvas>element was being rendered instead of showing the fallback content as per the specification. Now the fallback content is rendered instead.
crossoriginattribute is now supported on
- Support for the
text-align-lastproperty has been added (prefixed).
- Support for sharp variables (a Netscape non-standard extension) has been dropped.
ArrayBuffer.prototype.slice()has been implemented.
DOMParsernow supports parsing of HTML document fragments.
XMLHttpRequestnow supports timeouts using the
timeoutproperty and "timeout" event, as well as the
ontimeoutevent handler on the
XMLHttpRequestcan now load from
- When downloading large amounts of data,
XMLHttpRequestprogress event handlers are now called periodically with the
responseTypeset to "moz-blob" and the response being a
Blobcontaining all of the data received so far. This lets progress handlers begin processing data without having to wait for it all to arrive.
- Gecko now supports multi-touch (instead of just single touches at a time) on Android.
- While editing text using an IME, the
inputevent is now sent whenever the contents of the element being edited have been changed; this happens after the
compositionupdateevent has been sent to indicate that the IME's text has been changed. You can use the
inputevent handler, therefore, to monitor changes to the actual content of the element.
DOMErroras defined in the DOM 4 specification has been implemented.
Document.createNodeIterator()method has been updated to match the DOM4 specification. This makes the
filterparameters optional and removes the non-standard fourth parameter,
slice()method was affected by a bug that prevented it from properly accepting
endvalues outside the range of a signed 64-bit integer; this has been fixed.
element.getBoundingClientRect()method now considers effect of CSS transforms when computing the element's bounding rectangle.
crossOriginproperty is now supported by
- Network Information API: Experimental support for
window.navigator.connectionhas been added (prefixed).
- WebTelephony API:
window.navigator.mozTelephonyhas been implemented and provides support for dialing, answering, and managing phone calls on a device.
- WebSMS API:
window.navigator.mozSmsis now available for mobile devices to send SMS text messages.
- Screen brightness API:
window.screen.mozBrightnesshave been added to control the device's screen.
- Firefox now implements the
SVGTestsDOM API, see bug 607854
SVGStringListDOM interface support the non-standard
lengthproperty see bug 711958
- To control the directionality of MathML formulas, the
dirattribute is now supported on the
<mstyle>elements as well as on MathML Token Elements. This is particularly important for some Arabic mathematical notations.
- The alignment attribute
aligndefined in MathML3 has been implemented for
- Previously, Gecko reported the close code
CLOSE_NORMALwhen a WebSocket channel was closed due to an unexpected error, or if it was closed due to an error condition that the specification doesn't cover. Now
CLOSE_GOING_AWAYis reported instead.
- The Web Console now caches error messages and log entries added using
console.log()if the console isn't currently open, and displays them when the console is opened.
- You can now reset the zoom level, panning, and rotation in the 3D view by pressing the "r" key.
- You can now hide nodes in the 3D view by pressing the "x" key after selecting them.
- The source editor has a several new editing features and keyboard shortcuts; see Using the Source Editor for details
Mozilla has been working on integrating its own Web developer tools that complement the popular Firebug add-on. You can get more information about these tools as well as see a list of resources external to Firefox that will help you with your Web development. The entire list is located at Web developer tools.
- The GEOSTD8 character set, which was never fully supported, is no longer supported at all.
Changes for Mozilla and add-on developers
resetUndo()method was added; this lets you clear the undo stack.
- The source editor now offers methods for providing search capability:
- The definition of the values for the
chromemarginattribute has changed slightly, to make it easier to make cross-platform XUL code look good on platforms with different default window border widths.
nsISupportsproxies are no longer supported. You should be using runnables instead; see Making cross-thread calls using runnables.
- Firefox 11 changed the behavior of
Components.utils.getWeakReference()to throw an exception when the object reference is null; the previous behavior of silently failing has been restored.
PRUint64data type was incorrectly essentially identical to
PRint64when used with XPConnect. This has been fixed.
nsIScreen_MOZILLA_2_0_BRANCHinterface has been merged into
nsIScreen. The APIs defined in that interface (for controlling minimum screen brightness) had not previously been documented, but now they are.
nsIScriptError2interface has been merged into
nsIDownloadManager.addDownload()is now handled asynchronously rather than synchronously.
imgIContainerObserver.frameChanged()method now receives as its first parameter an
imgIRequestobject identifying the corresponding request.
nsIDOMWindowUtils.sendTouchEvent()method has been added to allow synthesizing touch events.
- You can now scroll the specified content to the vertical center of the view by specifying
SCROLL_CENTER_VERTICALLYas the scroll constant when calling
- The new
nsIMemoryMultiReporter.explicitNonHeapattribute has been added; this is a more efficient way to obtain the sum of all of the multi-reporter's measurements that have a path that starts with "explicit" and are of the kind
nsIDOMWindowUtils.paintingSuppressedattribute has been added; this boolean value indicates whether or not painting is currently suppressed on the window. This is used on mobile to prevent bouncy rendering that occurs when attempts to draw the page begin before enough content is available to do so smoothly.
nsIDocumentCharsetInfointerfaces have been merged into
nsIDocShell. As part of this work, the old
forcedDetectorattribute has been removed; it never did anything.
JSThreadhas been eliminated.
JSThreadDatahas been merged into
- When building on Windows, you must have the Windows 7 SDK installed.
- Firefox 11 for developers
- Firefox 10 for developers
- Firefox 9 for developers
- Firefox 8 for developers
- Firefox 7 for developers
- Firefox 6 for developers
- Firefox 5 for developers
- Firefox 4 for developers
- Firefox 3.6 for developers
- Firefox 3.5 for developers
- Firefox 3 for developers
- Firefox 2 for developers
- Firefox 1.5 for developers