Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
hschneider committed Nov 22, 2023
1 parent 7ae388b commit 02b9ac8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,8 @@ Just follow these steps:
- Copy **resources/js/python-extension.js** to **resources/js**.
- Add `<script src="js/python-extension.js"></script>` to your **index.html**
- Add `const PYTHON = new PythonExtension(true)` to your **main.js**
- Add **event listeners to main.js**, to fetch data from Python.
- Add **PYTHON.run(function_name, data) to main.js** to submit data to Python.
- Add **PYTHON.run(function_name, data) to main.js** to run Python functions from Neutralino.
- Add **event listeners to main.js**, to fetch result data from Python.

## main.py explained

Expand All @@ -99,8 +99,8 @@ def processAppEvent(data):
if data['event'] == 'runPython':
(f, d) = ext.parseFunctionCall(data)

# Process incoming method calls:
# m: method name, d: data as JSON or string
# Process incoming function calls:
# f: function name, d: data as JSON or string
#
if f == 'ping':
ping(d)
Expand Down

0 comments on commit 02b9ac8

Please sign in to comment.