panel mode sizing appears ok - except in big test.
- last time I did that I got a huge out of mem issue - dunno what that was, but the strip calc is off for wtf4 - wait, it also has the previous piece in it. that's not good.
This commit is contained in:
parent
6c84ce3b49
commit
57c9eb5950
2 changed files with 14 additions and 9 deletions
18
sahli.coffee
18
sahli.coffee
|
|
@ -256,13 +256,16 @@ class @Sahli
|
||||||
outer.addClass 'nosb'
|
outer.addClass 'nosb'
|
||||||
$('#panel').append outer
|
$('#panel').append outer
|
||||||
$('#outbox').toggle()
|
$('#outbox').toggle()
|
||||||
canvs.width Math.floor fw/numcols
|
newwidth = Math.floor fw/(numcols+1)
|
||||||
|
ratio = newwidth / @origwidth
|
||||||
|
canvs.width newwidth
|
||||||
level = 0
|
level = 0
|
||||||
drawcol = 1
|
drawcol = 1
|
||||||
for pic in canvs
|
for pic in canvs
|
||||||
$("#column#{drawcol}").append pic
|
$("#column#{drawcol}").append pic
|
||||||
level = level + pic.height
|
newheight = pic.height * ratio
|
||||||
if level > fh
|
level = level + newheight
|
||||||
|
if level+newheight > fh+newheight/2
|
||||||
level = 0
|
level = 0
|
||||||
drawcol = drawcol + 1
|
drawcol = drawcol + 1
|
||||||
|
|
||||||
|
|
@ -270,9 +273,12 @@ class @Sahli
|
||||||
$('.scrolly').width @origwidth
|
$('.scrolly').width @origwidth
|
||||||
$('#outbox').show()
|
$('#outbox').show()
|
||||||
$('.scrolly').append pic for pic in canvs
|
$('.scrolly').append pic for pic in canvs
|
||||||
|
canvs.width @origwidth
|
||||||
|
$('body').scrollTop 0
|
||||||
|
|
||||||
|
|
||||||
@createpanel = (i,amt) ->
|
@createpanel = (i,amt) ->
|
||||||
dcol = $("<div id='column#{i}'>#{i}</div>")
|
dcol = $("<div id='column#{i}'>")
|
||||||
dcol.addClass 'panelcolumn'
|
dcol.addClass 'panelcolumn'
|
||||||
dcol.width amt
|
dcol.width amt
|
||||||
|
|
||||||
|
|
@ -286,10 +292,10 @@ class @Sahli
|
||||||
when @keycode 's'
|
when @keycode 's'
|
||||||
@setscroll()
|
@setscroll()
|
||||||
when @keycode 't'
|
when @keycode 't'
|
||||||
$('body').scrollTop(0)
|
$('body').scrollTop 0
|
||||||
@zoom 0
|
@zoom 0
|
||||||
when @keycode 'b'
|
when @keycode 'b'
|
||||||
$('body').scrollTop($('body').height())
|
$('body').scrollTop $('body').height()
|
||||||
when @keycode 'a'
|
when @keycode 'a'
|
||||||
$('body').stop()
|
$('body').stop()
|
||||||
@scroll_direction = - @scroll_direction
|
@scroll_direction = - @scroll_direction
|
||||||
|
|
|
||||||
|
|
@ -155,9 +155,8 @@ p.infobox {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
color: #00f080;
|
color: #00f080;
|
||||||
width: 2em;
|
width: 2em;
|
||||||
border: 2px dashed #10161a;
|
background: #082020;
|
||||||
background: #0a0a0f;
|
display: inline-table;
|
||||||
display: inline-block;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.nosb {
|
.nosb {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue