Test adding syles to todoListView

This commit is contained in:
Rohan Sircar 2020-12-21 13:20:41 +05:30
parent cfc11368b7
commit 08fe33b5d8

View File

@ -46,6 +46,45 @@ object TodoListView {
selectionModel().selectionMode = SelectionMode.Multiple selectionModel().selectionMode = SelectionMode.Multiple
selectionModel().selectedItems.observableSeqValue ==> _selectedItems selectionModel().selectedItems.observableSeqValue ==> _selectedItems
stylesheets ++= Seq(
(os.rel / "static" / "css" / "main.css").toString
)
style = """|
| .scroll-bar:horizontal .track,
| .scroll-bar:vertical .track{
| -fx-background-color:transparent;
| -fx-border-color:transparent;
| -fx-background-radius: 0em;
| -fx-border-radius:2em;
| }
|
| .scroll-bar:horizontal .increment-button ,
| .scroll-bar:horizontal .decrement-button {
| -fx-background-color:transparent;
| -fx-background-radius: 0em;
| -fx-padding:0 0 10 0;
| }
|
| .scroll-bar:vertical .increment-button ,
| .scroll-bar:vertical .decrement-button {
| -fx-background-color:transparent;
| -fx-background-radius: 0em;
| -fx-padding:0 10 0 0;
| }
| .scroll-bar .increment-arrow,
| .scroll-bar .decrement-arrow{
| -fx-shape:" ";
| -fx-padding:0;
| }
|
| .scroll-bar:horizontal .thumb,
| .scroll-bar:vertical .thumb {
| -fx-background-color:derive(black,90%);
| -fx-background-insets: 2, 0, 0;
| -fx-background-radius: 2em;
}""".stripMargin
cc += items <-- todos cc += items <-- todos
val emptyCell = ObjectProperty(new HBox) val emptyCell = ObjectProperty(new HBox)
@ -78,10 +117,6 @@ object TodoListView {
contextMenu = new ContextMenu { contextMenu = new ContextMenu {
items ++= Seq( items ++= Seq(
new MenuItem {
text = "Add"
// obsAction.useLazyEval(TodoListStore.Add("blah3")) --> store
},
new MenuItem { new MenuItem {
text = "Delete" text = "Delete"
obsAction.useIterableEval(_ => obsAction.useIterableEval(_ =>