rogerhoward | 3 Mar 2008 15:10

Novice help - animating a view on mouseout

I'm a novice with OpenLaszlo, though I work a lot with Flex. I'm
learning OL to possibly use the LZC compiler to generate
SWFs as part of a batch process, and as well as a learning exercise.
I've got a question about mouse tracking and animating a multiimage
resource on mouseout and OL is different enough from Flex that I'm a
little stumped.

I've reduced my code to the relevant parts below. This LZX loads 18
frames (in this case) into a view, and using mousetracking switches the
current frame (using setResourceNumber) based on the position of the
mouse on the x plane. This much works fine.

When the mouse leaves the view I'd like to trigger the sequence of
frames to play as a looping animation, regaining mouse control only when
the mouse enters the view. I've tried adding a onmouseout handler  to
call play() on the view but I can't get anywhere.

What am I missing?

Thanks,

Roger Howard

----- Example below -----

<canvas width="320" height="240">

   <resource name="spinframes">
       <frame src="001.jpg" />
       <frame src="003.jpg" />
(Continue reading)

Prateek Dayal | 4 Mar 2008 18:27
Picon

Openlaszlo for icecast client?

Hi

I have just setup a radio stream and I wanted to write a flash client
in openlaszlo .. but it does not seem to be working.

Can laszlo play an icecast stream ? If yes, then do we need  to do
something special for that?

Thanks & Regards

--

-- 
Prateek Dayal

www.Muziboo.com
get an audience

Elliot Winard | 5 Mar 2008 17:53

suggestions for tracking down source of INFO message in pagan-deities?

I'm changing the debug messageLevel used in a large application from 
WARNING to ALL [0] to complete a port from wafflecone to the 
pagan-deities branch of OLS.

One of the INFO messages that shows up is a message about global `menu` 
already being defined.
I grepped through the code (I didn't write all of it) and it is not 
obvious what LZX (or ECMAScript) is triggering this warning.

What's the best way to track this down?  I filed  LPP-5545 to track this 
issue.

Thanks,
-e

[0]
I'm removing this -
Debug.messageLevel='WARNING';

[0]
INFO: The global `menu` is already defined.  To dynamically create a 
<menu> element, you will have to use `lz.menu`.
INFO  <at> ../../applib/contacts/contacts.lzx#384: getNodeAttribute: p is 
null in LzDatapointer  
lzx> Debug.inspect(«LzInfo| INFO: The global `menu` is alrea...»)
«LzInfo#1| INFO: The global `menu` is already defined.  To dynamically 
create a <menu> element, you will have to use `lz.menu`.» {
backtrace: $lzsc$initialize <- lz.class <- makeChild <- makeSomeViews <- 
checkQ <- ...
file: null
(Continue reading)

P T Withington | 5 Mar 2008 18:57
Picon
Favicon
Gravatar

Re: suggestions for tracking down source of INFO message in pagan-deities?

What this warning is telling you is that in 3.x when you defined a  
user class (e.g., `<class name="menu">`) we would define it globally.   
If you wanted to instantiate that class from script, you would say  
`new menu`.  For backwards compatibility, in 4.x we still define the  
global if it does not conflict with a built-in (runtime) class.  (We  
don't want to clobber globals in the different runtimes, e.g., in  
DHTML there is already a global class named `menu`.)  In the case  
where we don't define the global, we are emitting this warning, to  
remind you that if you want to instantiate the user-defined class from  
script, you need to say `new lz.menu` now.

Perhaps we should just do away with this warning and rely on  
documentation instead?

On 2008-03-05, at 11:53 EST, Elliot Winard wrote:

> I'm changing the debug messageLevel used in a large application from  
> WARNING to ALL [0] to complete a port from wafflecone to the pagan- 
> deities branch of OLS.
>
> One of the INFO messages that shows up is a message about global  
> `menu` already being defined.
> I grepped through the code (I didn't write all of it) and it is not  
> obvious what LZX (or ECMAScript) is triggering this warning.
>
> What's the best way to track this down?  I filed  LPP-5545 to track  
> this issue.
>
> Thanks,
> -e
(Continue reading)

Elliot Winard | 5 Mar 2008 19:04

Re: suggestions for tracking down source of INFO message in pagan-deities?

This makes sense.  The problem is that the code triggering this might be 
in the LFC because I don't think it's in the code of this application 
but there's no easy way to figure that out based on the warning, errr, 
INFO message.
-e

P T Withington wrote:
> What this warning is telling you is that in 3.x when you defined a 
> user class (e.g., `<class name="menu">`) we would define it globally.  
> If you wanted to instantiate that class from script, you would say 
> `new menu`.  For backwards compatibility, in 4.x we still define the 
> global if it does not conflict with a built-in (runtime) class.  (We 
> don't want to clobber globals in the different runtimes, e.g., in 
> DHTML there is already a global class named `menu`.)  In the case 
> where we don't define the global, we are emitting this warning, to 
> remind you that if you want to instantiate the user-defined class from 
> script, you need to say `new lz.menu` now.
>
> Perhaps we should just do away with this warning and rely on 
> documentation instead?
>
> On 2008-03-05, at 11:53 EST, Elliot Winard wrote:
>
>> I'm changing the debug messageLevel used in a large application from 
>> WARNING to ALL [0] to complete a port from wafflecone to the 
>> pagan-deities branch of OLS.
>>
>> One of the INFO messages that shows up is a message about global 
>> `menu` already being defined.
>> I grepped through the code (I didn't write all of it) and it is not 
(Continue reading)

Camilo Aguilar | 6 Mar 2008 02:33
Picon
Gravatar

rotation support in DHTML

Hi, I am newbie in Openlaszlo. I am trying set rotation to a resource and in flash it does work well but not in DHTML

Can anybody help me ? it is a bug maybe ?


Best Regards,

Camilo Aguilar

acec acec | 6 Mar 2008 20:52
Picon
Favicon

Tabs in multiple rows

Hi,
I try to layout tabs in multiple rows, I found 
http://forum.openlaszlo.org/showthread.php?t=747

I create one file - mytabs.lzx:
<library>
	<class name="mytab" extends="tab">
    	<method name="setSelected" args="s">
        <![CDATA[
            if (s) {
                setAttribute('tabstate', 4);
            } else {
                setAttribute('tabstate', 2);
            }
            super.setSelected(s);
        ]]>
        </method>
	</class>
	<class name="multirowtabsbar" extends="tabsbar"
layout="class: wrappinglayout; axis:'x'; yspacing:-5"
width="${canvas.width}" />

</library>
=======================================
In my application, I declared tabs like:
<tabs tabclass="mytab" barclass="multirowtabsbar"

The initial screen is perfect, but when I selected the
tab in second row, which will be moved into first row
and overlap others.

Do you have any suggestion?

Thanks in advance.

acec

      Be smarter than spam. See how smart SpamGuard is at giving junk email the boot with the All-new Yahoo! Mail. 
Click on Options in Mail and switch to New Mail today or register for free at http://mail.yahoo.ca 

Elliot Winard | 7 Mar 2008 16:28

search engine-friendly Laszlo applications

How much work has gone into making OpenLaszlo-fronted web applications 
more easily indexible by search engines?

I've been talking to drupal developers and people at content sites like 
meetup.com and outside.in, video and social-networking sites like 
blip.tv and non-profits like Greenpeace about RIAs.  They're interested 
in creating rich front-ends for their sites but only if the rich 
front-end can degrade to something that bots can crawl and Google can 
index.  Search engine exposure is *very* important to them because most 
people find out about info on these sites through Google. 

How much thought has gone into making OpenLaszlo-based apps 
search-friendly?  I see this as a two different problems - making the 
Laszlo app itself indexable using something like the Flash Search Engine 
SDK *and* always publishing a set of non-RIA crawlable pages in addition 
to the Laszlo app.  The problem is one of providing a good user 
experience to users and a good search engine experience to search 
engines.  I'm not sure that the expense of forked development and extra 
maintenance imposed by having an RIA in parallel with their HTML-based 
sites is worth it much of the time.

Any thoughts on searchability of OpenLaszlo-based applications?
Thanks,
-e

[0] http://www.adobe.com/licensing/developer/search/faq/

Elliot Winard | 7 Mar 2008 17:45

constraints and method-calls

I'm refactoring a chunk of declarative LZX code so it's

Elliot Winard | 7 Mar 2008 18:50

Re: constraints and method-calls

Oops.  Itchy trigger finger.

I'm refactoring a chunk of LZX code to make it less declarative and LZXy 
and more programmatic and ECMAScripty.

I was going to ask about the mechanics of dependency functions but I 
decided to just change the code I'm working on to *not* use functions 
wherever possible. 
Basically, I turned stuff like this -
      <text name="mytext"
               text="${ LzBrowser.xmlEscape( parent.forminput.getText() 
) }" />
- into this -
      <text name="mytext"
               text="${ LzBrowser.xmlEscape( parent.forminput.text) }" />
- and then replaced the constraint with methods & delegates & altogether.

Thx,
-e

Elliot Winard wrote:
> I'm refactoring a chunk of declarative LZX code so it's
>
>
>
>
>


Gmane