[Laszlo-user] [Laszlo-dev] LzResizeReplication working but vscrollbar is misbehaving
jamesr
circlecycle at gmail.com
Sat Jun 9 15:40:52 PDT 2007
well, it sounds to me like the size of the views are under
replication are calculated more towards efficiency then accuracy (for
good reason, sometimes), and the algorithm for determining the
scrollmax takes the first replicated node and multiplies it by the
number of replicated nodes. Just a guess! To set scrollmax correctly
under this premise, you'd make an handler on the outer replicated
view that looks like this..
<view>
<view datapath="something">
...
</view>
<scroll name="scroller" axis="y">
<handler name="onheight" reference="parent">
var h = 0;
for(x in parent.subviews[0].nodes){
h += x.height;
}
scroller.scrollmax = h;
</handler>
</scroll>
</view>
NOTE, if you send a code snippet, privately if you want, then i could
base this code off of your code and make a working example and post
that back to the list. This may not be exactly right, esp. with the
subviews[] object in the for loop. there i'm trying to hit the
replication manager object, aka the first child of the outer view.
Note the usage of reference on the handler -- this lets you make an
encapsulated new scrollbar class against this special case if this
works out.
Have you tried this approach yet? Hope to help,
.j.
On Jun 9, 2007, at 1:38 PM, petergien wrote:
>
> If I add a large space to the end of the vscrollbar then it scrolls
> all my
> views into the clip window and allows me to scroll way past the end
> point.
> <vscrollbar name="vbar" scrollmax="${parent.tree.height + 5000}" />
>
> I would like to calculate the exact value for scrollmax but it
> seems that it
> cannot be calculated up front. Is this a fundamental limitation of
> resize
> replication?
>
>
> petergien wrote:
>>
>> I'm using LzResizeReplication and it is working great. However the
>> vscrollbar associated with the clip view only scrolls down 80% of
>> the way.
>> There are about 30 variable hight views still hanging off the
>> bottom that
>> never come into the clip view because the thumb slider does not go
>> all the
>> way to the bottom.
>>
>> OL 3.4.0
>>
>>
>
> --
> View this message in context: http://www.nabble.com/
> LzResizeReplication-working-but-vscrollbar-is-misbehaving-
> tf3894938.html#a11042141
> Sent from the OpenLaszlo - Dev mailing list archive at Nabble.com.
>
More information about the Laszlo-user
mailing list