Browse Source

Add `HostOS` utility

This currently calls out to a private JavaFX utility from Sun. If that
changes, I'll modify the code to use the system properties directly.
master
Sarah Gerweck 8 years ago
parent
commit
f0ced5fd66
  1. 13
      src/main/scala/org/gerweck/scalafx/util/HostOS.scala

13
src/main/scala/org/gerweck/scalafx/util/HostOS.scala

@ -0,0 +1,13 @@
package org.gerweck.scalafx.util
import com.sun.javafx.PlatformUtil
/** Utilities for identifying the Host OS of the application.
*
* @author Sarah Gerweck <sarah.a180@gmail.com>
*/
object HostOS {
lazy val isMac = PlatformUtil.isMac()
lazy val isUnix = PlatformUtil.isUnix()
lazy val isWindows = PlatformUtil.isWindows()
}
Loading…
Cancel
Save