Skip to content

Commit 8486959

Browse files
author
Philip Guo
committed
some minor cleanups to David's resizer pull request
1 parent c867e1a commit 8486959

2 files changed

Lines changed: 5 additions & 9 deletions

File tree

‎v3/css/pytutor.css‎

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -523,7 +523,7 @@ div.ExecutionVisualizer div#heapHeader {
523523
}
524524

525525
div.ExecutionVisualizer #executionSlider {
526-
width: 500px;
526+
/* if you set 'width', then it looks ugly when you dynamically resize */
527527
margin-top: 15px;
528528
margin-bottom: 5px;
529529

@@ -705,12 +705,9 @@ div.ExecutionVisualizer .highlight-legend {
705705
padding: 2px;
706706
}
707707

708+
/* resizing sliders from David Pritchard */
708709
.ui-resizable-e {
709-
background-color: #DDDDFF;
710+
background-color: #dddddd;
710711
border: 3px solid white;
711712
box-sizing: border-box;
712713
}
713-
714-
.ui-resizable-e:hover {
715-
border-color: #DDDDFF;
716-
}

‎v3/js/pytutor.js‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -546,12 +546,11 @@ ExecutionVisualizer.prototype.render = function() {
546546

547547
this.hasRendered = true;
548548

549-
// left-right horizontal resizer
549+
// left-right draggable pane resizer (from David Pritchard)
550550
$('#pyCodeOutputDiv').css({"max-width":"inherit"});
551551
$('#codeDisplayDiv').css({"max-width":"inherit"});
552-
$('#codeDisplayDiv').css({"width":"350px"}); // or whatever default width you want
553552
$('#pyStdout').css({"max-width":"inherit"});
554-
$('#executionSlider').css({"width":"75%"});
553+
$('#executionSlider').css({"width":"95%"});
555554
var syncStdoutWidth = function(event, ui){
556555
$("#vizLayoutTdFirst #pyStdout").width(ui.size.width-2*parseInt($("#pyStdout").css("padding-left")));};
557556
$('#codeDisplayDiv').resizable({handles:"e", resize: syncStdoutWidth});

0 commit comments

Comments
 (0)