Compare commits

...

13 Commits

Author SHA1 Message Date
52e67c6bfc 0.6.43 2016-12-16 15:29:33 -08:00
5a6f23a7d0 Bump pxt-core to 0.6.5 2016-12-16 15:29:26 -08:00
d1b36f2022 0.6.42 2016-12-16 14:57:24 -08:00
284579181b Bump pxt-core to 0.6.4 2016-12-16 14:57:09 -08:00
20fcb05538 0.6.41 2016-12-16 14:40:12 -08:00
e1a2074ef5 Bump pxt-core to 0.6.3 2016-12-16 14:39:58 -08:00
fa3e33dab9 Default product.json for enabling Electron builds (#323) 2016-12-16 12:16:06 -08:00
300a98b858 0.6.40 2016-12-13 21:58:35 -08:00
5986671bcb Bump pxt-core to 0.6.1 2016-12-13 21:58:29 -08:00
efd5c46143 0.6.39 2016-12-14 09:16:58 +11:00
62c1a1da35 Bump pxt-core to 0.5.102 2016-12-14 09:16:57 +11:00
ebbc7c983d 0.6.38 2016-12-13 12:49:06 -08:00
173fc4bf7b Bump pxt-core to 0.5.101 2016-12-13 12:49:04 -08:00
7 changed files with 16 additions and 77 deletions

View File

@ -1,2 +0,0 @@
node_modules
projects

View File

@ -1,5 +0,0 @@
# PXT micro:bit Electron app
A very basic wrapper around the web app. To install, copy the contents of this
directory to somewhere outside the main `pxt-microbit` repository. Then run `npm
install && npm start`.

View File

@ -1,15 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>code the micro:bit</title>
</head>
<body>
<webview id="webview" style="position:absolute; left:0; top:0; right:0; bottom:0"/>
<script>
const webview = document.getElementById("webview")
const url = `http://localhost:3232/${window.location.hash}`
webview.src = url
</script>
</body>
</html>

View File

@ -1,39 +0,0 @@
const {app, BrowserWindow, Menu} = require('electron')
const pxt = require('pxt-core')
const path = require('path')
let win
const cliPath = path.join(process.cwd(), "node_modules/pxt-microbit")
function startServerAndCreateWindow() {
pxt.mainCli(cliPath, ["serve", "-no-browser"])
createWindow()
}
function createWindow () {
win = new BrowserWindow({
width: 800,
height: 600,
title: "code the micro:bit"
})
Menu.setApplicationMenu(null)
win.loadURL(`file://${__dirname}/index.html#local_token=${pxt.globalConfig.localToken}`)
win.on('closed', () => {
win = null
})
}
app.on('ready', startServerAndCreateWindow)
app.on('window-all-closed', () => {
if (process.platform !== 'darwin') {
app.quit()
}
})
app.on('activate', () => {
if (win === null) {
createWindow()
}
})

View File

@ -1,14 +0,0 @@
{
"name" : "code-the-microbit",
"version" : "1.0.0",
"description": "Blocks / Javascript editor",
"author": "Microsoft",
"main" : "main.js",
"scripts": {
"start": "node_modules/.bin/electron ."
},
"devDependencies": {
"electron": "*",
"pxt-microbit": "*"
}
}

14
electron/product.json Normal file
View File

@ -0,0 +1,14 @@
{
"applicationName": "pxt-microbit-oss",
"dataFolderName": ".pxt-microbit-oss",
"darwinBundleIdentifier": "com.microsoft.pxtoss",
"nameShort": "PXT Microbit - OSS",
"nameLong": "PXT Microbit - OSS",
"targetId": "pxt-microbit",
"win32AppId": "{{92db071a-6f58-4938-8c97-13c873f4da13}",
"win32AppUserModelId": "Microsoft.PXTMicrobitOss",
"win32DirName": "Microsoft PXT-Microbit - OSS",
"win32MutexName": "pxtmicrobitoss",
"win32NameVersion": "Microsoft PXT-Microbit-OSS",
"win32RegValueName": "PXTMicrobitOss"
}

View File

@ -1,6 +1,6 @@
{
"name": "pxt-microbit",
"version": "0.6.37",
"version": "0.6.43",
"description": "micro:bit target for PXT",
"keywords": [
"JavaScript",
@ -34,6 +34,6 @@
"semantic-ui-less": "^2.2.4"
},
"dependencies": {
"pxt-core": "0.5.100"
"pxt-core": "0.6.5"
}
}