From 15cc649b270434308d3ed0d2f111af69c1d5bd73 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Sun, 20 Oct 2013 14:35:29 +0200 Subject: [PATCH] Platform: markup improvements for web applications. Indented and cleaned up cruft from HTML template, renamed NaClApplication.css to WebApplication.css, as it is universal and not tied only to NaCl. --- src/Platform/CMakeLists.txt | 2 +- src/Platform/NaClApplication.h | 32 ++++---- ...NaClApplication.css => WebApplication.css} | 0 src/Platform/magnum-info-nacl.html | 74 +++++++++---------- 4 files changed, 54 insertions(+), 54 deletions(-) rename src/Platform/{NaClApplication.css => WebApplication.css} (100%) diff --git a/src/Platform/CMakeLists.txt b/src/Platform/CMakeLists.txt index afabc07ad..e0d0461a1 100644 --- a/src/Platform/CMakeLists.txt +++ b/src/Platform/CMakeLists.txt @@ -86,7 +86,7 @@ endif() # JavaScript and CSS stuff for NaCl if(WITH_NACLAPPLICATION OR WITH_WINDOWLESSNACLAPPLICATION) - install(FILES NaClApplication.js NaClApplication.css DESTINATION ${MAGNUM_DATA_INSTALL_DIR}) + install(FILES NaClApplication.js WebApplication.css DESTINATION ${MAGNUM_DATA_INSTALL_DIR}) endif() # GLX application diff --git a/src/Platform/NaClApplication.h b/src/Platform/NaClApplication.h index 815d39601..632232c02 100644 --- a/src/Platform/NaClApplication.h +++ b/src/Platform/NaClApplication.h @@ -75,26 +75,26 @@ to simplify porting. You need to provide HTML markup for your application. Template one is below, you can modify it to your liking. The markup references two files, -`NaClApplication.js` and `NaClApplication.css`, both are in `Platform/` +`NaClApplication.js` and `WebApplication.css`, both are in `Platform/` directory in the source tree and are also installed into `share/magnum/` inside your NaCl toolchain. @code - - -Magnum NaCl Application - - - - -

Magnum NaCl Application

-
- - -
Initialization...
-
-
- + + + Magnum NaCl Application + + + + +

Magnum NaCl Application

+
+ +
Initialization...
+
+ +
+ @endcode diff --git a/src/Platform/NaClApplication.css b/src/Platform/WebApplication.css similarity index 100% rename from src/Platform/NaClApplication.css rename to src/Platform/WebApplication.css diff --git a/src/Platform/magnum-info-nacl.html b/src/Platform/magnum-info-nacl.html index cd679fb9d..eb9941637 100644 --- a/src/Platform/magnum-info-nacl.html +++ b/src/Platform/magnum-info-nacl.html @@ -1,41 +1,41 @@ - - -Magnum Info - - - - - -

Magnum Info

-
- - + - -
Initialization...
-
-
-
- + var listener = document.getElementById('listener'); + listener.addEventListener('message', messageReceived, true); + +
+