[aida] Source browser and list question

Janko Mivšek janko.mivsek at eranova.si
Fri Nov 7 21:23:44 CET 2008

Hi Michael,

We actualy have a form element for such scrollable list box, it is a 
WebMenu with its size set. If you set the size, it is not anymore drop 
down menu but becomes a list box with scrollers on the left.

Quick example:

	m := WebMenu new.
	m collection: #('First' 'Second' 'Third').
	m size: 10.

Now for your task (let say you have an instvar #selectedClass in your App):

   m := WebMenu new.
   m size := 10.
   m collection: self classNames
       selectedToAspect: #selectedClass of: self.
     onChangePostAndUpdate: methodsElement;
     onChangePostAndUpdate: methodElement.

I hope this helps.

Michael Rueger wrote:
> Michael Rueger wrote:
>> - how do I build a simple scrolling list interface like Yoshiki used for 
>> his code browser 
>> (http://tinlizzie.org:8080/seaside/examples/authorship2)? Couldn't find 
>> any example or even a matching web element in AIDA, but I'm still pretty 
>> much a newbie as far as AIDA is concerned...
> Some progress :-)
> I'm working somewhat outside of AIDA's supported features with the 
> overflow:auto style setting. Although one might argue it is really a CSS 
> layout setting, as it only really affects the layout of the page, not 
> the functionality.
> classesElement
> 	| e list |
> 	e := WebElement new.
> 	e
> 		setDiv;
> 		style: 'OVERFLOW: auto; WIDTH: 300px; HEIGHT: 200px;';
> 		yourself.
> 	list := WebGrid new
> 		columnAspects: #(nil name);
> 		columnLinkViews: #(nil main);
> 		collection: self observee classes;
> 		yourself.
> 	e add: list.
> 	^e
> Tips and tricks welcome, but I'll keep you posted about my progress.
> Michael
> _______________________________________________
> Aida mailing list
> Aida na aidaweb.si
> http://lists.aidaweb.si/mailman/listinfo/aida

Janko Mivšek
Smalltalk Web Application Server

More information about the Aida mailing list