Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

Firefox 49 for developers

这篇文章需要文法复核。如何帮忙。

这篇翻译不完整。请帮忙从英语翻译这篇文章

Firefox 49,基于 Gecko 49, 将会在 September 2016 正式发布。本文记录了开发者们应该注意的,该版本的 Firefox 的各种变化。

对于Web开发者的改变

开发者工具

HTML

CSS

JavaScript

Interfaces/APIs/DOM

DOM & HTML DOM

  • 方法 DOMTokenList.supports() 已经被增加 (bug 1257849).
  • DOMTokenList.replace() 方法已经被增加 (bug 1224186).
  • 第一位的 '?' 字符现在已经被忽视当作为参数在URLSearchParams() 构造器 (bug 1268361).
  • The value returned by URL.origin, HTMLAnchorElement.origin, and HTMLAreaElement.origin for URL using the blob: scheme is no longer incorrectly null but is instead the origin of the URL formed by removing the leading blob: (bug 1270451).
  • 在预渲染模式, Document.visibilityState 属性现在返回 'prerender' (bug 1069772).
  • Window.isSecureContext 属性已经被实现 (bug 1162772).
  • DOM4 ChildNode.before(), ChildNode.after(), ChildNode.replaceWith(), ParentNode.append() and ParentNode.prepend() 方法已经被实现 (bug 911477).
  • TouchList.identifiedTouch() 方法已经被移除 (bug 1188539).
  • 在默认的情况下, scrollbars Window 特性是开启的当调用Window.open(). 在过去, 这种情况下被强烈推荐开启但却不是默认开启的 (bug 1257887).
  • 增加实验性并且非标准的 HTMLMediaElement.seekToNextFrame() 方法, 它允许你which allows seeking frame-by-frame through video content (bug 1235301). While you're encouraged to experiment with this method to help us understand how useful it is, do not use it in production code!
  • The HTMLLabelElement.form property now returns the form with which the label's control is associated, if there is a control (and if that control is associated with a form). Previously, labels were directly associated with forms using this property (bug 1268852).
  • Support for the third parameter of EventTarget.addEventListener(), either a Boolean or an EventListenerOptions has been added (bug 1266164 and bug 1266066).
  • The audio volume related values for KeyboardEvent.key have been renamed. "VolumeDown" is now "AudioVolumeDown", "VolumeUp" is now "AudioVolumeUp", and "VolumeMute" is now "AudioVolumeMute". This brings Firefox into alignment with the latest draft of the UI Events specification (bug 1272578). See "Code values" in KeyboardEvent.code for a full list of available key codes.
  • The keys previously referred to as "MozHomeScreen", "MozCameraFocusAdjust", and "MozPhoneCall" now have official names in the UI Events specification: "GoHome", "CameraFocus", and "Call". Firefox 49 has been updated to use the new names (bug 1272599). See "Code values" in KeyboardEvent.code for a full list of available key codes.
  • The key values "Separator" and "MediaSkip" have been removed, as they were deprecated and unused (bug 1232919).
  • Key values and the corresponding key codes "Hyper" and "Super" have been added to represent these legacy modifier keys (bug 1232919).
  • 两个键值为了多媒体数字小键盘已经被增加: "Key11" and "Key12" (bug 1232919).
  • 下面的心键值被增加为了音频控制按键: "AudioBassBoostToggle", "AudioTrebleDown", and "AudioTrebleUp" (bug 123919).
  • 键值被增加为了麦克风控制按键: "MicrophoneToggle", "MicrophoneVolumeDown", "MicrophoneVolumeUp", and "MicrophoneVolumeMute" (bug 123919).
  • 新的键值被增加为了支持语音识别设备: "SpeechCorrectionList" and "SpeechInputToggle" (bug 1232919).
  • 新的键值已经被增加去支持手机上的特别的按键: "AppSwitch", "Call", "CameraFocus", "EndCall", "GoBack", "GoHome", "HeadsetHook", "LastNumberRedial", "Notification", "MannerMode", and "VoiceDial" (bug 1232919).
  • 这些新的应用程序键值已经被增加: "LaunchContacts" and "LaunchPhone" (bug 1232919).
  • 新的键值被增加去支持电视设备: "TV3DMode", "TVAntennaCable", "TVAudioDescription", "TVAudioDescriptionMixDown", "TVAudioDescriptionMixUp", "TVContentsMenu", "TVDataService", "TVInput", "TVInputComponent1", "TVInputComponent2", "TVInputComposite1", "TVInputComposite2", "TVInputHDMI1", "TVInputHDMI2", "TVInputHDMI3", "TVInputHDMI4", "TVInputVGA1", "TVMediaContext", "TVNetwork", "TVNumberEntry", "TVRadioService", "TVSatellite", "TVSatelliteBS", "TVSatelliteCS", "TVSatelliteToggle", "TVTerrestrialAnalog", "TVTerrestrialDigital", "TVTimer", and "DVR" (bug 1232919).
  • 键值 "MediaSelect" 已经被替换成标准的 "LaunchMediaPlayer" 键值 (bug 1272592).
  • Additional media player key values have been added as well. These are "MediaAudioTrack", "MediaSkipBackward", "MediaSkipForward", "MediaStepBackward", "MediaStepForward", "MediaTopMenu", "NavigateIn", "NavigateNext", "NavigateOut", and "NavigatePrevious" (bug 1232919).

Canvas

WebGL

IndexedDB

  • The Fetch API's Response object now implements the redirected property, which indicates whether or not the response is for a request which was redirected. Please review the security related notes in the documentation before using this property (bug 1243792).
  • In the Permissions API, Firefox no longer supports the 'push' PermissionDescriptor dictionary type (referred to in the spec as PushPermissionDescriptor); this is because Firefox relies on a quota system for controlling the userVisibleOnly status instead, and was throwing an error when it encountered a PushPermissionDescriptor instance (bug 1266821). With this dictionary removed, Firefox now simply ignores it.

Media Streams

  • In the past, it was possible for a call to MediaDevices.getUserMedia() which requests both audio and video to succeed in cases where the user has only one of the two types of hardware available. This has been fixed (bug 802326).
  • In prior versions of Firefox, it was possible for a call to MediaDevices.getUserMedia() which requests both audio and video to succeed even though the user denied access to one but not both of the matching devices. This has been fixed (bug 802326). This involves minor user interface changes as well, to remove the options to choose "No audio" or "No video" when the user is prompted for permissions.
  • The MediaStream.getTrackById() method has been implemented (bug 1208390).

WebRTC

  • The RTCPeerConnection.addTrack() method has been updated to allow tracks which are not components of the specified streams to be added to the connection. Instead, the streams are used to group tracks on the receiving end of the connection (bug 1271669).

New APIs

Others

MathML

No change.

SVG

Audio/Video

没有改变.

HTTP

Networking

  • The Proxy Auto-Configuration (PAC) implementation has been updated. Now weekdayRange, dateRange, and timeRange support "reversed ranges", for example, weekdayRange("SAT", "MON") will evaluate true if the current day is Saturday, Sunday, or Monday (bug 1251332).

Security

Compatibility

为了增强兼容性对于现在已经存在的内容, Firefox 现在接受一些 webkit 前缀 properties and attributes.

改变对于 add-on and Mozilla developers

WebExtensions

  • Support for the history has been added. This provides access to the browser history, with methods available for searching the history, getting information about previously-visited pages, and adding and removing history entries.
  • Added the tabs.removeCSS() method to the tabs API. This method lets you remove CSS which was previously injected by calling tabs.insertCSS().

Interfaces

Other

没有改变.

See also

Older versions

文档标签和贡献者

标签: 
 此页面的贡献者: Jiang-Xuan
 最后编辑者: Jiang-Xuan,