View this PageEdit this PageAttachments to this PageHistory of this PageHomeRecent ChangesSearch the SwikiHelp Guide
Hotspots: Admin Pages | Turn-in Site |
Current Links: Cases Final Project Summer 2007

Discussion 3 - Sashmit Bhaduri

In detail, describe a feature of Squeak that you have found particularly useful. What is the feature? Why is it useful? How do you envoke it?

I'm gonna title this YAFS (Yet Another File Selector). During Milestone 2, I was looking for a file selector
class that was similiar to the Java file selector. StandardFileMenu was recommended by some of the TA's. It was
cool but wasn't quite what I had envisioned. So I looked around I found the FileList and FileList2 classes. They looked intriguing, but I had no idea how to use them. After some googling and looking through the code, I found one that suited
my needs perfectly. Enter FileList2 morphicViewFileSelector!

Here is a screenshot:


Here is some sample code:

"open the morph"
fView:=FileList2 morphicViewFileSelector openInWorld.

"make sure we process events while the file selector is open"
[fView world notNil] whileTrue: [
	fView outermostWorldMorph doOneCycleNow.
].

"get the full pathname of the selected file as a string"
fName :=(fView valueOfProperty: #fileListModel) getSelectedFile name.


This particular file selector is useful because:
1). it interfaces well with morphic
2). it's more powerful than standardfilemenu
3). it's like the file selectors we're used to
4). it can work in modal and non-modal ways


Part Deux:

In Discussion 3 - Jiasheng He, Jiasheng talked about MonkeyBrowser. It sounds like an absolute
must in the toolbox of every 2340 student. Looking at multiple functions sounds like a great
feature– I hate having 3 or 4 browsers getting buried under transcripts, test widgets, workspaces
, etc.. MonkeyBrowser seems exactly like what I need.

In Discussion 3 - Nirav Shah, Nirav talks about a very interesting class: CustomMenu. I've also been
looking for a selection menu-type of morph. It sounds useful in Milestone 3 (e.g, selecting choices
like layouts, etc...)



Links to this Page