Congratulations. This is a great use of the script. I made it so you can configure where the center will be, but didn’t thought about multiple instances. You can duplicate the script with different parameters, but rotating the panel is also an awesome idea.
Thank you all I’m searching how to rotate in all directions but I’m not happen then there remained only the panel to rotate. Otherwise when I put mais widget internet the panel all widget becomes smaller there is still a value to change in the script?
mickael delarue at the top, there are some numbers after ‘h = ‘
If you want the wheel to be at the right part you need to change the h to 1. Similar to the vertical value. (All is explained in the wiki)
The problem is that it will change in all the containers (so you can have multiple scripts with only those values changed, or just leave the panels rotated)
Yes. The items are resized to avoid overlapping. If you want to leave their original size (but they can overlap) use this:
/*Config: */
var h = -1; //horizontal alignment (-1 , 0 , 1 )
var v = 0; //vertical alignment ( -1 , 0 , 1 )
var r = 0; //rotation offset ( 0 = default) in angles, not very implemented (0 or 180 recommended)
var f = 2; //sensitivity
var event = LL.getEvent();
var desktop = event.getContainer();
var a = desktop.getItems();
var na = a.getLength();
var radius = Math.min( desktop.getHeight()/ (v==0?4:2) , desktop.getWidth()/ (h==0?4:2) );
var alt = 0.5;
var size = [ radius*(2-alt)*Math.PI/na , radius*2 ];
var desf = (desktop.getPositionX()* (v>0?-1:1)+desktop.getPositionY()*(h>0?-1:1) )*Math.PI/desktop.getWidth();
TrianguloY If I understand well your script can be multiplied but the values are the same for each wheel set? is it hard to modify it to be defined by the container label?
Just put 2 or 3 panels in there, where you want your wheels and filled with the icons, and set the script to the positionchanged event of each of them.
When you scroll the first time you have to set up your parameters.
< ![CDATA[
That is awesome..do you plan on sharing the script and a tutorial?..again awesome work
]]>
< ![CDATA[
I think the script is in the wiki… look for rotating wheel or something like that
]]>
< ![CDATA[
Yves the script is in the wiki.
Here is a video showing the installation script with a panel
http://youtu.be/rgwB9OPd-UE
]]>
< ![CDATA[
wow!
]]>
< 
]]>
< ![CDATA[
Sweet!
]]>
< ![CDATA[
Thank you all I’m searching how to rotate in all directions but I’m not happen then there remained only the panel to rotate. Otherwise when I put mais widget internet the panel all widget becomes smaller there is still a value to change in the script?
]]>
< ![CDATA[
mickael delarue at the top, there are some numbers after ‘h = ‘
If you want the wheel to be at the right part you need to change the h to 1. Similar to the vertical value. (All is explained in the wiki)
The problem is that it will change in all the containers (so you can have multiple scripts with only those values changed, or just leave the panels rotated)
Yes. The items are resized to avoid overlapping. If you want to leave their original size (but they can overlap) use this:
/*Config: */
var h = -1; //horizontal alignment (-1 , 0 , 1 )
var v = 0; //vertical alignment ( -1 , 0 , 1 )
var r = 0; //rotation offset ( 0 = default) in angles, not very implemented (0 or 180 recommended)
var f = 2; //sensitivity
var event = LL.getEvent();
var desktop = event.getContainer();
var a = desktop.getItems();
var na = a.getLength();
var radius = Math.min( desktop.getHeight()/ (v==0?4:2) , desktop.getWidth()/ (h==0?4:2) );
var alt = 0.5;
var size = [ radius*(2-alt)*Math.PI/na , radius*2 ];
var desf = (desktop.getPositionX()* (v>0?-1:1)+desktop.getPositionY()*(h>0?-1:1) )*Math.PI/desktop.getWidth();
desf*=f;
for ( var i=0; i
var t = a.getAt(i);
size=[t.getWidth(),t.getHeight()];
var angle = Math.PI*2*i/na-desf;
var x = Math.cos( angle -Math.PI/2 ) * radius;
var y = Math.sin( angle -Math.PI/2 ) * radius;
var rot = angle*180/Math.PI+r;
x+= (h<0? 0 : desktop.getWidth()/ (h==0? 2 : 1) ) ;
y+= (v>0? 0 : desktop.getHeight()/ (v==0? 2 : 1) );
x-= size[0]/2;
y-= size[1]/2;
t.setRotation(0);
t.setSize(size[0] ,size[1]);
t.setPosition(x, y);
t.setRotation(rot);
}
]]>
< ![CDATA[
Thank you very very much I’ll try with this
]]>
< ![CDATA[
Please consider sharing here: http://www.pierrox.net/android/applications/lightning_launcher/wiki/doku.php?id=templates
]]>
< ![CDATA[
TrianguloY If I understand well your script can be multiplied but the values are the same for each wheel set? is it hard to modify it to be defined by the container label?
]]>
< ![CDATA[
Fabrice Fournier not really. Do you need it?
]]>
< ![CDATA[
I was bored, so I modified the script.
Values are unchecked.
But one major improvement: it is now ready-to-use, and you can define different values in different containers.
]]>
< ![CDATA[
var event = LL.getEvent();
var desktop = event.getContainer();
var data=JSON.parse(desktop.getTag()||”null”);
if(data==null)
{
data=new Object();
data.h=parseInt(prompt(“No Settings found.\nInput your horizontal Alignment (-1 , 0 , 1 )”,0))||0;
data.v=parseInt(prompt(“Input your vertical Alignment (-1 , 0 , 1 )”,0))||0;
data.r=parseInt(prompt(“Input your rotation offset ( 0 = default) in angles, not very implemented (0 or 180 recommended) “,0))||0;
data.f=parseInt(prompt(“Input your sensitivity”,2))||2;
}
desktop.setTag(JSON.stringify(data));
var h=data.h;
var v=data.v;
var r=data.r;
var f=data.f;
var a = desktop.getItems();
var na = a.getLength();
var radius = Math.min( desktop.getHeight()/ (v==0?4:2) , desktop.getWidth()/ (h==0?4:2) );
var alt = 0.5;
var size = [ radius*(2-alt)*Math.PI/na , radius*2 ];
var desf = (desktop.getPositionX()* (v>0?-1:1)+desktop.getPositionY()*(h>0?-1:1) )*Math.PI/desktop.getWidth();
desf*=f;
for ( var i=0; i
{
var t = a.getAt(i); size=[t.getWidth(),t.getHeight()];
var angle = Math.PI*2*i/na-desf;
var x = Math.cos( angle -Math.PI/2 ) * radius;
var y = Math.sin( angle -Math.PI/2 ) * radius;
var rot = angle*180/Math.PI+r;
x+= (h<0? 0 : desktop.getWidth()/ (h==0? 2 : 1) ) ;
y+= (v>0? 0: desktop.getHeight()/ (v==0? 2 : 1) );
x-= size[0]/2;
y-= size[1]/2;
t.setRotation(0);
t.setSize(size[0] ,size[1]);
t.setPosition(x, y);
t.setRotation(rot);
}
]]>
< 
]]>
< ![CDATA[
Good! Now I don’t have to.
But you used the container tag,
Fabrice Fournier: are you ok with Lukas’s modification or you need it to be from the label?
]]>
< ![CDATA[
From tag to label is a two line change. no problem if needed
]]>
< ![CDATA[
i explain : I want to put 2 or 3 different sizes of wheels and rotate at different speeds with Lukas Morawietz version i can ? in the same desktop
]]>
< ![CDATA[
Fabrice Fournier yes you can.
Just put 2 or 3 panels in there, where you want your wheels and filled with the icons, and set the script to the positionchanged event of each of them.
When you scroll the first time you have to set up your parameters.
]]>
< 
]]>
< 
]]>
< ![CDATA[
Fabrice Fournier does that mean it works?
Edit: tested now, works for me
]]>
< ![CDATA[
Another thing: if you want to reset your configuration, run this line in the container
LL.getEvent.getContainer().setTag(null);
]]>
< ![CDATA[
yes it’s working fine
thks
]]>
< ![CDATA[
TrianguloY thinking about publishing in wiki: your choice:
– replace the old one
– publish as new one
– something other, if you have a good idea
– a cake
]]>
< 
I’ll place…, well I’m busy at the moment.
You can place it under the original.
Just add a new title under the script: ‘modifications’
Write your name, this post if you wish and the script.
The original will be kept, but the modification will be available for those who want.
What do you think?
]]>