Changeset 8288 for lang/scala

Show
Ignore:
Timestamp:
03/23/08 11:54:32 (8 months ago)
Author:
kmizu
Message:
 
Location:
lang/scala/sandbox
Files:
3 modified

Legend:

Unmodified
Added
Removed
  • lang/scala/sandbox/src/jp/gr/java_conf/mizu/gui/GUIBuilder.scala

    r7003 r8288  
    1717  Box, 
    1818  BoxLayout, 
     19  DefaultListModel, 
    1920  JButton, 
    2021  JFrame, 
    2122  JLabel, 
     23  JList, 
    2224  JPanel, 
    2325  JTextField 
     
    5153    } 
    5254    withContext(widget)(thunk) 
     55    widget 
     56  } 
     57  def list(params :Any*) :JList = { 
     58    val widget = new JList 
     59    val model = new DefaultListModel 
     60    params.foreach { 
     61      case param => model.addElement(param) 
     62    } 
     63    widget.setModel(model) 
    5364    widget 
    5465  }