Summary of conversion scripts in OpenLaszlo Server 4.x/bin/
These should all be run for a 4.1 upgrading to 4.2, or users can
upgrade by hand.
There is no overlap with the scripts, they address different parts of
the problem.
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
convert_required.pl :
converts 'new':
'new LzText' is converted to 'new lz.text'
'new myclass' is converted to 'new lz.myclass'
converts names of service classes:
'LzTimer' is converted to 'lz.Timer'
This works for LzAudio, LzBrowser, LzCursor, LzFocus,
LzGlobalMouse, LzHistory, LzIdle, LzInstantiator, LzKeys,
LzModeManager, LzTimer, LzTrack
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
convert_laszlo.pl:
<method event=...>
1)
<method event="foo" args="bar" name="blarg">...</
method>
converted to
<handler name="foo" method="blarg"/> <method
name="blarg" args="bar">...</method>
2)
<method event="foo">...</method>
converted to
<handler name="foo">...</handler>
3)
<method event="foo" args="bar">...</method>
converted to
<handler name="foo" args="bar">...</handler>
setAttribute:
e.g. converts 'setVisible' to setAttribute('visible', ...)
width, height:
e.g. converts getWidth(),getHeight() to width,height
constructor to tagname:
constructor.classname is converted to constructor.tagname
states syntax:
apply= is changed to applied=
apply call:
state.apply()/remove() changed to
setAttribute('applied', true|false)
proxy methods:
Lz.setCanvasAttribute.... changed to lz.embed.....
Lz.callMethod...... changed to lz.embed.....
method - <method ...> transforms
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
convert_setters.pl
Converts numerous setters to use names of variables
'setLayout' => 'layout',
'setFontName' => 'font',
'setResource' => 'resource',
'setVisible' => 'visible',
'setVisibility' => 'visibility',
'setWidth' => 'width',
'setHeight' => 'height',
'setOpacity' => 'opacity',
'setX' => 'x',
'setY' => 'y',
'setRotation' => 'rotation',
'setAlign' => 'align',
'setXOffset' => 'xoffset',
'setYOffset' => 'yoffset',
'setValign' => 'valign',
'setColor' => 'fgcolor',
'setResourceNumber' => 'frame',
# 'stretchResource' => 'stretches',
'setBGColor' => 'bgcolor',
'setClickable' => 'clickable',
'setCursor' => 'cursor',
'setPlay' => 'play',
'setShowHandCursor' => 'showhandcursor',
'setAAActive' => 'aaactive',
'setAAName' => 'aaname',
'setAADescription' => 'aadescription',
'setAATabIndex' => 'aatabindex',
'setAASilent' => 'aasilent',
'setProxyURL' => 'proxyurl',
# lz.text
'setResize' => 'resize',
'setMaxLength' => 'maxlength',
'setPattern' => 'pattern',
'setXScroll' => 'xscroll',
'setText' => 'text',
'setSelectable' => 'selectable',
'setFontSize' => 'fontsize',
'setFontStyle' => 'fontstyle',
'setAntiAliasType' => 'aliasType',
'setGridFit' => 'gridFit',
'setSharpness' => 'sharpness',
'setThickness' => 'thickness',
# lz.inputtext
'setEnabled' => 'enabled',
# lz.animator
'setMotion' => 'motion',
'setTo' => 'to',
# lz.animatorgroup
'setTarget' => 'target',
'setDuration' => 'duration',
# lz.node
'setDatapath' => 'datapath', # Also used in LzReplicationManager
# lz.dataset
'setSrc' => 'src',
'setRequest' => 'request',
'setAutorequest' => 'autorequest',
# lz.command
'setKeys' => 'key'
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
--
Don Anderson
Java/C/C++, Berkeley DB, systems consultant
voice: 617-306-2057
email: [email protected]
www: http://www.ddanderson.com