Attachment #8471906: Part 4a: Fix parse errors in addon-sdk/ for bug #1001090

View | Details | Raw Unified | Return to bug 1001090
Collapse All | Expand All

(-)a/addon-sdk/source/lib/sdk/deprecated/symbiont.js (-1 lines)
Line     Link Here 
 Lines 175-191   const Symbiont = Worker.resolve({ Link Here 
175
            self._onInit();
175
            self._onInit();
176
          }
176
          }
177
177
178
        });
178
        });
179
      return;
179
      return;
180
    }
180
    }
181
181
182
    let eventName = 'end' == this.contentScriptWhen ? 'load' : 'DOMContentLoaded';
182
    let eventName = 'end' == this.contentScriptWhen ? 'load' : 'DOMContentLoaded';
183
    let self = this;
184
    this._loadEvent = eventName;
183
    this._loadEvent = eventName;
185
    frame.addEventListener(eventName,
184
    frame.addEventListener(eventName,
186
      this._loadListener = function _onReady(event) {
185
      this._loadListener = function _onReady(event) {
187
186
188
        if (event.target != frame.contentDocument)
187
        if (event.target != frame.contentDocument)
189
          return;
188
          return;
190
        self._unregisterListener();
189
        self._unregisterListener();
191
190
(-)a/addon-sdk/source/lib/sdk/io/fs.js (-2 / +2 lines)
Line     Link Here 
 Lines 642-660   exports.closeSync = closeSync; Link Here 
642
 * given to the completion callback.
642
 * given to the completion callback.
643
 */
643
 */
644
let close = Async(closeSync);
644
let close = Async(closeSync);
645
exports.close = close;
645
exports.close = close;
646
646
647
/**
647
/**
648
 * Synchronous open(2).
648
 * Synchronous open(2).
649
 */
649
 */
650
function openSync(path, flags, mode) {
650
function openSync(path, flags_, mode_) {
651
  let [ fd, flags, mode, file ] =
651
  let [ fd, flags, mode, file ] =
652
      [ { path: path }, Flags(flags), Mode(mode), nsILocalFile(path) ];
652
      [ { path: path }, Flags(flags_), Mode(mode_), nsILocalFile(path) ];
653
653
654
  nsIFile(fd, file);
654
  nsIFile(fd, file);
655
655
656
  // If trying to open file for just read that does not exists
656
  // If trying to open file for just read that does not exists
657
  // need to throw exception as node does.
657
  // need to throw exception as node does.
658
  if (!file.exists() && !isWritable(flags))
658
  if (!file.exists() && !isWritable(flags))
659
    throw FSError("open", "ENOENT", 34, path);
659
    throw FSError("open", "ENOENT", 34, path);
660
660
(-)a/addon-sdk/source/lib/sdk/windows/fennec.js (-1 / +1 lines)
Line     Link Here 
 Lines 59-75   function getBrowserWindow(options) { Link Here 
59
59
60
  // if we have a BrowserWindow already then use it
60
  // if we have a BrowserWindow already then use it
61
  if ('window' in options)
61
  if ('window' in options)
62
    window = getRegisteredWindow(options.window);
62
    window = getRegisteredWindow(options.window);
63
  if (window)
63
  if (window)
64
    return window;
64
    return window;
65
65
66
  // we don't have a BrowserWindow yet, so create one
66
  // we don't have a BrowserWindow yet, so create one
67
  var window = BrowserWindow(options);
67
  window = BrowserWindow(options);
68
  addListItem(browserWindows, window);
68
  addListItem(browserWindows, window);
69
  return window;
69
  return window;
70
}
70
}
71
71
72
WindowTracker({
72
WindowTracker({
73
  onTrack: function onTrack(chromeWindow) {
73
  onTrack: function onTrack(chromeWindow) {
74
    if (!isBrowser(chromeWindow)) return;
74
    if (!isBrowser(chromeWindow)) return;
75
    let window = getBrowserWindow({ window: chromeWindow });
75
    let window = getBrowserWindow({ window: chromeWindow });

Return to bug 1001090