Skip to content

Commit 1cd6980

Browse files
committed
release 8.2.4
1 parent 9a5d50b commit 1cd6980

40 files changed

+3730
-3689
lines changed

fx-onscreen-keyboard-samples/pom.xml

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<parent>
44
<groupId>org.comtel2000</groupId>
55
<artifactId>fx-parent</artifactId>
6-
<version>8.2.4-SNAPSHOT</version>
6+
<version>8.2.4</version>
77
</parent>
88
<artifactId>fx-onscreen-keyboard-samples</artifactId>
99
<name>fx-onscreen-keyboard-samples</name>
@@ -19,7 +19,7 @@
1919
<dependency>
2020
<groupId>org.comtel2000</groupId>
2121
<artifactId>fx-onscreen-keyboard-swing</artifactId>
22-
<version>8.2.4-SNAPSHOT</version>
22+
<version>${project.version}</version>
2323
</dependency>
2424

2525
<dependency>

fx-onscreen-keyboard-samples/src/main/java/org/comtel2000/samples/fx/MainDemo.java

+81-84
Original file line numberDiff line numberDiff line change
@@ -3,30 +3,27 @@
33
/*******************************************************************************
44
* Copyright (c) 2016 comtel2000
55
*
6-
* Redistribution and use in source and binary forms, with or without modification,
7-
* are permitted provided that the following conditions are met:
6+
* Redistribution and use in source and binary forms, with or without modification, are permitted
7+
* provided that the following conditions are met:
88
*
9-
* 1. Redistributions of source code must retain the above copyright notice, this
10-
* list of conditions and the following disclaimer.
9+
* 1. Redistributions of source code must retain the above copyright notice, this list of conditions
10+
* and the following disclaimer.
1111
*
12-
* 2. Redistributions in binary form must reproduce the above copyright notice,
13-
* this list of conditions and the following disclaimer in the documentation
14-
* and/or other materials provided with the distribution.
12+
* 2. Redistributions in binary form must reproduce the above copyright notice, this list of
13+
* conditions and the following disclaimer in the documentation and/or other materials provided with
14+
* the distribution.
1515
*
16-
* 3. Neither the name of the comtel2000 nor the names of its contributors
17-
* may be used to endorse or promote products derived from this software without
18-
* specific prior written permission.
16+
* 3. Neither the name of the comtel2000 nor the names of its contributors may be used to endorse or
17+
* promote products derived from this software without specific prior written permission.
1918
*
20-
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
21-
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
22-
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
23-
* IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
24-
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
25-
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
26-
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
27-
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
28-
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
29-
* OF THE POSSIBILITY OF SUCH DAMAGE.
19+
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
20+
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
21+
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
22+
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23+
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24+
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
25+
* WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY
26+
* WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
3027
*******************************************************************************/
3128

3229
import java.util.Locale;
@@ -52,90 +49,90 @@
5249

5350
public class MainDemo extends Application implements VkProperties {
5451

55-
@Override
56-
public void start(Stage stage) {
57-
stage.setTitle("FX Keyboard (" + System.getProperty("javafx.runtime.version") + ")");
58-
stage.setResizable(true);
52+
@Override
53+
public void start(Stage stage) {
54+
stage.setTitle("FX Keyboard (" + System.getProperty("javafx.runtime.version") + ")");
55+
stage.setResizable(true);
5956

60-
KeyBoardPopup popup = KeyBoardPopupBuilder.create().initLocale(Locale.ENGLISH).build();
57+
KeyBoardPopup popup = KeyBoardPopupBuilder.create().initLocale(Locale.ENGLISH).build();
6158

62-
VBox pane = new VBox(20);
59+
VBox pane = new VBox(20);
6360

64-
Button okButton = new Button("Ok");
65-
okButton.setDefaultButton(true);
61+
Button okButton = new Button("Ok");
62+
okButton.setDefaultButton(true);
6663

67-
Button cancelButton = new Button("Cancel");
68-
cancelButton.setCancelButton(true);
64+
Button cancelButton = new Button("Cancel");
65+
cancelButton.setCancelButton(true);
6966

70-
CheckBox spaceKeyMove = new CheckBox("Movable");
71-
spaceKeyMove.setSelected(true);
72-
popup.getKeyBoard().spaceKeyMoveProperty().bindBidirectional(spaceKeyMove.selectedProperty());
67+
CheckBox spaceKeyMove = new CheckBox("Movable");
68+
spaceKeyMove.setSelected(true);
69+
popup.getKeyBoard().spaceKeyMoveProperty().bindBidirectional(spaceKeyMove.selectedProperty());
7370

74-
CheckBox capsLock = new CheckBox("CapsLock");
75-
capsLock.setSelected(true);
76-
popup.getKeyBoard().capsLockProperty().bindBidirectional(capsLock.selectedProperty());
71+
CheckBox capsLock = new CheckBox("CapsLock");
72+
capsLock.setSelected(true);
73+
popup.getKeyBoard().capsLockProperty().bindBidirectional(capsLock.selectedProperty());
7774

78-
CheckBox numblock = new CheckBox("NumBlock");
79-
numblock.setSelected(false);
80-
numblock.selectedProperty().addListener((l, a, b) -> popup.getKeyBoard().switchLayer(b ? DefaultLayer.NUMBLOCK : DefaultLayer.DEFAULT));
75+
CheckBox numblock = new CheckBox("NumBlock");
76+
numblock.setSelected(false);
77+
numblock.selectedProperty().addListener((l, a, b) -> popup.getKeyBoard().switchLayer(b ? DefaultLayer.NUMBLOCK : DefaultLayer.DEFAULT));
8178

82-
pane.getChildren().add(new ToolBar(okButton, cancelButton, spaceKeyMove, capsLock, numblock));
79+
pane.getChildren().add(new ToolBar(okButton, cancelButton, spaceKeyMove, capsLock, numblock));
8380

84-
pane.getChildren().add(new Label("Text0"));
85-
TextField tf0 = new TextField();
86-
tf0.setPromptText("text");
87-
pane.getChildren().add(tf0);
81+
pane.getChildren().add(new Label("Text0"));
82+
TextField tf0 = new TextField();
83+
tf0.setPromptText("text");
84+
pane.getChildren().add(tf0);
8885

89-
pane.getChildren().add(new Label("Text1 (numeric)"));
90-
TextField tf1 = new TextField();
91-
tf1.setPromptText("0-9");
92-
// Currently, the vkType property supports the following values:
93-
// numeric, url, email, and text
94-
tf1.getProperties().put(VK_TYPE, "numeric");
95-
pane.getChildren().add(tf1);
86+
pane.getChildren().add(new Label("Text1 (numeric)"));
87+
TextField tf1 = new TextField();
88+
tf1.setPromptText("0-9");
89+
// Currently, the vkType property supports the following values:
90+
// numeric, url, email, and text
91+
tf1.getProperties().put(VK_TYPE, "numeric");
92+
pane.getChildren().add(tf1);
9693

97-
pane.getChildren().add(new Label("Text2 (locale 'de')"));
98-
TextField tf2 = new TextField();
99-
tf2.setPromptText("switch locale to 'DE'");
100-
tf2.getProperties().put(VK_LOCALE, "de");
101-
pane.getChildren().add(tf2);
94+
pane.getChildren().add(new Label("Text2 (locale 'de')"));
95+
TextField tf2 = new TextField();
96+
tf2.setPromptText("switch locale to 'DE'");
97+
tf2.getProperties().put(VK_LOCALE, "de");
98+
pane.getChildren().add(tf2);
10299

103-
pane.getChildren().add(new Label("Text3 (email)"));
104-
TextField tf3 = new TextField();
105-
tf3.setPromptText("email");
106-
tf3.getProperties().put(VK_TYPE, VK_TYPE_EMAIL);
107-
pane.getChildren().add(tf3);
100+
pane.getChildren().add(new Label("Text3 (email)"));
101+
TextField tf3 = new TextField();
102+
tf3.setPromptText("email");
103+
tf3.getProperties().put(VK_TYPE, VK_TYPE_EMAIL);
104+
pane.getChildren().add(tf3);
108105

109-
pane.getChildren().add(new Label("Text4 (url)"));
110-
TextField tf4 = new TextField();
111-
tf4.setPromptText("url");
112-
tf4.getProperties().put(VK_TYPE, VK_TYPE_URL);
113-
pane.getChildren().add(tf4);
106+
pane.getChildren().add(new Label("Text4 (url)"));
107+
TextField tf4 = new TextField();
108+
tf4.setPromptText("url");
109+
tf4.getProperties().put(VK_TYPE, VK_TYPE_URL);
110+
pane.getChildren().add(tf4);
114111

115-
ComboBox<String> combo = new ComboBox<>();
116-
combo.setEditable(true);
117-
combo.getProperties().put(VK_TYPE, VK_TYPE_NUMERIC);
118-
pane.getChildren().add(combo);
112+
ComboBox<String> combo = new ComboBox<>();
113+
combo.setEditable(true);
114+
combo.getProperties().put(VK_TYPE, VK_TYPE_NUMERIC);
115+
pane.getChildren().add(combo);
119116

120-
pane.getChildren().add(new TextArea());
121-
pane.getChildren().add(new Label("Password"));
122-
pane.getChildren().add(new PasswordField());
123-
pane.getChildren().add(new Separator());
117+
pane.getChildren().add(new TextArea());
118+
pane.getChildren().add(new Label("Password"));
119+
pane.getChildren().add(new PasswordField());
120+
pane.getChildren().add(new Separator());
124121

125-
Scene scene = new Scene(pane, 600, 800);
122+
Scene scene = new Scene(pane, 600, 800);
126123

127-
stage.setOnCloseRequest(e -> System.exit(0));
128-
stage.setScene(scene);
124+
stage.setOnCloseRequest(e -> System.exit(0));
125+
stage.setScene(scene);
129126

130-
popup.addDoubleClickEventFilter(stage);
131-
popup.addFocusListener(scene);
127+
popup.addDoubleClickEventFilter(stage);
128+
popup.addFocusListener(scene);
132129

133-
stage.show();
130+
stage.show();
134131

135-
}
132+
}
136133

137-
public static void main(String[] args) {
138-
Application.launch(args);
139-
}
134+
public static void main(String[] args) {
135+
Application.launch(args);
136+
}
140137

141138
}

0 commit comments

Comments
 (0)