Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • clients/cesium-grp/cesium-desktop
1 result
Show changes
Commits on Source (2)
......@@ -47,10 +47,9 @@ src/nw/cesium
tmp
package-lock.json
src/nw/yarn.lock
src/nw/swiftshader/libEGL.so
src/nw/swiftshader/libGLESv2.so
downloads
src/nw/yarn.lock
\ No newline at end of file
src/nw/yarn.lock
[Dolphin]
Timestamp=2019,1,2,16,41,57
Version=3
ViewMode=1
......@@ -10,7 +10,7 @@ CESIUM_TAG=
ADDON_VERSION=48
NW_VERSION=0.35.3
NW_RELEASE="v${NW_VERSION}"
NW="nwjs-sdk-${NW_RELEASE}-linux-x64"
NW="nwjs-${NW_RELEASE}-linux-x64"
NW_GZ="${NW}.tar.gz"
# Folders
......
......@@ -4,7 +4,6 @@ Section: misc
Priority: optional
Architecture: all
Installed-Size: 235351
License: AGPL-3+
Maintainer: Duniter team
Description: Cesium Wallet for Ğ1 currency
Cesium is a wallet (client-software) for Ğ1, a libre currency.
......
#!/bin/bash
# Yarn
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
# System tools
apt-get update
apt-get install --yes git curl yarn python-minimal zip
# User installation
sudo su vagrant -c "bash /vagrant/user-bootstrap.sh"
#!/bin/bash
# NVM
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.1/install.sh | bash
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
# Node.js
nvm install 6
# node-pre-gyp
npm install -g nw-gyp node-pre-gyp
......@@ -51,12 +51,12 @@ then
rmdir nw
cd $ROOT_DIR/src/nw
npm install
yarn
# Check NW version
else
cd ${ROOT_DIR}/src/nw
npm install
yarn
NW_ACTUAL_VERSION=`./nw --version | grep nwjs | awk '{print $2}'`
echo "Using Chromium version: ${NW_ACTUAL_VERSION}"
......
// Rename "require" to avoid conflicts with pure JS libraries
requireNodejs = require
require = undefined
......@@ -11,8 +10,8 @@ const fs = requireNodejs('fs')
const path = requireNodejs('path')
const yaml = requireNodejs('js-yaml')
const bs58 = requireNodejs('bs58')
const gui = requireNodejs('nw.gui');
const clc = requireNodejs('cli-color');
const gui = requireNodejs('nw.gui');
Base58 = {
encode: (bytes) => bs58.encode(new Buffer(bytes)),
......@@ -53,6 +52,9 @@ const DEFAULT_CESIUM_SETTINGS = {
"showUDHistory": true
};
function isSdkMode () {
return gui && (window.navigator.plugins.namedItem('Native Client') !== null);
}
/**** Process command line args ****/
var commands = gui && gui.App && gui.App.argv;
......@@ -60,9 +62,13 @@ var debug = false;
if (commands && commands.length) {
for (i in commands) {
if (commands[i] === "--debug") {
console.log("[NW] Enabling DEV tool (--debug)");
console.log("[NW] Enabling debug mode (--debug)");
debug = true;
gui.Window.get().showDevTools();
// Open the DEV tool (need a SDK version of NW)
if (isSdkMode()) {
gui.Window.get().showDevTools();
}
}
}
}
......