====== OpenLaszlo ====== [[http://openlaszlo.org/|Laszlo]] ... Sur les g'noux qu'je suis depuis tout à l'heure. C'est d'la balle cette application ... Encore une tuerie réalisée en Open Source. Merci les gas !! http://openlaszlo.org/. OpenLaszlo est un équivalent de "Macromedia Flex". Ne connaissant pas Flex, je ne sais pas où s'arrête la ressemble. En tout cas, d'un 1er coup d'oeil, c'est kif kif bourico. Pour vous faire une idée, et pour rejoindre le 7ième ciel des developpeurs, je vous conseille chaudement cette url : [[http://reloaded.laszlosystems.com/lps/laszlo-in-ten-minutes/|laszlo-in-ten-minutes]]. C'est des tutoriaux, de puissantes docs, des demos ... ===== Tips & Trucs ===== ==== Persistent Connection ==== Dans la doc, ils disent qu'il ne faut pas utiliser cette fonctionnalité en production. Donc à tester sauvagement pour confirmer cette infirmation. Combien de clients simultanés ? Deconnexions intempestives ? l'attribut 'group' permet de partager une connexion entre différentes applications, c'est à dire différentes url (mais tournants bien entendu sur le même serveur :-) ). ==== Addressing & Referencing objects ==== On parle de tout ça ici :\\ http://www.laszlosystems.com/developers/community/forums/showthread.php?s=&threadid=3453&highlight=parent.parent.parent You can try: classroot.searchSubviews("name", "componentName"); Here is another option. Especially if you use it more than once. and use it like so il semble que l'attribut 'id' puisse service à référencer un objet sans connaitre son chemin : lps-3.0.2/docs/reference/node.html#attr-id :\\ A global identifer for this node. If given, a pointer to this node with the given value will be placed in the global namespace. A la différence de lps-3.0.2/docs/reference/node.html#attr-name :\\ The name for this subview. If given, then this node's parent and immediate parent will use store a pointer to this node as the given name value. ==== Debug stuff ==== at script level : Debug.write( a string ); Debug.write( a string, an object ); for Embedded Debugger look at http://www.openlaszlo.org/wiki/Embedded_Debugger. for Remote Debugging look at http://www.openlaszlo.org/wiki/Remote_Debugging. ==== Load Balancing ==== Comme ça tourne avec Tomcat5, ça devrait supporter de tourner sur plusieurs serveurs. A tester donc. ==== Nested XML comment ==== Often when debugging you find yourself commenting out sections of code. Because it's illegal to nest XML comments within XML comments, this technique does not work for commented sections of declarative LZX. A good way around this problem is to use XML processing instructions which are of the form : ?> ==== File upload (swf8 only) ==== http://www.laszlosystems.com/developers/community/forums/showthread.php?threadid=3856&highlight=file+upload ==== About state object ==== === Q. === I've a strange behavior when creating method in class when it extends class dragstate. the debugger say "call to undefined method 'start'" here is the code : this.apply(); if I replace the onmousedown "myDragger.start()" by "myDragger.apply()" the code is working, so I think there is no syntax error ... Please, help ... I'm probably tired ;o) === R. === The debugger doesn't lie. States are tricky though. The attributes of a state (including methods) will be attached to the enclosing view when the state is applied, and removed when the state is removed. (The `apply` attribute and `onapply` and `onremove` events are special.) If you need to have something more happen when your state is applied, you should put that code in the `onapply` event.