Skip to content
This repository has been archived by the owner on Aug 31, 2021. It is now read-only.

[[ HTML5Callbacks ]] Allow specified LiveCode handlers to be called from JavaScript #5602

Merged
merged 8 commits into from Jun 14, 2017

Conversation

livecodeian
Copy link
Contributor

No description provided.

Export functions required by JS library code
Fix valueref parameter passed incorrectly to
MCExecTypeConvertAndReleaseAlways
Fix broken stacklist iteration in _emscripten_get_stack
fix broken string building in LiveCodeUtil.stringFromMCString
fix incorrect function names called from JS
Renamed to avoid overshadowing by real property once implemented

## Calling from JavaScript

The standalone engine will create a `liveCode` object on the DOM `document` object. To this object will be attached the `findStackWithName` method that can be called to return a JavaScript stack object. Each stack object will have methods corresponding to the exposed handlers of that stack. For instance, a stack with the `cJavascriptHandlers` property set to :
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest we make the name 'livecode' - I think liveCode will be prone to errors.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

liveCode is consistent with the naming in the browser widget, although the usage there is slightly different

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that's fine - we'll keep it consistent for now - we can add an alias at a later date.

@runrevmark
Copy link
Contributor

@livecode-vulcan review ok 93f1d75

@livecode-vulcan
Copy link
Contributor

💙 review by @runrevmark ok 93f1d75

livecode-vulcan added a commit that referenced this pull request Jun 14, 2017
[[ HTML5Callbacks ]] Allow specified LiveCode handlers to be called from JavaScript
@livecode-vulcan
Copy link
Contributor

😎 test success 93f1d75

  • try-community-armv6-android-api8: success
  • try-community-armv6-android-api9: success
  • try-community-js-emscripten-sdk1.35: success
  • try-community-universal-ios-iphoneos10.3: success
  • try-community-universal-ios-iphonesimulator10.3: success
  • try-community-universal-mac-macosx10.6: success
  • try-community-universal-mac-macosx10.9: success
  • try-community-x86-linux-debian7: success
  • try-community-x86-linux-debian8: success
  • try-community-x86_64-linux-debian7: success
  • try-community-x86_64-linux-debian8: success
  • try-community-x86-win32: success
  • try-community-x86_64-win32: success

@runrevmark runrevmark merged commit d6267de into livecode:develop Jun 14, 2017
@mwieder
Copy link
Contributor

mwieder commented Jun 14, 2017

This is an awesome addition. I am so looking forward to this feature. Thanks.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
4 participants