-
Notifications
You must be signed in to change notification settings - Fork 5
/
GSMonitorExtended.java
47 lines (41 loc) · 974 Bytes
/
GSMonitorExtended.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
package org.genericsystem.reactor.az;
import org.genericsystem.reactor.Context;
import org.genericsystem.reactor.Tag;
import org.genericsystem.reactor.gstag.HtmlButton;
import org.genericsystem.reactor.gstag.HtmlLabel;
import javafx.beans.binding.Bindings;
public class GSMonitorExtended extends GSMonitor {
public GSMonitorExtended(Tag parent) {
this(parent, FlexDirection.ROW);
}
public GSMonitorExtended(Tag parent, FlexDirection direction) {
super(parent, direction);
}
@Override
protected void middlePart() {
createNewProperty("Ts");
new HtmlButton(this) {
{
setText("Mount");
bindAction(Context::mount);
}
};
new HtmlLabel(this) {
{
bindText(context -> Bindings.convert(context.getCacheLevelObservableValue()));
}
};
new HtmlButton(this) {
{
setText("UnMount");
bindAction(Context::unmount);
}
};
new HtmlButton(this) {
{
setText("ShiftTS");
bindAction(Context::shiftTs);
}
};
}
}