Sunday, 5 July 2009

End of an Era – leaving MS

Friday was my last day at Morgan Stanley. I had a great time working there, made some good friends and met some very talented developers.

I was there for just over a year and learnt so much in that year.

It was quite sad leaving on Friday and I nearly had a tear in my eye at one point (but don't tell anyone ;) ). I'll only be across the road at my new job with HSBC though so I'll still be able to meet up with the guys.

Here is a picture from the last pink shirt Friday. It was the first time I participated as the pink shirt was a leaving present.

A special mention to Alex, Ged, Johnny, Ben, Sam, Leon, Tom, Dianne, James, Christie, Nick and Claire. I hope we’ll stay in touch and stay friends.

Sunday, 21 June 2009

Picasa Tool Update

I’ve updated my picasa tool slightly. Firstly I have corrected the spelling from picassa to picasa and I have added some more text fields. This is mostly to make it easier for me to include pictures on my car blog.

Updated version is here:

http://giles.roadnight.name/picasaTool/

There is still more that I would like to do with this tool. Ideally you’d be able to log directly into your picasa account and browse the albums and images directly and pick your image in that way.

Previous attempts to do something similar got tricky as picasa does not have a crossdomain.xml file.

Maybe I’ll do it in an air app one day.

Skinning Panel with borderSkin

I spent far longer than I should have about a week ago trying to skin Panel. This should have been a simple task but it took me about 2 days.

What I was trying to achieve was to skin a Panel with an asset from Flash as a border skin. To begin with we have an un-styled Panel (all the below versions have view source enabled):

If we then add a borderSkin style we can see that the content of the Panel overlaps the titleBar and controlBar:

As we are using our own skin class in this example one possible fix is to make our skin class extend IRectangularBorder:

The problem is though that if we are using an asset to skin our panel we can’t make the asset implement IRectangularBorder. Looking at the code for Panel there is a get viewMetrics function that is supposed to calculate the border around the content area. In our case this is not working so it seems logical that we can override it as follows:

override public function get viewMetrics() : EdgeMetrics
{
    var metrics : EdgeMetrics = super.viewMetrics;
    if( titleBar )
    {
        metrics.top = titleBar.height;
    }
    if( controlBar )
    {
        metrics.bottom = controlBar.height
    }
    return metrics;
}

However if we do this we get this result:

We get extremely odd behaviour in all sorts of other view components even outside our panel. The extra top and bottom that we add to the view metrics seems to get progressively applied to buttons, other non styled Panels and all sorts of other view components.

The solution to this is to change the above code very slightly:

override public function get viewMetrics() : EdgeMetrics
{
    var metrics : EdgeMetrics = super.viewMetrics.clone();
    if( titleBar )
    {
        metrics.top = titleBar.height;
    }
    if( controlBar )
    {
        metrics.bottom = controlBar.height
    }
    return metrics;
}

And we get the following:

I can only guess that the layout class used by Panel retains references to the EdgeMetrics objects returned from super.viewMetrics and this somehow messes up the layout of other components.

I have submitted a bug here that you can vote on if you like.

I hope this blog post helps someone else out who comes across the same problem.

Tuesday, 9 June 2009

Read Write Web article on the Matrix

Read Write Web have an article on the Matrix. They are pretty enthusiastic. Have a look here.

I think that this is all based on the microsite and don't think that they have looked at the actual app.

Shared via AddThis

Tuesday, 2 June 2009

Morgan Stanley Matrix

I’m finally allowed to talk about the project that I have been working on for pretty much the last year. I have been working for Morgan Stanley on a sales and trading platform.

This is by far the biggest project I have ever worked on and there are some really talented people on the team. I have really enjoyed working on this project. I have learnt so much in the last year. Despite the product launching soon there is still a lot of work to keep us all busy for the next few months.

Obviously I can’t link to the actual app as you need a login but there is a microsite that you can take a look at. I didn’t actually work on the microsite but it gives you some idea of what the actual application is like.

http://www.morganstanley.com/matrixinfo/

Google Wave

I'm really excited about Google Wave. It it becomes widely accepted I think it could be really useful. Check out the video:

http://www.youtube.com/watch?v=v_UyVmITiYQ

Saturday, 30 May 2009

Tweens in Flex

I came across a problem I've had before with Flex yesterday. Sometimes Tweens (and anything that relies on a Tween such as a Move or a Resize) just doesn't work. You call play() but you don't get any events from the Tween, not even a tweenStart event.

On another project I had this problem and had to write my own Tween which I called WorkingTween. I had to re-implement it yesterday.

I think it is a better implementation anyway as it just uses event listeners, you don't have to supply a listener object and you don't have to implement tweenUpdate and tweenEnd method (which you have to make public when using Tween).

My Tween you supply a startValue, endValue, duration and optionally interval and easingFunction. You then add listeners to the standard TweenEvent - tweenStart, tweenUpdate and tweenEnd.

Has anyone else had trouble with the standard Tween?