Skip to content

Commit 204db7e

Browse files
committed
Fix issue with position of bar being top left when reloading after hiding.
1 parent ada8990 commit 204db7e

File tree

4 files changed

+4
-5
lines changed

4 files changed

+4
-5
lines changed

TracyDebugger.module

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class TracyDebugger extends WireData implements Module, ConfigurableModule {
3232
'summary' => __('Tracy debugger from Nette with several PW specific custom tools.', __FILE__),
3333
'author' => 'Adrian Jones',
3434
'href' => 'https://processwire.com/talk/topic/12208-tracy-debugger/',
35-
'version' => '4.10.18',
35+
'version' => '4.10.19',
3636
'autoload' => true,
3737
'singular' => true,
3838
'requires' => 'ProcessWire>=2.7.2, PHP>=5.4.4',
@@ -858,6 +858,7 @@ class TracyDebugger extends WireData implements Module, ConfigurableModule {
858858
function unhideBar() {
859859
document.getElementById("tracy-debug").style.display = "block";
860860
document.getElementById("tracy-show-button").style.display = "none";
861+
window.Tracy.Debug.bar.restorePosition();
861862
document.cookie = "tracyHidden=; expires=Thu, 01 Jan 1970 00:00:01 GMT; path=/";
862863
document.cookie = "tracyShow=1; path=/";';
863864
if($this->showServerTypeIndicator() && $this->data['styleAdminType'] == 'custom') {
@@ -2421,7 +2422,7 @@ class TracyDebugger extends WireData implements Module, ConfigurableModule {
24212422

24222423
$f = $this->wire('modules')->get("InputfieldInteger");
24232424
$f->attr('name', 'panelZindex');
2424-
$f->label = __('Starting zIndex for panels', __FILE__);
2425+
$f->label = __('Starting z-index for panels', __FILE__);
24252426
$f->description = __('Adjust if you find panels are below/above elements that you don\'t want.', __FILE__);
24262427
$f->notes = __('Default: 100', __FILE__);
24272428
$f->columnWidth = 33;

styles.css

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ body.tracyHidden:before {
2222

2323

2424
#tracy-debug * {
25-
pointer-events: auto; /* needed to make panels draggable - comes from bar.css but we change block to #tracy-debug-bar so need to add this here. */
2625
font: inherit;
2726
}
2827

tracy-master/src/Tracy/assets/Bar/bar.css

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ body#tracy-debug { /* in popup window */
1818
position: absolute;
1919
left: 0;
2020
top: 0;
21-
pointer-events: none;
2221
}
2322

2423
#tracy-debug-bar * {
@@ -41,7 +40,6 @@ body#tracy-debug { /* in popup window */
4140
white-space: inherit;
4241
float: none;
4342
clear: none;
44-
pointer-events: auto;
4543
}
4644

4745
#tracy-debug-bar *:before,

tracy-master/src/Tracy/assets/Bar/bar.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -320,6 +320,7 @@
320320

321321

322322
savePosition() {
323+
if(document.getElementById('tracy-debug').style.display == 'none') return;
323324
var pos = getPosition(this.elem);
324325
localStorage.setItem(this.id, JSON.stringify(this.isAtTop() ? {right: pos.right, top: pos.top} : {right: pos.right, bottom: pos.bottom}));
325326
}

0 commit comments

Comments
 (0)