Strict Standards: Declaration of plxFeed::prechauffage() should be compatible with plxMotor::prechauffage($mode = '', $motif = '', $bypage = '') in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.feed.php on line 490

Deprecated: Non-static method plxDate::microtime() should not be called statically, assuming $this from incompatible context in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.motor.php on line 56

Deprecated: Non-static method plxUtils::getGets() should not be called statically, assuming $this from incompatible context in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.motor.php on line 57

Deprecated: Non-static method plxUtils::mobileDetect() should not be called statically, assuming $this from incompatible context in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.motor.php on line 65

Warning: Cannot modify header information - headers already sent by (output started at /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.feed.php:490) in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.utils.php on line 558

Warning: Cannot modify header information - headers already sent by (output started at /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.feed.php:490) in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.utils.php on line 559

Deprecated: Non-static method plxDate::dateToIso() should not be called statically, assuming $this from incompatible context in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.motor.php on line 473

Warning: Cannot modify header information - headers already sent by (output started at /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.feed.php:490) in /var/www/sda/4/3/manuchap/pluxml/index.php on line 54
<br /> <b>Deprecated</b>: Non-static method plxUtils::strCheck() should not be called statically, assuming $this from incompatible context in <b>/var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.show.php</b> on line <b>135</b><br /> Dashcode et StackLayout - Blog Notes


Deprecated: Non-static method plxUtils::strCheck() should not be called statically, assuming $this from incompatible context in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.show.php on line 390
Dashcode et StackLayout

Classé dans :
Deprecated: Non-static method plxUtils::strCheck() should not be called statically, assuming $this from incompatible context in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.show.php on line 467
Web | 0 commentaire(s)


Deprecated: Non-static method plxDate::dateIsoToHum() should not be called statically, assuming $this from incompatible context in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.show.php on line 421

Deprecated: Non-static method plxDate::getCalendar() should not be called statically, assuming $this from incompatible context in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.date.php on line 109

Deprecated: Non-static method plxDate::getCalendar() should not be called statically, assuming $this from incompatible context in /var/www/sda/4/3/manuchap/pluxml/core/lib/class.plx.date.php on line 110
11
12 | 11

Vous avez un mac et vous avez installé Xcode? Bien, donc vous avez sûrement joué un peu avec Dashcode, une interface de création de site webkit/mobile. Premier tuto avec l'élément StackLayout...
Donc un tuto un peu fermé sur ce soft mais bon, c'est moi qui décide.

Dashcode est une interface wysiwyg de création de sites html/css/javascript qui s'installe avec Xcode. Le code qui suit concerne l'élément StackLayout, un snippet qui permet de gérer une pile de vues avec des transitions façon slideshow. Parmi ces transition (fade, dissolve,etc.) la transition slide est la plus prisée mais les réglages par défaut ne permettent pas un glissé de droite à gauche. Le code suivant (sur un évènement onclick) génère un glissement vers la gauche à la vue suivante:
function boutondedroite_onclick(event)
{
   var views = document.getElementById('stackLayout');
   for (var i=0;i<views.object.getAllViews().length;i++)
   {
       if (views.object.getAllViews()[i] == views.object.getCurrentView())
         var next = views.object.getAllViews()[i+1];
   }
   if (views && views.object && next) {
      views.object.setCurrentView(next);
   }
}
Pour inverser le glissement et revenir à la vue précédente il suffit de recopier cette fonction sous un autre nom (boutondegauche_onclick) et remplacer:
var next = views.object.getAllViews()[i+1];

par
var next = views.object.getAllViews()[i-1];

et
views.object.setCurrentView(next);

par
views.object.setCurrentView(next, 'reverse');


Partager cette page :

Identi.ca Twitter Digg Stumble Delicious Technorati Facebook


Ecrire un commentaire



Quelle est la première lettre du mot tzadm ? :