From 8b56c324d3fa5cd757368bd150f3d59bdb392ffb Mon Sep 17 00:00:00 2001 From: Ilya Novoselov Date: Wed, 30 Nov 2011 18:45:41 +0600 Subject: [PATCH 1/3] Fix debugger source scroll for Firefox. Signed-off-by: Armin Ronacher --- werkzeug/debug/shared/debugger.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/werkzeug/debug/shared/debugger.js b/werkzeug/debug/shared/debugger.js index 3d21a4ab6..3e4397c5c 100644 --- a/werkzeug/debug/shared/debugger.js +++ b/werkzeug/debug/shared/debugger.js @@ -196,5 +196,6 @@ function focusSourceBlock() { line = tmp; } var container = $('div.sourceview'); - container.scrollTop(line.offset().top); + + container.scrollTop(line.offset().top - container.offset().top + container.scrollTop()); } From f330882a5f4cfee30b44f504b0cc720d4779ce79 Mon Sep 17 00:00:00 2001 From: Ilya Novoselov Date: Thu, 3 Nov 2011 20:18:50 +0600 Subject: [PATCH 2/3] Work correctly with urls like http://doubleshlash//something Signed-off-by: Armin Ronacher --- werkzeug/debug/shared/debugger.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/werkzeug/debug/shared/debugger.js b/werkzeug/debug/shared/debugger.js index 3e4397c5c..73305bf06 100644 --- a/werkzeug/debug/shared/debugger.js +++ b/werkzeug/debug/shared/debugger.js @@ -44,7 +44,7 @@ $(function() { .click(function() { sourceView.slideUp('fast'); }); - $.get(document.location.pathname, {__debugger__: 'yes', cmd: + $.get('', {__debugger__: 'yes', cmd: 'source', frm: frameID, s: SECRET}, function(data) { $('table', sourceView) .replaceWith(data); @@ -134,7 +134,7 @@ function openShell(consoleNode, target, frameID) { var form = $('
>>>
') .submit(function() { var cmd = command.val(); - $.get(document.location.pathname, { + $.get('', { __debugger__: 'yes', cmd: cmd, frm: frameID, s: SECRET}, function(data) { var tmp = $('
').html(data); $('span.extended', tmp).each(function() { @@ -178,7 +178,7 @@ function openShell(consoleNode, target, frameID) { return false; } }); - + return consoleNode.slideDown('fast', function() { command.focus(); }); From 49fd6e2e01bee73adc6fd087b1dd92d3eaf6571d Mon Sep 17 00:00:00 2001 From: Armin Ronacher Date: Wed, 28 Mar 2012 00:32:04 +0100 Subject: [PATCH 3/3] Added changelog entry --- CHANGES | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGES b/CHANGES index 8b4152a0a..2af32c6d4 100644 --- a/CHANGES +++ b/CHANGES @@ -13,6 +13,8 @@ Version 0.8.4 context local objects on a stack with context preservation on errors. - Fixed an issue with scolling up in the debugger. +- Fixed an issue with debuggers running on a different URL + than the URL root. - Fixed a problem with proxies not forwarding some rarely used special methods properly. - Added a workaround to prevent the XSS protection from Chrome