Add support for DPI within size instruction and client info.

This commit is contained in:
Michael Jumper
2013-12-27 00:35:21 -08:00
parent 9b20d5e1eb
commit b722cf5977
5 changed files with 46 additions and 8 deletions

View File

@@ -953,7 +953,11 @@ GuacUI.Client.attach = function(guac) {
*/
window.onresize = function() {
guac.sendSize(window.innerWidth, window.innerHeight);
var pixel_density = window.devicePixelRatio || 1;
var width = window.innerWidth * pixel_density;
var height = window.innerHeight * pixel_density;
guac.sendSize(width, height);
GuacUI.Client.updateDisplayScale();
};