Backed out changeset 258cff340229 (bug 1200798) for new intermittent test failures in browser_dbg_breakpoints-button-02.js

This commit is contained in:
Carsten "Tomcat" Book
2015-11-30 12:45:12 +01:00
parent bee3c47f76
commit f3d45a4d77
132 changed files with 6773 additions and 6479 deletions

View File

@@ -8,8 +8,6 @@ loader.lazyRequireGetter(this, "Services");
loader.lazyImporter(this, "gDevTools", "resource://devtools/client/framework/gDevTools.jsm");
loader.lazyImporter(this, "Task", "resource://gre/modules/Task.jsm");
var DevToolsUtils = require("devtools/shared/DevToolsUtils");
/**
* Tries to open a Stylesheet file in the Style Editor. If the file is not found,
* it is opened in source view instead.
@@ -57,7 +55,7 @@ exports.viewSourceInDebugger = Task.async(function *(toolbox, sourceURL, sourceL
let { panelWin: dbg } = yield toolbox.loadTool("jsdebugger");
if (!debuggerAlreadyOpen) {
yield dbg.DebuggerController.waitForSourcesLoaded();
yield dbg.once(dbg.EVENTS.SOURCES_ADDED);
}
let { DebuggerView } = dbg;
@@ -66,11 +64,7 @@ exports.viewSourceInDebugger = Task.async(function *(toolbox, sourceURL, sourceL
let item = Sources.getItemForAttachment(a => a.source.url === sourceURL);
if (item) {
yield toolbox.selectTool("jsdebugger");
const isLoading = dbg.DebuggerController.getState().sources.selectedSource !== item.attachment.source.actor;
DebuggerView.setEditorLocation(item.attachment.source.actor, sourceLine, { noDebug: true });
if (isLoading) {
yield dbg.DebuggerController.waitForSourceShown(sourceURL);
}
yield DebuggerView.setEditorLocation(item.attachment.source.actor, sourceLine, { noDebug: true });
return true;
}