[Laszlo-checkins] r7011 - in openlaszlo/branches/paperpie: . WEB-INF/lps/lfc WEB-INF/lps/lfc/compiler WEB-INF/lps/lfc/data WEB-INF/lps/lfc/debugger WEB-INF/lps/lfc/debugger/platform/dhtml WEB-INF/lps/lfc/kernel WEB-INF/lps/lfc/kernel/dhtml WEB-INF/lps/lfc/kernel/swf WEB-INF/lps/lfc/services WEB-INF/lps/lfc/views WEB-INF/lps/schema WEB-INF/lps/server/sc/src/org/openlaszlo/sc WEB-INF/lps/server/src/org/openlaszlo/compiler WEB-INF/lps/server/src/org/openlaszlo/sc WEB-INF/lps/server/src/org/openlaszlo/xml/internal demos/lzpix demos/lzpix/classes demos/lzpix/views docs docs/src/deployers docs/src/developers docs/src/developers/images docs/src/developers/programs lps/admin lps/components/base lps/components/lzunit lps/includes/source test/compiler_errors test/extensions test/lfc/animators test/lfc/data test/lfc/legals test/lfc/legals/resc test/lztest
ben@openlaszlo.org
ben at openlaszlo.org
Thu Oct 25 14:45:32 PDT 2007
Author: ben
Date: 2007-10-25 14:44:51 -0700 (Thu, 25 Oct 2007)
New Revision: 7011
Added:
openlaszlo/branches/paperpie/docs/src/developers/programs/canvasversion.lzx
openlaszlo/branches/paperpie/docs/src/developers/programs/debuginfo.lzx
openlaszlo/branches/paperpie/test/compiler_errors/attribute-overrides-method.lzx
openlaszlo/branches/paperpie/test/compiler_errors/method-override.lzx
openlaszlo/branches/paperpie/test/compiler_errors/override-x-attribute.lzx
openlaszlo/branches/paperpie/test/lfc/legals/music.mp3
openlaszlo/branches/paperpie/test/lfc/legals/resc/logo.swf
openlaszlo/branches/paperpie/test/lfc/legals/resc/wallpaper-thumb.jpg
Removed:
openlaszlo/branches/paperpie/docs/changelog.html
Modified:
openlaszlo/branches/paperpie/
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/build.xml
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/compiler/LzRuntime.lzs
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/data/LzReplicationManager.lzs
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/debugger/LzDebug.lzs
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/debugger/platform/dhtml/LzDebug.js
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/LzUtils.lzs
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/dhtml/LzContextMenu.js
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzLoadQueue.as
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzLoader.lzs
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzSprite.as
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzTextSprite.as
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/services/LzModeManager.lzs
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/services/LzTrack.lzs
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/views/LaszloView.lzs
openlaszlo/branches/paperpie/WEB-INF/lps/lfc/views/LzText.lzs
openlaszlo/branches/paperpie/WEB-INF/lps/schema/lfc.lzx
openlaszlo/branches/paperpie/WEB-INF/lps/server/sc/src/org/openlaszlo/sc/Parser.jjt
openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/AttributeSpec.java
openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ClassCompiler.java
openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ClassModel.java
openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/Compiler.java
openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/NodeModel.java
openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ViewSchema.java
openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ViewSchema_Test.java
openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/sc/Compiler.java
openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/sc/JavascriptGenerator.java
openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/xml/internal/Schema.java
openlaszlo/branches/paperpie/build.properties
openlaszlo/branches/paperpie/demos/lzpix/app.lzx
openlaszlo/branches/paperpie/demos/lzpix/classes/favorites.lzx
openlaszlo/branches/paperpie/demos/lzpix/classes/photo.lzx
openlaszlo/branches/paperpie/demos/lzpix/classes/pivotlayout.lzx
openlaszlo/branches/paperpie/demos/lzpix/classes/search.lzx
openlaszlo/branches/paperpie/demos/lzpix/views/tools.lzx
openlaszlo/branches/paperpie/docs/src/deployers/deploy-preface.dbk
openlaszlo/branches/paperpie/docs/src/deployers/deployers-index.dbk
openlaszlo/branches/paperpie/docs/src/developers/classes-introductory.dbk
openlaszlo/branches/paperpie/docs/src/developers/data-structures.dbk
openlaszlo/branches/paperpie/docs/src/developers/databinding.dbk
openlaszlo/branches/paperpie/docs/src/developers/debugging.dbk
openlaszlo/branches/paperpie/docs/src/developers/deployers-index.dbk
openlaszlo/branches/paperpie/docs/src/developers/designers.dbk
openlaszlo/branches/paperpie/docs/src/developers/developers_guide_preface.dbk
openlaszlo/branches/paperpie/docs/src/developers/images/debugger-new-console.png
openlaszlo/branches/paperpie/docs/src/developers/index.dbk
openlaszlo/branches/paperpie/docs/src/developers/language-preliminaries.dbk
openlaszlo/branches/paperpie/docs/src/developers/media-resources.dbk
openlaszlo/branches/paperpie/docs/src/developers/persistent_connection.dbk
openlaszlo/branches/paperpie/docs/src/developers/program-development.dbk
openlaszlo/branches/paperpie/docs/src/developers/programs/debugging-$3.lzx
openlaszlo/branches/paperpie/docs/src/developers/programs/debugging-$4.lzx
openlaszlo/branches/paperpie/docs/src/developers/proxied.dbk
openlaszlo/branches/paperpie/docs/src/developers/rpc-javarpc.dbk
openlaszlo/branches/paperpie/docs/src/developers/rpc-soap.dbk
openlaszlo/branches/paperpie/docs/src/developers/rpc-xmlrpc.dbk
openlaszlo/branches/paperpie/docs/src/developers/rpc.dbk
openlaszlo/branches/paperpie/docs/src/developers/views.dbk
openlaszlo/branches/paperpie/index.jsp
openlaszlo/branches/paperpie/lps/admin/solo-dhtml-deploy.jsp
openlaszlo/branches/paperpie/lps/components/base/basegrid.lzx
openlaszlo/branches/paperpie/lps/components/base/basewindow.lzx
openlaszlo/branches/paperpie/lps/components/lzunit/lzunit.lzx
openlaszlo/branches/paperpie/lps/includes/source/embednew.js
openlaszlo/branches/paperpie/lps/includes/source/flash.js
openlaszlo/branches/paperpie/test/extensions/html.lzx
openlaszlo/branches/paperpie/test/lfc/animators/lzunit_animator_prop.lzx
openlaszlo/branches/paperpie/test/lfc/data/testhttpdata.lzx
openlaszlo/branches/paperpie/test/lfc/legals/multiframeresource.lzx
openlaszlo/branches/paperpie/test/lztest/lztest-class-impl.lzx
Log:
Merged revisions 6878-7010 via svnmerge from
http://svn.openlaszlo.org/openlaszlo/trunk
.......
r6896 | lou | 2007-10-18 06:04:24 -0700 (Thu, 18 Oct 2007) | 32 lines
Change 20071016-lou-6 by lou at loumac.local on 2007-10-16 10:54:52 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: rationalize documentation titles
New Features: go through the designer's and administrator's guides, and change titles:
current name -> new name
System Administrator's Guide to Deploying OpenLaszlo Applications -> OpenLaszlo System Administrator's Guide
Software Engineer's Guide to Developing OpenLaszlo Applications ->OpenLaszlo Application Developer's Guide
In addition, check cross references to these docs, and fix any broken links
Bugs Fixed: LPP-4804
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
Documentation:
Release Notes:
Details:
Tests:
.......
r6900 | lou | 2007-10-18 06:32:17 -0700 (Thu, 18 Oct 2007) | 17 lines
Change 20071018-lou-q by lou at loumac.local on 2007-10-18 09:17:08 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: dguide broken links: links containing /guide
Bugs Fixed: LPP-4923
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
Documentation: a couple of these links were fixed by fixing the link path, that is, replacing
/guide with /developers. These were implemented as ulinks. In most cases, however, xref was
a better choice, so I changed to that.
.......
r6901 | lou | 2007-10-18 07:22:56 -0700 (Thu, 18 Oct 2007) | 15 lines
Change 20071018-lou-n by lou at loumac.local on 2007-10-18 10:14:35 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: explanation of truncated objects in debugger
Bugs Fixed: LPP-4211
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
Documentation: clarify 1.5. Inspecting Objects to describe how objects are abbrevieated
.......
r6902 | lou | 2007-10-18 07:33:55 -0700 (Thu, 18 Oct 2007) | 15 lines
Change 20071018-lou-w by lou at loumac.local on 2007-10-18 10:28:43 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: describe "has no properties" error
Bugs Fixed: LPP-4861
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
Documentation: clarified section 8.3. Dereferencing Null Pointers of the debugging chapter
.......
r6903 | lou | 2007-10-18 08:37:44 -0700 (Thu, 18 Oct 2007) | 15 lines
Change 20071018-lou-m by lou at loumac.local on 2007-10-18 11:35:17 AST
in /Users/lou/src/svn/openlaszlo/trunk/docs/src
for http://svn.openlaszlo.org/openlaszlo/trunk/docs/src
Summary: document pixel lock
New Features: add section 3.4. Pixel locking to the views chapter of the dguide
Bugs Fixed: LPP-992
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
.......
r6905 | max | 2007-10-18 11:08:08 -0700 (Thu, 18 Oct 2007) | 43 lines
Change 20071017-maxcarlson-S by maxcarlson at plastik on 2007-10-17 17:18:46 PDT
in /Users/maxcarlson/openlaszlo/trunk-clean
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Merge 'Increase size of installer window when flash installs' from trunk
New Features:
Bugs Fixed: LPP-4737
Technical Reviewer: promanik
QA Reviewer: jcrowley
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details: plastik:~/openlaszlo/trunk-clean maxcarlson$ svnmerge.py merge -b -r 6509 -S ../wafflecone
property 'svnmerge-integrated' set on '.'
U lps/includes/source/flash.js
property 'svnmerge-integrated' set on '.'
From r6509 - When the flash installer runs, a small window is used (the minimum size poissible). I increased the window width/height to 100% of the browser window. This may not be the right fix long term but it hopefully wafflecone to ship.
Tests: From r6509
1. Remove flash from the browsers: The download link is at the bottom of this pa
ge: http://www.adobe.com/support/flashplayer/downloads.html. For Windows, the ex
ecutable is: http://download.macromedia.com/pub/flashplayer/current/uninstall_fl
ash_player.exe
2. Shutdown all instances of the browser(s). Restart your browser.
3. Navigate to the page you want to run. You should get a message that flash mus
t be installed. Once flash is installed, the window size should be 100% and not
the default value (215x138). If the server has just started running, it may take
some time before the app begins to run.
.......
r6907 | jcrowley | 2007-10-18 11:55:23 -0700 (Thu, 18 Oct 2007) | 29 lines
Change 20071018-jcrowley-7 by jcrowley at doctormanhattan.mshome.net on 2007-10-18 14:20:26 EDT
in /Users/jcrowley/src/svn/openlaszlo/trunk-a
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Setting "rowheight" produces warnings. (Contributor bug
fix from Andre Bargull)
New Features:
Bugs Fixed: LPP-4925 - Setting "rowheight" produces warnings.
Technical Reviewer: pbr
QA Reviewer: ben
Doc Reviewer:
Documentation:
Release Notes:
Details: Applied and tested Andre Bargull's bug fix.
Tests: Run the following and note an absence of errors in the
Debugger:
<canvas debug="true">
<grid rowheight="17" shownitems="6"/>
</canvas>
.......
r6909 | lou | 2007-10-18 13:34:16 -0700 (Thu, 18 Oct 2007) | 15 lines
Change 20071018-lou-b by lou at loumac.local on 2007-10-18 16:31:33 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: picture of debug window needs to be updated in dguide
New Features: replace picture with annotated current-version snapshot
Bugs Fixed: LPP-4895
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
.......
r6920 | lou | 2007-10-19 06:57:10 -0700 (Fri, 19 Oct 2007) | 21 lines
Change 20071019-lou-s by lou at loumac.local on 2007-10-19 09:53:57 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Developer forum URL incorrect in deploy-preface.html
Bugs Fixed: LPP-2637
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
Documentation: change link
http://www.laszlosystems.com/developers/forums/
to
http://www.laszlosystems.com/developers/community/forums/
.......
r6924 | lou | 2007-10-19 08:09:54 -0700 (Fri, 19 Oct 2007) | 15 lines
Change 20071019-lou-L by lou at loumac.local on 2007-10-19 11:07:01 AST
in /Users/lou/src/svn/openlaszlo/trunk/docs/src
for http://svn.openlaszlo.org/openlaszlo/trunk/docs/src
Summary: broken example in dbug chapter of the dguide
Bugs Fixed: LPP-4894
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
Documentation: Fixed the sample code by replacing the ">" in the inner loop with "<"
.......
r6926 | ptw | 2007-10-19 10:31:12 -0700 (Fri, 19 Oct 2007) | 19 lines
Change 20071017-ptw-S by ptw at dueling-banjos.local on 2007-10-17 07:33:26 EDT
in /Users/ptw/OpenLaszlo/ringding-2
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Correct DHTML expansion of assignOp to global
Bugs Fixed:
LPP-4920 'Erroneous output from DHTML compiler in debug mode causes runtime errors w/ trunk build 6836'
Technical Reviewer: dda at ddanderson.com (Message-Id: <14C1CC5F-D768-4629-BCFB-D2EE6F05D209 at ddanderson.com>)
QA Reviewer: rcyeager at bellsouth.net (pending)
Details:
JavascriptGenerator: translate references before rewriting.
Tests:
Test case from bug report. smokecheck in SWF and DHTML
.......
r6928 | max | 2007-10-19 11:46:42 -0700 (Fri, 19 Oct 2007) | 24 lines
Change 20071018-maxcarlson-M by maxcarlson at plastik on 2007-10-18 21:14:20 PDT
in /Users/maxcarlson/openlaszlo/trunk-clean
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Fix modemanager braino
New Features:
Bugs Fixed: LPP-4902 - Modal view causing DHTML FF error whenever mouse moved in trunk build 6836
Technical Reviewer: promanik
QA Reviewer: jcrowley
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details: Don't null out the event!
Tests: See LPP-4902
.......
r6929 | max | 2007-10-19 14:42:57 -0700 (Fri, 19 Oct 2007) | 31 lines
Change 20071018-maxcarlson-X by maxcarlson at plastik on 2007-10-18 19:16:37 PDT
in /Users/maxcarlson/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Enhance dhtml event mouse and media event support
New Features: DHTML support for onmousedragin, onmousedragout, onmouseupoutside, onplay, onstop, onframe and onlastframe events.
Bugs Fixed: LPP-3730 - A number of events don't currently work for views with multi-frame resources.
Technical Reviewer: promanik
QA Reviewer: jcrowley
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details: Add resources for testing.
multiframeresource.lzx - updated testcase to test mouse and media load events across runtimes
LzSprite.js - Add callbacks for onmousedragin, onmousedragout, onmouseupoutside, onplay, onstop, onframe and onlastframe events
LzTrack.lzs - Update doc comment to events that exist
LaszloView.lzs - Remove unused onaddsubresource event. Add resourceevent() callback to receive media events from sprites.
Tests: run test/lfc/legals/multiframeresource across swf7 and 8, dhtml proxied and non. Most events should now fire.
.......
r6936 | bargull | 2007-10-20 06:42:43 -0700 (Sat, 20 Oct 2007) | 27 lines
Change 20071020-bargull-4 by bargull at dell--p4--2-53 on 2007-10-20 15:16:25
in /home/Admin/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: LzReplicationManager needs to check immediateparent for implicit datapath
New Features:
Bugs Fixed:
LPP-4654 - "LzReplicationManager doesn't handle relative xpath appropriately"
Technical Reviewer: hminsky
QA Reviewer: (pending)
Doc Reviewer: (pending)
Documentation:
LzDatapath#setDataContext(..) checks all immediateparents of its immediateparent for an implicit datapath, but LzReplicationManager must also check its immediateparent for an implicit datapath.
We cannot directly check in LzDatapath for an implicit datapath on its immediateparent, because this would lead to a circular logic as the datapath of the immediateparent of a datapath is the same datapath.
Release Notes:
Details:
Tests:
.......
r6941 | bargull | 2007-10-21 14:46:39 -0700 (Sun, 21 Oct 2007) | 28 lines
Change 20071003-bargull-8 by bargull at dell--p4--2-53 on 2007-10-03 17:45:40
in /home/Admin/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: basewindow does not properly update "windowlist"
New Features:
Bugs Fixed:
LPP-4617 - basewindow does not properly update "windowlist"
Technical Reviewer: max
QA Reviewer: promanik
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details:
Added check in basewindow#setVisible(..) to ensure the window is part of its parent's windowlist.
Updated basewindow#sendInFrontOf(..) and basewindow#sendBehind(..) to protect against bad values.
Tests:
see testcase at LPP-4617
.......
r6942 | ptw | 2007-10-21 16:16:22 -0700 (Sun, 21 Oct 2007) | 24 lines
Change 20071019-ptw-j by ptw at dueling-banjos.local on 2007-10-19 14:11:18 EDT
in /Users/ptw/OpenLaszlo/ringding-2
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Permit arbitrary escapes in strings
Bugs Fixed:
LPP-4940 'Trouble parsing strings with backslashes'
Technical Reviewer: dda at ddanderson.com (Message-Id: <220FBB1B-9429-4A45-AA48-563AEF2D4FF0 at ddanderson.com>)
QA Reviewer: hminsky (pending)
Details:
Permit any character after '\' (while still ensuring that '\0',
'\u', and '\x' escapes are valid).
Tests:
Test case no longer gives parse error:
lzx> "Foo\/"
'Foo/'
lzx>
.......
r6945 | ben | 2007-10-22 12:38:44 -0700 (Mon, 22 Oct 2007) | 14 lines
Change 20071017-ben-s by ben at slim.local on 2007-10-17 10:49:48 PDT
in /Users/ben/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Delete docs/changelog.html
Bugs Fixed: LPP-4205 docs/changelog.html refers to 3.3.1
Technical Reviewer: crowley
Documentation:
Deleting an unused, out-of-date file.
.......
r6954 | bargull | 2007-10-22 14:50:39 -0700 (Mon, 22 Oct 2007) | 26 lines
Change 20071020-bargull-0 by bargull at dell--p4--2-53 on 2007-10-20 17:39:06
in /home/Admin/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: setScroll was defined twice in LzText and in LzTextSprite (swf)
New Features:
Bugs Fixed:
LPP-4944 - "LzText#setScroll" is doubly defined
Technical Reviewer: max
QA Reviewer: (pending)
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details:
Just removed the second definition of setScroll in LzText.lzx and LzTextSprite.as
Tests:
.......
r6955 | bargull | 2007-10-22 15:01:24 -0700 (Mon, 22 Oct 2007) | 29 lines
Change 20071022-bargull-2 by bargull at dell--p4--2-53 on 2007-10-22 01:13:18
in /home/Admin/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Update LzLoader errorhandling for LzHTTPDataProvider
New Features:
Bugs Fixed:
LPP-4946 - "dataset getErrorString return null"
Technical Reviewer: hminsky
QA Reviewer: (pending)
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details:
Updated error-handling in LzLoader to conform to the new LzHTTPDataProvider class.
In proxied applications, LPS sends a special error-xml response to forward any errors (<resultset><error status="..." msg="..." /></resultset>).
And LzHTTPDataProvider#loadResponse(..) determines on the basis of this xml-response any errors. Unfortunately LzLoader#onerror did not send the whole xml-response, but only the value of the "msg"-attribute.
So, I've updated LzLoader#onerror to send the xml-response if its owner is a LzHTTPLoader, in any other case it is sending an appropriate error-message just like before.
Tests:
.......
r6967 | lou | 2007-10-23 09:36:57 -0700 (Tue, 23 Oct 2007) | 16 lines
Change 20071023-lou-C by lou at loumac.local on 2007-10-23 12:31:26 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Example 50.3. Logging to the debugger in dguide is unclear
New Features: give the button text, show both x and y onclick
change second Debug.write to Debug.format
Bugs Fixed: LPP-4953
Technical Reviewer: P T Withington
QA Reviewer: (pending)
Doc Reviewer: John Sundman
.......
r6968 | ptw | 2007-10-23 09:54:41 -0700 (Tue, 23 Oct 2007) | 66 lines
Change 20071018-ptw-X by ptw at dueling-banjos.local on 2007-10-18 18:34:57 EDT
in /Users/ptw/OpenLaszlo/ringding-2
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Be more careful detecting DOM nodes
Bugs Fixed:
LPP-4739 'Printing LzDataText in Debugger is erronous for "%w"'
Technical Reviewer: a.bargull at intensis.de (Message-ID: <471D1729.6040406 at intensis.de>)
QA Reviewer: sosullivan at laszlosystems.com (pending)
Details:
LzDebug.lzs: objectOwnProperties: Be more careful detecting
prototypes, simplify test for 'own' properties to be any property
that is different from that same property in the prototype (or all
properties, if there is no prototype). Take care poking at the
prototype, which may be a runtime native object.
LzDebug.js: Tighten up the test for DOM nodes so that we don't
mistake an LZ node for one.
LzRuntime: Eliminate old debugging output that was there just to
verify source warnings were working. Add Debug.ignoringErrors
which can be used on any platform to evaluate a closure without
recursing into the debugger.
Tests:
1. Verified that LzDataText is printed as an LZX object (in SWF,
Firefox, Safari, Opera):
lzx> Debug.write("%#w\n", new LzDataText('test'))
?\194?\171LzDataText(0)#71| test?\194?\187
2. Verified that DOM nodes can still be inspected (does not apply to SWF):
lzx> Debug.inspect(canvas.sprite.__LZdiv)
?\194?\171HTMLDivElement#22| #document/html/body/div#lzappContainer/div.lzcanvasdiv[1]?\194?\187 {
align: ''
attributes: [object NamedNodeMap]
...
tagName: 'DIV'
textContent: ''
title: ''
}
#document/html/body/div#lzappContainer/div.lzcanvasdiv[1]
3. Verified that movieclips can still be inspected (only applies to
SWF):
lzx> Debug.inspect(_level0.spriteroot)
?\194?\171MovieClip#160| _level0.spriteroot?\194?\187 {
_currentframe: 0
_opacity: ?\194?\171undefined?\194?\187
...
_visible: true
_x: 0
_xscale: 100
_y: 0
_yscale: 100
}?\194?\171MovieClip#160| _level0.spriteroot?\194?\187
lzx>
4. Ran smokecheck in swf and dhtml on Firefox
.......
r6972 | ptw | 2007-10-23 12:09:37 -0700 (Tue, 23 Oct 2007) | 19 lines
Change 20071023-ptw-n by ptw at dueling-banjos.local on 2007-10-23 15:06:29 EDT
in /Users/ptw/OpenLaszlo/ringding-2
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Fix misplaced brace which causes non-debug DHTML to fail
Bugs Fixed:
LPP-4739 'Printing LzDataText in Debugger is erronous for "%w"'
Technical Reviewer: a.bargull at intensis.de (pending)
QA Reviewer: sosullivan at laszlosystems.com (pending)
Details:
Testing with debug off reveals a type-oh in my last change
Tests:
I can now run non-debug DHTML
.......
r6973 | max | 2007-10-23 12:21:10 -0700 (Tue, 23 Oct 2007) | 32 lines
Change 20071022-maxcarlson-k by maxcarlson at plastik on 2007-10-22 20:30:29 PDT
in /Users/maxcarlson/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Fix context menus to work without bgcolor set
New Features:
Bugs Fixed: LPP-3852 - Context menu doesn't work properly with transparent views
Technical Reviewer: promanik
QA Reviewer: jcrowley
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details: Remove extra assignments of width/height/x/y.
In setBGColor() if the bgcolor was set for a context menu, reset its alpha to the correct value and allow opacity to be applied. If clearing the bgcolor, don't remove the movieclip and don't allow opacity to be applied.
In setOpacity() set the bgcolor alpha if not set by the context menu and overridden by the context menu.
In changeOrder() store and restore the current alpha value of the bgcolor movieclip.
In setContextMenu() always add a bgcolor view, and set its alpha to 0 to hide it if no bgcolor is currently set.
Tests: See LPP-3852.
.......
r6975 | hqm | 2007-10-23 13:05:36 -0700 (Tue, 23 Oct 2007) | 54 lines
Change 20071023-hqm-8 by hqm at IBM-2E06404CB67 on 2007-10-23 12:09:47 EDT
in /cygdrive/c/users/hqm/openlaszlo/trunk/WEB-INF/lps/lfc
for http://svn.openlaszlo.org/openlaszlo/trunk/WEB-INF/lps/lfc
Summary: fix to report errors in media loading
New Features:
Bugs Fixed: LPP-4099
Technical Reviewer: max
QA Reviewer: pbr
Doc Reviewer:
Documentation:
Release Notes:
Details:
In the case of a server media error, the media loader calls returnData
twice, once when the image swf is loaded (normal path), and the error
swf itself calls returnData.
That second call was being ignored by returnData because it ignored
any loader which was marked as loaded.
This fix adds a check for non-null data, and if so, returns it.
Tests:
test/lfc/data/testhttpdata.lzx
test/lfc/data/alldata.lzx
This should report an error immediately in proxied mode
<canvas width="100%" height="80%" debug="true">
<debug fontsize="12"/>
<view resource="http://www.javawen.info/try/news_bg.png"
onload="Debug.write('onload', this)"
ontimeout="Debug.write('ontimeout', this)"
onerror="Debug.write('onerror', this)"
/>
</canvas>
.......
r6976 | pbr | 2007-10-23 13:07:24 -0700 (Tue, 23 Oct 2007) | 103 lines
Change 20071018-Philip-0 by Philip at Philip-DC on 2007-10-18 20:23:02 EDT
in /cygdrive/f/laszlo/svn/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Fix context menu for dhtml (to match swf)
New Features:
Bugs Fixed: LPP-4213
Technical Reviewer: max
QA Reviewer: (pending)
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details:
The context menu worked differently in swf and dhtml. In swf, duplicate captions
are not displayed. I added this behavior to dhtml. swf is only sensitive to the
caption name, and not the method name called.
Tests:
Run the following test in swf and dhtml. When you right click on the canvas you should see:
swf
---
About OpenLaszlo...
View Source
My Function
box4
box5
box6
------
Settings
------
About Adobe Flash Player 9...
dhtml
-----
About OpenLaszlo...
View Source
My Function
box4
box5
box6
<canvas debug="true">
<class name="box">
<handler name="oninit">
var cm = canvas.getContextMenu();
var del = new LzDelegate (this, 'cmHandler');
cm.addItem(cm.makeMenuItem('My Function', del));
</handler>
<method name="cmHandler">
Debug.write("cmHandler", this);
</method>
</class>
<class name="uniquebox">
<handler name="oninit">
var cm = canvas.getContextMenu();
var del = new LzDelegate (this, 'cmHandler');
cm.addItem(cm.makeMenuItem(this.id, del));
</handler>
<method name="cmHandler">
Debug.write("cmHandler", this);
</method>
</class>
<handler name="oninit">
var cm = canvas.getContextMenu();
var del = new LzDelegate (this, 'cmHandler');
cm.addItem(cm.makeMenuItem('My Function', del));
</handler>
<method name="cmHandler">
Debug.write("cmHandler", this);
</method>
<simplelayout axis="x" spacing="10"/>
<box width="50" height="50" name="box1" bgcolor="red"/>
<box width="50" height="50" name="box2" bgcolor="green"/>
<box width="50" height="50" name="box3" bgcolor="blue"/>
<uniquebox width="50" height="50" name="box4" bgcolor="red"/>
<uniquebox width="50" height="50" name="box5" bgcolor="green"/>
<uniquebox width="50" height="50" name="box6" bgcolor="blue"/> </canvas>
Files:
M WEB-INF/lps/lfc/kernel/dhtml/LzContextMenu.js
Changeset: http://svn.openlaszlo.org/openlaszlo/patches/20071018-Philip-0.tar
.......
r6977 | lou | 2007-10-23 13:21:43 -0700 (Tue, 23 Oct 2007) | 15 lines
Change 20071023-lou-i by lou at loumac.local on 2007-10-23 16:19:01 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: added new section 1.4. Getting version information
New Features: added description and examples for canvas.version and Debug.versionInfo()
Bugs Fixed: LPP-4822 and LPP-2658
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
.......
r6978 | lou | 2007-10-23 13:33:31 -0700 (Tue, 23 Oct 2007) | 16 lines
Change 20071023-lou-Y by lou at loumac.local on 2007-10-23 16:30:49 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: debug chapter example: move debug window so it's visible
New Features: Example 50.3. Logging to the debugger: the debug window was below the bottom of the screen.
add a <debug> tag and move the window so it's visible.
Bugs Fixed: LPP-4955
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
.......
r6980 | ptw | 2007-10-23 15:02:40 -0700 (Tue, 23 Oct 2007) | 42 lines
Change 20071023-ptw-D by ptw at dueling-banjos.local on 2007-10-23 15:11:20 EDT
in /Users/ptw/OpenLaszlo/ringding-2
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Make lzunit work without debugging
New Features: lzunit can now be used without the debugger enabled,
although it is always best to run it with debugging on.
Bugs Fixed:
LPP-4822 'lzunit_animator_prop.lzx in dhtml doesn't succeed unless debug=true. Fails smokecheck'
Technical Reviewer: hminsky (Message-ID: <8c61fad60710231247gc6ec97sd8b46a092dd54743 at mail.gmail.com>)
QA Reviewer: ben (pending)
Doc Reviewer: jsundman (pending)
Documentation:
You can now run lzunit without the debugger. It is still
recommended that you run it with the debugger, because runtime
errors that occur in your code will not be caught in tests if the
debugger is disabled.
There is a new Test interface: displayMessage which can be used
to display a message in the test result pane, whether the debugger
is enabled or not.
Details:
lzunit: Use the new LzFormatter mixin to do your formatting, so
that test results can still be seen even without the debugger.
Echo failures and errors to the debug console (only if debugging
is enabled).
Add a new interface for Test: displayMessage. Echo messages as
INFO messages to the debug console if debugging is enabled.
lzunit_animator_prop: Use displayMessage rather than Debug.write
Tests:
Test case from bug works properly with or without debugging on.
.......
r6981 | lou | 2007-10-23 15:29:28 -0700 (Tue, 23 Oct 2007) | 16 lines
Change 20071023-lou-P by lou at loumac.local on 2007-10-23 18:24:48 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: fix typo in debugging chapter of the dguide
New Features:
Bugs Fixed:
change canvas.versionInfoString() to lz.canvas.versionInfoString()
in 2.2. Customizing Debug.write() in the debug chapter of the dguide
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: John Sundman
.......
r6984 | hqm | 2007-10-23 20:14:32 -0700 (Tue, 23 Oct 2007) | 39 lines
Change 20071023-hqm-6 by hqm at IBM-2E06404CB67 on 2007-10-23 23:07:13 EDT
in /cygdrive/c/users/hqm/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: make better LZX compiler warnings for colliding attribute names
New Features:
Bugs Fixed: LPP-3910
Technical Reviewer: ptw
QA Reviewer: dda
Doc Reviewer:
Documentation:
Release Notes:
Details:
Use AttributeSpec to store declared methods in addition to attributes, so it's
easier to detect attributes overriding methods and vice versa.
Add or improve various warnings
Tests:
ant test
ant lztest
compile webtop mail app
demos
verify that the compiled javascript is same after this patch as before on
smokecheck and webtop app
.......
r6985 | hqm | 2007-10-23 20:21:44 -0700 (Tue, 23 Oct 2007) | 1 line
added new test case
.......
r6988 | ptw | 2007-10-24 09:59:09 -0700 (Wed, 24 Oct 2007) | 19 lines
Change 20071024-ptw-z by ptw at dueling-banjos.local on 2007-10-24 12:53:50 EDT
in /Users/ptw/OpenLaszlo/ringding-2
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Fix class-impl test
Bugs Fixed:
LPP-4942 'lztest-class-impl.lzx fails'
Technical Reviewer: hminsky (pending)
QA Reviewer: mamye (pending)
Details:
Change <x>.make to new <x>.
Tests:
Test passes now.
.......
r6990 | hqm | 2007-10-24 10:48:10 -0700 (Wed, 24 Oct 2007) | 40 lines
Change 20071023-hqm-a by hqm at IBM-2E06404CB67 on 2007-10-23 23:46:20 EDT
in /cygdrive/c/users/hqm/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: add another check for method redefinition warnings
New Features:
Make thecheck when a view definition overrides a non-overridable method, not just a in class definition
Bugs Fixed: LPP-3910
Technical Reviewer: dda
QA Reviewer: pbr
Doc Reviewer:
Documentation:
Release Notes:
Details:
The check for redefining non-overridable methods was only being done in class declarations.
This adds the check into processing of regular view (node) declarations.
Tests:
This should generate a warning about overriding the "call" method, which is declared
as non-overridable in the base schema file lfc.lzx.
<canvas width="100%" height="100%" debug="true">
<view>
<method name="call" />
</view>
</canvas>
.......
r6993 | ptw | 2007-10-24 13:09:32 -0700 (Wed, 24 Oct 2007) | 20 lines
Change 20071024-ptw-3 by ptw at dueling-banjos.local on 2007-10-24 15:15:44 EDT
in /Users/ptw/OpenLaszlo/ringding-2
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Build LFCdhtml-{debug,backtrace}-simple.js for 'simple' browsers
Bugs Fixed:
LPP-4607 'Add dhtml debug-simple-lfc.js for browsers that can't handle the regular debugger'
Technical Reviewer: max (verbal)
QA Reviewer: henry (pending)
Details:
Renamed debugSafari to debugSimple and set the LFC build to build
the requisite versions.
Tests:
ant make generates the new LFC's
.......
r6997 | hqm | 2007-10-24 13:34:48 -0700 (Wed, 24 Oct 2007) | 24 lines
Change 20071024-hqm-4 by hqm at IBM-2E06404CB67 on 2007-10-24 16:21:19 EDT
in /cygdrive/c/users/hqm/openlaszlo/trunk/lps/admin
for http://svn.openlaszlo.org/openlaszlo/trunk/lps/admin
Summary: make solo dhtml deployer grab all dhtml LFC files
New Features:
Bugs Fixed: LPP-NaN
Technical Reviewer: max
QA Reviewer: ptw
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details:
Tests:
.......
r6998 | max | 2007-10-24 13:36:16 -0700 (Wed, 24 Oct 2007) | 24 lines
Change 20071024-maxcarlson-4 by maxcarlson at Plastik.local on 2007-10-24 13:11:52 PDT
in /Users/maxcarlson/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Add support to embednew.js for LFCdhtml-{debug,backtrace}-simple.js
New Features:
Bugs Fixed: LPP-4607 'Add dhtml debug-simple-lfc.js for browsers that can't handle the regular debugger'
Technical Reviewer: ptw
QA Reviewer: promanik
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details: Detect IE < 6 and Safari < 3 for 'debug' and 'backtrace' versions of the LFC, and switch the filename to be *-simple.
Tests: Run http://localhost:8080/trunk/my-apps/copy-of-hello.lzx?lzr=dhtml&debug=true runs in Safari 2 and IE 6.
.......
r7003 | bargull | 2007-10-24 16:59:05 -0700 (Wed, 24 Oct 2007) | 27 lines
Change 20071024-bargull-6 by bargull at dell--p4--2-53 on 2007-10-24 01:01:37
in /home/Admin/src/svn/openlaszlo/trunk/WEB-INF/lps/lfc
for http://svn.openlaszlo.org/openlaszlo/trunk/WEB-INF/lps/lfc
Summary: Convert LzUtils.color.inttohex arg to a 24bit positive integer
New Features:
Bugs Fixed:
LPP-4909 - "Invalid property value when animating bgcolor in IE7 DHTML w/ trunk build 6836"
Technical Reviewer: max
QA Reviewer: promanik
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details:
Setting LzView#bgcolor to a float value, a value greater than 0xffffff or to a negative value doesn't emit any warnings anymore in DHTML.
Also resolved an issue when you set bgcolor to a string which cannot be parsed to a numeric value. To test this, type into the debugger-console LzUtils.color.inttohex("foo"). Beforehand, this would print "#000NaN", now it prints "#000000".
Tests:
.......
r7006 | lou | 2007-10-25 02:28:29 -0700 (Thu, 25 Oct 2007) | 18 lines
Change 20071024-lou-r by lou at loumac.local on 2007-10-24 16:51:29 AST
in /Users/lou/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: provide example use of Debug.monitor and Debug.trace
New Features: provide new Example 50.3. Using Debug.monitor() and Debug.trace()
Bugs Fixed: LPP-4954
Technical Reviewer: (pending)
QA Reviewer: (pending)
Doc Reviewer: (pending)
Documentation: remove old static listing of Debug.monitor()
remove legacy code examples that the build ignored
.......
r7007 | jcrowley | 2007-10-25 08:04:19 -0700 (Thu, 25 Oct 2007) | 65 lines
Change 20071019-jcrowley-N by jcrowley at doctormanhattan.mshome.net on 2007-10-19 04:46:51 EDT
in /Users/jcrowley/src/svn/openlaszlo/trunk-a
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Various LzPix fixes
New Features:
Bugs Fixed: LPP-4877 - LZPix, SWF7 FireFox 2.0.0.7 WXP SP2: Scrolling
beyond 100 photos (or back from over 100) mashes counter and
counter only incremements by one
LPP-4876 - LZPix, SWF7 Safari 2.0.4 OSX 10.4.10: Searches
only returning 100 photos
LPP-4874 - LZPix, SWF7 Firefox 2.0.0.7 OSX 10.4.10: Scrolling
backwards through found set presents photos in expanding grouping
LPP-4873 - LZPix, SWF7 Firefox 2.0.0.7 OSX 10.4.10: Scrolling
quickly during photo download will result in empty photo pane.
Technical Reviewer: max
QA Reviewer: ben
Doc Reviewer:
Documentation:
Release Notes:
Details: It turns out, Flickr's data can only be loaded in pages
of up to 100. So when there are more than 100 results,
it's broken up into separate XML pages that have to be
individually requested. So I added in a bunch of stuff
to facilitate this, where if you get to the end of one
list, it will request the next list when you move to the
right. This results in a rather insubstantial bit of
loading time while we switch between sheets. I added a
text field that temporarily replaces the image counter
in the lower right-hand side that appears during this
loading time, to indicate that it's getting the next 100
or previous 100 (if you're going backward).
In doing so, I also made it so you can't scroll beyond
the 100 in each list, which fixes one of the other bugs.
Meanwhile, I noticed and fixed a few minor glitches while
I was in there (like if you search for a new term, the
search results come in starting at the image number
where you'd left off in the previous search), and
a couple other minor things (misplaced text, etc).
Tests: Run modified LzPix versus unmodified:
Move beyond 100 images. Note that new data is loaded
after you get to the end of the first set of 100, and
that you no longer move off into oblivion with a
broken counter.
Move backward from 100, and note that you move into the
previous data. Note that images aren't grouped together
awkwardly as described in LPP-4874.
Move forward to about 150. Search for something new,
either by using the search box or clicking on one of
the "favorites" pictures. Note that the image count
resets instead of remaining where you were.
.......
r7009 | jcrowley | 2007-10-25 09:46:45 -0700 (Thu, 25 Oct 2007) | 28 lines
Change 20071023-jcrowley-u by jcrowley at doctormanhattan.mshome.net on 2007-10-23 03:39:14 EDT
in /Users/jcrowley/src/svn/openlaszlo/trunk-g
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Warnings in test/extensions/html.lzx
New Features:
Bugs Fixed: LPP-4344 - Warnings in test/extensions/html.lzx
Technical Reviewer: pbr
QA Reviewer: ben
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details: There are no width, height, x or y attributes
on the html class. Removed these attempts at
declaring these attributes from the test file.
(The remaining errors are from Henry's schema
changes.)
Tests: Run test/extensions/html.lzx and notice an absence
of errors about undefined attributes.
.......
Property changes on: openlaszlo/branches/paperpie
___________________________________________________________________
Name: svnmerge-integrated
- /openlaszlo/branches/wafflecone:1-5746,5818-6068,6070-6205,6207-6213,6216-6265,6267-6368,6370-6431,6433-6450,6497 /openlaszlo/trunk:1-6877
+ /openlaszlo/branches/wafflecone:1-5746,5818-6068,6070-6205,6207-6213,6216-6265,6267-6368,6370-6431,6433-6450,6497 /openlaszlo/trunk:1-7010
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/build.xml
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/build.xml 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/build.xml 2007-10-25 21:44:51 UTC (rev 7011)
@@ -151,6 +151,7 @@
var buildDebug = lfc.getProperty("build.lfc.runtime.debug");
var buildProfile = lfc.getProperty("build.lfc.runtime.profile");
+ var buildDebugSimple = lfc.getProperty("build.lfc.runtime.debug.simple");
var LFCdir = lfc.getProperty("LFCdir") + '/';
importPackage(java.io);
@@ -161,22 +162,42 @@
dobuild(plain, "dhtml", "");
}
if (buildDebug) {
- var debug = LFCdir + "LFCdhtml-debug.js";
- if (!(new File(debug)).exists()) {
+ var dest = LFCdir + "LFCdhtml-debug.js";
+ if (!(new File(dest)).exists()) {
// TODO: [2006-06-07 ptw] (LPP-2034) When the LFC is 'clean' of
// warnings, the options can be changed to simply --debug
- dobuild(debug,
+ dobuild(dest,
"dhtml",
"--option nameFunctions --option warnGlobalAssignments '-D$debug=true'");
}
- var backtrace = LFCdir + "LFCdhtml-backtrace.js";
- if (!(new File(backtrace)).exists()) {
+ if (buildDebugSimple) {
+ var dest = LFCdir + "LFCdhtml-debug-simple.js";
+ if (!(new File(dest)).exists()) {
+ // TODO: [2006-06-07 ptw] (LPP-2034) When the LFC is 'clean' of
+ // warnings, the options can be changed to simply --debug
+ dobuild(dest,
+ "dhtml",
+ "--option debugSimple --option nameFunctions --option warnGlobalAssignments '-D$debug=true'");
+ }
+ }
+ var dest = LFCdir + "LFCdhtml-backtrace.js";
+ if (!(new File(dest)).exists()) {
// TODO: [2006-06-07 ptw] (LPP-2034) When the LFC is 'clean' of
// warnings, the options can be changed to simply -g3
- dobuild(backtrace,
+ dobuild(dest,
"dhtml",
"--option debugBacktrace --option nameFunctions --option warnGlobalAssignments '-D$debug=true'");
}
+ if (buildDebugSimple) {
+ var dest = LFCdir + "LFCdhtml-backtrace-simple.js";
+ if (!(new File(dest)).exists()) {
+ // TODO: [2006-06-07 ptw] (LPP-2034) When the LFC is 'clean' of
+ // warnings, the options can be changed to simply -g3
+ dobuild(dest,
+ "dhtml",
+ "--option debugSimple --option debugBacktrace --option nameFunctions --option warnGlobalAssignments '-D$debug=true'");
+ }
+ }
}
if (buildProfile) {
var profile = LFCdir + "LFCdhtml-profile.js";
@@ -199,19 +220,19 @@
dobuild(plain, "swf" + v, "");
}
if (buildDebug) {
- var debug = LFCdir + "LFC" + v + "-debug.lzl";
- if (!(new File(debug)).exists()) {
+ var dest = LFCdir + "LFC" + v + "-debug.lzl";
+ if (!(new File(dest)).exists()) {
// TODO: [2006-06-07 ptw] (LPP-2034) When the LFC is 'clean' of
// warnings, the options can be changed to simply --debug
- dobuild(debug,
+ dobuild(dest,
"swf" + v,
"--option nameFunctions --option warnGlobalAssignments '-D$debug=true'");
}
- var backtrace = LFCdir + "LFC" + v + "-backtrace.lzl";
- if (!(new File(backtrace)).exists()) {
+ var dest = LFCdir + "LFC" + v + "-backtrace.lzl";
+ if (!(new File(dest)).exists()) {
// TODO: [2006-06-07 ptw] (LPP-2034) When the LFC is 'clean' of
// warnings, the options can be changed to simply -g3
- dobuild(backtrace,
+ dobuild(dest,
"swf" + v,
"--option debugBacktrace --option nameFunctions --option warnGlobalAssignments '-D$debug=true'");
}
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/compiler/LzRuntime.lzs
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/compiler/LzRuntime.lzs 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/compiler/LzRuntime.lzs 2007-10-25 21:44:51 UTC (rev 7011)
@@ -222,9 +222,6 @@
Debug.__write(warning);
};
- Debug.debug("Source warnings enabled");
- $reportSourceWarning('testing', 0, 'Test source warning');
-
// Each of the warnings that the compile may call maintains a flag to
// avoid recursing (e.g., when the debugger has a bug).
@@ -339,5 +336,34 @@
}
}
}
+
+ if ($as2) {
+ /**
+ * Evaluate a closure in context, ignoring any errors
+ * @param closure:Function the closure to evaluate
+ * @param context:Object the context to evaluate the closure in
+ * @param errval:* the value to return if there is an error
+ * @access private
+ */
+ Debug.ignoringErrors = function ignoringErrors (closure, context, errval) {
+ #pragma "warnUndefinedReferences=false"
+ return closure.call(context);
+ }
+ } else {
+ /**
+ * Evaluate a closure in context, ignoring any errors
+ * @param closure:Function the closure to evaluate
+ * @param context:Object the context to evaluate the closure in
+ * @param errval:* the value to return if there is an error
+ * @access private
+ */
+ Debug.ignoringErrors = function ignoringErrors (closure, context, errval) {
+ #pragma "warnUndefinedReferences=false"
+ try {
+ return closure.call(context);
+ } catch(e) {
+ return errval;
+ }
+ }
+ }
}
-
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/data/LzReplicationManager.lzs
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/data/LzReplicationManager.lzs 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/data/LzReplicationManager.lzs 2007-10-25 21:44:51 UTC (rev 7011)
@@ -289,6 +289,18 @@
/**
* @access private
*/
+function setDataContext ( p , implicit ){
+ var args = arguments;
+ if (p == null && this.immediateparent != null && 'datapath' in this.immediateparent && this.immediateparent.datapath != null){
+ args[0] = this.immediateparent.datapath;
+ args[1] = true;
+ }
+ super.setDataContext.apply(this, args);
+}
+
+/**
+ * @access private
+ */
function getNodeOffset ( p ){
if (this.nodes != null) {
var l = this.nodes.length;
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/debugger/LzDebug.lzs
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/debugger/LzDebug.lzs 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/debugger/LzDebug.lzs 2007-10-25 21:44:51 UTC (rev 7011)
@@ -481,15 +481,19 @@
var alen = (('length' in obj) &&
(Math.floor(obj.length) === obj.length) &&
(obj.length >= 0)) ? obj.length : false;
- var hopp = 'hasOwnProperty' in obj;
- var proto = (('__proto__' in obj) ? obj.__proto__ :
- (('constructor' in obj) ? obj.constructor.prototype : false));
+ var hopp = 'hasOwnProperty' in obj && obj.hasOwnProperty instanceof Function;
+ // Use typeof == 'object' rather than instanceof Object for native prototypes
+ var proto = (('__proto__' in obj && (typeof obj.__proto__ == 'object')) ? obj.__proto__ :
+ (('constructor' in obj && (typeof obj.constructor.prototype == 'object')) ? obj.constructor.prototype : false));
for (var key in obj) {
- if ((! hopp) ||
- obj.hasOwnProperty(key) ||
- // Heuristic to find getter slots (there is no way to ask if a
- // property is a getter)
- (proto && (obj[key] !== proto[key]))) {
+ // Heuristic to find 'interesting' slots, by which we mean slots
+ // that have a non-inherited value. This should find 'own' slots,
+ // getters, and funny 'native' slots like swf movieclips, etc.
+ if ((! proto) ||
+ this.ignoringErrors(function () { return obj.hasOwnProperty(key);}, this, (! (key in proto))) ||
+ // Be careful poking at prototypes (consider getters that may
+ // fail when called on the prototype)
+ (obj[key] !== this.ignoringErrors(function () { return proto[key];}, this, {}))) {
if ((alen != false) &&
// Only `==` here because all keys are strings
(Math.floor(key) == key) &&
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/debugger/platform/dhtml/LzDebug.js
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/debugger/platform/dhtml/LzDebug.js 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/debugger/platform/dhtml/LzDebug.js 2007-10-25 21:44:51 UTC (rev 7011)
@@ -222,8 +222,9 @@
s = this.functionName(thing, false);
if (s == null) { s = ''; }
}
- } else if (! isNaN(Number(thing['nodeType']))) { // Doesn't work in Opera (thing instanceof Node) {
- // tip o' the pin to osteele.com fot the notation format
+ } else if ((thing instanceof HTMLElement) &&
+ (! isNaN(Number(thing['nodeType'])))) {
+ // tip o' the pin to osteele.com for the notation format
function nodeToString(node) {
var tn = node.nodeName || '';
var path = tn.toLowerCase();
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/LzUtils.lzs
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/LzUtils.lzs 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/LzUtils.lzs 2007-10-25 21:44:51 UTC (rev 7011)
@@ -99,7 +99,7 @@
}
if (typeof c == 'number') {
- var hex = LzUtils.dectohex(c, 6);
+ var hex = LzUtils.dectohex(c & 0xffffff, 6);
c = '#' + hex;
}
return c;
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/dhtml/LzContextMenu.js
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/dhtml/LzContextMenu.js 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/dhtml/LzContextMenu.js 2007-10-25 21:44:51 UTC (rev 7011)
@@ -65,9 +65,22 @@
var o = '';
for (var i = 0; i < this.items.length; i++) {
- var v = this.items[i].cmenuitem;
+ var cm = this.items[i];
+ var v = cm.cmenuitem;
if (v.visible != true) continue;
if (v.separatorBefore) o += '<br/>';
+
+ // Don't display the same item twice (matches swf behavior)
+ var duplicate = false;
+ for (var j=0; j<i; j++) {
+ if (cm._equals(this.items[j])) {
+ duplicate = true;
+ break;
+ }
+ }
+ if (duplicate)
+ continue;
+
if (v.enabled) {
o += '<a onmousedown="javascript:LzMouseKernel.__showncontextmenu.__select(' + i + ');return false;"'
o +='>' + v.caption + '</a>';
@@ -187,6 +200,13 @@
}
}
+/** @access private */
+// Must match the behavior of swf (only the caption is matched)
+function _equals (cm) {
+ return (cm != null) && (this.cmenuitem.caption == cm.cmenuitem.caption);
+}
+
+
/**
* LzContextMenuItem.setCaption
* Sets the text string which is displayed for the menu item
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js 2007-10-25 21:44:51 UTC (rev 7011)
@@ -673,7 +673,17 @@
}
//Debug.write('__mouseEvent', eventname, this.owner);
- if (skipevent == false && this.owner.mouseevent && LzModeManager && LzModeManager['handleMouseButton']) LzModeManager.handleMouseButton(this.owner, eventname);
+ if (skipevent == false && this.owner.mouseevent && LzModeManager && LzModeManager['handleMouseButton']) {
+ LzModeManager.handleMouseButton(this.owner, eventname);
+
+ if (this.__mousedown) {
+ if (eventname == 'onmouseover') {
+ LzModeManager.handleMouseButton(this.owner, 'onmousedragin');
+ } else if (eventname == 'onmouseout') {
+ LzModeManager.handleMouseButton(this.owner, 'onmousedragout');
+ }
+ }
+ }
}
// called by LzMouseKernel when mouse goes up on another sprite
@@ -683,6 +693,7 @@
LzSprite.prototype.__globalmouseup = function ( e ){
if (this.__mousedown) {
this.__mouseEvent(e);
+ this.__mouseEvent({type: 'mouseupoutside'});
}
}
@@ -845,6 +856,7 @@
if (this.frames && this.frames.length > 1) {
this.playing = true;
+ this.owner.resourceevent('play', null, true);
LzIdleKernel.addCallback(this, '__incrementFrame');
}
}
@@ -852,6 +864,7 @@
LzSprite.prototype.stop = function(f) {
if (this.playing == true) {
this.playing = false;
+ this.owner.resourceevent('stop', null, true);
LzIdleKernel.removeCallback(this, '__incrementFrame');
}
@@ -879,10 +892,12 @@
LzSprite.prototype.__updateFrame = function(force) {
if (this.playing || force) {
var url = this.frames[this.frame - 1];
- //Debug.info('__updateFrame', this.frame, url);
+ //Debug.info('__updateFrame', this.frame, url, this.owner);
this.setSource(url, true);
}
- if (this.owner.frame != this.frame - 1) this.owner.spriteAttribute('frame', this.frame);
+ this.owner.resourceevent('frame', this.frame);
+ if (this.frames.length == this.frame)
+ this.owner.resourceevent('lastframe', null, true);
}
if (LzSprite.prototype.quirks.preload_images_only_once) {
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzLoadQueue.as
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzLoadQueue.as 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzLoadQueue.as 2007-10-25 21:44:51 UTC (rev 7011)
@@ -104,6 +104,11 @@
// cancel the timeout handler
LzLoadQueue.unloadRequest(this);
} else {
+ // If we timed out, and this response came in late, ignore it.
+ if (this.timedout) {
+ return;
+ }
+
//Debug.write("LzLoadQueue.XMLOnDataHandler success", this, this.loader);
// Create a queue containing one root node, myself, and convert it and all children to
// LzDataNodes.
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzLoader.lzs
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzLoader.lzs 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzLoader.lzs 2007-10-25 21:44:51 UTC (rev 7011)
@@ -113,7 +113,9 @@
} else {
var lmname = "loadmc" + this.loadmcdepth;
if (this.mc[lmname]) {
- Debug.error("%w.mc[%s]: %w", this, lmname, this.mc[lmname]);
+ if ($debug) {
+ Debug.error("%w.mc[%s]: %w", this, lmname, this.mc[lmname]);
+ }
}
this.mc.attachMovie( "empty" , lmname , this.loadmcdepth );
var newmc = this.mc[ lmname ];
@@ -144,7 +146,7 @@
// object. This can happen if a serverless data load timed out in
// the LFC, but eventually returned something via the
// LoadVars.sendAndLoad() callback.
- if (loadobj.loaded && loadobj.valid) {
+ if (loadobj.loaded && loadobj.valid && loadobj.timedout && data == null) {
if ($debug) {
Debug.warn("%w.returnData: %w already loaded",
this, loadobj);
@@ -200,9 +202,15 @@
}
if ( err != null ){
- Debug.error( err );
+ if ($debug) {
+ Debug.error( err );
+ }
if (this.onerror.ready) {
- this.onerror.sendEvent( err );
+ /* we need to pass the data-object if our owner is a LzHTTPLoader,
+ * to conform to the new LzHTTPDataProvider class,
+ * also see "LzHTTPDataProvider#loadResponse(..)"
+ */
+ this.onerror.sendEvent( this.owner instanceof LzHTTPLoader ? data : err );
}
return;
}
@@ -349,6 +357,9 @@
* @access private
*/
function requestDirectXML ( o ){
+ if ($debug) {
+ LzLoader.debugLoadObj(o);
+ }
this.initializeRequestObj(o);
LzLoadQueue.enqueueRequest( o );
// We should probably be passing something other than the obj itself to
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzSprite.as
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzSprite.as 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzSprite.as 2007-10-25 21:44:51 UTC (rev 7011)
@@ -154,11 +154,6 @@
// when it has the focus. (see LzFocus for more details)
LzSprite.prototype.focusable = false;
-LzSprite.prototype.width = null;
-LzSprite.prototype.height = null;
-LzSprite.prototype.x = 0;
-LzSprite.prototype.y = 0;
-
LzSprite.prototype.visible = true;
LzSprite.prototype.opacity = 1;
@@ -460,9 +455,20 @@
}
this.bgcolor = Number(bgc);
this.applyBG();
+ if (this._bgcolorhidden) {
+ this.__LZbgRef._alpha = this.opacity * 100;
+ // overriding context menu color so opacity setting works
+ this._bgcolorshown = true;
+ }
} else {
- this.bgcolor = null;
- this.removeBG();
+ if (this._bgcolorhidden) {
+ this.__LZbgRef._alpha = 0;
+ //opacity setting should not work
+ this._bgcolorshown = false;
+ } else {
+ this.bgcolor = null;
+ this.removeBG();
+ }
}
}
@@ -629,7 +635,8 @@
if (this.__LZmovieClipRef)
this.__LZmovieClipRef._alpha = 100*v;
- if (this.__LZbgRef)
+ // set the bgcolor alpha if not set by the context menu and overridden by the context menu
+ if (this.__LZbgRef && (this._bgcolorhidden != true && this._bgcolorshown != true))
this.__LZbgRef._alpha = 100*v;
//@event onopacity: Sent when a view changes its opacity
@@ -1139,9 +1146,9 @@
//Debug.write('got attachPoint', cVMv);
var reback = cSprite.__LZisBackgrounded;
- var menu = null;
if (reback) {
- menu = cSprite.__LZbgRef.menu;
+ var menu = cSprite.__LZbgRef.menu;
+ var al = cSprite.__LZbgRef._alpha;
}
cSprite.removeBG();
while (cSprite.__LZdepth + next < dl.length && cSprite.__LZdepth+next >= 0 ){
@@ -1169,15 +1176,18 @@
if ( nv.__LZisBackgrounded ){
var menu2 = nv.__LZbgRef.menu;
+ var al2 = nv.__LZbgRef._alpha;
nv.removeBG();
nv.applyBG();
nv.__LZbgRef.menu = menu2;
+ nv.__LZbgRef._alpha = al2;
}
}
if ( reback ){
cSprite.applyBG();
cSprite.__LZbgRef.menu = menu;
+ cSprite.__LZbgRef._alpha = al;
}
return true;
}
@@ -1548,16 +1558,15 @@
}
}
- var mc = this.getMCRef();
// [todo hqm 01-24-07] SWF-specific
var mb = this.__LZbgRef;
- // If there's no movieclip attached, use the background clip.
- if (mc != null) {
- mc.menu = cmenu;
+ if (mb == null) {
+ this.setBGColor(0xffffff);
+ var mb = this.__LZbgRef;
+ mb._alpha = 0;
}
- if (mb != null) {
- mb.menu = cmenu;
- }
+ this._bgcolorhidden = true;
+ mb.menu = cmenu;
if (mb == null && mc == null) {
if ($debug) Debug.warn("LzView.setContextMenu: cannot set menu on view %w, it has no foreground or background movieclip", this.owner);
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzTextSprite.as
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzTextSprite.as 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/kernel/swf/LzTextSprite.as 2007-10-25 21:44:51 UTC (rev 7011)
@@ -775,13 +775,6 @@
/**
*
*/
-LzTextSprite.prototype.setScroll = function (s){
- this.__LZtextclip.scroll = s;
-}
-
-/**
- *
- */
LzTextSprite.prototype.setHScroll = function (s){
this.__LZtextclip.hscroll = s;
}
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/services/LzModeManager.lzs
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/services/LzModeManager.lzs 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/services/LzModeManager.lzs 2007-10-25 21:44:51 UTC (rev 7011)
@@ -52,8 +52,6 @@
/** Sent when the mode changes. */
DeclareEvent(LzModeManager, 'onmode' );
-LzModeManager.onmode = null;
-
/** @access private */
LzModeManager.__LZlastclick = null;
LzModeManager.willCall = false;
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/services/LzTrack.lzs
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/services/LzTrack.lzs 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/services/LzTrack.lzs 2007-10-25 21:44:51 UTC (rev 7011)
@@ -12,8 +12,8 @@
/**
* <p>This service helps tracking the mouse over a number of views, as in
* common when implementing menus and drag-and-drop behaviors. When the
- * mouse is down, standard view events such as <event>ondragin</event>
- * and <event>ondragout</event> are only sent to the view which received
+ * mouse is down, standard view events such as <event>onmousedragin</event>
+ * and <event>onmousedragout</event> are only sent to the view which received
* the onmousedown events. When views are registered using the
* <classname>LzTrack</classname> service, they will receive events
* independent of the mouse button state.
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/views/LaszloView.lzs
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/views/LaszloView.lzs 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/views/LaszloView.lzs 2007-10-25 21:44:51 UTC (rev 7011)
@@ -76,7 +76,6 @@
*/
static var tagname = 'view';
-DeclareEvent(prototype, 'onaddsubresource' );
/** Event called when this view adds a subview */
DeclareEvent(prototype, 'onaddsubview' );
DeclareEvent(prototype, 'onbgcolor' );
@@ -995,6 +994,16 @@
}
/**
+ * @access private
+ * Called by the sprite when the resource playback events occur
+ */
+function resourceevent(name, value, eventonly) {
+ if (eventonly != true) this[name] = value;
+ var ev = this['on'+ name];
+ if (ev.ready) ev.sendEvent(value);
+}
+
+/**
* This method is called to set the number of total frames in the resource.
* The ontotalframes event is generated
*
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/lfc/views/LzText.lzs
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/lfc/views/LzText.lzs 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/lfc/views/LzText.lzs 2007-10-25 21:44:51 UTC (rev 7011)
@@ -992,13 +992,6 @@
/**
*
*/
-function setScroll (s){
- this.sprite.setScroll(s);
-}
-
-/**
- *
- */
function setHScroll (s){
this.sprite.setHScroll(s);
}
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/schema/lfc.lzx
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/schema/lfc.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/schema/lfc.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -13,15 +13,31 @@
* P_LZ_COPYRIGHT_END ********************************************************
-->
+
+<interface name="Instance" extends="Object">
+ <method name="validateClassStructure" override="false"/>
+ <method name="initialize" override="false"/>
+ <method name="nextMethod" override="false"/>
+ <method name="addProperty" override="false"/>
+ <method name="constructor" override="false"/>
+ <method name="hasOwnProperty" override="false"/>
+ <method name="isPropertyEnumerable" override="false"/>
+ <method name="isPrototypeOf" override="false"/>
+ <method name="toLocaleString" override="false"/>
+ <method name="prototype" override="false"/>
+ <method name="apply" override="false"/>
+ <method name="call" override="false"/>
+</interface>
+
<interface name="canvas" extends="Instance">
<attribute name="id" type="ID"/>
<!-- The oninit script is executed once, after the element's
children, if any, have been initialized. -->
<event name="oninit"/>
<!-- The width of the canvas. -->
- <attribute name="width" type="sizeExpression" value="500"/>
+ <attribute name="width" type="size" value="500"/>
<!-- The height of the canvas. -->
- <attribute name="height" type="sizeExpression" value="400"/>
+ <attribute name="height" type="size" value="400"/>
<!-- The background color of the canvas. -->
<attribute name="bgcolor" type="color" value="white"/>
<!-- The string that is used in the browser window. -->
@@ -112,6 +128,10 @@
-->
<event name="oninit"/>
<event name="ondata"/>
+ <event name="onconstruct"/>
+ <event name="onclonenumber"/>
+ <event name="ondestroy"/>
+
<attribute name="initstage" type="string" value="normal" enum="early|normal|late|immediate|defer"/>
<attribute name="datapath" type="string"/>
<attribute name="placement" type="string"/>
@@ -141,7 +161,7 @@
<attribute name="fgcolor" type="color"/>
<attribute name="font" type="string"/>
<attribute name="fontstyle" type="string"/>
- <attribute name="fontsize" type="sizeExpression"/>
+ <attribute name="fontsize" type="size"/>
<attribute name="resource" type="string"/>
<attribute name="source" type="expression" />
<attribute name="clip" type="boolean" value="false"/>
@@ -157,8 +177,8 @@
<attribute name="stretches" type="string" enum="width|height|both"/>
<attribute name="visible" type="expression" value="true"/>
<attribute name="visibility" type="string" value="visibility"/>
- <attribute name="width" type="sizeExpression"/>
- <attribute name="height" type="sizeExpression"/>
+ <attribute name="width" type="size"/>
+ <attribute name="height" type="size"/>
<attribute name="x" type="numberExpression" value="0"/>
<attribute name="y" type="numberExpression" value="0"/>
<attribute name="aaname" type="string"/>
@@ -167,17 +187,49 @@
<attribute name="aatabindex" type="number"/>
<attribute name="aasilent" type="boolean"/>
<attribute name="showhandcursor" type="boolean"/>
+ <event name="onaddsubresource"/>
+ <event name="onaddsubview"/>
+ <event name="onbgcolor"/>
+ <event name="onblur"/>
<event name="onclick"/>
<event name="ondblclick"/>
- <event name="onmousedown"/>
- <event name="onmouseup"/>
- <event name="onmouseover"/>
- <event name="onmouseout"/>
+ <event name="onerror"/>
<event name="onfocus"/>
- <event name="onblur"/>
+ <event name="onframe"/>
+ <event name="onheight"/>
+ <event name="onimload"/>
<event name="onkeydown"/>
<event name="onkeyup"/>
+ <event name="onlastframe"/>
+ <event name="onload"/>
+ <event name="onloadperc"/>
+ <event name="onmousedown"/>
+ <event name="onmouseout"/>
+ <event name="onmouseover"/>
+ <event name="onmousetrackover"/>
+ <event name="onmousetrackup"/>
+ <event name="onmouseup"/>
+ <event name="onopacity"/>
+ <event name="onplay"/>
+ <event name="onremovesubview"/>
+ <event name="onresource"/>
+ <event name="onresourceheight"/>
+ <event name="onresourcewidth"/>
+ <event name="onrotation"/>
<event name="onselect"/>
+ <event name="onstop"/>
+ <event name="ontimeout"/>
+ <event name="ontotalframes"/>
+ <event name="onunstretchedheight"/>
+ <event name="onunstretchedwidth"/>
+ <event name="onvisibility"/>
+ <event name="onvisible"/>
+ <event name="onwidth"/>
+ <event name="onx"/>
+ <event name="onxoffset"/>
+ <event name="ony"/>
+ <event name="onyoffset"/>
+
<containsElements>
<element>dataselectionmanager</element>
<element>selectionmanager</element>
@@ -367,7 +419,7 @@
<!-- This controls the spacing between elements if <a
href="datapath.html#attr-replication">lazy replication</a> is
true -->
- <attribute name="spacing" type="sizeExpression" value="0"/>
+ <attribute name="spacing" type="size" value="0"/>
<attribute name="p" type="expression"/>
</interface>
@@ -451,7 +503,9 @@
</interface>
<interface name="state" extends="node">
- <attribute name="apply" type="boolean"/>
+ <!-- This is unfortunately both a setter attribute AND a method. No
+ real nice way to represent that. -->
+ <method name="apply" override="true" />
<!-- If pooling is true, views that are created by the state are not
destroyed when the state is removed - instead they just act as
if they were by sending the onremovesubview event and setting
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/sc/src/org/openlaszlo/sc/Parser.jjt
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/sc/src/org/openlaszlo/sc/Parser.jjt 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/sc/src/org/openlaszlo/sc/Parser.jjt 2007-10-25 21:44:51 UTC (rev 7011)
@@ -216,10 +216,13 @@
)*
"'"
>
-| // The Octal escapes are not in the spec, but rhino accepts them
+| // any single char can be escaped although "n","t","b","r","f","v"
+ // have special meanings
+ // The Octal escapes are not in the spec, but rhino accepts them;
+ // the x and u specs ensure they are valid
< #ESCAPE_SEQUENCE:
"\\"
- ( ["n","t","b","r","f","v","\\","'","\""]
+ ( (~["0"-"7","x","u"])
| (["0"-"3"])? (["0"-"7"])? ["0"-"7"]
| ["x"] ["0"-"9","a"-"f","A"-"F"] ["0"-"9","a"-"f","A"-"F"]
| ["u"] ["0"-"9","a"-"f","A"-"F"] ["0"-"9","a"-"f","A"-"F"] ["0"-"9","a"-"f","A"-"F"] ["0"-"9","a"-"f","A"-"F"]
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/AttributeSpec.java
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/AttributeSpec.java 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/AttributeSpec.java 2007-10-25 21:44:51 UTC (rev 7011)
@@ -18,7 +18,7 @@
/** The attribute name */
String name;
/** The default value */
- String defaultValue;
+ String defaultValue = null;
/** The setter function */
String setter;
/** The type of the attribute value*/
@@ -28,6 +28,12 @@
/** When does the initial value for this attribute get evaluated? */
String when = NodeModel.WHEN_IMMEDIATELY;
+ /** If this is a method, the arglist */
+ String arglist = null;
+
+ /** Can this attribute be overridden without a warning? value is null, 'true' or 'false' */
+ String override = null;
+
/** Is this attribute equivalent to element content of a given type? */
int contentType = NO_CONTENT;
@@ -49,6 +55,10 @@
public String toLZX(String indent, ClassModel superclass) {
AttributeSpec superSpec = superclass.getAttribute(name);
+ if (ViewSchema.METHOD_TYPE.equals(type)) {
+ return indent + " <method name='" + name + "'" + (("".equals(arglist))?"":(" args='" + arglist +"'")) + " />";
+ }
+
if (superSpec == null) {
if (ViewSchema.EVENT_HANDLER_TYPE.equals(type)) {
return indent + "<event name='" + name + "' />";
@@ -82,6 +92,21 @@
}
return null;
}
+
+ public String toString() {
+ if (ViewSchema.METHOD_TYPE.equals(type)) {
+ return "[AttributeSpec: method name='" + name + "'" + (("".equals(arglist))?"":(" args='" + arglist +"'")) + " override="+(override == null ? "null" : ("'"+override+"'"))+"]";
+ }
+ if (ViewSchema.EVENT_HANDLER_TYPE.equals(type)) {
+ return "[AttributeSpec: event name='" + name + "' ]";
+ }
+ return "[AttributeSpec: attribute name='" + name + "'" +
+ ((defaultValue != null)?(" value='" + defaultValue + "'"):"") +
+ ((type != null)?(" type='" + typeToLZX() + "'"):"") +
+ ((when != NodeModel.WHEN_IMMEDIATELY)?(" when='" + when + "'"):"") +
+ (required?(" required='true'"):"") +
+ " ";
+ }
AttributeSpec (String name, Type type, String defaultValue, String setter, Element source) {
this.source = source;
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ClassCompiler.java
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ClassCompiler.java 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ClassCompiler.java 2007-10-25 21:44:51 UTC (rev 7011)
@@ -127,9 +127,29 @@
Object o = iterator.next();
if (o instanceof Element) {
Element child = (Element) o;
+ if (child.getName().equals("method")) {
+ String attrName = child.getAttributeValue("name");
+ String attrEvent = child.getAttributeValue("event");
+ if (attrEvent == null) {
+ if (schema.enforceValidIdentifier) {
+ try {
+ attrName = requireIdentifierAttributeValue(child, "name");
+ } catch (MissingAttributeException e) {
+ throw new CompilationError(
+ "'name' is a required attribute of <" + child.getName() + "> and must be a valid identifier", child);
+ }
+ }
+ ViewSchema.Type attrType = ViewSchema.METHOD_TYPE;
+ AttributeSpec attrSpec =
+ new AttributeSpec(attrName, attrType, null, null, child);
+ attrSpec.override = child.getAttributeValue("override");
+ attributeDefs.add(attrSpec);
+ }
+
+ } else if (child.getName().equals("attribute")) {
// Is this an element named ATTRIBUTE which is a
// direct child of this CLASS or INTERFACE tag?
- if (child.getName().equals("attribute")) {
+
String attrName = child.getAttributeValue("name");
if (schema.enforceValidIdentifier) {
try {
@@ -179,6 +199,7 @@
AttributeSpec attrSpec =
new AttributeSpec(attrName, attrType, attrDefault,
attrSetter, child);
+ attrSpec.override = child.getAttributeValue("override");
if (attrName.equals("text") && attrTypeName != null) {
if ("text".equals(attrTypeName))
attrSpec.contentType = attrSpec.TEXT_CONTENT;
@@ -208,7 +229,7 @@
}
// Add this class to the schema
- schema.addElement(element, classname, superclass, attributeDefs);
+ schema.addElement(element, classname, superclass, attributeDefs, mEnv);
}
public void compile(Element elt) {
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ClassModel.java
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ClassModel.java 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ClassModel.java 2007-10-25 21:44:51 UTC (rev 7011)
@@ -29,8 +29,7 @@
protected boolean supportsTextAttribute = false;
/** Map attribute name to type */
protected final Map attributeSpecs = new LinkedHashMap();
- /** Map of method names to arglist */
- protected final Map methods = new LinkedHashMap();
+
protected boolean inline = false;
protected String sortkey = null;
@@ -82,14 +81,7 @@
lzx += specLZX;
}
}
- for (Iterator i = methods.entrySet().iterator(); i.hasNext(); ) {
- Map.Entry entry = (Map.Entry)i.next();
- String name = (String)entry.getKey();
- String arglist = (String)entry.getValue();
- if (superclass.getMethod(name) == null) {
- lzx += "\n" + indent + " <method name='" + name + "'" + (("".equals(arglist))?"":(" args='" + arglist +"'")) + " />";
- }
- }
+
lzx += "\n" + indent + "</interface>";
return lzx;
}
@@ -130,6 +122,14 @@
}
}
+ /** Return the AttributeSpec for the attribute named attrName.
+ Only returns locally defined attribute, does not follow up the
+ class hierarchy.
+ */
+ AttributeSpec getLocalAttribute(String attrName) {
+ return (AttributeSpec) attributeSpecs.get(attrName);
+ }
+
/** Return the AttributeSpec for the attribute named attrName. If
* the attribute is not defined on this class, look up the
* superclass chain.
@@ -198,23 +198,6 @@
return type;
}
- /** Return the 'MethodSpec' for the method named methName. If
- * the method is not defined on this class, look up the
- * superclass chain.
- * TODO: [2007-01-27 ptw] For now the MethodSpec is just the
- * arglist String
- */
- String getMethod(String methName) {
- String meth = (String) methods.get(methName);
- if (meth != null) {
- return meth;
- } else if (superclass != null) {
- return(superclass.getMethod(methName));
- } else {
- return null;
- }
- }
-
void setNodeModel(NodeModel model) {
this.nodeModel = model;
}
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/Compiler.java
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/Compiler.java 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/Compiler.java 2007-10-25 21:44:51 UTC (rev 7011)
@@ -370,6 +370,17 @@
// If we are not linking, then we consider all external
// files to have already been imported.
if (! linking) { externalLibraries = env.getImportedLibraryFiles(); }
+ if (root.getName().intern() !=
+ (linking ? "canvas" : "library")) {
+ throw new CompilationError(
+/* (non-Javadoc)
+ * @i18n.test
+ * @org-mes="invalid root element type: " + p[0]
+ */
+ org.openlaszlo.i18n.LaszloMessages.getMessage(
+ Compiler.class.getName(),"051018-357", new Object[] {root.getName()})
+ );
+ }
Compiler.updateRootSchema(root, env, schema, externalLibraries);
Properties nprops = (Properties) env.getProperties().clone();
Map compileTimeConstants = new HashMap();
@@ -406,17 +417,6 @@
mLogger.debug("new env..." + env.getProperties().toString());
- if (root.getName().intern() !=
- (linking ? "canvas" : "library")) {
- throw new CompilationError(
-/* (non-Javadoc)
- * @i18n.test
- * @org-mes="invalid root element type: " + p[0]
- */
- org.openlaszlo.i18n.LaszloMessages.getMessage(
- Compiler.class.getName(),"051018-357", new Object[] {root.getName()})
- );
- }
processCompilerInstructions(root, env);
compileElement(root, env);
@@ -613,17 +613,29 @@
static void updateRootSchema(Element root, CompilationEnvironment env,
ViewSchema schema, Set externalLibraries)
{
- ToplevelCompiler ec = (ToplevelCompiler)getElementCompiler(root, env);
- Set visited = new HashSet();
- // Update schema for auto-includes
- // Note: this call does _not_ share visited with the update
- // calls intentionally.
- for (Iterator iter = ec.getLibraries(env, root, null, externalLibraries, new HashSet()).iterator();
- iter.hasNext(); ) {
- File library = (File) iter.next();
- Compiler.updateSchemaFromLibrary(library, env, schema, visited);
- }
- ec.updateSchema(root, schema, visited);
+ ElementCompiler ecompiler = getElementCompiler(root, env);
+ if (! (ecompiler instanceof ToplevelCompiler)) {
+ throw new CompilationError(
+/* (non-Javadoc)
+ * @i18n.test
+ * @org-mes="invalid root element type: " + p[0]
+ */
+ org.openlaszlo.i18n.LaszloMessages.getMessage(
+ Compiler.class.getName(),"051018-357", new Object[] {root.getName()})
+ );
+ }
+ ToplevelCompiler tlc = (ToplevelCompiler) ecompiler;
+
+ Set visited = new HashSet();
+ // Update schema for auto-includes
+ // Note: this call does _not_ share visited with the update
+ // calls intentionally.
+ for (Iterator iter = tlc.getLibraries(env, root, null, externalLibraries, new HashSet()).iterator();
+ iter.hasNext(); ) {
+ File library = (File) iter.next();
+ Compiler.updateSchemaFromLibrary(library, env, schema, visited);
+ }
+ tlc.updateSchema(root, schema, visited);
}
static void updateSchema(Element element, CompilationEnvironment env,
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/NodeModel.java
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/NodeModel.java 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/NodeModel.java 2007-10-25 21:44:51 UTC (rev 7011)
@@ -585,11 +585,6 @@
// global there is "id='foo'" or if "name='foo'" at the
// top level (immediate child of the canvas).
//
- // NB: since this finds class names via a lookup from
- // elements in the schema, it will give some false
- // positives on class-name collisions, such as tag names
- // like "audio" which do not actually correspond to a LFC
- // class at runtime.
if ((name.equals("id")) ||
(name.equals("name") &&
topLevelDeclaration() && !className.equals("class"))) {
@@ -890,21 +885,19 @@
return (child.getName().equals("datapath"));
}
- void checkChildNameConflict(Element child, CompilationEnvironment env) {
+ /** Warn if named child tag conflicts with a declared attribute in the parent class.
+ */
+ void checkChildNameConflict(String parentName, Element child, CompilationEnvironment env) {
String attrName = child.getAttributeValue("name");
if (attrName != null) {
- ViewSchema.Type attrType = null;
- try {
- attrType = schema.getAttributeType(element, attrName);
- } catch (UnknownAttributeException e) {
-
- }
- if (attrType != null) {
+ AttributeSpec attrSpec = schema.getClassAttribute ( parentName, attrName) ;
+ // Only warn if the attribute we are shadowing has a declared initial value.
+ if (attrSpec != null && attrSpec.defaultValue != null) {
// TODO [2007-09-26 hqm] i18n this
env.warn(
"Child tag '" + child.getName() +
"' with attribute '"+attrName +
- "' conflicts with attribute named '"+attrName+"' of type '" + attrType +
+ "' conflicts with attribute named '"+attrName+"' of type '" + attrSpec.type +
"' on parent tag '"+element.getName()+"'.",
element);
}
@@ -927,7 +920,7 @@
try {
if (child.getName().equals("data")) {
- checkChildNameConflict(child, env);
+ checkChildNameConflict(element.getName(), child, env);
// literal data
addLiteralDataElement(child);
} else if (isPropertyElement(child)) {
@@ -937,11 +930,11 @@
} else if (schema.isDocElement(child)) {
; // ignore doc nodes.
} else if (isDatapathElement(child)) {
- checkChildNameConflict(child, env);
+ checkChildNameConflict(element.getName(), child, env);
NodeModel dpnode = elementAsModel(child, schema, env);
this.datapath = dpnode;
} else {
- checkChildNameConflict(child, env);
+ checkChildNameConflict(element.getName(), child, env);
NodeModel childModel = elementAsModel(child, schema, env);
children.add(childModel);
totalSubnodes += childModel.totalSubnodes();
@@ -1110,6 +1103,8 @@
String name = element.getAttributeValue("name");
String event = element.getAttributeValue("event");
String args = XMLUtils.getAttributeValue(element, "args", "");
+ String override = element.getAttributeValue("override");
+
if ((name == null || !ScriptCompiler.isIdentifier(name)) &&
(event == null || !ScriptCompiler.isIdentifier(event))) {
env.warn(
@@ -1148,12 +1143,6 @@
CompilerUtils.attributeUniqueName(element, "event") :
CompilerUtils.attributeUniqueName(element, "name"));
}
- if (name != null && "class".equals(className)) {
- schema.addMethodDeclaration(element,
- element.getParentElement().getAttributeValue("name"),
- name, args);
- }
-
if (event != null) {
if (name == null) {
// Names have to be unique across binary libraries, so
@@ -1210,6 +1199,18 @@
,element);
}
+
+
+ if (!("true".equals(override))) {
+ String classname = element.getParentElement().getName();
+ // Just check method declarations on regular node.
+ // Method declarations inside of class definitions will be already checked elsewhere,
+ // in the call from ClassCompiler.updateSchema to schema.addElement
+ if (!"class".equals(classname)) {
+ schema.checkMethodDeclaration(element, classname, name, env);
+ }
+ }
+
attrs.put(name, fndef);
}
@@ -1385,6 +1386,8 @@
if (when.equals(WHEN_IMMEDIATELY)) {
when = WHEN_ONCE;
}
+ } else if (type == ViewSchema.METHOD_TYPE) {
+ // methods are emitted elsewhere
} else {
throw new RuntimeException("unknown schema datatype " + type);
}
@@ -1526,6 +1529,7 @@
parenttype = getAttributeTypeInfoFromSuperclass(parent, name);
} else {
parenttype = schema.getAttributeType(parent, name);
+
}
} catch (UnknownAttributeException e) {
// If attribute type is not defined on parent, leave
@@ -1574,6 +1578,18 @@
}
}
+ // Warn if we are overidding a method, handler, or other function
+ if (parenttype == schema.METHOD_TYPE ||
+ parenttype == schema.EVENT_HANDLER_TYPE ||
+ parenttype == schema.SETTER_TYPE ||
+ parenttype == schema.REFERENCE_TYPE) {
+ env.warn( "In element '" + parent.getName()
+ + "' attribute '" + name
+ + "' is overriding parent class attribute which has the same name but type: "
+ + parenttype.toString(),
+ element);
+ }
+
// Don't initialize an attribute that is only declared.
if (value != null) {
CompiledAttribute cattr = compileAttribute(element, name,
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ViewSchema.java
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ViewSchema.java 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ViewSchema.java 2007-10-25 21:44:51 UTC (rev 7011)
@@ -78,12 +78,14 @@
public static final Type TOKEN_TYPE = newType("token");
public static final Type COLOR_TYPE = newType("color");
public static final Type NUMBER_EXPRESSION_TYPE = newType("numberExpression");
- public static final Type SIZE_EXPRESSION_TYPE = newType("sizeExpression");
+ public static final Type SIZE_EXPRESSION_TYPE = newType("size");
public static final Type CSS_TYPE = newType("css");
public static final Type INHERITABLE_BOOLEAN_TYPE = newType("inheritableBoolean");
public static final Type XML_LITERAL = newType("xmlLiteral");
+ public static final Type METHOD_TYPE = newType("method");
static {
+
sHTMLContentElements.add("text");
sInputTextElements.add("inputtext");
@@ -171,7 +173,13 @@
}
}
- public void addMethodDeclaration (Element elt, String classname, String methodName, String arglist) {
+ /** Checks to do when declaring a method on a class;
+ * Does the class exist?
+ * Is this a duplicate of another method declaration on this class?
+ * Does the superclass allow overriding of this method?
+ */
+ public void checkMethodDeclaration (Element elt, String classname, String methodName,
+ CompilationEnvironment env) {
ClassModel classModel = getClassModel(classname);
if (classModel == null) {
throw new RuntimeException(
@@ -181,19 +189,31 @@
*/
org.openlaszlo.i18n.LaszloMessages.getMessage(
ViewSchema.class.getName(),"051018-168", new Object[] {classname})
-);
+ );
}
- if (classModel.methods.get(methodName) != null) {
- throw new CompilationError(
-/* (non-Javadoc)
- * @i18n.test
- * @org-mes="duplicate definition of method " + p[0] + "." + p[1]
- */
- org.openlaszlo.i18n.LaszloMessages.getMessage(
- ViewSchema.class.getName(),"051018-207", new Object[] {classname, methodName})
-, elt);
+ AttributeSpec localAttr = classModel.getLocalAttribute(methodName);
+ if ( localAttr != null) {
+ if (localAttr.type == METHOD_TYPE) {
+ env.warn(
+ /* (non-Javadoc)
+ * @i18n.test
+ * @org-mes="duplicate definition of method " + p[0] + "." + p[1]
+ */
+ org.openlaszlo.i18n.LaszloMessages.getMessage(
+ ViewSchema.class.getName(),"051018-207", new Object[] {classname, methodName}),
+ elt);
+ } else {
+ env.warn(
+ "Method named "+methodName+" on class "+classname+
+ " conflicts with attribute with named "+methodName+" and type "+localAttr.type,
+ elt);
+ }
}
- classModel.methods.put(methodName, arglist);
+
+ if (!methodOverrideAllowed(classname, methodName)) {
+ env.warn("Method "+classname+"."+methodName+" is overriding a superclass method"
+ + " of the same name which has been declared non-overridable" , elt);
+ }
}
public String getSuperclassName(String className) {
@@ -246,7 +266,8 @@
* @param attributeDefs list of attribute name/type defs
*/
public void addElement (Element elt, String className,
- String superclassName, List attributeDefs)
+ String superclassName, List attributeDefs,
+ CompilationEnvironment env)
{
ClassModel superclass = getClassModel(superclassName);
@@ -312,7 +333,7 @@
}
// Add in the attribute declarations
- addAttributeDefs(elt, className, attributeDefs);
+ addAttributeDefs(elt, className, attributeDefs, env);
}
/**
@@ -323,7 +344,8 @@
* @param attributeDefs list of AttributeSpec attribute info to add to the Schema
*
*/
- void addAttributeDefs (Element sourceElement, String classname, List attributeDefs)
+ void addAttributeDefs (Element sourceElement, String classname, List attributeDefs,
+ CompilationEnvironment env)
{
if (!attributeDefs.isEmpty()) {
for (Iterator iter = attributeDefs.iterator(); iter.hasNext();) {
@@ -336,25 +358,26 @@
// redefining an attribute of a parent class with a
// different type.
- if (getClassAttribute(classname, attr.name) == null) {
- // Splice some XML into the Schema element
- String attrTypeName = attr.type.toString();
- } else {
+ Type parentType = null;
+ if (getClassAttribute(classname, attr.name) != null) {
// Check that the overriding type is the same as the superclass' type
- Type parentType = getAttributeType(classname, attr.name);
+ parentType = getAttributeType(classname, attr.name);
if (parentType != attr.type) {
- throw new CompilationError(sourceElement, attr.name, new Throwable(
- /* (non-Javadoc)
- * @i18n.test
- * @org-mes="In class '" + p[0] + "' attribute '" + p[1] + "' with type '" + p[2] + "' is overriding superclass attribute with same name but different type: " + p[3]
- */
- org.openlaszlo.i18n.LaszloMessages.getMessage(
- ViewSchema.class.getName(),"051018-364", new Object[] {classname, attr.name, attr.type.toString(), parentType.toString()})
- ));
+ env.warn(/* (non-Javadoc)
+ * @i18n.test
+ * @org-mes="In class '" + p[0] + "' attribute '" + p[1] + "' with type '" + p[2] + "' is overriding superclass attribute with same name but different type: " + p[3]
+ */
+ org.openlaszlo.i18n.LaszloMessages.getMessage(
+ ViewSchema.class.getName(),"051018-364", new Object[] {classname, attr.name, attr.type.toString(), parentType.toString()}),
+ sourceElement);
}
}
+ if (attr.type == ViewSchema.METHOD_TYPE && !("true".equals(attr.override))) {
+ checkMethodDeclaration(sourceElement, classname, attr.name, env);
+ }
+
// Update the in-memory attribute type table
setAttributeType(sourceElement, classname, attr.name, attr);
}
@@ -446,6 +469,23 @@
return type;
}
+
+ /**
+ * checks whether a method with a given method is allowed to be overridden
+ * @param elt an Element name
+ * @param methodName a method name
+ * @return boolean if the method exists on the class or superclass
+ */
+ public boolean methodOverrideAllowed(String classname, String methodName)
+ {
+ AttributeSpec methodspec = getClassAttribute(classname, methodName);
+ if (methodspec == null) {
+ return true;
+ } else {
+ return ! ("false".equals(methodspec.override));
+ }
+ }
+
boolean isMouseEventAttribute(String name) {
return sMouseEventAttributes.contains(name);
}
@@ -485,7 +525,7 @@
// This is the base class from which all classes derive unless otherwise
// specified. It has no attributes.
- makeNewStaticClass("Instance");
+ makeNewStaticClass("Object");
schemaDOM = (Document) sCachedSchemaDOM.clone();
Element docroot = schemaDOM.getRootElement();
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ViewSchema_Test.java
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ViewSchema_Test.java 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/compiler/ViewSchema_Test.java 2007-10-25 21:44:51 UTC (rev 7011)
@@ -80,8 +80,9 @@
public void testSetAttributes () {
ViewSchema schema = new ViewSchema();
+ CompilationEnvironment env = new CompilationEnvironment();
try {
- schema.loadSchema(new CompilationEnvironment());
+ schema.loadSchema(env);
} catch (JDOMException e) {
throw new RuntimeException(e.getMessage());
} catch (IOException e) {
@@ -94,11 +95,11 @@
Element elt1 = new Element("classdef1");
Element elt2 = new Element("classdef2");
- schema.addElement(elt1, "mynewclass", "view", new ArrayList());
- schema.addElement(elt2, "mynewsubclass", "mynewclass", new ArrayList());
+ schema.addElement(elt1, "mynewclass", "view", new ArrayList(), env);
+ schema.addElement(elt2, "mynewsubclass", "mynewclass", new ArrayList(), env);
assertEquals("undefined class superclass",
- null,
+ "Object",
schema.getBaseClassname("view"));
assertEquals(" superclass",
@@ -110,11 +111,11 @@
schema.getSuperclassName("mynewsubclass"));
assertEquals("mynewclass superclass",
- "view",
+ "Object",
schema.getBaseClassname("mynewclass"));
assertEquals("mynewsubclass superclass",
- "view",
+ "Object",
schema.getBaseClassname("mynewsubclass"));
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/sc/Compiler.java
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/sc/Compiler.java 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/sc/Compiler.java 2007-10-25 21:44:51 UTC (rev 7011)
@@ -285,10 +285,11 @@
if (options.getBoolean(DEBUG) ||
options.getBoolean(NAME_FUNCTIONS)) {
if (! options.containsKey(DEBUG_BACKTRACE)) {
- options.put(DEBUG_BACKTRACE, Boolean.valueOf("false"));
+ options.putBoolean(DEBUG_BACKTRACE, false);
}
- // TODO: [2007-02-21 ptw] Remove after Leopard
- options.put("debugSafari", LPS.getProperty("compiler.debug.safari", "false"));
+ if (! options.containsKey(DEBUG_SIMPLE)) {
+ options.putBoolean(DEBUG_SIMPLE, false);
+ }
}
if (! options.containsKey(PROFILE)) {
options.putBoolean(PROFILE, false);
@@ -394,6 +395,7 @@
public static String CONSTRAINT_FUNCTION = "constraintFunction";
public static String DEBUG = "debug";
public static String DEBUG_BACKTRACE = "debugBacktrace";
+ public static String DEBUG_SIMPLE = "debugSimple";
public static String DISABLE_CONSTANT_POOL = "disableConstantPool";
public static String ELIMINATE_DEAD_EXPRESSIONS = "eliminateDeadExpressions";
public static String FLASH_COMPILER_COMPATABILITY = "flashCompilerCompatability";
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/sc/JavascriptGenerator.java
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/sc/JavascriptGenerator.java 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/sc/JavascriptGenerator.java 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1012,22 +1012,23 @@
}
public SimpleNode visitAssignmentExpression(SimpleNode node, boolean isReferenced, SimpleNode[] children) {
- SimpleNode lhs = children[0];
+ JavascriptReference lhs = translateReference(children[0]);
int op = ((ASTOperator)children[1]).getOperator();
- SimpleNode rhs = children[2];
+ SimpleNode rhs = visitExpression(children[2]);
if (op != ParserConstants.ASSIGN &&
- translateReference(lhs).isChecked()) {
+ lhs.isChecked()) {
// The undefined reference checker needs to have this expanded
// to work
Map map = new HashMap();
- map.put("_1", lhs);
+ map.put("_1", lhs.get());
map.put("_2", rhs);
- String pattern = "(function () { var $lzsc$tmp = _1; return _1 = $lzsc$tmp " + AssignOpTable.get(op) + " _2; })()";
+ map.put("_3", lhs.set());
+ String pattern = "(function () { var $lzsc$tmp = _1; return _3 = $lzsc$tmp " + AssignOpTable.get(op) + " _2; })()";
SimpleNode n = (new Compiler.Parser()).substitute(pattern, map);
return visitExpression(n);
}
- children[2] = visitExpression(rhs);
- children[0] = translateReference(lhs).set();
+ children[2] = rhs;
+ children[0] = lhs.set();
return node;
}
@@ -1098,8 +1099,8 @@
userFunctionName = functionName;
if (! useName) {
if ((! identifierPattern.matcher(functionName).matches())
- // TODO: [2007-02-21 ptw] Remove after Leopard
- || options.getBoolean("debugSafari")) {
+ // Some JS engines die if you name function expressions
+ || options.getBoolean(Compiler.DEBUG_SIMPLE)) {
// This is a function-expression that has been annotated
// with a non-legal function name, so remove that and put it
// in _dbg_name (below)
Modified: openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/xml/internal/Schema.java
===================================================================
--- openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/xml/internal/Schema.java 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/WEB-INF/lps/server/src/org/openlaszlo/xml/internal/Schema.java 2007-10-25 21:44:51 UTC (rev 7011)
@@ -3,7 +3,7 @@
* ****************************************************************************/
/* J_LZ_COPYRIGHT_BEGIN *******************************************************
-* Copyright 2001-2004 Laszlo Systems, Inc. All Rights Reserved. *
+* Copyright 2001-2007 Laszlo Systems, Inc. All Rights Reserved. *
* Use is subject to license terms. *
* J_LZ_COPYRIGHT_END *********************************************************/
@@ -53,6 +53,11 @@
return newtype;
}
+
+ public static void addTypeAlias(String typeName, Type type) {
+ typeNames.put(typeName, type);
+ }
+
/** Look up the Type object from a Javascript type name */
public Type getTypeForName (String typeName) {
return (Type) typeNames.get(typeName);
Modified: openlaszlo/branches/paperpie/build.properties
===================================================================
--- openlaszlo/branches/paperpie/build.properties 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/build.properties 2007-10-25 21:44:51 UTC (rev 7011)
@@ -27,6 +27,7 @@
# LFC variants to build
build.lfc.runtime.debug = true
+build.lfc.runtime.debug.simple = true
# build.lfc.runtime.krank = true
build.lfc.runtime.profile = true
Modified: openlaszlo/branches/paperpie/demos/lzpix/app.lzx
===================================================================
--- openlaszlo/branches/paperpie/demos/lzpix/app.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/demos/lzpix/app.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -244,7 +244,13 @@
// create a method to be called when the last photo view is created
// find out how many images there are
if (! this.pagecounter_dp.p) return;
- var c = this.pagecounter_dp.p.childNodes.length;
+ var c = this.pagecounter_dp.p.childNodes.length;
+ var currentpage = this.pagecounter_dp.xpathQuery('@page');
+ var perpage = this.pagecounter_dp.xpathQuery('@perpage');
+ var totalpages = this.pagecounter_dp.xpathQuery('@pages');
+ photoscontainer.lyt.setAttribute('currentpage', currentpage);
+ photoscontainer.lyt.setAttribute('perpage', perpage);
+ photoscontainer.lyt.setAttribute('totalpages', totalpages);
tls.setpPagingParams( c );
gResultsCountLabel.setText( this.buildResultsString(c) );
this.watchforlast();
Modified: openlaszlo/branches/paperpie/demos/lzpix/classes/favorites.lzx
===================================================================
--- openlaszlo/branches/paperpie/demos/lzpix/classes/favorites.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/demos/lzpix/classes/favorites.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -169,8 +169,9 @@
<view name="interior" height="${parent.height}">
<favoriteslayout name="lyt" spacing="15" inset="0"
mymask="parent.parent"/>
- <photo datapath="favoritesds:/rsp/photos/photo">
+ <photo datapath="favoritesds:/rsp/photos/photo" visible="true">
<method event="onclick">
+ photoscontainer.lyt.setAttribute('currentpage', 1);
var id = datapath.p.getAttr("id");
var tag = datapath.p.getAttr("favoritetag");
classroot.loadSet( tag );
@@ -186,6 +187,6 @@
</library>
<!--
* X_LZ_COPYRIGHT_BEGIN ****************************************************
-* Copyright 2006 Laszlo Systems, Inc. All Rights Reserved. *
+* Copyright 2007 Laszlo Systems, Inc. All Rights Reserved. *
* Use is subject to license terms. *
* X_LZ_COPYRIGHT_END ******************************************************-->
Modified: openlaszlo/branches/paperpie/demos/lzpix/classes/photo.lzx
===================================================================
--- openlaszlo/branches/paperpie/demos/lzpix/classes/photo.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/demos/lzpix/classes/photo.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,7 +1,7 @@
-<!-- Copyright 2001-2006 Laszlo Systems, Inc. All Rights Reserved. -->
+<!-- Copyright 2001-2007 Laszlo Systems, Inc. All Rights Reserved. -->
<library>
- <class name="photo" width="77" height="77">
+ <class name="photo" width="77" height="77" visible="${!tls.waitforload}">
<attribute name="defaultplacement" value="interior" type="text" />
<attribute name="text" value="title" type="text" />
@@ -137,7 +137,9 @@
this.updateY( true );
this.setAttribute( "loaded", true );
intparent.interior.setAttribute("opacity", 0);
- this.intparent.setVisible(true);
+ if(tls.waitforload != true){
+ this.intparent.setVisible(true);
+ }
intparent.interior.animate('opacity', 1, 200);
</method>
@@ -180,9 +182,11 @@
<!-- title -->
<text text="" width="100" fgcolor="0x1b1191" fontsize="10"
- name="txt">
- <method event="ontext" >
- this.adjustDimensions()
+ name="txt" visible="false"><!-- Setting this initially to false
+ seems to fix a visual issue where these would cluster on the
+ upper left of the page in DHTML. -->
+ <method event="ontext">
+ this.adjustDimensions();
</method>
<method event="onvisible" >
this.adjustDimensions();
@@ -194,6 +198,9 @@
this.setX(tx);
this.setY(classroot.height + 3);
</method>
+ <method name="makeVisible">
+
+ </method>
</text>
<attribute name="doesdrag" value="false"/>
Modified: openlaszlo/branches/paperpie/demos/lzpix/classes/pivotlayout.lzx
===================================================================
--- openlaszlo/branches/paperpie/demos/lzpix/classes/pivotlayout.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/demos/lzpix/classes/pivotlayout.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,6 +1,6 @@
<!--
* X_LZ_COPYRIGHT_BEGIN ****************************************************
-* Copyright 2001-2006 Laszlo Systems, Inc. All Rights Reserved. *
+* Copyright 2001-2007 Laszlo Systems, Inc. All Rights Reserved. *
* Use is subject to license terms. *
* X_LZ_COPYRIGHT_END ******************************************************-->
<library>
@@ -69,7 +69,12 @@
<attribute name="pagebegin" value="-1" />
<attribute name="pageend" value="-1" />
<attribute name="pagesize" value="0" />
+ <attribute name="totalitems" value="0"/>
+ <attribute name="currentpage" value="1"/>
+ <attribute name="perpage" value="0"/>
+ <attribute name="totalpages" value="0"/>
+
<attribute name="duration" value="0"/>
<attribute name="calcpageparams" value="true"/>
@@ -139,6 +144,12 @@
var numinrow = Math.floor( limitwidth/( itemwidth + this.xspacing ) );
limitwidth = numinrow*( itemwidth + this.xspacing );
+ var limitheight = this.immediateparent.height;
+ var numincol = Math.floor(limitheight/(itemwidth + this.xspacing));
+
+ // Set the total number of items possible on the page.
+ this.setAttribute('totalitems', numinrow * numincol);
+
// now we can calculate the row of the view that is subviews[pivotindex]
var pivotrow = Math.floor( this.pivotindex/ numinrow );
Modified: openlaszlo/branches/paperpie/demos/lzpix/classes/search.lzx
===================================================================
--- openlaszlo/branches/paperpie/demos/lzpix/classes/search.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/demos/lzpix/classes/search.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,8 +1,8 @@
-<!-- Copyright 2001-2006 Laszlo Systems, Inc. All Rights Reserved. -->
<library>
<class name="search" >
<attribute name="sendsearch_del"
value="$once{new LzDelegate( this, 'sendsearch') }"/>
+ <attribute name="lastsearchterm" value="${null}"/>
<method name="doSearch">
if ( !canvas.isopen ) {
@@ -27,6 +27,8 @@
resource="transparent_rsc"
width="${parent.width}" height="${parent.height}" >
<method event="onclick">
+ photoscontainer.lyt.setAttribute('currentpage', 1);
+ tls.resetOnLoad();
classroot.doSearch();
</method>
</mybutton>
@@ -44,6 +46,8 @@
<inputtext name="txt" width="${parent.width}" height="${parent.height}" y="3">
<method event="onkeyup" args="k" >
if ( k == 13 ) { //return key
+ photoscontainer.lyt.setAttribute('currentpage', 1);
+ tls.resetOnLoad();
classroot.doSearch();
}
</method>
@@ -53,7 +57,7 @@
<!-- Only search for photos with a creative commons license:
http://creativecommons.org/licenses/by/2.0/
-->
- <method name="sendsearch" >
+ <method name="sendsearch">
var tags = this.getText();
var argobj;
if (tags == "interesting") {
@@ -77,8 +81,14 @@
{argname:"tag_mode", argvalue:"all"},
{argname:"sort", argvalue:"interestingness-desc"}
]
- }
- gDataMan.doFlickrRequest(photods, argobj);
+ }
+ if(this.getText() != this.lastsearchterm){
+ photoscontainer.lyt.setAttribute('currentpage', 1);
+ tls.resetOnLoad();
+ }
+ argobj.push({argname:"page", argvalue:Number(photoscontainer.lyt.currentpage)});
+ this.setAttribute('lastsearchterm', this.getText());
+ gDataMan.doFlickrRequest(photods, argobj);
//info('sendsearch', tags);
tls.displayPage();
</method>
@@ -101,6 +111,6 @@
</library>
<!--
* X_LZ_COPYRIGHT_BEGIN ****************************************************
-* Copyright 2006 Laszlo Systems, Inc. All Rights Reserved. *
+* Copyright 2007 Laszlo Systems, Inc. All Rights Reserved. *
* Use is subject to license terms. *
* X_LZ_COPYRIGHT_END ******************************************************-->
Modified: openlaszlo/branches/paperpie/demos/lzpix/views/tools.lzx
===================================================================
--- openlaszlo/branches/paperpie/demos/lzpix/views/tools.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/demos/lzpix/views/tools.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,6 +1,6 @@
<!--
* X_LZ_COPYRIGHT_BEGIN ****************************************************
-* Copyright 2001-2006 Laszlo Systems, Inc. All Rights Reserved. *
+* Copyright 2001-2007 Laszlo Systems, Inc. All Rights Reserved. *
* Use is subject to license terms. *
* X_LZ_COPYRIGHT_END ******************************************************-->
<view id="tls" name="tools"
@@ -19,6 +19,8 @@
<attribute name="nextstartindex" value="1"/>
<attribute name="endindex" value="18"/>
<attribute name="nextendindex" value="18"/>
+
+ <attribute name="waitforload" type="boolean" value="false"/>
<method name="reset">
@@ -26,6 +28,15 @@
this.endindex = this.startindex + photoscontainer.lyt.pagesize -1;
this.displayRange(this.startindex,this.endindex);
</method>
+
+ <method name="resetOnLoad">
+ this.loadtext.setText('Loading...');
+ this.setAttribute('waitforload', true);
+ this.setAttribute('startindex', 1);
+ this.setAttribute('nextstartindex', 1);
+ this.setAttribute('endindex', 1 + photoscontainer.lyt.totalitems);
+ this.setAttribute('nextendindex', 1 + photoscontainer.lyt.totalitems);
+ </method>
<method name="enableZoom">
thmb.setVisible(true);
@@ -68,9 +79,14 @@
showhandcursor="false" onclick="" bgcolor="0x7F7F7F"
x="0" y="13" width="130" height="30" />
- <text name="firstphotoindex" fgcolor="0x463e9D" y="7" x="152" fontsize="9"/>
- <text text="-" fgcolor="0x463e9D" y="4" x="165" />
- <text name="lastphotoindex" fgcolor="0x463e9D" y="7" x="172" fontsize="9" />
+ <text name="firstphotoindex" fgcolor="0x463e9D" y="7" x="${152 - (this.width / 2)}" fontsize="9"
+ visible="${!parent.waitforload}"/>
+ <text text="-" fgcolor="0x463e9D" y="4" x="162" visible="${!parent.waitforload}"/>
+ <text name="lastphotoindex" fgcolor="0x463e9D" y="7" x="172" fontsize="9"
+ visible="${!parent.waitforload}"/>
+
+ <text name="loadtext" fgcolor="0x463e9D" x="${170 - (this.width / 2)}" y="7" fontsize="9"
+ visible="${parent.waitforload}"/>
<!-- Button for previous page -->
<mybutton name="pageprev"
@@ -91,11 +107,30 @@
<method name="displayNextPage" >
+ <![CDATA[
//get paging parameters at this point ( before layout is animated offscreen )
this.nextstartindex = this.endindex + 1;
this.nextendindex = Math.min( this.nextstartindex + photoscontainer.lyt.pagesize - 1, this.numberofphotos );
- photoscontainer.lyt.calcpageparams = false;
- photoscontainer.lyt.pageNext.doStart();
+ if(this.nextstartindex <= this.numberofphotos){
+ if(nextendindex == this.numberofphotos){
+ this.nextendindex = this.numberofphotos;
+ this.nextstartindex = this.nextendindex - photoscontainer.lyt.totalitems + 1;
+ }
+ photoscontainer.lyt.calcpageparams = false;
+ photoscontainer.lyt.pageNext.doStart();
+ } else if(photoscontainer.lyt.currentpage < photoscontainer.lyt.totalpages){
+ /* Request the next set of data, if we've reached the limit.
+ Unfortunately, we have to go by sets of 100, because Flickr's
+ API breaks data up into single-request XML pages of 100 items
+ apiece. */
+ this.loadtext.setText('Next 100...');
+ this.setAttribute('waitforload', true);
+ this.nextstartindex = 1;
+ this.nextendindex = Math.min(this.nextstartindex + photoscontainer.lyt.pagesize - 1, this.numberofphotos );
+ photoscontainer.lyt.setAttribute('currentpage', Number(photoscontainer.lyt.currentpage) + 1);
+ gSearch.doSearch();
+ }
+ ]]>
</method>
<method event="onstop" reference="photoscontainer.lyt.pageNext" >
@@ -111,13 +146,26 @@
</method>
<method name="displayPrevPage" >
+ <![CDATA[
if ( this.startindex > 1 ) {
this.nextendindex = this.startindex - 1;
- this.nextstartindex = Math.max( this.nextendindex - photoscontainer.lyt.pagesize + 1, 1 );
- if ( this.nextstartindex == 1 ) this.nextendindex = photoscontainer.lyt.pagesize;
+ this.nextstartindex = Math.max( this.nextendindex - photoscontainer.lyt.totalitems + 1, 1 );
+ if ( this.nextstartindex == 1 ) this.nextendindex = photoscontainer.lyt.totalitems;
photoscontainer.lyt.calcpageparams = false;
photoscontainer.lyt.pagePrev.doStart();
+ } else if(photoscontainer.lyt.currentpage > 1){
+ /* Request the previous set of data, if we've reached the limit.
+ Unfortunately, we have to go by sets of 100, because Flickr's
+ API breaks data up into single-request XML pages of 100 items
+ apiece. */
+ this.loadtext.setText('Prev 100...');
+ this.setAttribute('waitforload', true);
+ this.nextendindex = this.numberofphotos;
+ this.nextstartindex = this.nextendindex - photoscontainer.lyt.totalitems + 1;
+ photoscontainer.lyt.setAttribute('currentpage', Number(photoscontainer.lyt.currentpage) - 1);
+ gSearch.doSearch();
}
+ ]]>
</method>
<method event="onstop" reference="photoscontainer.lyt.pagePrev" >
@@ -150,8 +198,8 @@
</method>
<method name="displayRange" args="s,e" >
- this.firstphotoindex.setText( s);
- this.lastphotoindex.setText( e );
+ this.firstphotoindex.setText( s + (photoscontainer.lyt.perpage * (photoscontainer.lyt.currentpage - 1)));
+ this.lastphotoindex.setText( e + (photoscontainer.lyt.perpage * (photoscontainer.lyt.currentpage - 1)));
</method>
<method name="setpPagingParams" args="n" >
@@ -162,6 +210,7 @@
</method>
<method event="ondata" reference="photods" >
+ this.setAttribute('waitforload', false);
photoscontainer.lyt.calcparams = true;
</method>
Deleted: openlaszlo/branches/paperpie/docs/changelog.html
Modified: openlaszlo/branches/paperpie/docs/src/deployers/deploy-preface.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/deployers/deploy-preface.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/deployers/deploy-preface.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,8 +1,7 @@
<section>
-
+<!-- change title per LPP-4804, IORIO 16 oct 2007 -->
<para>OpenLaszlo applications are written in the LZX language and compiled to .swf files that execute in the Flash Player. This
-Guide explains how to make those applications available to users on the Web. The <ulink url="../guide">Software Developer's
-Guide to Laszlo Applications</ulink> explains how to construct and test applications before you deploy them for general use.</para>
+Guide explains how to make those applications available to users on the Web. The <ulink url="../developers/">OpenLaszlo Application Developer's Guide</ulink> explains how to construct and test applications before you deploy them for general use.</para>
<para/><section><title>Audience and rationale for this book</title>
@@ -51,9 +50,11 @@
-
-<para>In addition to this <emphasis role="em">Administrator's Guide</emphasis>, please see also</para>
-<itemizedlist spacing="compact"><listitem><para>The <ulink url="../guide"><emphasis role="em">Software Developer's Guide to Laszlo Applications</emphasis></ulink>, the comprehensive
+<!-- change title per LPP-2637, IORIO 19 oct 2007 -->
+<para>In addition to this <emphasis role="em">OpenLaszlo System Administrator's Guide</emphasis>, please see also</para>
+<itemizedlist spacing="compact"><listitem>
+<!-- change title per LPP-4804, IORIO 16 oct 2007 -->
+<para>The <ulink url="../developers"><emphasis role="em">OpenLaszlo Application Developer's Guide</emphasis></ulink>, the comprehensive
explanation of how to write and test OpenLaszlo programs.</para></listitem><listitem><para>The <ulink url="../design"><emphasis role="em">User Interface Designer's Guide to Laszlo Applications</emphasis></ulink>,
which addresses aspects
of the Laszlo platform that are of special interest to UI and graphic designers</para></listitem><listitem><para>The <ulink url="../reference/../reference/" type="laszlo-reference"><emphasis role="em">LZX Reference
@@ -64,11 +65,11 @@
provide a hands-on instructional overview of the LZX language.</para></listitem></itemizedlist>
<para/><section><title>Use the Forums</title>
-
+<!-- change link to forums per LPP-2637, IORIO 19 oct 2007 -->
<para>The best way to learn any programming language is to draw upon the
experience and goodwill of its development community (and to write
code! as the saying goes, nobody learned to ride a bicycle by reading
-about it). The LZX developer community has a home at <ulink url="http://www.laszlosystems.com/developers/forums/">http://www.laszlosystems.com/developers/forums/</ulink>. There
+about it). The LZX developer community has a home at <ulink url="http://www.laszlosystems.com/developers/community/forums/">http://www.laszlosystems.com/developers/community/forums/</ulink>. There
you will find an active discussion of all aspects of the language, and
a place to ask questions of your own.</para>
Modified: openlaszlo/branches/paperpie/docs/src/deployers/deployers-index.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/deployers/deployers-index.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/deployers/deployers-index.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -8,7 +8,8 @@
<book xmlns:xi="http://www.w3.org/2003/XInclude">
<?dbhtml dir="deployers" ?>
<?dbhtml filename="index.html" ?>
- <title>System Administrator's Guide to Deploying OpenLaszlo Applications</title>
+ <!-- change title per LPP-4804, IORIO 14 oct 2007 -->
+ <title>OpenLaszlo System Administrator's Guide</title>
<titleabbrev>Deployer Guide</titleabbrev>
<preface id="deployers.preface">
Modified: openlaszlo/branches/paperpie/docs/src/developers/classes-introductory.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/classes-introductory.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/classes-introductory.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -17,10 +17,9 @@
Classes are at the heart of LZX programming. Depending on your background, you may consult any of several
discussions in the OpenLaszlo documentation to learn how to use classes effectively in your applications.
</para>
-
+<!-- change link for classes-tutorial per LPP-4923, IORIO 17 oct 2007 -->
<para>To get a feel for how to use classes in OpenLaszlo applications, you
-may want to start with the <ulink url="../guide/classes-tutorial.html" type="laszlo-dguide">Class
-tutorial</ulink>. That's the best place to start learning, especially if
+may want to start with the tutorial: <xref linkend="classes-tutorial" /> . That's the best place to start learning, especially if
you've never done any <glossterm>object oriented</glossterm> ("OO")
programming.</para>
Modified: openlaszlo/branches/paperpie/docs/src/developers/data-structures.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/data-structures.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/data-structures.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -2,7 +2,7 @@
<title>Data, XML, and XPath</title>
-
+<!-- change link for language-preliminaries per LPP-4923, IORIO 17 oct 2007 -->
<para>
The term <indexterm significance="preferred"><primary>data</primary></indexterm><glossterm>data</glossterm> refers to numbers, characters, or text
in a form that can be displayed or manipulated by
@@ -19,7 +19,7 @@
<itemizedlist spacing="compact"><listitem><para>embedding data directly into an application</para></listitem><listitem><para>receiving data from or sending data to a remote data source at runtime</para></listitem><listitem><para>receiving data from or sending data to a web service</para></listitem><listitem><para>creating and manipulating data at runtime </para></listitem><listitem><para><emphasis role="i">binding</emphasis> data to the user-interface declaratively as well as with script</para></listitem></itemizedlist>
<para>
-For a gentle introduction to databinding and manipulation in OpenLaszlo applications, you may start with the <ulink url="../guide/data-tutorial.html" type="laszlo-dguide">tutorials</ulink>
+For a gentle introduction to databinding and manipulation in OpenLaszlo applications, you may start with the tutorial: <xref linkend="data-tutorial" />.
</para>
<para/></section><section><title>What is XML?</title>
@@ -144,7 +144,11 @@
contentType="text/xml; charset=UTF-8" %><?xml version='1.0' encoding='UTF-8'
standalone='yes' ?><%@ page import="java.util.*,org.jdom.output.*"%>
</programlisting>
-<para/></section></section><section><title>XPath</title>
+<para/></section></section>
+<section id="xpath">
+<title>XPath</title>
+<!-- add titleabbrev to use as target text per LPP-4923, IORIO 17 oct 2007 -->
+<titleabbrev id="xpathshort">XPath</titleabbrev>
<para>
LZX data access and binding makes heavy use of the W3C <ulink url="http://www.w3.org/TR/xpath">XPath</ulink> standard
Modified: openlaszlo/branches/paperpie/docs/src/developers/databinding.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/databinding.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/databinding.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,10 +1,11 @@
<chapter id="databinding">
<title>Data Access and Binding</title>
+<!-- change link for data-tutorial per LPP-4923, IORIO 17 oct 2007 -->
<para>This chapter describes various methods of tying XML data structures into your LZX application. See
<xref linkend="data-structures"/> for discussion of some of the concepts used in this chapter.
For a gentle introduction to databinding and manipulation in OpenLaszlo applications, you may start
- with the <ulink url="../guide/data-tutorial.html" type="laszlo-dguide">tutorials</ulink>.
+ with the tutorial: <xref linkend="data-tutorial" />
</para>
<para/><section><title>Preview of databinding</title>
<para>By "databinding" we mean the automatic association of a value in an XML data structure with an element in the LZX view hierarchy of the application. This chapter explores various aspects of databinding and manipulation in OpenLaszlo applications. Before going into specific details, we'll start with a conceptual overview of how data is represented in LZX applications, and the APIs for manipulating it.</para>
Modified: openlaszlo/branches/paperpie/docs/src/developers/debugging.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/debugging.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/debugging.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,12 +1,10 @@
<chapter id="debugging">
-
-
<title>Debugging</title>
<para>
Openlaszlo provides a powerful debugger which you can use either embedded in the application or as a separate ("remote") process. In addition, when you are compiling applications for deployment to DHTML, you may benefit from using tools for debugging in that environment.
</para>
-<para/><section><title>Using the OpenLaszlo Debugger</title>
+<section><title>Using the OpenLaszlo Debugger</title>
<para>When you run an application with debugging enabled, the application
is compiled with instrumentation to detect runtime errors, and the
@@ -28,11 +26,6 @@
<textobject><textdata fileref="debugging-$1.lzx"/></textobject>
</programlisting>
</example>
-<?example role="live-example"><title>The Debugger window</title><programlisting role="lzx-embednew"><filename>debugging-$1.lzx</filename><parameter/><code>
-<canvas height="150" debug="true"/>
-</code></programlisting><programlisting>
-<canvas height="150" debug="true"/>
-</programlisting><?lzx-edit programs/debugging-$1.lzx></example?>
<para>Debugging may cause the application to run more slowly, even if
the debugger window is not visible.</para>
@@ -44,19 +37,13 @@
<variablelist><varlistentry><term>The <indexterm><primary>debug</primary></indexterm><sgmltag class="attribute">debug</sgmltag> attribute</term><listitem><para>The debugger is enabled on if the canvas <indexterm><primary>debug</primary></indexterm><sgmltag class="attribute">debug</sgmltag> attribute is set to true:</para>
-
-
<example role="live-example">
<title>The canvas debug attribute</title>
<programlisting language="lzx">
<textobject><textdata fileref="programs/debugging-$2.lzx"/></textobject>
</programlisting>
</example>
-<?example role="live-example"><title>The <canvas> debug attribute</title><programlisting role="lzx-embednew"><filename>debugging-$2.lzx</filename><parameter/><code>
-<canvas height="150" debug="true"/>
-</code></programlisting><programlisting>
-<canvas height="150" debug="true"/>
-</programlisting><?lzx-edit programs/debugging-$2.lzx></example?>
+
</listitem></varlistentry><varlistentry><term>The "Debug" button</term><listitem><para>Press the "Debug" button on the <glossterm>developer console</glossterm> to request a copy of the application with debugging enabled. This is equivalent to recompiling the application with the <literal>debug="true"</literal>.</para>
<!-- remove para tags; para is not a legal child of term LI LPP-4636 9/3/2007 -->
<!-- <term><para>The <literal>debug</literal> query parameter</para></term> -->
@@ -65,13 +52,15 @@
This is equivalent to pressing the "Debug" button in the developer
console.</para>
-
-<para>See the<ulink url="../deploy/request-types.html" type="">System Administrator's Guide</ulink> for more information
+<!-- change title per LPP-4804, IORIO 15 oct 2007 -->
+<para>See the <ulink url="../deployers/request-types.html" type="">OpenLaszlo System Administrator's Guide</ulink> for more information
about request types.</para></listitem></varlistentry></variablelist>
-<para/></section><section id="debugging.runtime-error-checking"><title>Runtime Error Checking</title>
+<para/></section>
-<para>Enabling the debugger <?ignore Using any of the first three methods in <xref linkend="debugging.enabling-the-debugger"/>?> has two effects:</para>
+<section id="debugging.runtime-error-checking"><title>Runtime Error Checking</title>
+
+<para>Enabling the debugger using one of the methods described in <xref linkend="debugging.enabling-the-debugger"/> has two effects:</para>
<itemizedlist spacing="compact"><listitem><para>It includes the debugger visual component. This displays debug messages, and has a command line interface for evaluating JavaScript statements.</para></listitem><listitem><para>It compiles the application with additional instrumentation to perform <indexterm significance="preferred"><primary>runtime error checking</primary></indexterm><glossterm>runtime error checking</glossterm>. Certain classes of erroneous code (below) result in warnings that are logged to the debug window.</para></listitem></itemizedlist>
<para>A program that is compiled with runtime error checking will contain code that checks for the following conditions:</para>
@@ -88,23 +77,6 @@
<textobject><textdata fileref="programs/debugging-$3.lzx"/></textobject>
</programlisting>
</example>
-<?informalexample role="live-example"><programlisting role="lzx-embednew"><filename>debugging-$3.lzx</filename><parameter/><code>
-<canvas debug="true" height="150">
- <handler name="oninit"><![CDATA[
- for (var i = 0; i > 10; i ++) {
- canvas.width();
- }
- ]]></handler>
-</canvas>
-</code></programlisting><programlisting>
-<canvas debug="true" height="150">
- <handler name="oninit"><![CDATA[
- for (var i = 0; i > 10; i ++) {
- canvas.width();
- }
- ]]></handler>
-</canvas>
-</programlisting><?lzx-edit programs/debugging-$3.lzx></informalexample?>
<para>Turning on runtime error checking makes an application bigger
and slower. You should only perform size and speed optimization on
@@ -127,28 +99,38 @@
<textobject><textdata fileref="programs/debugging-$4.lzx"/></textobject>
</programlisting>
</example>
-<?example role="live-example"><title>Logging to the debugger</title><programlisting role="lzx-embednew"><filename>debugging-$4.lzx</filename><parameter/><code>
-<canvas debug="true" height="150">
- <script>
- Debug.write('user code');
- </script>
- <button onclick="Debug.write('click', getMouse('x'))"/>
-</canvas>
-</code></programlisting><programlisting>
-<canvas debug="true" height="150">
- <script>
- Debug.write('user code');
- </script>
- <button onclick="Debug.write('click', getMouse('x'))"/>
-</canvas>
-</programlisting><?lzx-edit programs/debugging-$4.lzx></example?>
<para>Some object are <glossterm baseform="inspect">inspectable</glossterm>. See <xref linkend="debugging.inspecting"/> for more about the inspect feature of
the debugger. See <xref linkend="debugging.debug-tostring"/> to see
how to customize the display of objects within the debugger.</para>
+</section>
+<!-- added next section on getting version info to fix LPP-4822 and LPP-2658. IORIO 23 oct 2007 -->
+<!-- added two new examples, canvasversion.lzx and debuginfo.lzx. IORIO 23 oct 2007 -->
+<section>
+<title>Getting version information</title>
+<para>There simplest way to get LPS version information is to use <varname>canvas.lpsversion</varname>. </para>
+<example role="live-example">
+ <title>Using canvas.lpsversion</title>
+ <programlisting language="lzx">
+ <textobject><textdata fileref="programs/canvasversion.lzx"/></textobject>
+ </programlisting>
+</example>
+<?example role="live-example"><title>Using canvas.lpsversion</title><programlisting role="lzx-embednew"><filename>canvasversion.lzx</filename><parameter/><code>
+</programlisting><?lzx-edit programs/canvasversion.lzx></example?>
+<para>You can get more information, for example the build number and target runtime, by using <literal>Debug.versionInfo()</literal>.</para>
+<example role="live-example">
+ <title>Using Debug.versionInfo()</title>
+ <programlisting language="lzx">
+ <textobject><textdata fileref="programs/debuginfo.lzx"/></textobject>
+ </programlisting>
+</example>
+<?example role="live-example"><title>Using Debug.versionInfo()</title><programlisting role="lzx-embednew"><filename>debuginfo.lzx</filename><parameter/><code>
+</programlisting><?lzx-edit programs/debuginfo.lzx></example?>
+<para>While the previous two methods give you version information, if you want to generat a full bug report, see <xref linkend="generate-bug-report" />.</para>
+</section>
+<!-- end of added section to fix LPP-4822 and LPP-2658. IORIO 23 oct 2007 -->
+<section><title>Using the Evaluator</title>
-<para/></section><section><title>Using the Evaluator</title>
-
<para>The bottom portion of the debugger window is the
<indexterm significance="preferred"><primary>evaluator</primary></indexterm><glossterm>evaluator</glossterm>. This is a command-line interface for evaluating
JavaScript expressions and statements within the application. Enter a
@@ -228,7 +210,7 @@
<variablelist><varlistentry><term><literal>_</literal></term><listitem><para>The result of the previous expression with a non-undefined value.</para></listitem></varlistentry><varlistentry><term><literal>__</literal> [two underscore characters])</term><listitem><para>The result of the expression prior to the previous expression.</para></listitem></varlistentry><varlistentry><term><literal>___</literal> [three underscore characters]</term><listitem><para>The result of the expression prior to the <literal>__</literal> expression.</para></listitem></varlistentry></variablelist>
<para/></section></section><section id="debugging.inspecting"><title>Inspecting Objects</title>
-
+<!-- clarified explanation of abbreviated inspectable representation per LPP-4211, IORIO 18 oct 2007 -->
<para>Evaluating <literal>Debug.write(<varname>object</varname>)</literal>, where
<literal><varname>object</varname></literal> is an expression that evaluates to a
JavaScript object, displays an <indexterm significance="preferred"><primary>inspectable representation</primary></indexterm><glossterm>inspectable representation</glossterm>
@@ -264,24 +246,10 @@
<textobject><textdata fileref="programs/debugging-$5.lzx"/></textobject>
</programlisting>
</example>
-<?example role="live-example"><title>Two ways of calling Debug.write</title><programlisting role="lzx-embednew"><filename>debugging-$5.lzx</filename><parameter/><code>
-<canvas debug="true" height="150">
- <handler name="oninit">
- Debug.write('subviews: ' + canvas.subviews);
- Debug.write('subviews:', canvas.subviews);
- </handler>
-</canvas>
-</code></programlisting><programlisting>
-<canvas debug="true" height="150">
- <handler name="oninit">
- Debug.write('subviews: ' + canvas.subviews); <co id="N10239"/>
- Debug.write('subviews:', canvas.subviews); <co id="N10243"/>
- </handler>
-</canvas>
-</programlisting><?lzx-edit programs/debugging-$5.lzx></example?>
+
<calloutlist><callout arearefs="N10239"><para>The (only) argument to <indexterm><primary><literal>Debug.write()</literal> method</primary></indexterm><methodname>Debug.write()</methodname> is a string, so the value of <literal>canvas.subviews</literal> is not inspectable.</para></callout><callout arearefs="N10243"><para>The second argument to <indexterm><primary><literal>Debug.write()</literal> method</primary></indexterm><methodname>Debug.write()</methodname> is an non-string Object, so it is inspectable.</para></callout></calloutlist>
<para/></section>
-<section>
+<section id="generate-bug-report">
<title>Generating a bug report</title>
<para>If you encounter a bug that prints a message in the debugger and you believe it is an OpenLaszlo bug, take the following steps to generate a bug report:</para>
<orderedlist spacing="compact">
@@ -308,7 +276,9 @@
<para>
The compiler will omit those statements when you compile without debugging.
</para>
-<para/></section></section><section id="configuring-debugger"><title>Configuring the Debugger</title>
+<para/></section>
+
+<section id="configuring-debugger"><title>Configuring the Debugger</title>
<para/><section><title>Debugger Window Position</title>
<para>By default, the debugger comes up over the top left corner of your
@@ -343,8 +313,10 @@
<para>In addition to
Debug.write, Debug.warn, Debug.info, Debug.format, there are utilities for determining client environment (Debug.versionInfo() and others)
</para>
- <itemizedlist spacing="compact"><listitem><para>
- Canvas.versionInfoString(), Debug.versionInfo() which can be very helpful to record for bug reports.
+ <itemizedlist spacing="compact">
+ <!-- fix typo: canvas.versionInfoString to lz.canvas.versionInfoString() IORIO 23 oct 2007-->
+ <listitem><para>
+ lz.canvas.versionInfoString(), Debug.versionInfo() which can be very helpful to record for bug reports.
</para></listitem><listitem><para>
Debug.debug, Debug.info—like Debug.warn and Debug.error, but with different colors and tags that match many popular Ajax runtimes.
</para></listitem><listitem><para>
@@ -367,8 +339,8 @@
method.</para>
<para role="todo"><remark role="todo"><emphasis role="para-label">TODO: </emphasis>Examples</remark></para>
-
-<para>See the <ulink url="../deploy/logging.html" type="">System Administrator's Guide to Delpoying OpenLaszlo Applications</ulink> for information about configuration
+<!-- change title per LPP-4804, IORIO 15 oct 2007 -->
+<para>See the <ulink url="../deployers/logging.html" type="">OpenLaszlo System Administrator's Guide</ulink> for information about configuration
and reading the server log.</para>
<para/></section><section><title>Formatting Output</title>
<para>
@@ -402,7 +374,7 @@
<para/></section></section><section><title>Inspecting Warnings and Errors</title>
<para>Warnings and Errors are 'inspectable'. If you click on them, you will inspect the warning or error object. If backtracing is enabled, a backtrace will be one of the properties of the object that you can inspect. Inspecting the backtrace will reveal the recorded stack frames which record: the function called, <literal>this</literal> and the arguments to the function.</para>
-<para/></section></section><section><title>Monitoring object properties</title>
+<para/></section></section><section><title>Monitoring and tracing object properties</title>
<para><literal>Debug.monitor(who, what)</literal>: Takes an object and property name
and will emit a 'monitor message' each time that property is
changed.
@@ -411,8 +383,15 @@
<literal>Debug.unmonitor(who, what)</literal>: Turns that off.
</para>
<para>
-A monitor message consists of a timestamp, the function that caused the change, the object and property, and the old and new
-values. E.g.:</para>
+A monitor message consists of the function that caused the change, a timestamp, the object and property, and the old and new
+values. The following example uses <literal>Debug.monitor()</literal> and <literal>Debug.trace()</literal>:</para>
+<example role="live-example">
+ <title>Using Debug.monitor() and Debug.trace()</title>
+ <programlisting language="lzx">
+ <textobject><textdata fileref="programs/debug-mon-trace.lzx"/></textobject>
+ </programlisting>
+</example>
+<!-- replaced with live example. IORIO 24 oct 2007
<programlisting><literal>
MONITOR: [69227.23] LzLoader.initializeRequestObj: «LoadMovie#0| __debugger.lzx (loaded)».valid: true -> true
MONITOR: [69265.36] LzLoader.initializeRequestObj: «LoadMovie#0| __debugger.lzx (loaded)».loaded: true -> false
@@ -421,8 +400,27 @@
MONITOR: [69436.51] LzLoadQueue.makeRequest: «LoadMovie#0| __debugger.lzx (initialized)».loading: false -> true
MONITOR: [69702.58] LzLoader.returnData: «LoadMovie#0| __debugger.lzx (loading)».loaded: false -> true
</literal>
-</programlisting>
-<para/></section><section><title>Tracing and Backtracing</title>
+</programlisting> -->
+<para/>
+<para>As shown in this example:</para>
+<itemizedlist><listitem><para>
+<literal>Debug.monitor()</literal> monitors attribute modification. It gives a timestamp on attribute modification,
+shows the function doing the modification and the old and new value.
+</para></listitem>
+<listitem><para>
+<literal>Debug.trace()</literal> traces method calls. It gives a timestamp on function call, shows the call and arguments,
+and a timestamp on function exit, shows the return value.
+</para></listitem>
+
+</itemizedlist>
+<para>If backtracing is enabled, the trace and monitor messages also capture a backtrace
+(which you can see by inspecting the message). Can be especially handy if
+you are trying to figure out who/what/when is calling a method or clobbering a property.
+</para>
+
+</section>
+<!-- added id to section so we can link to here. IORIO 24 oct 2007 -->
+<section id="trace-backtrace"><title>Tracing and Backtracing</title>
<para>The debugger provides methods that allow you to see interactions between parts of your application.</para>
<para/><section><title>Tracing</title>
<para>
@@ -432,8 +430,9 @@
<para>
The configuration parameter <literal>compiler.debug.backtrace</literal>, when true, causes the compiler to instrument functions to maintain a call stack. You must recompile both the OpenLaszlo Runtime Library and your program if you change the setting of this parameter. It defaults to false because there is significant overhead introduced in enabling backtracing; in general it is only useful on small test cases.
</para>
+<!-- change title per LPP-4804, IORIO 15 oct 2007 -->
<para>
-The configuration parameter is set in the configuration file<literal> lps.config </literal>, as explained in the <ulink url="../deploy/deployers-guide.html#deployers-guide.lps.properties" type="">System Administrator's Guide</ulink>.</para>
+The configuration parameter is set in the configuration file<literal> lps.config </literal>, as explained in the <ulink url="../deployers/deployers-guide.html#deployers-guide.lps.properties" type="">OpenLaszlo System Administrator's Guide</ulink>.</para>
<para>
To create your own backtrace at any time:
@@ -488,7 +487,7 @@
objects as intelligently as our debugger, and </para></listitem><listitem><para>Firebug does not understand
OpenLaszlo #file and #line declarations, so it cannot give as accurate error locations as our debugger does. </para></listitem></itemizedlist>
-<!-- added not about script running slowly error to fix JIRA-LPP-4846, IORIO 7 oct 2007 -->
+<!-- added note about script running slowly error to fix JIRA-LPP-4846, IORIO 7 oct 2007 -->
<note><para>If you have Firebug enabled in Firefox, the LZX debugger echos
all messages to the Firebug console, preserving objects. The Firebug
debugger will attempt to interpret an object with a `length` field as
@@ -507,7 +506,7 @@
<para>
In JavaScript you are allowed to ask for a non-existent slot, but not for a slot on something that is not an object. Therefore, don't say <literal>foo.bar</literal> unless you know that foo is an object. If you know foo is either an object or null, you can say <literal>if (foo)</literal> before you say <literal>foo.bar</literal>. If you don't even know that, you would need to say <literal>if (foo instanceof Object)</literal>.
</para>
- <!-- added "has no properties" error to fix JIRA-LPP-4861, IORIO 12 oct 2007 -->
+ <!-- added "has no properties" error to fix JIRA-LPP-4861, IORIO 18 oct 2007 -->
<para condition="dhtml">
Furthermore, in DHTML you cannot reference a non-existent variable. Therefore you should declare all your
variables. In SWF, you could get by without declaring them, and they would just appear to be `undefined`, in
Modified: openlaszlo/branches/paperpie/docs/src/developers/deployers-index.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/deployers-index.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/deployers-index.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -6,7 +6,8 @@
<!--DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"-->
<book xmlns:xi="http://www.w3.org/2003/XInclude">
- <title>System Administrator's Guide to Deploying OpenLaszlo Applications</title>
+ <!-- change title per LPP-4804, IORIO 15 oct 2007 -->
+ <title>OpenLaszlo System Administrator's Guidee</title>
<titleabbrev>Administrator's Guide</titleabbrev>
<part id="preface">
<xi:include href="deploy-preface.dbk"/>
Modified: openlaszlo/branches/paperpie/docs/src/developers/designers.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/designers.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/designers.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -10,12 +10,13 @@
We'll discuss OpenLaszlo's ability to support designers and engineers in building innovative Internet applications.
</para>
<para/><section><title>Leaning to Think Laszlorificly</title>
+<!-- change link for tutorials per LPP-4923, IORIO 18 oct 2007 -->
<para>
With OpenLaszlo technology, web application designers are freed from the familiar limitations of static, linear, page-based task flow.
Your visions of dynamic, data-driven, concise and intelligent UI can become a reality. But you may need to change your thinking
a little bit, because things are possible with OpenLaszlo that aren't possible with most other technologies. And while it is not necessary for you to learn to write code in order to be an effective designer on an OpenLaszlo project,
a familiarity with the basic structure and features of the LZX language will help you understand how to approach your task.
-So we recommend that you at least work through a few of the <ulink url="../guide/" type="laszlo-dguide">tutorials</ulink>.
+So we recommend that you at least work through a few of the <ulink url="../developers/" type="laszlo-dguide">tutorials</ulink>.
</para>
<para>
@@ -131,9 +132,9 @@
change size. Verity contains an unaccented subset of characters; for the full Windows Western Unicode font set, use VerityPlus,
which includes accented European characters. The Bitstream font Vera was released as an open source font for the Gnome Project.
The Ultra Pixel font Verity was built by Christopher Lowery using technology produced by Truth in Design.</para>
-<para>
<!-- fix broken link per LPP-4896, IORIO 15 oct 2007 -->
<!-- change title per LPP-4804, IORIO 15 oct 2007 -->
+<para>
For more on fonts, see <ulink url="../developers/fonts.html" type="laszlo-dguide">OpenLaszlo Application Developer's Guide</ulink>.</para>
<para/></section><section><title>OpenLaszlo Components Design Guide</title>
Modified: openlaszlo/branches/paperpie/docs/src/developers/developers_guide_preface.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/developers_guide_preface.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/developers_guide_preface.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -83,8 +83,9 @@
Nevertheless, as a developer you have to decide whether to:
</para>
<orderedlist spacing="compact"><listitem><para>optimize for swf (employ swf-only APIs, (and maybe even touch Flash APIs))</para></listitem><listitem><para>optimize for dhtml (employ dhtml-only APIs)</para></listitem><listitem><para>code to lowest common denominator ("core" APIs only)</para></listitem><listitem><para>conditionalize (include both. An example would be including comma separated list of embedded and system fonts; when compiled to swf you get embedded font, to dhtml you get system font).</para></listitem></orderedlist>
+<!-- change title per LPP-4804, IORIO 16 oct 2007 -->
<para>
-The focus of the <emphasis role="i">Developer's Guide</emphasis> is (c), the lowest common denominator; runtime-specific APIs and engineering approaches are presented as adjuncts. Graphic devices ("glyphs") in the margin call attention to non core/non SOLO information.
+The focus of the <emphasis role="i">OpenLaszlo Application Developer's Guide</emphasis> is (c), the lowest common denominator; runtime-specific APIs and engineering approaches are presented as adjuncts. Graphic devices ("glyphs") in the margin call attention to non core/non SOLO information.
</para>
<para role="fixme"><remark role="fixme"><emphasis role="para-label">FIXME: </emphasis>illustrate the glyphs here when they're ready</remark></para>
<para>
@@ -155,8 +156,8 @@
-
-<para>In addition to this <emphasis role="em">Developer's Guide</emphasis>, please see also</para>
+<!-- change title per LPP-4804, IORIO 16 oct 2007 -->
+<para>In addition to this <emphasis role="em">OpenLaszlo Application Developer's Guide</emphasis>, please see also</para>
<itemizedlist spacing="compact"><listitem><para>The <ulink url="../reference/../reference/" type="laszlo-reference"><emphasis role="em">LZX Reference
Manual</emphasis></ulink>. This online, hyperlinked, comprehensive reference
for LZX contains entries for each LZX tag and API. Its format will
Modified: openlaszlo/branches/paperpie/docs/src/developers/images/debugger-new-console.png
===================================================================
(Binary files differ)
Modified: openlaszlo/branches/paperpie/docs/src/developers/index.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/index.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/index.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -8,7 +8,8 @@
<book xmlns:xi="http://www.w3.org/2003/XInclude">
<?dbhtml dir="developers" ?>
<?dbhtml filename="index.html" ?>
- <title>Software Engineer's Guide to Developing OpenLaszlo Applications</title>
+ <!-- change title per LPP-4804, IORIO 14 oct 2007 -->
+ <title>OpenLaszlo Application Developer's Guide</title>
<titleabbrev>Developer Guide</titleabbrev>
<preface id="developers.preface">
Modified: openlaszlo/branches/paperpie/docs/src/developers/language-preliminaries.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/language-preliminaries.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/language-preliminaries.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -29,9 +29,14 @@
different from its use in traditional web applications in which JavaScript is used to do things like communicate with the browser
or generate HTML pages. Those functions are basically irrelevant in LZX applications. Thus, although the language design is
rather traditional, the programming paradigm is fundamentally new.</para>
+<!-- change link for laszlo_basics per LPP-4923, IORIO 17 oct 2007 -->
+<para>This chapter summarizes the traditional and innovative aspects of LZX. It's an overview, not a tutorial;
+after reading it you will be better able to decide how to go about learning the language. Depending on your
+background and experience, you may determine that you need to go learn some more about XML or object-oriented
+programming before addressing LZX. On the other hand, if you find these concepts accessible, you may want to
+jump right in and begin coding, in which case we suggest starting with the
+tutorial: <xref linkend="laszlo_basics" /></para>
-<para>This chapter summarizes the traditional and innovative aspects of LZX. It's an overview, not a tutorial; after reading it you will be better able to decide how to go about learning the language. Depending on your background and experience, you may determine that you need to go learn some more about XML or object-oriented programming before addressing LZX. On the other hand, if you find these concepts accessible, you may want to jump right in and begin coding, in which case we suggest starting with the <ulink url="../guide/laszlo_basics.html" type="laszlo-dguide">OpenLaszlo Basics</ulink> tutorial.</para>
-
<para/><section><title>Overview of Syntax and Semantics</title>
<para>In LZX, XML tags are used to create JavaScript objects, and JavaScript is used inside of LZX programs to
@@ -704,8 +709,9 @@
Nevertheless, as a developer you have to decide whether to:
</para>
<orderedlist spacing="compact"><listitem><para>optimize for swf (employ swf-only APIs, (and maybe even touch Flash APIs))</para></listitem><listitem><para>optimize for dhtml (employ dhtml-only APIs)</para></listitem><listitem><para>code to lowest common denominator ("core" APIs only)</para></listitem><listitem><para>conditionalize (include both. An example would be including comma separated list of embedded and system fonts; when compiled to SWF you get embedded font, to DHTML you get system font).</para></listitem></orderedlist>
+<!-- change title per LPP-4804, IORIO 16 oct 2007 -->
<para>
-The focus of the <emphasis role="i">Developer's Guide</emphasis> is (c), the lowest common denominator; runtime-specific APIs and engineering approaches are presented as adjuncts. Graphic devices ("glyphs") in the margin call attention to non core/non SOLO information.
+The focus of the <emphasis role="i">OpenLaszlo Application Developer's Guide</emphasis> is (c), the lowest common denominator; runtime-specific APIs and engineering approaches are presented as adjuncts. Graphic devices ("glyphs") in the margin call attention to non core/non SOLO information.
</para>
<para role="fixme"><remark role="fixme"><emphasis role="para-label">FIXME: </emphasis>illustrate the glyphs here when they're ready</remark></para>
<para>
Modified: openlaszlo/branches/paperpie/docs/src/developers/media-resources.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/media-resources.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/media-resources.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -781,9 +781,9 @@
<glossterm>Compiler Media Cache</glossterm>. In general,
the Compiler Media Cache settings only affect the speed of
the OpenLaszlo compiler. The settings for the Media Cache
- can affect server performance. See
- <ulink url="../deploy/" type="">The Administrator's
- Guide</ulink>for details.</para>
+ can affect server performance. See the
+ <!-- change title per LPP-4804, IORIO 15 oct 2007 -->
+ <ulink url="../deployers/">OpenLaszlo System Administrator's Guide</ulink>for details.</para>
<para>The example below provides a text input area for you
to type in urls that you'd like to test. To run the
example, copy it into your local environment and compile
Modified: openlaszlo/branches/paperpie/docs/src/developers/persistent_connection.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/persistent_connection.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/persistent_connection.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -788,12 +788,11 @@
<connection authenticator="org.openlaszlo.auth.HTTPAuthentication"
authparam="url=http://other.host.com/MySecurityServer"/>
</programlisting>
-
+<!-- change title and add link per LPP-4804, IORIO 15 oct 2007 -->
<para>If the authentication was successful, the security server should return
HTTPAuthentication a username, which, in turn, is returned to the OpenLaszlo Server. You can
change the default authenticator with the
-<literal>connection.default.authenticator</literal> property. See the "Administrator's
-Guide" for more on how to configure your server and <link linkend="persistent_connection.httpauthentication">HTTPAuthentication</link> for what the XML response
+<literal>connection.default.authenticator</literal> property. See the <ulink url="../deployers/">OpenLaszlo System Administrator's Guide</ulink> for more on how to configure your server and <link linkend="persistent_connection.httpauthentication">HTTPAuthentication</link> for what the XML response
format of authentication servers should look like.</para>
Modified: openlaszlo/branches/paperpie/docs/src/developers/program-development.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/program-development.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/program-development.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -3,10 +3,10 @@
<title>Overview of OpenLaszlo Application Development</title>
<para>
This chapter summarizes information about OpenLaszlo application structure and mechanics that an experienced programmer will need in order to start playing with code.</para>
-
+<!-- change link for tutorials per LPP-4923, IORIO 17 oct 2007 -->
<para>This discussion is necessarily abbreviated and incomplete; its
purpose is merely to point you in the right direction. As you begin to
-write LZX applications, you should also work through the <ulink url="../guide/" type="laszlo-dguide">tutorials</ulink>.</para>
+write LZX applications, you should also work through the <ulink url="../developers/" type="laszlo-dguide">tutorials</ulink>.</para>
<para/><section><title>The program development cycle in a nutshell</title>
<para>
Copied: openlaszlo/branches/paperpie/docs/src/developers/programs/canvasversion.lzx (from rev 7009, openlaszlo/trunk/docs/src/developers/programs/canvasversion.lzx)
Modified: openlaszlo/branches/paperpie/docs/src/developers/programs/debugging-$3.lzx
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/programs/debugging-$3.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/programs/debugging-$3.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,7 +1,7 @@
<canvas debug="true" height="150">
<handler name="oninit"><![CDATA[
- for (var i = 0; i > 10; i ++) {
+ for (var i = 0; i < 10; i ++) {
canvas.width();
}
]]></handler>
Modified: openlaszlo/branches/paperpie/docs/src/developers/programs/debugging-$4.lzx
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/programs/debugging-$4.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/programs/debugging-$4.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,9 +1,8 @@
-
-<canvas debug="true" height="150">
- <script>
- Debug.write('user code');
- </script>
- <button onclick="Debug.write('click', getMouse('x'))"/>
+<canvas debug="true" height="350">
+<debug x="160" y="5" height="150" width="300" />
+ <script>Debug.write('user code\n');</script>
+ <button text="Get x, y" width="150" height="150"
+ onclick="Debug.format('click: x=%d, y=%d\n', getMouse('x'), getMouse('y'))" />
</canvas>
<!-- * X_LZ_COPYRIGHT_BEGIN ***************************************************
* Copyright 2007 Laszlo Systems, Inc. All Rights Reserved. *
Copied: openlaszlo/branches/paperpie/docs/src/developers/programs/debuginfo.lzx (from rev 7009, openlaszlo/trunk/docs/src/developers/programs/debuginfo.lzx)
Modified: openlaszlo/branches/paperpie/docs/src/developers/proxied.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/proxied.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/proxied.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -104,8 +104,9 @@
Note that the default behavior is proxied. See below.
</para></note>
<para/><section><title>Availability of J2EE Server or Servlet Container</title>
+<!-- change title per LPP-4804, IORIO 15 oct 2007 -->
<para>
-As explained in the <ulink url="../deploy/">System Administrator's Guide to Deploying OpenLaszlo Applications</ulink>, deploying proxied OpenLaszlo applications
+As explained in the <ulink url="../deployers/">OpenLaszlo System Administrator's Guide</ulink>, deploying proxied OpenLaszlo applications
requires that you install a J2EE application server or servlet container. OpenLaszlo comes with the Tomcat servlet container included,
but, depending on how you have access to the web, it may not be practical or even possible for you to use this to make your applications
generally available. So, before you decide to start development of an OpenLaszlo application for, say, a hobby website, you should find out
@@ -132,8 +133,9 @@
If either deployment manner is available to you, the decision may come down to which works better. You should do test deployments under each
method and see which gives the faster performance.</para>
<para/><section><title>GZipping DHTML Applications</title>
+<!-- change title per LPP-4804, IORIO 15 oct 2007 -->
<para>
-When compiling for DHTML, you should ensure that gzipping is turned on at the server. This is done automatically for DHTML files, but not for DHTML. See the Administrator's Guide for details.
+When compiling for DHTML, you should ensure that gzipping is turned on at the server. This is done automatically for DHTML files, but not for DHTML. See the <ulink url="../deployers/">OpenLaszlo System Administrator's Guide</ulink> for details.
</para>
<para>
The data transfer size and run-time performance may be bigger or smaller, faster or slower.
@@ -143,8 +145,9 @@
It would be redundant to have the web server compress them as well.</para>
<para/></section></section><section><title>Open Proxy by Default</title>
+<!-- change title per LPP-4804, IORIO 15 oct 2007 -->
<para>
-By default, the OpenLaszlo proxy server ships "wide open", which can be a security hazard. See the <ulink url="../deploy/">System Administrator's Guide to Deploying OpenLaszlo Applications</ulink>, for a discussion of OpenLaszlo security management.</para>
+By default, the OpenLaszlo proxy server ships "wide open", which can be a security hazard. See the <ulink url="../deployers/">OpenLaszlo System Administrator's Guide</ulink>, for a discussion of OpenLaszlo security management.</para>
<para/></section><section><title>Compile-time and run-time differences between proxied and SOLO applications</title>
<para>
If an application is compiled for proxied operation, all data and media requests are proxied and the remote
Modified: openlaszlo/branches/paperpie/docs/src/developers/rpc-javarpc.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/rpc-javarpc.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/rpc-javarpc.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,7 +1,8 @@
<chapter id="rpc-javarpc">
<title>JavaRPC</title>
-
+<!-- add titleabbrev to use as target text per LPP-4923, IORIO 17 oct 2007 -->
+<titleabbrev id="rpc-javashort">JavaRPC</titleabbrev>
<para>JavaRPC is a feature that allows server-side Java objects and methods to be
accessed from a client application. The <javarpc> element is used to
declare a JavaRPC object in LZX. JavaRPC is part of the OpenLaszlo RPC family and
Modified: openlaszlo/branches/paperpie/docs/src/developers/rpc-soap.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/rpc-soap.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/rpc-soap.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,6 +1,8 @@
<chapter id="rpc-soap">
<!-- move title before warning to validate against DocBook dtd LI LPP-4641 9/4/2007 -->
<title>SOAP</title>
+<!-- add titleabbrev to use as target text per LPP-4923, IORIO 17 oct 2007 -->
+<titleabbrev id="rpc-soapshort">SOAP</titleabbrev>
<warning><para>
This feature works in proxied applications only. It does not work in SOLO applications.
</para></warning>
Modified: openlaszlo/branches/paperpie/docs/src/developers/rpc-xmlrpc.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/rpc-xmlrpc.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/rpc-xmlrpc.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,10 +1,10 @@
<chapter id="rpc-xmlrpc">
-
<title condition="proxied">XML-RPC</title>
-
+<!-- change link rpc per LPP-4923, IORIO 17 oct 2007 -->
<para>XML-RPC is simple spec that describes how to invoke a remote operation using
-XML over HTTP. OpenLaszlo XML-RPC is part of <ulink url="../guide/rpc.html" type="laszlo-dguide"> OpenLaszlo
-RPC</ulink> and shares many of the same APIs and concepts. OpenLaszlo RPC includes <ulink url="../guide/rpc-soap.html" type="laszlo-dguide">SOAP</ulink> and <ulink url="../guide/rpc-javarpc.html" type="laszlo-dguide">JavaRPC</ulink>. For more information on XML-RPC,
+XML over HTTP. OpenLaszlo XML-RPC is part of <xref linkend="rpc" endterm="rpcshort" />, and shares many of the
+same APIs and concepts. OpenLaszlo RPC includes <xref linkend="rpc-soap" endterm="rpc-soapshort" /> and
+<xref linkend="rpc-javarpc" endterm="rpc-javashort" />. For more information on XML-RPC,
go to <ulink url="http://www.xmlrpc.com/">XML-RPC.com</ulink></para>
<para/><section><title><xmlrpc></title>
Modified: openlaszlo/branches/paperpie/docs/src/developers/rpc.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/rpc.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/rpc.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,6 +1,7 @@
<chapter id="rpc">
-
<title>OpenLaszlo RPC</title>
+<!-- add titleabbrev to use as target text per LPP-4923, IORIO 17 oct 2007 -->
+<titleabbrev id="rpcshort">OpenLaszlo RPC</titleabbrev>
<warning><para>
Remote procedure calls work in proxied applications only. They do not work in SOLO applications.
</para></warning>
@@ -471,7 +472,8 @@
</programlisting><?lzx-edit programs/rpc-$11.lzx></example?>
<warning><para>
-Remote procedure calls return native objects, not XML, and cannot be used with <ulink url="../guide/data-structures.html" type="laszlo-dguide">XPath</ulink>.
+Remote procedure calls return native objects, not XML, and cannot be used with
+<xref linkend="xpath" endterm="xpathshort" />.
</para></warning>
Modified: openlaszlo/branches/paperpie/docs/src/developers/views.dbk
===================================================================
--- openlaszlo/branches/paperpie/docs/src/developers/views.dbk 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/docs/src/developers/views.dbk 2007-10-25 21:44:51 UTC (rev 7011)
@@ -866,6 +866,7 @@
</programlisting><?lzx-edit programs/views-$20.lzx></example?>
<para/></section>
<section>
+<!-- add sectin on pixel locking per LPP-992, IORIO 18 oct 2007 -->
<title>Pixel locking</title>
<para>Subpixel positioning gets blurry lines and images, with more positioning possibilities. This makes it look worse
for static images, and better for animation, and for drawing
Modified: openlaszlo/branches/paperpie/index.jsp
===================================================================
--- openlaszlo/branches/paperpie/index.jsp 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/index.jsp 2007-10-25 21:44:51 UTC (rev 7011)
@@ -86,9 +86,11 @@
<p>Docs</p>
<ul>
<li><a href="docs">Docs index</a></li>
- <li><a href="docs/developers">Software Developer's Guide</a></li>
+ <!-- change title per LPP-4804, IORIO 14 oct 2007 -->
+ <li><a href="docs/developers">Application Developer's Guide</a></li>
<li><a href="docs/component-design">UI Designer's Guide</a></li>
- <li><a href="docs/deployers">Deployer's Guide</a></li>
+ <!-- change title per LPP-4804, IORIO 14 oct 2007 -->
+ <li><a href="docs/deployers">System Administrator's Guide</a></li>
<li><a href="http://www.openlaszlo.org/lps3/docs/reference">Reference Guide (for OL 3.4, served from www.openlaszlo.org)</a> or <a href="docs/reference">Reference Guide (local)</a></li>
<li><a href="docs/contributors">Contributor's Guide</a></li>
<li><a href="docs/release-notes.html">Latest Release Notes</a></li>
Modified: openlaszlo/branches/paperpie/lps/admin/solo-dhtml-deploy.jsp
===================================================================
--- openlaszlo/branches/paperpie/lps/admin/solo-dhtml-deploy.jsp 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/lps/admin/solo-dhtml-deploy.jsp 2007-10-25 21:44:51 UTC (rev 7011)
@@ -411,12 +411,14 @@
}
// Copy the DHTML LFC to lps/includes/LFC-dhtml.js
- copyFileToZipFile(zout, basedir + "/lps/includes/lfc/LFCdhtml.js", "lps/includes/lfc/LFCdhtml.js", out);
- // Copy blank.gif for IE
- copyFileToZipFile(zout, basedir + "/lps/includes/blank.gif", "lps/resources/lps/includes/blank.gif", out);
- // Copy excanvas.js for IE
- copyFileToZipFile(zout, basedir + "/lps/includes/excanvas.js", "lps/resources/lps/includes/excanvas.js",out);
-
+ ArrayList lfcfiles = new ArrayList();
+ listFiles(lfcfiles, new File(basedir + "/lps/includes/lfc"));
+ for (int i=0; i<lfcfiles.size(); i++) {
+ String fname = (String) lfcfiles.get(i);
+ if (!fname.matches(".*LFCdhtml.*.js")) { continue; }
+ String stripped = fname.substring(basedir.getCanonicalPath().length()+1);
+ copyFileToZipFile(zout, fname, stripped, out);
+ }
// track how big the file is, check that we don't write more than some limit
int contentSize = 0;
Modified: openlaszlo/branches/paperpie/lps/components/base/basegrid.lzx
===================================================================
--- openlaszlo/branches/paperpie/lps/components/base/basegrid.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/lps/components/base/basegrid.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -485,10 +485,12 @@
this.shownitems = s;
if ( this.rowheight == null ) return;
- if ( s != -1 ){
- var bottompart = this.height -
- (this.content.y + this.content.height );
- this.setHeight( bottompart + this.content.y + s * rowheight );
+ if(this.isinited){
+ if ( s != -1 ){
+ var bottompart = this.height -
+ (this.content.y + this.content.height );
+ this.setHeight( bottompart + this.content.y + s * rowheight );
+ }
}
if ( this.onshownitems ){
Modified: openlaszlo/branches/paperpie/lps/components/base/basewindow.lzx
===================================================================
--- openlaszlo/branches/paperpie/lps/components/base/basewindow.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/lps/components/base/basewindow.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -247,21 +247,23 @@
<method name="setVisible" args="isVisible"> <![CDATA[
super.setVisible(isVisible);
if (isVisible) {
- //need to add this window to the parent's windowlist
- var foundMe = false;
- var wlist = parent.options["windowlist"];
- var len = wlist.length;
- for (var i=0; i < len; ++i) {
- if (wlist[i] == this){
- foundMe = true;
- break;
+ if (this.isinited) {
+ //need to add this window to the parent's windowlist
+ var foundMe = false;
+ var wlist = parent.options["windowlist"];
+ var len = wlist.length;
+ for (var i=0; i < len; ++i) {
+ if (wlist[i] == this){
+ foundMe = true;
+ break;
+ }
}
+
+ if (!foundMe) {
+ wlist[len] = this;
+ }
}
- if (!foundMe) {
- wlist[len] = this;
- }
-
this.setAttribute('haswindowfocus', true);
} else {
this._removeFromWindowlist();
Modified: openlaszlo/branches/paperpie/lps/components/lzunit/lzunit.lzx
===================================================================
--- openlaszlo/branches/paperpie/lps/components/lzunit/lzunit.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/lps/components/lzunit/lzunit.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -28,11 +28,6 @@
of test cases run, the number of failures, and the number of
errors. If any error occurs, an obvious error message is presented.
- [Future:
- o allow inspection of error details.
- o hook into debugger errors
- ]
-
Below is a simple example of the use of LZUnit:
<canvas debug="true">
@@ -152,8 +147,10 @@
@keywords public
@param Boolean debugWrite: Whether or not to emit debugging statements.
+
+ @devnote TODO: [2007-10-23 ptw] Use LzFormatter as a mixin instead of deriving from text
-->
-<class name="DebugObject">
+<class name="DebugObject" extends="text">
<!--- whether or not to emit debugging statements -->
<attribute name="debugWrite" />
@@ -203,7 +200,7 @@
<!---
Takes any number of arguments and outputs them using
- Debug.write. Strings are output literally, any other objects
+ Debug.debug. Strings are output literally, any other objects
are described in more detail using Debug.__String (which uses
_dbg_typename and _dbg_name of objects that support it).
@@ -222,7 +219,7 @@
s += Debug.__String(e);
}
}
- Debug.write(s);
+ Debug.debug(s);
}
]]>
</method>
@@ -342,8 +339,13 @@
if (this.result) {
this.result.addFailure(message);
} else {
- Debug.write('result is null on fail call: "' + message + '"');
+ Debug.debug('result is null on fail call: "' + message + '"');
}
+ if ($debug) {
+ Debug.freshLine();
+ // create an error, which will include a backtrace, if applicable
+ Debug.__write(new LzError(null, null, message));
+ }
</method>
<!---
@@ -357,8 +359,13 @@
if (this.result) {
this.result.addError(message);
} else {
- Debug.write('result is null on error call: "' + message + '"');
+ Debug.debug('result is null on error call: "' + message + '"');
}
+ if ($debug) {
+ Debug.freshLine();
+ // create an error, which will include a backtrace, if applicable
+ Debug.__write(new LzError(null, null, message));
+ }
</method>
<!---
@@ -373,15 +380,29 @@
@return String: the formatted failure message
-->
<method name="format" args="message, expected, actual">
- var msg = Debug.formatToString(
+ return this.formatToString(
'%s expected %#w got %#w',
(jsTrue(message) ? message + ": " : ""), expected, actual);
- if (Debug) {
+ </method>
+
+ <!---
+ Output a message on the result display
+
+ Outputs a message without affecting the success/failure state of the test
+
+ @param ...:* Any number of parameters will be formatted using
+ LzFormatter.formatToString and output to the display
+ -->
+ <method name="displayMessage">
+ var message = this.formatToString.apply(this, arguments);
+ if (this.result) {
+ this.result.addMessage(message);
+ }
+ if ($debug ) {
Debug.freshLine();
// create an error, which will include a backtrace, if applicable
- Debug.__write(new LzError(null, null, msg));
+ Debug.__write(new LzInfo(null, null, message));
}
- return String(msg);
</method>
<!---
@@ -550,18 +571,14 @@
<method name="assertNotSame" args="expected, actual, message">
if (expected === actual) {
// In-line Test.format so we can invert the sense
- var msg = Debug.formatToString(
+ var msg = LzFormatter.prototype.formatToString(
'%s expected anything but %#w got %#w',
(jsTrue(message) ? message + ": " : "NotSame: "), expected, actual);
- if (Debug) {
- Debug.freshLine();
- // create an error, which will include a backtrace, if applicable
- Debug.__write(new LzError(null, null, msg));
- }
this.fail(msg);
}
canvas.setAttribute('runTests', canvas.runTests + 1)
</method>
+
</class>
<!---
@@ -624,14 +641,18 @@
}
}
<!-- hand-crafted closure -->
- wrapper.env = {inrsw: false, rsw: $reportSourceWarning, testcase: this};
- var savedrsw = $reportSourceWarning;
- if (catchErrors) {
- $reportSourceWarning = wrapper;
+ if ($debug) {
+ wrapper.env = {inrsw: false, rsw: $reportSourceWarning, testcase: this};
+ var savedrsw = $reportSourceWarning;
+ if (catchErrors) {
+ $reportSourceWarning = wrapper;
+ }
}
runTest(theTestName);
- if (catchErrors) {
- $reportSourceWarning = savedrsw;
+ if ($debug) {
+ if (catchErrors) {
+ $reportSourceWarning = savedrsw;
+ }
}
<!-- end capture source warnings -->
tearDown();
@@ -664,8 +685,7 @@
error("method '" + theTestName + "' not found", false);
}
else {
- <!-- TODO: [2002-11-10 ptw] (apply) m.apply(this) -->
- this[theTestName]();
+ m.call(this);
}
</method>
@@ -794,6 +814,7 @@
this.currentTest = null;
this.failures = [];
this.errors = [];
+ this.messages = [];
super.construct(parent, args);
dw("TestResult.construct(", args, ");");
@@ -853,14 +874,27 @@
update();
</method>
+ <!---
+ Record a message
+
+ @keywords private
+ @param ...:* format args
+ -->
+ <method name="addMessage">
+ messages.push(readout.formatToString.apply(readout, arguments));
+ update();
+ </method>
+
<method name="myToString">
var s = "Tests: " + this.totalTests +
" Failures: " + failedTests +
" Errors: " + erroredTests;
- for (var f in failures)
- s += "\n" + failures[f];
- for (var e in errors)
- s += "\n" + errors[e];
+ for (var i in failures)
+ s += "\n" + failures[i];
+ for (var i in errors)
+ s += "\n" + errors[i];
+ for (var i in messages)
+ s += "\n" + messages[i];
return s;
</method>
@@ -984,7 +1018,7 @@
var query = "logfile="+escape(logfile)+"&msg="+escape(msg);
var reqstr = LzBrowser.toAbsoluteURL( base+"/test/lzunit/Logger.jsp?"+query, false );
- //Debug.write("sendServerLogCommand", reqobj, reqstr);
+ //Debug.debug("sendServerLogCommand", reqobj, reqstr);
var tloader = new LzHTTPLoader(this, false, null);
tloader.open ("GET" , reqstr, /* username */ null, /* password */ null);
tloader.send (/* content */ null)
@@ -1015,7 +1049,7 @@
<!--- @keywords private
event handler for test suite end -->
<method event="onsuitefinish">
- //Debug.write("onsuitefinish");
+ //Debug.debug("onsuitefinish");
//this.resultstring += ("failures: "+ this.result.numFailures()+ "\n");
//this.resultstring += ("time: "+ (((new Date)['getTime']()) - this.starttime)+"\n");
this.resultstring += "finish_testsuite: "+this.testpath + " failures: "+ this.result.numFailures()+ "\n";
Modified: openlaszlo/branches/paperpie/lps/includes/source/embednew.js
===================================================================
--- openlaszlo/branches/paperpie/lps/includes/source/embednew.js 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/lps/includes/source/embednew.js 2007-10-25 21:44:51 UTC (rev 7011)
@@ -160,6 +160,14 @@
var scripturl = lzOptions.ServerRoot+ '/lps/includes/excanvas.js';
this.__dhtmlLoadScript(scripturl)
}
+ if ((Lz.__BrowserDetect.isIE && Lz.__BrowserDetect.version < 7) || (Lz.__BrowserDetect.isSafari && Lz.__BrowserDetect.version <= 419.3)) {
+ // use the 'simple' version of the LFC: LFCdhtml-{debug,backtrace}-simple.js for Safari 2 and IE 6
+ var i = url.indexOf('debug.js') || url.indexOf('backtrace.js')
+ if (i != -1) {
+ var type = url.substring(i, url.length - 3);
+ url = url.substring(0, i) + type + '-simple.js';
+ }
+ }
this.__dhtmlLoadScript(url)
}
Modified: openlaszlo/branches/paperpie/lps/includes/source/flash.js
===================================================================
--- openlaszlo/branches/paperpie/lps/includes/source/flash.js 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/lps/includes/source/flash.js 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1321,11 +1321,11 @@
url = url.substring(0, i + 3) + '8' + url.substring(i + 4, url.length);
dojo.flash.flash8_version = url;
}
- var installObj = new dojo.flash.Embed(true);
+ var installObj = new dojo.flash.Embed(true, '100%', '100%');
installObj.write(8); // write out HTML for Flash 8 version+
}else if(dojo.flash.info.isVersionOrAbove(6, 0, 65)){ // Express Install
//dojo.debug("Express install");
- var installObj = new dojo.flash.Embed(false);
+ var installObj = new dojo.flash.Embed(false, '100%', '100%');
installObj.write(8, true); // write out HTML for Flash 8 version+
installObj.setVisible(true);
installObj.center();
Copied: openlaszlo/branches/paperpie/test/compiler_errors/attribute-overrides-method.lzx (from rev 7009, openlaszlo/trunk/test/compiler_errors/attribute-overrides-method.lzx)
Copied: openlaszlo/branches/paperpie/test/compiler_errors/method-override.lzx (from rev 7009, openlaszlo/trunk/test/compiler_errors/method-override.lzx)
Copied: openlaszlo/branches/paperpie/test/compiler_errors/override-x-attribute.lzx (from rev 7009, openlaszlo/trunk/test/compiler_errors/override-x-attribute.lzx)
Modified: openlaszlo/branches/paperpie/test/extensions/html.lzx
===================================================================
--- openlaszlo/branches/paperpie/test/extensions/html.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/test/extensions/html.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -8,7 +8,7 @@
<class name="browser" extends="window" resizable="true" bgcolor="silver">
<edittext name="txt" text="http://openlaszlo.org/" width="300"/>
<button x="310" onclick="parent.htmlview.setSrc(parent.txt.getText()); parent.htmlview.setAttribute('visible', true)">Load</button>
- <html name="htmlview" width="${parent.width - 19}" height="${parent.height - 74}" x="${parent.x + 7}" y="${parent.y + 53}"/>
+ <html name="htmlview"/>
</class>
<browser width="100%" height="100%"/>
Modified: openlaszlo/branches/paperpie/test/lfc/animators/lzunit_animator_prop.lzx
===================================================================
--- openlaszlo/branches/paperpie/test/lfc/animators/lzunit_animator_prop.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/test/lfc/animators/lzunit_animator_prop.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -32,13 +32,13 @@
<method name="checkSimpleXAnim2">
assertEquals(200, bluebox.x);
bluebox.setX(0);
- Debug.write('--- test complete ---');
+ displayMessage('--- test complete ---');
</method>
</TestCase>
</TestSuite>
</canvas>
<!-- * X_LZ_COPYRIGHT_BEGIN ***************************************************
-* Copyright 2001-2006 Laszlo Systems, Inc. All Rights Reserved. *
+* Copyright 2001-2007 Laszlo Systems, Inc. All Rights Reserved. *
* Use is subject to license terms. *
* X_LZ_COPYRIGHT_END ****************************************************** -->
Modified: openlaszlo/branches/paperpie/test/lfc/data/testhttpdata.lzx
===================================================================
--- openlaszlo/branches/paperpie/test/lfc/data/testhttpdata.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/test/lfc/data/testhttpdata.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -49,6 +49,8 @@
<dataset name="data12" src="http:httpdate.jsp"
getresponseheaders="false" cacheable="true" />
+ <dataset name="dataError" src="http:nosuchfile.xml"/>
+
<class name="testdatapointer" extends="datapointer">
<method event="ondata">
Debug.format("%s: .ondata(%w)\n", parent.text, arguments[0]);
@@ -62,7 +64,6 @@
</class>
<view id="tests">
- <simplelayout/>
<view name="buttons" layout="class:wrappinglayout;axis:x;spacing:2" width="${canvas.width}">
<button>
Unqueued
@@ -173,6 +174,14 @@
<testdatapointer xpath="data11:/*" />
</button>
<button>
+ Do Error
+ <method event="onclick">
+ Debug.format("%s request\n", this.text);
+ canvas.datasets.dataError.doRequest();
+ </method>
+ <testdatapointer xpath="dataError:/*" />
+ </button>
+ <button>
Date
<method event="onclick">
Debug.format("%s request\n", this.text);
Modified: openlaszlo/branches/paperpie/test/lfc/legals/multiframeresource.lzx
===================================================================
--- openlaszlo/branches/paperpie/test/lfc/legals/multiframeresource.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/test/lfc/legals/multiframeresource.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -1,18 +1,76 @@
<!--
/* X_LZ_COPYRIGHT_BEGIN ***************************************************
-* Copyright 2001-2006 Laszlo Systems, Inc. All Rights Reserved. *
+* Copyright 2001-2007 Laszlo Systems, Inc. All Rights Reserved. *
* Use is subject to license terms. *
* X_LZ_COPYRIGHT_END ******************************************************/
-->
-<canvas width="100%" height="80%">
+<canvas width="100%" height="400">
<resource name="tabrsrc" >
+ <frame src="resc/h_c_web2con.gif" />
<frame src="resc/wallpaper.jpg" />
- <frame src="resc/h_c_web2con.gif" />
</resource>
<resource name="logoanim" src="animation/"/>
- <view name="foo" resource="tabrsrc" onmousedown="this.play()" onmouseup="this.stop()"/>
+ <class name="eventtester" width="150">
+ <attribute name="eventname" value="" type="text"/>
+ <handler name="oninit">
+ if (eventname == '') Debug.warn('Must specify event name.')
+ this.evDel = new LzDelegate(this, 'update', parent, eventname);
+ </handler>
+ <method name="update" args="d">
+ this.txt.setText(eventname + ': '+ d);
+ this.bg.setBGColor(green);
+ </method>
- <view name="bar" resource="logoanim" x="300" oninit="this.play()"/>
+ <view name="bg" bgcolor="red" opacity=".5" width="100%" height="100%"/>
+ <text name="txt" text="${classroot.eventname}" width="150"/>
+ </class>
+
+ <view name="foo" resource="tabrsrc" onmousedown="this.play()" onmouseup="this.stop()" options="ignorelayout"/>
+
+ <class name="statusloader" width="150">
+ <attribute name="label" value="" type="text"/>
+ <handler name="onlastframe">
+ this.stop();
+ </handler>
+ <handler name="onvisible">
+ this.setVisible(true);
+ </handler>
+
+ <simplelayout/>
+ <text text="${classroot.label}"/>
+ <eventtester eventname="onframe"/>
+ <eventtester eventname="ontotalframes"/>
+ <eventtester eventname="onlastframe"/>
+ <eventtester eventname="onplay"/>
+ <eventtester eventname="onstop"/>
+ <eventtester eventname="onload"/>
+ <eventtester eventname="onloadperc"/>
+ <eventtester eventname="onerror"/>
+ <eventtester eventname="ontimeout"/>
+ </class>
+
+ <simplelayout axis="x" inset="200"/>
+
+ <view name="mousetester" clickable="true">
+ <simplelayout/>
+ <text text="mouse events turn green"/>
+ <eventtester eventname="onmouseover"/>
+ <eventtester eventname="onmouseout"/>
+ <eventtester eventname="onmousedown"/>
+ <eventtester eventname="onmouseup"/>
+ <eventtester eventname="onclick"/>
+ <eventtester eventname="ondblclick"/>
+ <eventtester eventname="onmousedragin"/>
+ <eventtester eventname="onmousedragout"/>
+ <eventtester eventname="onmouseupoutside"/>
+ </view>
+
+ <statusloader resource="logoanim" label="local resource" onclick="this.play()"/>
+ <statusloader resource="logoanim" play="true" label="local resource play" onclick="this.play()"/>
+ <statusloader oninit="this.setSource('resc/wallpaper-thumb.jpg')" label="single frame"/>
+ <statusloader oninit="this.setSource('resc/logo.swf')" label="swf only multiframe" onclick="this.play()"/>
+ <statusloader resource="http:music.mp3" label="swf only mp3 audio" onclick="this.play()"/>
+ <statusloader oninit="this.setSource('bad.bar')" label="should fail"/>
</canvas>
Copied: openlaszlo/branches/paperpie/test/lfc/legals/music.mp3 (from rev 7009, openlaszlo/trunk/test/lfc/legals/music.mp3)
Copied: openlaszlo/branches/paperpie/test/lfc/legals/resc/logo.swf (from rev 7009, openlaszlo/trunk/test/lfc/legals/resc/logo.swf)
Copied: openlaszlo/branches/paperpie/test/lfc/legals/resc/wallpaper-thumb.jpg (from rev 7009, openlaszlo/trunk/test/lfc/legals/resc/wallpaper-thumb.jpg)
Modified: openlaszlo/branches/paperpie/test/lztest/lztest-class-impl.lzx
===================================================================
--- openlaszlo/branches/paperpie/test/lztest/lztest-class-impl.lzx 2007-10-25 17:24:16 UTC (rev 7010)
+++ openlaszlo/branches/paperpie/test/lztest/lztest-class-impl.lzx 2007-10-25 21:44:51 UTC (rev 7011)
@@ -83,7 +83,7 @@
LzTestManager.assertEquals("LzSubSub", LzSubSub.classname);
- var sub2Inst = LzSubSub.make();
+ var sub2Inst = new LzSubSub();
LzTestManager.assertTrue( sub2Inst instanceof LzSub);
LzTestManager.assertTrue( sub2Inst instanceof LzSubSub);
@@ -104,7 +104,7 @@
var LzNodeSub = Class.make( "LzNodeSub", LzNode );
LzTestManager.assertEquals("LzNodeSub", LzNodeSub.classname);
- var nodeSubInst = LzNodeSub.make();
+ var nodeSubInst = new LzNodeSub();
LzTestManager.assertTrue( nodeSubInst instanceof LzNodeSub );
}
More information about the Laszlo-checkins
mailing list