now browsing by tag
I hate google!
I’ve rated llx with only four stars when I bought it. Now I am beta tester and not allowed to rework my rating.
]]>I would really love to see dynamic text set by a script
I know I can edit a label, but that’s only a workaround
Horizontal and vertical screen loop with items movement
– allow infinite scroll (decelerate/bounce may also work instead)
– set script in positionchanged event of your desktop. (should work also in other containers)
– i recommend to use snap to pages, it may fail without
– set up your configuration: if you want to disable it for one direction set the value to false
Known bugs:
– Scrolling left very fast with a low amount of pages moves items to false positions (Too far left). fixed
– Scrolling right/bottom fast moves items to false positions (Too far right/bottom). occurence reduced
– using the script in more than one container is buggy fixed
– no check for single pages added
——————————
//config
var horizontalScrolling=true;
var verticalScrolling=true;
//endconfig
var d=LL.getEvent().getContainer();
if(d.getId()==-1)d=LL.getCurrentDesktop();
if(d.getPositionScale()!=1)return;
var data=JSON.parse(d.getTag()||”null”);
if (data==null)
{
data=new Object();
data.stateX=0;
data.stateY=0;
data.running=false;
}
if(data.running==true)return;
data.running=true;
d.setTag(JSON.stringify(data));
var dwidth=d.getWidth();
var dheight=d.getHeight();
var cwidth=d.getCellWidth();
var cheight=d.getCellHeight();
var posX=d.getPositionX();
var posY=d.getPositionY();
var box=d.getBoundingBox();
var minX=box.getLeft();
var maxX=box.getRight();
var minY=box.getTop();
var maxY=box.getBottom();
var fullwidth=maxX-minX;
var fullheight=maxY-minY;
var items=d.getItems();
var setLeft=function()
{
data.stateX=1;
for(x=0;x { var item=items.getAt(x); if(item.getPositionX()>=maxX-dwidth) { if(item.getProperties().getBoolean(“i.onGrid”)) { var cell=item.getCell(); item.setCell(Math.round(cell.getLeft()-fullwidth/cwidth), Math.round(cell.getTop()), Math.round(cell.getRight() -fullwidth/cwidth), Math.round(cell.getBottom())); } else { item.setPosition(item.getPositionX()-fullwidth,item.getPositionY()); } } } } var setRight=function() { data.stateX=0; for(x=0;x { var item=items.getAt(x); if(item.getPositionX() { if(item.getProperties().getBoolean(“i.onGrid”)) { var cell=item.getCell(); item.setCell( Math.round(cell.getLeft()+fullwidth/cwidth), Math.round(cell.getTop()), Math.round(cell.getRight() +fullwidth/cwidth), Math.round(cell.getBottom())); } else { item.setPosition(item.getPositionX()+fullwidth,item.getPositionY()); } } } } var setTop=function() { data.stateY=1; for(x=0;x { var item=items.getAt(x); if(item.getPositionY()>=maxY-dheight) { if(item.getProperties().getBoolean(“i.onGrid”)) { var cell=item.getCell(); item.setCell(Math.round(cell.getLeft()), Math.round(cell.getTop()-fullheight/cheight), Math.round(cell.getRight()), Math.round(cell.getBottom()-fullheight/cheight)); } else { item.setPosition(item.getPositionX(),item.getPositionY()-fullheight); } } } } var setBottom=function() { data.stateY=0; for(x=0;x { var item=items.getAt(x); if(item.getPositionY() { if(item.getProperties().getBoolean(“i.onGrid”)) { var cell=item.getCell(); item.setCell( Math.round(cell.getLeft()), Math.round(cell.getTop()+fullheight/cheight), Math.round(cell.getRight()), Math.round(cell.getBottom()+fullheight/cheight)); } else { item.setPosition(item.getPositionX(),item.getPositionY()+fullheight); } } } } if(fullwidth>dwidth && horizontalScrolling) { if(data.stateX==1) { if(posX<=minX || posX>=minX+dwidth) { if(posX<=minX) d.setPosition(maxX,posY,1,false); setRight(); } } else { if(posX setLeft(); if(posX>maxX-dwidth) { d.setPosition(minX-dwidth,posY,1,false); setLeft(); } } } else { if(posX d.setPosition(minX,posY,1,false); if(posX>maxX-dwidth) d.setPosition(maxX-dwidth,posY,1,false); } posX=d.getPositionX(); if(fullheight>dheight && verticalScrolling) { if(data.stateY==1) { if(posY<=minY || posY>=minY+dheight) { if(posY<=minY) d.setPosition(posX,maxY,1,false); setBottom(); } } else { if(posY setTop(); if(posY>maxY-dheight) { d.setPosition(posX,minY-dheight,1,false); setTop(); } } } else { if(posY d.setPosition(posX,minY,1,false); if(posY>maxY-dheight) d.setPosition(posX,maxY-dheight,1,false); } var done=function() { data.running=false; d.setTag(JSON.stringify(data)); } setTimeout(done,0); Please report all bugs! *And give feedback*
Horzontal Page Transition Animation: “Bulldoze” with page loop
Horzontal Page Transition Animation: “Bulldoze” with page loop
For a video look here: https://plus.google.com/115366157037831519359/posts/N4vKniRC4pe
– Set Script 1 in positionchanged event of your container
– Set Script 2 somewhere easy accessible (create a shortcut/tick show in lightning menu)
– enable “snap to pages”
– don’t use items over page bounds, this would look stupid.
– zooming may break the animation.
How to use:
Enable the effect: Run script 2.
Edit screen: – Run script 2 (disables animation)
– edit as much as you want (add items, move items, remove items.)
– run script 2 again.
Please report all bugs!
And give feedback
Update 30.3.
– improve reliability
]]>I would love to have the following desktop events:
-Enter edit mode (also when an item is moved)
-leave edit mode
-Item added
]]>I’m trying around with creating page transition animations.
I have the problem, that setting the alpha of an item is a very heavy operation. Is there a way to reduce the script executions in positionchanged event?
]]>Another thing missing:
A tap event contains a container, a swipe event returns -1 for container.
]]>implemented
I would like to have a method to access the borders of a container.
+TrianguloY and I figured out, that it is unnecessary to calculate it again in scripts, if the launcher already knows this values
changed and implemented
Script API reference:
1. Some values like gridPColumnNum are integers, not strings
2.why is i.onGrid readonly?
Would be nice to be able to change that in scripts…
D5 Creation