Skip to content

Commit

Permalink
Merge pull request binford2k#13 from binford2k/presenter_view
Browse files Browse the repository at this point in the history
Made the presenter view work for more screens
  • Loading branch information
Ralph Luchs committed Jul 7, 2012
2 parents 23f81ca + fed98bc commit 19f6c90
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 0 deletions.
26 changes: 26 additions & 0 deletions public/css/presenter.css
Original file line number Diff line number Diff line change
Expand Up @@ -87,3 +87,29 @@ div.zoomed {
.tGreen { background: #9d9; }
.tRed { background: #d99; }
.tYellow { background: #dd9; }


/* I want this view to like, actually work on multiple screen sizes... */
#main { height: 100%; }
#sidebar { height: 75%; min-height: 430px; }
#preview { height: 75%; min-height: 430px; overflow: scroll; }

#slideSource { height: 8%; padding: 0; }
#progress { height: 5%; padding: 0; }
#timerSection { height: 5%; padding: 0; background-color: #ccc; border: none; }
#slidemenu { height: 82%; padding: 0; }
.menu { height: 100%; max-height: 100%; }

#bottom { height: 10%; }
#notes { height: 100%; min-height: 100%; max-height: 100%; font-size: 1em; }

a.controls {
text-decoration: none;
padding: 0 0.25em 0.1em 0.25em;
background-color: #fff2ce;
border: 1px solid #ccc;
-moz-border-radius: 0.5em;
-webkit-border-radius: 0.5em;
-khtml-border-radius: 0.5em;
border-radius: 0.5em;
}
6 changes: 6 additions & 0 deletions public/js/presenter.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,12 @@ function openSlave()
w.presenterView = window;
}

function zoom(val)
{
var n = val ? val + parseFloat($(".zoomed").css("zoom")) : 0.5;
$(".zoomed").css("zoom", n);
}

function presPrevStep()
{
prevStep()
Expand Down
4 changes: 4 additions & 0 deletions views/presenter.erb
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@
<div id="main" class="container_12">
<div id="topbar" class="grid_12">
<div id="links">
<a class="controls" href="javascript:zoom(-0.01);">-</a>
<a class="controls" href="javascript:zoom();">o</a>
<a class="controls" href="javascript:zoom(0.01);">+</a>
&nbsp; &nbsp;
<a href="javascript:openSlave();">Open Slave Window</a>
&nbsp; &nbsp;
<a href="/pdf">Generate PDF</a>
Expand Down

0 comments on commit 19f6c90

Please sign in to comment.