iAudiophile.net Forums
Go Back   iAudiophile.net Forums > Flash-Memory Players > Cowon S9 > S9 UCI Themes & Stuff

Post New Thread  Reply
 
Thread Tools Display Modes
Old 09-09-2009, 15:07   #1
planetLars
Member
 
planetLars's Avatar
 
Join Date: Aug 2009
Location: Germany
Posts: 48
Send a message via Yahoo to planetLars
Thumb Up [Menu UCI] UCI chooser Free Open Source please support

Please sticky

Hello everyone,

I coded a UCI launcher which allows changing UCIs. All you have to do is: add your UCI to the launcher and post an updated version here. To call the launcher from your UCI, add the following code:
Code:
	var uciconf : SharedObject = SharedObject.getLocal("UCIchoosersSaveState");
	uciconf.data.UCIchosen=-1;
	uciconf.flush();
	ext_fscommand2("EtcUsrSetMainmenu", "0");
	_global.Load_SWF(_global.MODE_MAIN);


Here is the code of the launcher. Get the .fla and a working example from http://planetlars.net/store/BB.zip.
Code:
/*start code*/

var UCIs : Array = new Array();
var UCIOffs : Array = new Array();
var UCICovers : Array = new Array();

/*please add to*/
UCIs.push(Aero);
UCIOffs.push(AeroOff);
UCICovers.push(AeroCover);
UCIs.push(Swipe);
UCIOffs.push(SwipeOff);
UCICovers.push(SwipeCover);
UCIs.push(Puzzle);
UCIOffs.push(PuzzleOff);
UCICovers.push(PuzzleCover);
UCIs.push(BB);
UCIOffs.push(BBOff);
UCICovers.push(BBCover);


var UCISWFnames : Array = ["Aero.swf","Swipe.swf","Puzzle.swf","BB.swf"];
var OnForEachUCI : Number = 15; // 1111 bitwise //the decimal representation of the binary number which consists of 1s only and has got as many 1s as there are UCIs.
/*adding end*/



/*do not touch*/
var conf : SharedObject = SharedObject.getLocal("UCIchoosersSaveState");
var UCIchosen : Number = conf.data.UCIchosen;
if(UCIchosen==undefined)
{
	conf.data.UCIchosen=-1;
	conf.flush();
}
else if(UCIchosen>=0&&UCIchosen<UCISWFnames.length) _global.Load_SWF(_global.MODE_ETC,UCISWFnames[UCIchosen]);
var visibly : Number = conf.data.visibly;
if(visibly==undefined)
{
	conf.data.visibly=OnForEachUCI;
	conf.flush();
	visibly=OnForEachUCI;
}
for(i=0;i<UCIs.length;i++)
{
	if(visibly-(visibly|1)==-1)
	{
		UCIs[i]._visible=false;
		UCIOffs[i]._visible=false;
		UCICovers[i]._visible=false;
	}
	visibly>>=1;
}
/*do not touch end*/



/*please add to*/
AeroCover.onRelease=function()
{
	_root.conf.data.UCIchosen=0;
	_root.conf.flush();
	_global.Load_SWF(_global.MODE_ETC,_root.UCISWFnames[0]);
}

AeroOff.onRelease=function()
{
	_root.conf.data.visibly=conf.data.visibly&14; // 1110 bitwise
	_root.conf.flush();
	Aero._visible=false;
	AeroOff._visible=false;
	AeroCover._visible=false;
}


SwipeCover.onRelease=function()
{
	_root.conf.data.UCIchosen=1;
	_root.conf.flush();
	_global.Load_SWF(_global.MODE_ETC,UCISWFnames[1]);
}

SwipeOff.onRelease=function()
{
	_root.conf.data.visibly=conf.data.visibly&13; // 1101 bitwise
	_root.conf.flush();
	Swipe._visible=false;
	SwipeOff._visible=false;
	SwipeCover._visible=false;
}


PuzzleCover.onRelease=function()
{
	_root.conf.data.UCIchosen=2;
	_root.conf.flush();
	_global.Load_SWF(_global.MODE_ETC,_root.UCISWFnames[2]);
}

PuzzleOff.onRelease=function()
{
	_root.conf.data.visibly=conf.data.visibly&11; // 1011 bitwise
	_root.conf.flush();
	Puzzle._visible=false;
	PuzzleOff._visible=false;
	PuzzleCover._visible=false;
}


BBCover.onRelease=function()
{
	_root.conf.data.UCIchosen=3;
	_root.conf.flush();
	_global.Load_SWF(_global.MODE_ETC,_root.UCISWFnames[3]);
}

BBOff.onRelease=function()
{
	_root.conf.data.visibly=conf.data.visibly&7; // 0111 bitwise
	_root.conf.flush();
	BB._visible=false;
	BBOff._visible=false;
	BBCover._visible=false;
}
/*adding end*/



AllOnCover.onRelease=function()
{
	for(i=0;i<_root.UCIs.length;i++)
	{
		_root.UCIs[i]._visible=true;
		_root.UCIOffs[i]._visible=true;
		_root.UCICovers[i]._visible=true;
	}
	_root.conf.data.visibly=_root.OnForEachUCI;
	_root.conf.flush();
}



/*enable if you had to create a new mainmenu page, 3 mainmenu pages total maximum!*/
FlipCover.onRelease=function()
{
	/*
	ext_fscommand2("EtcUsrSetMainmenu", "1");
	_global.Load_SWF(_global.MODE_MAIN2);
	*/
}
/*enabling end*/

/*end of code*/

Hope it helps and gets supported The foot is from GNOME. It's their logo, yet as far as I understood from their brands page free to use.


planetLars
planetLars is offline View planetLars's Photo Album   Reply With Quote
Thanks from:
Old 09-09-2009, 16:37   #2
Ilmadic
Senior Member
 
Join Date: Mar 2009
Location: Germany, Leipzig
Posts: 276
Default

very nice
__________________
current: Cowons S9 16gb
previous: Archos Gmini 402
earbuds:
Shure SE115
AKG K 324 P
Sennheiser HD 202
Ilmadic is offline View Ilmadic's Photo Album   Reply With Quote
Old 09-10-2009, 01:29   #3
Zetx
Junior Member
 
Join Date: Sep 2004
Posts: 3
Default

Very nice. I have some ideas I would like to see if I can implement. I'm getting my S9 later today.
Zetx is offline View Zetx's Photo Album   Reply With Quote
Old 09-28-2009, 16:21   #4
planetLars
Member
 
planetLars's Avatar
 
Join Date: Aug 2009
Location: Germany
Posts: 48
Send a message via Yahoo to planetLars
Default

I bump this only this one time for the foreseeable future to get the attention of other developers.
Even if there are the names of UCIs other than BigButtons listed in the current version, they are not supported right now. They are placeholders only.
__________________
avatar and signature images cut from the Opera 10 wallpaper
planetLars is offline View planetLars's Photo Album   Reply With Quote
Old 12-07-2009, 15:59   #5
JunglePimp
We're still breathing baby.
 
JunglePimp's Avatar
 
Join Date: Nov 2009
Location: Dilli, India
Posts: 1,179
Send a message via Yahoo to JunglePimp
Default

Sorry but I couldn't really understand the use of the launcher.. unless it's related to launching UCIs.. for which I don't see how designers' support is needed. Help me out, someone.
__________________
  • If you're having major troubles with your player:
1. Search the forum for similar problems
2. Reinstall firmware
if this fails, THEN start a thread about it.
Signature Permissions For New Members

DonIago never leaves spam threads/bots for me to delete/ban
JunglePimp is offline View JunglePimp's Photo Album   Reply With Quote
Old 12-08-2009, 08:23   #6
planetLars
Member
 
planetLars's Avatar
 
Join Date: Aug 2009
Location: Germany
Posts: 48
Send a message via Yahoo to planetLars
Default

Hi, the launcher is for launching UCIs. The launcher automatically launches the last chosen UCI after the S9 has powered on (it replaces mainmenu1). In order to show the launcher again a UCI coder/designer has to add the code mentioned at the beginning of the first post to his/her UCI. Also a text entry has to be added to the launcher with which to access the UCI. Currently I'm only aware of BigButtons being able to show the launcher again, the other shown UCIs were placeholders meant to show how it looks with several UCIs. Perhaps this launcher is obsolete as I read something about a xml-based launcher which may be supported natively by the S9. Perhaps that one is in wide-spread use already? I don't know as I don't follow the forum anymore for time-reasons.
__________________
avatar and signature images cut from the Opera 10 wallpaper
planetLars is offline View planetLars's Photo Album   Reply With Quote
Reply

Tags
chooser, launcher, selector, uci

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 17:07.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2013, vBulletin Solutions, Inc.


Copyright © 2006-2011 CrowdGather |  About iAudiophile |  Advertisers | Investors | Legal | Contact