View Single Post
No!No!No!Yes!'s Avatar
Posts: 700 | Thanked: 846 times | Joined on Nov 2009
#830
Originally Posted by Dousan View Post
@No!No!No!Yes! i've tried to tweak your new cmd for rotation for a play/pause button and used @techies cmd for that button, but couldn't make it work right, it only started and the icon vanished. So i tried the above code you posted for the fm transmitter. Just pasted the start and stop buttons from mediaplayer dbus codes and it works as it should.
Now my problem is, i don't know how to integrate the rotation code to that beecon/button and that is needed to match the other beecons on my desktop (all rotating). I'm as shaz really lost on how to put the codes together
Any help will be great
Ps: I rather have 3 beccons/buttons than 4 for music on my desktop (previous, next, play/stop - previous, next, stop, start)...
PHP Code:
c=$QBW_CURRENT_RESULTS_TEXT
if [ "_$c== "_" -"$QBW_EXEC_REASON== "QBW_STARTUP_UPDATE" ];then
   
# On startup, initial play state is 
   # "stopped" so just set c=0 here
   
c=0;
fi;

if [ 
"$QBW_EXEC_REASON== "QBW_CLICK" ];then
   
if [ $c -eq 1 ]; then 
      
# Add here command for Stop/Pause
      
      
c=0
   else 
      
# Add here command for Play/Resume
      
      
c=1
   
fi
fi

case "$QBW_ORIENTATION_MODEin
   
"portrait")             x=644;y=292;xt=`expr 4 + 4 \\* $c` ;;
   
"landscape (inverted)"x=644;y=155;xt=`expr 5 + 4 \\* $c` ;;
   
"portrait (inverted)")  x=0;y=155;xt=`expr 6 + 4 \\* $c` ;;
   *)                      
x=0;y=292;xt=`expr 3 + 4 \\* $c` ;;
esac

# comment next line with "sharp" (trailing char of this line) if you don't need widget move
run-standalone.sh dbus-send --session --type=method_call --dest=oh.no.more.qbw /oh/no/more/qbw$QBW_ID oh.no.more.qbw.set_position int32:$x int32:$y

echo $c
exit $xt 
__________________
Have a look at Queen BeeCon Widget (WIKI) Customizable and flexible widget-based multi-instance monitoring, alerting and interactive tool for the N900
Please provide comments and feedback for having QBW supported and enhanced further - (DONATE) - v1.3.3devel / v1.3.3testing / v1.3.3extras
 

The Following User Says Thank You to No!No!No!Yes! For This Useful Post: