Twoje komentarze

This will force a number to always be stuck at a certain length.

<text name="Test-7" width="100%" height="100" color="#ffffff" font="Arial" size="48" align="center" alignment="center" text="Math Precision of 1.1 is [eval:1.1.toPrecision(3)]"></text>
You could use an eval for your total after it is calculated. If it were limited to 2 decimal spots, it would round. The eval would look like this:


<text name="Test-7" width="100%" height="100" color="#ffffff" font="Arial" size="48" align="center" alignment="center" text="Limit to 2 Decimals of 34.55555555 is [eval:34.55555555.toFixed(2)]"></text>



OR use a variable
[eval:[var:total].toFixed(2)]
I added a background color onto TOCWRAP and it looks like a scale action is working but only when you scale down and while the TOCWRAP panel will scale, the pager will still maintain the original height so there is space under the scaled panel. This is odd and looks like a bug, but it might be a temporary solution for you. I set your TOCWRAP to 200% and the scale seems to work in this fashion.
oops. That is because assigning height and width object properties is not a live feature yet (currently they are read only). I will check on the status of that ticket and get back to you.

In the meantime let me think about a workaround for this predicament...
Have you tried just using an assign tag to replace the value of height instead of a scale tag?

<assign property="object:TOCWRAP.height" value="[var:tocHeight]" />
Ah yes that changes things a bit.

Well the pager itself should never change height, since it needs to size based on the header screen. The panel inside the pager that contains the list objects is what needs to be dynamic. You should be able to give the panel a fitheight and it will size based on its children and then the pager will just fill out. The only thing you need to watch out for is making sure the panel inside the pager is greater than 100% or the pager won't scroll.
You are right, list tags don't like to be draggable.

I have come up with this solution, you should find it in your code:


<panel name="TOCPANEL" alias="TOCPANEL" width="100%" height="100%" ypos="-200%" hidden="no" background="#000000" padding-top="46" >
<image name="tocBg" alias="TOCBG" source="ui/toc_bg.png" width="100%" height="100%"></image>
<pager name="page" width="100%" height="73.7%" orientation="vertical" ypos="3.5%" paginate="no" >
<panel name="wrap" width="100%" height="150%">
<list name="tocList1" alias="TOCLIST" width="50%" fitheight="yes" datasource="tocFeed" orientation="vertical" paginate="no" align="left">
<object datasource="tocFeed" name="tocItem" class="tocItem" id="[param:id]" size="12" storyName="[param:name]" storyPage="[param:page]" storyAuthor="[param:author]" storyInfo="[param:info]" storyType="[param:type]" storyImage="[param:imgSrc]" lhs="[eval: [param:id] % 2]" operator="e" rhs="1"></object>
</list>
<list name="tocList2" alias="TOCLIST" width="50%" fitheight="yes" datasource="tocFeed" orientation="vertical" paginate="no" align="right">
<object datasource="tocFeed" name="tocItem" class="tocItem" id="[param:id]" size="12" storyName="[param:name]" storyPage="[param:page]" storyAuthor="[param:author]" storyInfo="[param:info]" storyType="[param:type]" storyImage="[param:imgSrc]" lhs="[eval: [param:id] % 2]" operator="e" rhs="0"></object>
</list>
</panel>
</pager>
</panel>
It looks like this might be a z-order issue, I can see your issue images and can swipe them in the background (I can see them at the top of the screen under the nav bar.). Can you move the lists in your TOC down in the code so it is under the images block?
You could achieve this by adding draggable="yes" and dragorientation="vertical" to your panel. But you would probably want to wrap it inside of another panel so it had some boundaries.
Tyler,

With any restful API you can reuse the httpheader that contains your auth tokens, but you will need to create a new datasource tag for logging in. You need an httpmethod of GET and a new source.


<datasource name="parseSignUp" datasourceerror="parseSignUpError" httpmethod="post" source="" query="/result" providertype="json" httpheader="parseHeader" urlcacheduration="1" />

<datasource name="parseSignIn" datasourceerror="parseError" httpmethod="get" source="" query="/" providertype="json" httpheader="parseHeader" urlcacheduration="1"/>

<assign property="datasource:parseSignIn.source" value="https://api.parse.com/1/login?username=[eval:encodeURI(&quot;[object:SIGNIN-FORMtextfield.text]&quot;)]&amp;password=[eval:encodeURI(&quot;[object:SIGNIN-FORMtextfield.text]&quot;)]"/>