show all comments

results

Showing progress in seaBreeze

April 01, 2009 10:57:34 +0200 (CEST)

Some days ago Roland encountered a problem with seaBreeze where we wanted to perform a timely task after the user pressed a button. During this time the user simply had to wait and he wanted to present a progressbar to the user. As the goal of seaBreeze is to provide easy solutions to the user I wanted to make such a progress bar as simple to use as it is in VisualWorks. In VisualWorks you can do:

Notice show:'we are working on it' while:[we doALot].

The implementation for seaBreeze looks exactly like that, just with a different class:

SBAjaxProgress show:'we are working on it' while: [we doALot].

This will show a window that only tells the user that something is being done. If you know how much you have to do and you can show a progress bar, you can call:

SBAjaxProgress showProgress: 'counting...' complete: 100 while:[
        1 to: 100 do:[:i | 
            we doABit.  
            IncrementNotification raiseSignal.
        ]
    ]

That’s all there is to do.

Karsten

Progressbar screenshot

posted by Karsten Kusche

results

getting rid of XML

November 13, 2008 16:45:49 +0100 (CET)

We’ve used XML Methods in seaBreeze for a lot of stuff, most of all for the #windowSpec methods. The biggest problem with these methods were those awful hacks to the parser. I think those hacks are the main reason why seaBreeze couldn’t easily be ported to Squeak.

The last couple days I’ve worked on changing the XML representation to a more smalltalk like representation. The objects are now stored as literal arrays. It doesn’t look pretty but compared to XML it’s much simpler to work with.

The encoding and decoding is a bit different to the normal literal array approach though. In VisualWorks a class needs to implement #literalArrayEncoding or #decodeFromLiteralArray:. I wanted a more general solution and did the same that I did for the previous XML representation: simple literal array representation - slar. The idea is that an object just needs to return an array of symbols. These symbols can be used to access the required properties of the object. With this information the object is converted into a literal array and back.

The resulting literal arrays look a bit like lisp with hashes:

#( #slar 'SeaBreeze.SBSubmitButton'
    #( #positioning #( #slar 'SeaBreeze.SBPositioning'
            #( #positioningType #absolute )
            #( #layout #( #slar 'SeaBreeze.SBLayout'
                    #( #leftOffset 255 )
                    #( #topOffset 20 )
                 ) )
         ) )
    )

The #slar symbol at the beginning of the array tells the array that it has a complex object encoded via simple literal array representation. The string with the name of the class is the second object in the array. Starting with the third object there’s an array for each property of the encoded object. The first object of this subarray is the name of the property and the second object is the literal representing this property. If this object is no literal it is automatically converted.

Karsten

posted by Karsten Kusche

results

Choose your color!

June 23, 2008 15:41:07 +0200 (CEST)

Last friday I added a ColorPicker to SeaBreeze. Gone are the times of entering some wild-guessed hex color values.

There’re two different modi: one mode will select the color and save it back into your model instantly, and one will only do so on submit.

Karsten

posted by Karsten Kusche

results

Things we should change

June 11, 2008 19:16:48 +0200 (CEST)

Some things should be done differently

posted by SeaBreeze Team

results

Can we change this?

May 17, 2008 10:14:00 +0200 (CEST)

There is one thing I never really understand how to use:

posted by SeaBreeze Team

results

CSS with Dreamweaver?

May 08, 2008 08:17:00 +0200 (CEST)

Is it really aood idea to work with external stylesheets (and even external tools on them)? If there exits a company policy/style, okay, but for a new (inhouse) project I'd prefer to do everything in Seaside...

posted by SeaBreeze Team

results

Lightbox - nice effects

April 28, 2008 09:35:00 +0200 (CEST)

but do I always have to load the Scriptaculous library for it to work

posted by SeaBreeze Team

results

Can someone build a download button?

April 23, 2008 15:35:00 +0200 (CEST)

I am missing a download button (not an anchor!) where just pressing the button results in the download of a file (created on the fly) - anyone done this?

posted by SeaBreeze Team