Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix virtual keyboard display on mobile device #9

Merged
merged 1 commit into from
Jun 28, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Fix virtual keyboard display on mobile device
  • Loading branch information
akfish committed Jun 28, 2014
commit c53ec13b4cdd3e043b126d642b9f0bc5cc101002
3 changes: 2 additions & 1 deletion web/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@
<link rel="shortcut icon" href="favicon.ico" type="image/x-icon" />
</head>
<body>
<input type="text" id="hidden-input"/>
<div id="content"></div>

<script src="/socket.io/socket.io.js"></script>
<script src="jquery.js"></script>
<script src="init.js"></script>
</body>
</html>
</html>
4 changes: 4 additions & 0 deletions web/init.js
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,10 @@
return output;
}

content.click(function (e) {
$("#hidden-input").focus();
});

$(window.document).keydown(function (e) {
var part1, part2;

Expand Down
5 changes: 5 additions & 0 deletions web/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,9 @@ body {
.inverse {
background-color: #FFFFFF;
color: #290029;
}

#hidden-input {
position: absolute;
top: -100px;
}