-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
33 lines (33 loc) · 1.17 KB
/
index.html
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
<!doctype html>
<html>
<meta charset="utf-8">
<title>Keyboard</title>
<link rel="stylesheet" type="text/css" href="keyboard.css" />
<body>
<div class="container">
<input type="button" value="展开/收起键盘" id="open" class="open" />
<span>输出结果1:</span><input type="text" class="result" />
<span>输出结果2:</span><input type="text" class="result" /><br/>
</div>
<script type="text/javascript" src="./lib/jquery-1.10.2.js"></script>
<script type="text/javascript" src="./j.keyboard.js"></script>
<script type="text/javascript">
$(function() {
$('#open').click(Keyboard.toggleKeyboard);
Keyboard.initKeyboard({
//left : 600,
//top : 40,
//keyboardName : 'lowerCaseKeyboard',
defaultInput : $('input.result:first'),
confirm : function() {
console.log($('[focused]').val());
},
fn : function() {
console.log($('[focused]').val());
},
inputs : $('input.result')
});
});
</script>
</body>
</html>