All Downloads are FREE. Search and download functionalities are using the official Maven repository.

scala.swing.SimpleSwingApplication.scala Maven / Gradle / Ivy

There is a newer version: 2.11.0-M7
Show newest version
package scala.swing

abstract class SimpleSwingApplication extends SwingApplication {
  def top: Frame

  override def startup(args: Array[String]) {
    val t = top
    if (t.size == new Dimension(0,0)) t.pack()
    t.visible = true
  }

  def resourceFromClassloader(path: String): java.net.URL =
    this.getClass.getResource(path)

  def resourceFromUserDirectory(path: String): java.io.File =
    new java.io.File(util.Properties.userDir, path)
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy