aboutsummaryrefslogtreecommitdiff
path: root/tests/test_html5.c
diff options
context:
space:
mode:
authorJukka Jylänki <jujjyl@gmail.com>2014-02-26 12:05:13 +0200
committerJukka Jylänki <jujjyl@gmail.com>2014-02-26 12:11:15 +0200
commit793eb176a0c777d91941cb17386de0f5da981bac (patch)
tree3cf9760bda0d588a05ebe9dec9b7bd4dd610b37b /tests/test_html5.c
parente2d05d569d7848d15ddd956e5c456d81f7bf9292 (diff)
Add new fields to EmscriptenFullscreenChangeEvent structure that report the new pixel sizes of the fullscreen element, as well as the whole screen size. These can be used to read and adjust the rendering canvas size appropriately when transitioning between fullscreen modes. Thanks to Joel Croteau for the suggestion at https://groups.google.com/forum/#!topic/emscripten-discuss/qaTrOXWv1Oc .
Bump version to 1.12.3 to update the cache after change to struct_info.json.
Diffstat (limited to 'tests/test_html5.c')
-rw-r--r--tests/test_html5.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/test_html5.c b/tests/test_html5.c
index 77ddea98..fec46035 100644
--- a/tests/test_html5.c
+++ b/tests/test_html5.c
@@ -145,8 +145,8 @@ EM_BOOL orientationchange_callback(int eventType, const EmscriptenOrientationCha
EM_BOOL fullscreenchange_callback(int eventType, const EmscriptenFullscreenChangeEvent *e, void *userData)
{
- printf("%s, isFullscreen: %d, fullscreenEnabled: %d, fs element nodeName: \"%s\", fs element id: \"%s\"\n",
- emscripten_event_type_to_string(eventType), e->isFullscreen, e->fullscreenEnabled, e->nodeName, e->id);
+ printf("%s, isFullscreen: %d, fullscreenEnabled: %d, fs element nodeName: \"%s\", fs element id: \"%s\". New size: %dx%d pixels. Screen size: %dx%d pixels.\n",
+ emscripten_event_type_to_string(eventType), e->isFullscreen, e->fullscreenEnabled, e->nodeName, e->id, e->elementWidth, e->elementHeight, e->screenWidth, e->screenHeight);
return 0;
}