Home Blog erstellt am: : 12/03/08 Zuletzt aktualisiert : 03/01/10 18:47 / 126 veröffentlichte Einträge
 

2.5.1 Elemente  (II. WebDev dashcode) Verfasst: Sonntag, den 16. März 2008 21:31

wie man sehen kann gibt es noch nicht soviele Elemente fürs iphone wie für z.B fürs Dashboard Widget ...  bei Dashboard Widget hat man noch mehr Spielzeug zur Verfügung ... jedoch setzen diese Ebtwicklung dann einen PC Browser vorraus und können in das eigene Dashboard installiert werden ....

Permalink

2.6 6aus49  (II. WebDev dashcode) Verfasst: Montag, den 17. März 2008 10:56

ok dann malen wir mal rum bis das ganze ungefähr so aussieht wie im Bild (1 Knopf und 7 TextAreas)  Tipp : Elemente im Infofenster Metrics auf Absolut stellen ... ich habe fast alles über die Information geändert ...  wenn man fertig ist mit der Malerei wird das Main.js editiert ... den Event onclick bei dem Button nicht vergessen...

___________

Links fürs Iphone (sieht schrecklich aus unter IE)

http://izero.host4free.de/6aus49/

Permalink

2.6.1 do while  (II. WebDev dashcode) Verfasst: Montag, den 17. März 2008 11:03

so nun den code eintippen ... ich benutze hier eine do while Schleife für die Zufallszahl ... im einzelnen Math.random erzeigt eine Zufallszahl zwischen 0 und 1 z.B. 0,5737788  - diese neme ich mal hundert und runde mit Math.round ab ... und dieses wird sollange wider holt bis die bedingungt im nagativen sinne erfüllt sind ... also nicht größe als 49 , nicht gleich null und nicht schon vorhanden...


// This file was generated by Dashcode from Apple Inc.
// You may edit this file to customize your web application.

//
// Function: load()
// Called by HTML body element's onload event when the web application is ready to start
//
function load()
{
    setupParts();
}


function meinClickHandler(event)
{    // Code hier eingeben
var textAreaToChange = document.getElementById("textarea"); 
do { var newTextAreaText = Math.round ((Math.random())*100);
} while (newTextAreaText > 49 || newTextAreaText == 0);
textAreaToChange.value = newTextAreaText;
var zahl = newTextAreaText;

var textAreaToChange = document.getElementById("textarea1"); 
do { var newTextAreaText = Math.round ((Math.random())*100);
} while (newTextAreaText > 49 || newTextAreaText == zahl || newTextAreaText == 0);
textAreaToChange.value = newTextAreaText;
var zahl1 = newTextAreaText;

var textAreaToChange = document.getElementById("textarea2"); 
do { var newTextAreaText = Math.round ((Math.random())*100);
} while (newTextAreaText > 49 || newTextAreaText == zahl || newTextAreaText == zahl1 || newTextAreaText == 0);
textAreaToChange.value = newTextAreaText;
var zahl2 = newTextAreaText;

var textAreaToChange = document.getElementById("textarea3"); 
do { var newTextAreaText = Math.round ((Math.random())*100);
} while (newTextAreaText > 49 || newTextAreaText == zahl || newTextAreaText == zahl1 || newTextAreaText == zahl2 || newTextAreaText == 0);
textAreaToChange.value = newTextAreaText;
var zahl3 = newTextAreaText;

var textAreaToChange = document.getElementById("textarea4"); 
do { var newTextAreaText = Math.round ((Math.random())*100);
} while (newTextAreaText > 49 || newTextAreaText == zahl || newTextAreaText == zahl1 || newTextAreaText == zahl2 || newTextAreaText == zahl3 || newTextAreaText == 0);
textAreaToChange.value = newTextAreaText;
var zahl4 = newTextAreaText;

var textAreaToChange = document.getElementById("textarea5"); 
do { var newTextAreaText = Math.round ((Math.random())*100);
} while (newTextAreaText > 49 || newTextAreaText == zahl || newTextAreaText == zahl1 || newTextAreaText == zahl2 || newTextAreaText == zahl3 || newTextAreaText == zahl4 || newTextAreaText == 0 );
textAreaToChange.value = newTextAreaText;
var zahl5 = newTextAreaText;

var textAreaToChange = document.getElementById("textarea6"); 
do { var newTextAreaText = Math.round ((Math.random())*100);
} while (newTextAreaText > 49 || newTextAreaText == zahl || newTextAreaText == zahl1 || newTextAreaText == zahl2 || newTextAreaText == zahl3 || newTextAreaText == zahl4 || newTextAreaText == zahl5 || newTextAreaText == 0);
textAreaToChange.value = newTextAreaText;

}

Permalink

2.6.2 Autoresize unter Metrics  (II. WebDev dashcode) Verfasst: Montag, den 17. März 2008 11:24

so damit es nicht aus dem Bild kommt beim derhene und so bauen wir noch 4 Federn in die Metric vom rounded RectangleShape ein. Zusätzlich verbessert sich die Ansicht im SIm wenn man den Footer erstmal löscht .

Permalink

2.6.3 textareas  (II. WebDev dashcode) Verfasst: Montag, den 17. März 2008 12:01

ok wer es mit der creativität nicht so hat hier mal die Einstellungen meiner grünen Textareas ... unter Attributes ist hier wichtig den Hacken aus Texarea Enable zu deaktivieren , damit nimand auf die Idee kommt dort etwas reinschreiben zu wollen.

Permalink