Skip to content

Commit 2c1029f

Browse files
committed
[[ Breaking Changes ]] Update for implicit object changes
This patch adds a note about the change to the implicit object in widget handlers introduced in this release.
1 parent 4bee4a0 commit 2c1029f

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

docs/notes-base/breaking_changes.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,3 +40,25 @@ The constant `infinity` has been added to the language in this release. As a
4040
result, the unquoted literal `infinity` is now reserved. Any existing uses
4141
of it should be quoted, as otherwise it will resolve to the floating point
4242
value representing infinity, rather than the string "infinity".
43+
44+
## Implicit object
45+
46+
A number of LCB commands use an implicit object to provide context for their
47+
execution. Some of these commands also allow specifying an explicit object.
48+
These commands are:
49+
50+
- `execute script`
51+
- `send`
52+
- `post`
53+
- `image from file`
54+
- `resolve file` - new in this version
55+
56+
In previous releases `execute script` and `image from file` would use
57+
`this card of the defaultStack` as the implicit object even if called from
58+
a widget. The `send` and `post` commands, however, used
59+
`this card of the defaultStack` when in a library module handler and the host
60+
widget when in a widget module handler. This release changes `execute script`
61+
and `image from file` to also use the host widget as the implicit object. This
62+
means, for example, that `image from file` will resolve a relative file path
63+
relative to the `stackFile` the host widget is on rather than the `stackFile` of
64+
the `defaultStack`.

0 commit comments

Comments
 (0)