Commit 2dbfa899 authored by bdash's avatar bdash

2006-11-04 David Smith <catfish.man@gmail.com>

        Reviewed by Tim H.

        Fixes: http://bugs.webkit.org/show_bug.cgi?id=11521
        Bug 11521: [Drosera] Breakpoint editor UI behaves incorrectly when multiple editors are open

        * Drosera/debugger.js: Use .// instead of // so that it doesn't root the search at the document.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@17602 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 78ec3b95
2006-11-04 David Smith <catfish.man@gmail.com>
Reviewed by Tim H.
Fixes: http://bugs.webkit.org/show_bug.cgi?id=11521
Bug 11521: [Drosera] Breakpoint editor UI behaves incorrectly when multiple editors are open
* Drosera/debugger.js: Use .// instead of // so that it doesn't root the search at the document.
2006-11-04 David Smith <catfish.man@gmail.com>
Reviewed by Tim H.
......
......@@ -429,12 +429,12 @@ function toggleBreakpointEditorOnLine(lineNum)
bp.editor = editor;
file.breakpoints[lineNum] = bp;
editor.query('//input[@class="enable"]').checked = bp.enabled;
editor.query('.//input[@class="enable"]').checked = bp.enabled;
editor.query('//select[@class="editorDropdown"]').selectedIndex = bp.type;
editor.query('.//select[@class="editorDropdown"]').selectedIndex = bp.type;
updateBreakpointTypeOnLine(lineNum);
editor.query('//span[@class="hitCounter"]').innerText = bp.hitcount;
editor.query('.//span[@class="hitCounter"]').innerText = bp.hitcount;
setConditionFieldText(bp);
} else {
......@@ -449,8 +449,8 @@ function updateBreakpointTypeOnLine(line)
{
var breakpoint = files[currentFile].breakpoints[line];
var editor = breakpoint.editor;
var label = editor.query('//label[@class="conditionLabel"]');
var dropdown = editor.query('//select[@class="editorDropdown"]');
var label = editor.query('.//label[@class="conditionLabel"]');
var dropdown = editor.query('.//select[@class="editorDropdown"]');
breakpoint.type = dropdown.selectedIndex;
switch(breakpoint.type) {
case 0:
......@@ -464,7 +464,7 @@ function updateBreakpointTypeOnLine(line)
function setConditionFieldText(breakpoint)
{
var conditionField = breakpoint.editor.query('//div[@class="condition"]');
var conditionField = breakpoint.editor.query('.//div[@class="condition"]');
var functionBody = breakpoint.value;
if (!functionBody || functionBody == "break")
......@@ -491,8 +491,8 @@ function saveBreakpointOnLine(lineNum)
var breakpoint = file.breakpoints[lineNum];
row = file.element.firstChild.childNodes.item(lineNum - 1);
var editor = breakpoint.editor;
var body = editor.query('//div[@class="condition"]').innerText;
var actionIndex = editor.query('//select[@class="editorDropdown"]').selectedIndex;
var body = editor.query('.//div[@class="condition"]').innerText;
var actionIndex = editor.query('.//select[@class="editorDropdown"]').selectedIndex;
if (body.length == 0)
breakpoint.value = "break";
else if (body.indexOf("return") != -1)
......@@ -515,7 +515,7 @@ function toggleBreakpointOnLine(lineNum)
breakpoint.enabled = !breakpoint.enabled;
var editor = breakpoint.editor;
if (editor) {
editor.query('//input[@class="enable"]').checked = breakpoint.enabled;
editor.query('.//input[@class="enable"]').checked = breakpoint.enabled;
setConditionFieldText(editor, lineNum);
}
}
......@@ -1290,7 +1290,7 @@ function willExecuteStatement(sourceId, line, fromLeavingFrame)
var editor = breakpoint.editor;
var counter = null;
if (editor)
counter = breakpoint.editor.query('//span[@class="hitCounter"]');
counter = breakpoint.editor.query('.//span[@class="hitCounter"]');
if (counter)
counter.innerText = breakpoint.hitcount;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment