Refactored sfx control wrappers
This commit is contained in:
parent
9155fdac96
commit
052e4f0fcb
@ -11,7 +11,7 @@ import monix.bio.Task
|
|||||||
import monix.eval.Coeval
|
import monix.eval.Coeval
|
||||||
import monix.{eval => me}
|
import monix.{eval => me}
|
||||||
import nova.monadic_sfx.executors.Schedulers
|
import nova.monadic_sfx.executors.Schedulers
|
||||||
import nova.monadic_sfx.implicits.JFXButton
|
import nova.monadic_sfx.util.controls.JFXButton
|
||||||
import nova.monadic_sfx.implicits._
|
import nova.monadic_sfx.implicits._
|
||||||
import nova.monadic_sfx.ui.MyFxApp
|
import nova.monadic_sfx.ui.MyFxApp
|
||||||
import nova.monadic_sfx.ui.components.router.FXRouter
|
import nova.monadic_sfx.ui.components.router.FXRouter
|
||||||
@ -80,6 +80,7 @@ class MainAppDelegate(schedulers: Schedulers)(implicit logger: Logger[Task]) {
|
|||||||
|
|
||||||
val init =
|
val init =
|
||||||
for {
|
for {
|
||||||
|
//FXRouter does not allocate mutable state so it's ok to use pure here
|
||||||
router <- Task.pure(new FXRouter[Page])
|
router <- Task.pure(new FXRouter[Page])
|
||||||
routerStore <- router.store(Page.Home, logger)
|
routerStore <- router.store(Page.Home, logger)
|
||||||
todoStore <- TodoListStore(logger)
|
todoStore <- TodoListStore(logger)
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
package nova.monadic_sfx.ui
|
package nova.monadic_sfx.ui
|
||||||
|
|
||||||
import nova.monadic_sfx.implicits.JFXSpinner
|
import nova.monadic_sfx.util.controls.JFXSpinner
|
||||||
import scalafx.geometry.Insets
|
import scalafx.geometry.Insets
|
||||||
import scalafx.geometry.Pos
|
import scalafx.geometry.Pos
|
||||||
import scalafx.scene.Scene
|
import scalafx.scene.Scene
|
||||||
|
@ -10,9 +10,9 @@ import monix.catnap.ConsumerF
|
|||||||
import monix.execution.Scheduler
|
import monix.execution.Scheduler
|
||||||
import monix.reactive.Observable
|
import monix.reactive.Observable
|
||||||
import monix.reactive.Observer
|
import monix.reactive.Observer
|
||||||
import nova.monadic_sfx.implicits.FontIcon
|
import nova.monadic_sfx.util.controls.FontIcon
|
||||||
import nova.monadic_sfx.implicits.IconLiteral
|
import nova.monadic_sfx.util.controls.IconLiteral
|
||||||
import nova.monadic_sfx.implicits.JFXListView
|
import nova.monadic_sfx.util.controls.JFXListView
|
||||||
import nova.monadic_sfx.implicits._
|
import nova.monadic_sfx.implicits._
|
||||||
import nova.monadic_sfx.util.reactive.store._
|
import nova.monadic_sfx.util.reactive.store._
|
||||||
import scalafx.Includes._
|
import scalafx.Includes._
|
||||||
|
@ -3,12 +3,12 @@ package nova.monadic_sfx.ui.components.todo
|
|||||||
import monix.bio.Task
|
import monix.bio.Task
|
||||||
import monix.execution.cancelables.CompositeCancelable
|
import monix.execution.cancelables.CompositeCancelable
|
||||||
import monix.{eval => me}
|
import monix.{eval => me}
|
||||||
import nova.monadic_sfx.implicits.FontIcon
|
import nova.monadic_sfx.util.controls.FontIcon
|
||||||
import nova.monadic_sfx.implicits.IconLiteral
|
import nova.monadic_sfx.util.controls.IconLiteral
|
||||||
import nova.monadic_sfx.implicits.JFXButton
|
import nova.monadic_sfx.util.controls.JFXButton
|
||||||
import nova.monadic_sfx.implicits.JFXListView
|
import nova.monadic_sfx.util.controls.JFXListView
|
||||||
import nova.monadic_sfx.implicits.JFXTextField
|
import nova.monadic_sfx.util.controls.JFXTextField
|
||||||
import nova.monadic_sfx.implicits.MenuItem
|
import nova.monadic_sfx.util.controls.MenuItem
|
||||||
import nova.monadic_sfx.implicits._
|
import nova.monadic_sfx.implicits._
|
||||||
import nova.monadic_sfx.util.reactive.store._
|
import nova.monadic_sfx.util.reactive.store._
|
||||||
import org.gerweck.scalafx.util._
|
import org.gerweck.scalafx.util._
|
||||||
|
@ -6,12 +6,12 @@ import animatefx.animation.FadeIn
|
|||||||
import animatefx.util.{SequentialAnimationFX => SeqFX}
|
import animatefx.util.{SequentialAnimationFX => SeqFX}
|
||||||
import cats.effect.Sync
|
import cats.effect.Sync
|
||||||
import monix.eval.Task
|
import monix.eval.Task
|
||||||
import nova.monadic_sfx.implicits.FontIcon
|
import nova.monadic_sfx.util.controls.FontIcon
|
||||||
import nova.monadic_sfx.implicits.IconLiteral
|
import nova.monadic_sfx.util.controls.IconLiteral
|
||||||
import nova.monadic_sfx.implicits.JFXButton
|
import nova.monadic_sfx.util.controls.JFXButton
|
||||||
import nova.monadic_sfx.implicits.JFXListView
|
import nova.monadic_sfx.util.controls.JFXListView
|
||||||
import nova.monadic_sfx.implicits.JFXTextArea
|
import nova.monadic_sfx.util.controls.JFXTextArea
|
||||||
import nova.monadic_sfx.implicits.JFXTextField
|
import nova.monadic_sfx.util.controls.JFXTextField
|
||||||
import nova.monadic_sfx.ui.components.todo.TodoListComponentOld
|
import nova.monadic_sfx.ui.components.todo.TodoListComponentOld
|
||||||
import scalafx.collections.ObservableBuffer
|
import scalafx.collections.ObservableBuffer
|
||||||
import scalafx.scene.control.Label
|
import scalafx.scene.control.Label
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
package nova.monadic_sfx.implicits
|
package nova.monadic_sfx.util.controls
|
||||||
|
|
||||||
import monix.execution.Cancelable
|
import monix.execution.Cancelable
|
||||||
import monix.execution.Scheduler
|
import monix.execution.Scheduler
|
@ -1,4 +1,4 @@
|
|||||||
package nova.monadic_sfx.implicits
|
package nova.monadic_sfx.util.controls
|
||||||
|
|
||||||
import javafx.{scene => jfxs}
|
import javafx.{scene => jfxs}
|
||||||
import org.kordamp.ikonli.{javafx => ikonlifx}
|
import org.kordamp.ikonli.{javafx => ikonlifx}
|
@ -1,4 +1,4 @@
|
|||||||
package nova.monadic_sfx.implicits
|
package nova.monadic_sfx.util.controls
|
||||||
|
|
||||||
import com.jfoenix.{controls => jfoenixc}
|
import com.jfoenix.{controls => jfoenixc}
|
||||||
import javafx.{scene => jfxs}
|
import javafx.{scene => jfxs}
|
||||||
@ -6,6 +6,7 @@ import scalafx.Includes._
|
|||||||
import scalafx.beans.property.ObjectProperty
|
import scalafx.beans.property.ObjectProperty
|
||||||
import scalafx.scene.Node
|
import scalafx.scene.Node
|
||||||
import scalafx.scene.control.Button
|
import scalafx.scene.control.Button
|
||||||
|
import nova.monadic_sfx.implicits._
|
||||||
|
|
||||||
import jfxs.{paint => jfxsp}
|
import jfxs.{paint => jfxsp}
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package nova.monadic_sfx.implicits
|
package nova.monadic_sfx.util.controls
|
||||||
|
|
||||||
import com.jfoenix.{controls => jfoenixc}
|
import com.jfoenix.{controls => jfoenixc}
|
||||||
import javafx.scene.{control => jfxsc}
|
import javafx.scene.{control => jfxsc}
|
@ -1,4 +1,4 @@
|
|||||||
package nova.monadic_sfx.implicits
|
package nova.monadic_sfx.util.controls
|
||||||
|
|
||||||
import com.jfoenix.{controls => jfoenixc}
|
import com.jfoenix.{controls => jfoenixc}
|
||||||
import monix.execution.Scheduler
|
import monix.execution.Scheduler
|
||||||
@ -43,6 +43,4 @@ class JFXListView[T](
|
|||||||
def expanded = delegate.expandedProperty()
|
def expanded = delegate.expandedProperty()
|
||||||
def expanded_=(v: Boolean) = expanded() = v
|
def expanded_=(v: Boolean) = expanded() = v
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
@ -1,4 +1,4 @@
|
|||||||
package nova.monadic_sfx.implicits
|
package nova.monadic_sfx.util.controls
|
||||||
|
|
||||||
import com.jfoenix.{controls => jfoenixc}
|
import com.jfoenix.{controls => jfoenixc}
|
||||||
import scalafx.scene.control.ProgressIndicator
|
import scalafx.scene.control.ProgressIndicator
|
@ -1,4 +1,4 @@
|
|||||||
package nova.monadic_sfx.implicits
|
package nova.monadic_sfx.util.controls
|
||||||
|
|
||||||
import com.jfoenix.{controls => jfoenixc}
|
import com.jfoenix.{controls => jfoenixc}
|
||||||
import scalafx.Includes._
|
import scalafx.Includes._
|
@ -1,4 +1,4 @@
|
|||||||
package nova.monadic_sfx.implicits
|
package nova.monadic_sfx.util.controls
|
||||||
|
|
||||||
import com.jfoenix.{controls => jfoenixc}
|
import com.jfoenix.{controls => jfoenixc}
|
||||||
import scalafx.Includes._
|
import scalafx.Includes._
|
@ -1,4 +1,4 @@
|
|||||||
package nova.monadic_sfx.implicits
|
package nova.monadic_sfx.util.controls
|
||||||
|
|
||||||
import com.jfoenix.controls.datamodels.treetable.RecursiveTreeObject
|
import com.jfoenix.controls.datamodels.treetable.RecursiveTreeObject
|
||||||
import com.jfoenix.{controls => jfoenixc}
|
import com.jfoenix.{controls => jfoenixc}
|
@ -1,4 +1,4 @@
|
|||||||
package nova.monadic_sfx.implicits
|
package nova.monadic_sfx.util.controls
|
||||||
|
|
||||||
import nova.monadic_sfx.implicits._
|
import nova.monadic_sfx.implicits._
|
||||||
import scalafx.scene.{control => sfxc}
|
import scalafx.scene.{control => sfxc}
|
Loading…
Reference in New Issue
Block a user