diff --git a/code/code/.vs/MDT5/v15/.suo b/code/code/.vs/MDT5/v15/.suo index 979f38c..e6abca0 100644 Binary files a/code/code/.vs/MDT5/v15/.suo and b/code/code/.vs/MDT5/v15/.suo differ diff --git a/code/code/exercise04/app/css/mobile.css b/code/code/exercise04/app/css/mobile.css new file mode 100644 index 0000000..4fb2c70 --- /dev/null +++ b/code/code/exercise04/app/css/mobile.css @@ -0,0 +1,27 @@ +.btn-style{ + min-width: 150px; + margin-right: 10px; + margin-top: 20px; +} + +body{ + padding-top: 70px; +} + +.menu { + position: absolute; + top: 0px; + left: 0px; + width: 100%; + height: 30px; + padding: 10px; + color: white; + background-color: black; +} + +.img-center{ + margin-top: 30px; + margin-left: auto; + margin-right: auto; +} + diff --git a/code/code/exercise04/app/img/bootstrap.png b/code/code/exercise04/app/img/bootstrap.png new file mode 100644 index 0000000..827be8b Binary files /dev/null and b/code/code/exercise04/app/img/bootstrap.png differ diff --git a/code/code/exercise04/app/img/css3.png b/code/code/exercise04/app/img/css3.png new file mode 100644 index 0000000..df97055 Binary files /dev/null and b/code/code/exercise04/app/img/css3.png differ diff --git a/code/code/exercise04/app/img/html5.png b/code/code/exercise04/app/img/html5.png new file mode 100644 index 0000000..1d2c265 Binary files /dev/null and b/code/code/exercise04/app/img/html5.png differ diff --git a/code/code/exercise04/app/img/jQuery.png b/code/code/exercise04/app/img/jQuery.png new file mode 100644 index 0000000..ae8e551 Binary files /dev/null and b/code/code/exercise04/app/img/jQuery.png differ diff --git a/code/code/exercise04/app/img/js.png b/code/code/exercise04/app/img/js.png new file mode 100644 index 0000000..d9f240f Binary files /dev/null and b/code/code/exercise04/app/img/js.png differ diff --git a/code/code/exercise04/app/img/react.png b/code/code/exercise04/app/img/react.png new file mode 100644 index 0000000..1333eb9 Binary files /dev/null and b/code/code/exercise04/app/img/react.png differ diff --git a/code/code/exercise04/app/index.html b/code/code/exercise04/app/index.html new file mode 100644 index 0000000..b794948 --- /dev/null +++ b/code/code/exercise04/app/index.html @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + +
+
+
+ + + + + + + + + + + + + \ No newline at end of file diff --git a/code/code/exercise04/app/scripts/app.js b/code/code/exercise04/app/scripts/app.js new file mode 100644 index 0000000..871f5be --- /dev/null +++ b/code/code/exercise04/app/scripts/app.js @@ -0,0 +1,3 @@ +function loadTemplates() { $('#navigation').load('templates/NavbarTemplate.html'); + $('#content').load('templates/AboutTemplate.html'); +} $(document).ready(loadTemplates); \ No newline at end of file diff --git a/code/code/exercise04/app/scripts/landung.js b/code/code/exercise04/app/scripts/landung.js new file mode 100644 index 0000000..a1cabfb --- /dev/null +++ b/code/code/exercise04/app/scripts/landung.js @@ -0,0 +1,77 @@ +function simulation() { + var v; + var s; + var fuel; + var schub = false; + + setStartValues(50000, -1000, 10000); + + function switchon() { + schub = true; + update(); + checkGameOver(); + } + + function switchoff() { + schub = false; + update(); + checkGameOver(); + } + + function a() { + if (schub == false || fuel <= 0) + return -1.63; + else { + fuel = fuel - 100; + return -1.63 + 12; + } + } + + function showValues() { + $("#height").html("Höhe: " + s + " m"); + $("#speed").html("Geschwindigkeit: " + v + " m/s"); + $("#fuel").html("Teibstoffvorrat: " + fuel + " l"); + } + + + function update() { + v = v + a(); + s = s + v; + showValues(); + } + + function checkGameOver() { + if (s <= 0) { + if (v < -10) + alert("Fehlschlag"); + else + alert("Erfolgreich"); + + setStartValues(50000, -1000, 10000); + showValues(); + } + } + + function setStartValues(height, velocity, Newfuel) { + v = velocity; + s = height; + fuel = Newfuel; + } + + $('#content').html("

Mondlandung

"); + $("#content").append("") + $("#content").append("
Höhe:
"); + $("#content").append("
Geschwindikgiet:
"); + $("#content").append("
Treibstoffvorrat:
"); + $("#content").append(""); + $("#content").append(""); + + + + $("#energy").click(switchon); + $("#no-energy").click(switchoff); + + showValues(); +} + + diff --git a/code/code/exercise04/app/templates/AboutTemplate.html b/code/code/exercise04/app/templates/AboutTemplate.html new file mode 100644 index 0000000..d44ecb3 --- /dev/null +++ b/code/code/exercise04/app/templates/AboutTemplate.html @@ -0,0 +1,45 @@ +
+ +
+
+
+ HTML5 LOGO +

HTML5

+

Strukturierte Inhalte für den Browser

+
+
+ CSS3 LOGO +

CSS3

+

Flexibles Design und Layout

+
+
+ Bootstrap +

Bootstrap3

+

Responsive und schick

+
+ +
+ JQuery LOGO +

JQuery

+

Zugriff auf das DOM

+
+
+ REACT LOGO +

REACT

+

Building User Interfaces

+
+
+ JavaScript +

JavaScript

+

Die Programmiersprache im Browser

+
+
diff --git a/code/code/exercise04/app/templates/NavbarTemplate.html b/code/code/exercise04/app/templates/NavbarTemplate.html new file mode 100644 index 0000000..234e88c --- /dev/null +++ b/code/code/exercise04/app/templates/NavbarTemplate.html @@ -0,0 +1,22 @@ + +