Wednesday, December 31, 2008

My Zune Died today

So my Zune died today like many others of its origin and stripe.

First Microsoft denied the problem,

They then accepted that there is a problem after they were flooded with customers

They started investigating only to find that they forgot the concept of Leap Years. Somehow the zunes that we have don't know that some years are longer than others.

Finally they refused to fix it .. saying "The problem will fix itself tomorrow at noon". But drain your battery to trick your zune into restarting.

Now imagine this was your car! Or better yet a tanning bed.... You'd come out looking worse than some of us.

So for now my zune is up on craigslist or just hit me up.

Here is the post from Microscrew! http://forums.zune.net/412486/ShowPost.aspx
New maxim for 2009.

What have you changed today? (Dickens 2009)

Fresh thinking yields new ideas. (Dickens 2007)

any good system is free of surprises and delivers on expectations (Dickens 2008)

Thursday, December 18, 2008

Simple scrolling dynamic text in flash

Just make sure you have a field named dynamicTextField;

var scrolling:Boolean = false;
var displayWidth:Number = 190;
var originalX:Number = nowPlaying.x;
var maxWidth:Number = dynamicTextField.textWidth;
var position:Number = dynamicTextField.x + maxWidth;
var moveLeft:Boolean = true;
var scrollTimer:uint;

//add event listeners to the text field
dynamicTextField.addEventListener(MouseEvent.MOUSE_OVER, startScroll);
dynamicTextField.addEventListener(MouseEvent.MOUSE_OUT, endScroll);

function startScroll(e:MouseEvent) : void {
if(!scrolling && maxWidth > displayWidth) {
scrolling = true;
moveLeft = true;
nowPlaying.x = originalX;
clearInterval(scrollTimer);
scrollTimer = setInterval(scrollNowPlaying, 50);
}
}

function scrollNowPlaying() : void {

if( moveLeft ) {
position = position - 2;
moveLeft = position > displayWidth - originalX;
} else {
position = position + 2;
moveLeft = position > originalX + maxWidth;
if( moveLeft ) {
clearInterval(scrollTimer);
scrolling = false;
position = nowPlaying.x + maxWidth;
}

}
dynamicTextField.x = position - maxWidth;

}

function endScroll(e:MouseEvent) : void {
moveLeft = false;
}