Personal tools

DHTML Laszlo

From OpenLaszlo

See Legals_Project_Plan for more information.

Contents

Developer Notes for Legals

  • DHTML OLC - <LEGALS>/lps/includes/lfc/
  • tests - <LEGALS>/lps/includes/lfc/tests
  • DEMO at depot//apps/et. To run, click on large bright picture.
  • inheritance inside of component JS - LzText = makeLFCConstructor(LzView);
  • the new new - var gSign = LzFactory.create(LzView, chil, {x : 23, y: 12, id: 'gSign', bgcolor: '#9900ff', resource : 'resc/h_c_open_sign.gif'});
  • sprite object is where all runtime0specific stuff lives
  • kernel defines dhtml internals - sprite does the real work
  • URL QUERY PARAMS
    •  ?lzt=html&lzr=dhtml - DHTML
    •  ?lzt=object&lzr=dhtml - JS spit out by compiler
    •  ?lzt=lfc&lzr=dhtml - The 'compiled' LFC script file
    • &debug=true for debugger
  • to add a component
    • <COM>.js
    • probably add kernel stuff to sprite
    • modify template - <LEGALS>/WEB-INF/lps/templates/dhtml-response.xslt
    • Lots of classes declare events in SWF by setting a property to null, whereas in DHTML we use DeclareEvent. Make sure to remove the calls that set the property to null when updating.
  • check out shell bookmarklet on wiki
  • If a module sends an event, declare it with DeclareEvent(class prototype, event name), so that it is not left as undefined or null.
  • #pragma "warnUndefinedReferences=true" in a block in the LFC source will enable warnings for undefined var references in the LFC

Components Development

DHTMLComponentsDevelopment

Kernel API Proposal

KernelAPIProposal

Simple requires/provides proposal

SimpleRequiresProvidesProposal

Merging LFC files

LFCFileMerge

DHTML development tools

Cross-browser:

Opera:

  • Opera has the best javascript console error messages - includes a stack trace and

information about runtime errors, in cases where Firefox and IE will silently fail.

Actionscript:

Firefox:

Safari: