├── desktop
├── log
│ └── dr-monero
│ │ ├── peers.data
│ │ ├── block_proc.data
│ │ ├── limit_down.info
│ │ ├── limit_up.info
│ │ ├── net
│ │ ├── in-all.data
│ │ ├── out-all.data
│ │ └── req-all.data
│ │ ├── peers_limit.info
│ │ ├── blockchain_log.data
│ │ ├── down_sleep_log.data
│ │ ├── up_sleep_log.data
│ │ └── get_objects_calc_time.data
├── assets
│ ├── icon.ico
│ ├── logo.png
│ ├── icon32.png
│ ├── skin
│ │ ├── tiny.png
│ │ ├── uiskin.png
│ │ ├── default.png
│ │ ├── uiskin.atlas
│ │ ├── uiskin.json
│ │ ├── tiny.fnt
│ │ └── default.fnt
│ └── fonts
│ │ ├── quigleyw.png
│ │ ├── bauchaomaicha.png
│ │ └── bauchaomaicha.fnt
├── src
│ └── com
│ │ └── jw
│ │ └── lightwallet
│ │ └── desktop
│ │ └── DesktopLauncher.java
└── build.gradle
├── html
├── webapp
│ ├── soundmanager2-setup.js
│ ├── WEB-INF
│ │ └── web.xml
│ ├── refresh.png
│ ├── styles.css
│ └── index.html
├── src
│ └── com
│ │ └── jw
│ │ └── lightwallet
│ │ ├── GdxDefinition.gwt.xml
│ │ ├── client
│ │ └── HtmlLauncher.java
│ │ └── GdxDefinitionSuperdev.gwt.xml
└── build.gradle
├── settings.gradle
├── android
├── assets
│ ├── icon.ico
│ ├── logo.png
│ ├── icon32.png
│ ├── skin
│ │ ├── tiny.png
│ │ ├── uiskin.png
│ │ ├── default.png
│ │ ├── uiskin.atlas
│ │ ├── uiskin.json
│ │ ├── tiny.fnt
│ │ └── default.fnt
│ └── fonts
│ │ ├── quigleyw.png
│ │ ├── bauchaomaicha.png
│ │ └── bauchaomaicha.fnt
├── ic_launcher-web.png
├── res
│ ├── drawable-hdpi
│ │ └── ic_launcher.png
│ ├── drawable-mdpi
│ │ └── ic_launcher.png
│ ├── drawable-xhdpi
│ │ └── ic_launcher.png
│ ├── drawable-xxhdpi
│ │ └── ic_launcher.png
│ └── values
│ │ ├── strings.xml
│ │ └── styles.xml
├── project.properties
├── src
│ └── com
│ │ └── jw
│ │ └── lightwallet
│ │ └── android
│ │ └── AndroidLauncher.java
├── AndroidManifest.xml
├── proguard-project.txt
└── build.gradle
├── gradle.properties
├── gradle
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── core
├── src
│ ├── com
│ │ └── jw
│ │ │ └── lightwallet
│ │ │ ├── utils
│ │ │ ├── WalletSaveValues.java
│ │ │ ├── Constants.java
│ │ │ ├── BalanceValues.java
│ │ │ ├── WalletValues.java
│ │ │ ├── DaemonValues.java
│ │ │ └── Tx.java
│ │ │ ├── tx
│ │ │ ├── TxError.java
│ │ │ ├── TxResult.java
│ │ │ └── TxResponse.java
│ │ │ ├── wallet
│ │ │ ├── BalanceResult.java
│ │ │ ├── BalanceResponse.java
│ │ │ ├── WalletSaveRPC.java
│ │ │ └── BalanceRPC.java
│ │ │ ├── daemon
│ │ │ ├── Result.java
│ │ │ ├── DaemonResult.java
│ │ │ ├── DaemonResponse.java
│ │ │ ├── BlockHeader.java
│ │ │ └── DaemonRPC.java
│ │ │ ├── screens
│ │ │ ├── HistoryView.java
│ │ │ ├── AbstractScreen.java
│ │ │ ├── DaemonView.java
│ │ │ ├── WalletView.java
│ │ │ ├── PasswordScreen.java
│ │ │ ├── WizardScreen.java
│ │ │ ├── TransactionView.java
│ │ │ ├── CreateScreen.java
│ │ │ ├── ImportKeysScreen.java
│ │ │ └── ImportSeedScreen.java
│ │ │ └── LightWallet.java
│ └── LightWallet.gwt.xml
└── build.gradle
├── .gitignore
├── README.md
├── gradlew.bat
└── gradlew
/desktop/log/dr-monero/peers.data:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/block_proc.data:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/limit_down.info:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/limit_up.info:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/net/in-all.data:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/net/out-all.data:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/net/req-all.data:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/peers_limit.info:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/blockchain_log.data:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/down_sleep_log.data:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/up_sleep_log.data:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/desktop/log/dr-monero/get_objects_calc_time.data:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/html/webapp/soundmanager2-setup.js:
--------------------------------------------------------------------------------
1 | window.SM2_DEFER = true;
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | include 'desktop', 'android', 'html', 'core'
--------------------------------------------------------------------------------
/html/webapp/WEB-INF/web.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/android/assets/icon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/assets/icon.ico
--------------------------------------------------------------------------------
/android/assets/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/assets/logo.png
--------------------------------------------------------------------------------
/desktop/assets/icon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/desktop/assets/icon.ico
--------------------------------------------------------------------------------
/desktop/assets/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/desktop/assets/logo.png
--------------------------------------------------------------------------------
/html/webapp/refresh.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/html/webapp/refresh.png
--------------------------------------------------------------------------------
/android/assets/icon32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/assets/icon32.png
--------------------------------------------------------------------------------
/desktop/assets/icon32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/desktop/assets/icon32.png
--------------------------------------------------------------------------------
/android/assets/skin/tiny.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/assets/skin/tiny.png
--------------------------------------------------------------------------------
/android/ic_launcher-web.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/ic_launcher-web.png
--------------------------------------------------------------------------------
/desktop/assets/skin/tiny.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/desktop/assets/skin/tiny.png
--------------------------------------------------------------------------------
/android/assets/skin/uiskin.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/assets/skin/uiskin.png
--------------------------------------------------------------------------------
/desktop/assets/skin/uiskin.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/desktop/assets/skin/uiskin.png
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | org.gradle.daemon=true
2 | org.gradle.jvmargs=-Xms128m -Xmx512m
3 | org.gradle.configureondemand=true
--------------------------------------------------------------------------------
/android/assets/fonts/quigleyw.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/assets/fonts/quigleyw.png
--------------------------------------------------------------------------------
/android/assets/skin/default.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/assets/skin/default.png
--------------------------------------------------------------------------------
/desktop/assets/fonts/quigleyw.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/desktop/assets/fonts/quigleyw.png
--------------------------------------------------------------------------------
/desktop/assets/skin/default.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/desktop/assets/skin/default.png
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/android/assets/fonts/bauchaomaicha.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/assets/fonts/bauchaomaicha.png
--------------------------------------------------------------------------------
/desktop/assets/fonts/bauchaomaicha.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/desktop/assets/fonts/bauchaomaicha.png
--------------------------------------------------------------------------------
/android/res/drawable-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/res/drawable-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/res/drawable-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/res/drawable-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/res/drawable-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/res/drawable-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/res/drawable-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jwinterm/LightWallet2/HEAD/android/res/drawable-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/utils/WalletSaveValues.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.utils;
2 |
3 | public class WalletSaveValues {
4 |
5 |
6 | }
7 |
--------------------------------------------------------------------------------
/android/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | lightwallet
5 |
6 |
7 |
--------------------------------------------------------------------------------
/core/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: "java"
2 |
3 | sourceCompatibility = 1.6
4 | [compileJava, compileTestJava]*.options*.encoding = 'UTF-8'
5 |
6 | sourceSets.main.java.srcDirs = [ "src/" ]
7 |
8 |
9 | eclipse.project {
10 | name = appName + "-core"
11 | }
12 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Sat Sep 21 13:08:26 CEST 2013
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=http\://services.gradle.org/distributions/gradle-2.4-all.zip
7 |
--------------------------------------------------------------------------------
/core/src/LightWallet.gwt.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/tx/TxError.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.tx;
2 |
3 | public class TxError {
4 |
5 | int code;
6 | String message;
7 |
8 |
9 | public int getCode() {
10 | return code;
11 | }
12 | public void setCode(int code) {
13 | this.code = code;
14 | }
15 | public String getMessage() {
16 | return message;
17 | }
18 | public void setMessage(String message) {
19 | this.message = message;
20 | }
21 |
22 | }
23 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/tx/TxResult.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.tx;
2 |
3 | public class TxResult {
4 |
5 | String tx_hash;
6 | String tx_key;
7 |
8 |
9 | public String getTx_hash() {
10 | return tx_hash;
11 | }
12 | public void setTx_hash(String tx_hash) {
13 | this.tx_hash = tx_hash;
14 | }
15 | public String getTx_key() {
16 | return tx_key;
17 | }
18 | public void setTx_key(String tx_key) {
19 | this.tx_key = tx_key;
20 | }
21 |
22 |
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/wallet/BalanceResult.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.wallet;
2 |
3 | public class BalanceResult {
4 |
5 | long unlocked_balance;
6 | long balance;
7 |
8 | public long getUnlockedbalance() {
9 | return unlocked_balance;
10 | }
11 | public void setUnlockedbalance(long unlocked_balance) {
12 | this.unlocked_balance = unlocked_balance;
13 | }
14 | public long getBalance() {
15 | return balance;
16 | }
17 | public void setBalance(long balance) {
18 | this.balance = balance;
19 | }
20 |
21 | }
22 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/daemon/Result.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.daemon;
2 |
3 | public class Result {
4 |
5 | BlockHeader block_header;
6 | String status;
7 |
8 |
9 | public BlockHeader getBlock_header() {
10 | return block_header;
11 | }
12 | public void setBlock_header(BlockHeader block_header) {
13 | this.block_header = block_header;
14 | }
15 | public String getStatus() {
16 | return status;
17 | }
18 | public void setStatus(String status) {
19 | this.status = status;
20 | }
21 |
22 |
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/daemon/DaemonResult.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.daemon;
2 |
3 | public class DaemonResult {
4 |
5 | BlockHeader block_header;
6 | String status;
7 |
8 |
9 | public BlockHeader getBlock_header() {
10 | return block_header;
11 | }
12 | public void setBlock_header(BlockHeader block_header) {
13 | this.block_header = block_header;
14 | }
15 | public String getStatus() {
16 | return status;
17 | }
18 | public void setStatus(String status) {
19 | this.status = status;
20 | }
21 |
22 |
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/android/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/android/project.properties:
--------------------------------------------------------------------------------
1 | # This file is automatically generated by Android Tools.
2 | # Do not modify this file -- YOUR CHANGES WILL BE ERASED!
3 | #
4 | # This file must be checked in Version Control Systems.
5 | #
6 | # To customize properties used by the Ant build system edit
7 | # "ant.properties", and override values to adapt the script to your
8 | # project structure.
9 | #
10 | # To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home):
11 | #proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
12 |
13 | # Project target.
14 | target=android-21
15 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/daemon/DaemonResponse.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.daemon;
2 |
3 | public class DaemonResponse {
4 |
5 | String id;
6 | String jsonrpc;
7 | DaemonResult result;
8 |
9 |
10 | public String getId() {
11 | return id;
12 | }
13 | public void setId(String id) {
14 | this.id = id;
15 | }
16 | public String getJsonrpc() {
17 | return jsonrpc;
18 | }
19 | public void setJsonrpc(String jsonrpc) {
20 | this.jsonrpc = jsonrpc;
21 | }
22 | public DaemonResult getResult() {
23 | return result;
24 | }
25 | public void setResult(DaemonResult result) {
26 | this.result = result;
27 | }
28 |
29 | }
--------------------------------------------------------------------------------
/android/src/com/jw/lightwallet/android/AndroidLauncher.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.android;
2 |
3 | import android.os.Bundle;
4 |
5 | import com.badlogic.gdx.backends.android.AndroidApplication;
6 | import com.badlogic.gdx.backends.android.AndroidApplicationConfiguration;
7 | import com.jw.lightwallet.LightWallet;
8 |
9 | public class AndroidLauncher extends AndroidApplication {
10 | @Override
11 | protected void onCreate (Bundle savedInstanceState) {
12 | super.onCreate(savedInstanceState);
13 | AndroidApplicationConfiguration config = new AndroidApplicationConfiguration();
14 | initialize(new LightWallet(), config);
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/wallet/BalanceResponse.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.wallet;
2 |
3 | public class BalanceResponse {
4 |
5 | String id;
6 | String jsonrpc;
7 | BalanceResult result;
8 |
9 | public String getId() {
10 | return id;
11 | }
12 | public void setId(String id) {
13 | this.id = id;
14 | }
15 | public String getJsonrpc() {
16 | return jsonrpc;
17 | }
18 | public void setJsonrpc(String jsonrpc) {
19 | this.jsonrpc = jsonrpc;
20 | }
21 | public BalanceResult getResult() {
22 | return result;
23 | }
24 | public void setResult(BalanceResult result) {
25 | this.result = result;
26 | }
27 |
28 |
29 | }
30 |
--------------------------------------------------------------------------------
/html/src/com/jw/lightwallet/GdxDefinition.gwt.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/utils/Constants.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.utils;
2 |
3 | public class Constants {
4 | public static final int DESKTOP_WIDTH = 800;
5 | public static final int DESKTOP_HEIGHT = 600;
6 |
7 | public static final float WORLD_WIDTH = 800;
8 | public static final float WORLD_HEIGHT = 600;
9 |
10 | //public static final String moneroclubrpc = "http://node.moneroclub.com/json_rpc:8880";
11 | //public static final String moneroclubdmn = "http://node.moneroclub.com:8880";
12 | public static final String moneroclubrpc = "http://node.moneroworld.com/json_rpc:18081";
13 | public static final String moneroclubdmn = "http://node.moneroworld.com:18081";
14 | }
15 |
--------------------------------------------------------------------------------
/html/src/com/jw/lightwallet/client/HtmlLauncher.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.client;
2 |
3 | import com.badlogic.gdx.ApplicationListener;
4 | import com.badlogic.gdx.backends.gwt.GwtApplication;
5 | import com.badlogic.gdx.backends.gwt.GwtApplicationConfiguration;
6 | import com.jw.lightwallet.LightWallet;
7 |
8 | public class HtmlLauncher extends GwtApplication {
9 |
10 | @Override
11 | public GwtApplicationConfiguration getConfig () {
12 | return new GwtApplicationConfiguration(480, 320);
13 | }
14 |
15 | @Override
16 | public ApplicationListener getApplicationListener () {
17 | return new LightWallet();
18 | }
19 | }
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/utils/BalanceValues.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.utils;
2 |
3 | public class BalanceValues {
4 |
5 | long unlockedbalance;
6 | long balance;
7 | boolean checked;
8 |
9 | public boolean getChecked() {
10 | return checked;
11 | }
12 | public void setChecked(boolean checked) {
13 | this.checked = checked;
14 | }
15 | public Long getUnlockedbalance() {
16 | return unlockedbalance;
17 | }
18 | public void setUnlockedbalance(long unlockedbalance) {
19 | this.unlockedbalance = unlockedbalance;
20 | }
21 | public Long getBalance() {
22 | return balance;
23 | }
24 | public void setBalance(long balance) {
25 | this.balance = balance;
26 | }
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/html/src/com/jw/lightwallet/GdxDefinitionSuperdev.gwt.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/tx/TxResponse.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.tx;
2 |
3 | public class TxResponse {
4 |
5 | String id;
6 | String jsonrpc;
7 | TxResult result;
8 | TxError error;
9 |
10 |
11 | public String getId() {
12 | return id;
13 | }
14 | public void setId(String id) {
15 | this.id = id;
16 | }
17 | public String getJsonrpc() {
18 | return jsonrpc;
19 | }
20 | public void setJsonrpc(String jsonrpc) {
21 | this.jsonrpc = jsonrpc;
22 | }
23 | public TxResult getResult() {
24 | return result;
25 | }
26 | public void setResult(TxResult result) {
27 | this.result = result;
28 | }
29 | public TxError getError() {
30 | return error;
31 | }
32 | public void setError(TxError error) {
33 | this.error = error;
34 | }
35 |
36 |
37 |
38 | }
39 |
--------------------------------------------------------------------------------
/desktop/src/com/jw/lightwallet/desktop/DesktopLauncher.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.desktop;
2 |
3 | import com.badlogic.gdx.Files.FileType;
4 | import com.badlogic.gdx.backends.lwjgl.LwjglApplication;
5 | import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration;
6 | import com.jw.lightwallet.LightWallet;
7 | import com.jw.lightwallet.utils.Constants;
8 |
9 | public class DesktopLauncher {
10 | public static void main (String[] arg) {
11 | LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
12 | config.width = Constants.DESKTOP_WIDTH;
13 | config.height = Constants.DESKTOP_HEIGHT;
14 | config.title = "Monero LightWallet";
15 | config.addIcon("assets/icon32.png", FileType.Internal);
16 | new LwjglApplication(new LightWallet(), config);
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/android/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 |
14 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | ## Java
2 |
3 | *.class
4 | *.war
5 | *.ear
6 | hs_err_pid*
7 |
8 | ## GWT
9 | war/
10 | html/war/gwt_bree/
11 | html/gwt-unitCache/
12 | .apt_generated/
13 | html/war/WEB-INF/deploy/
14 | html/war/WEB-INF/classes/
15 | .gwt/
16 | gwt-unitCache/
17 | www-test/
18 | .gwt-tmp/
19 |
20 | ## Android Studio and Intellij and Android in general
21 | android/libs/armeabi/
22 | android/libs/armeabi-v7a/
23 | android/libs/x86/
24 | android/gen/
25 | .idea/
26 | *.ipr
27 | *.iws
28 | *.iml
29 | out/
30 | com_crashlytics_export_strings.xml
31 |
32 | ## Eclipse
33 | .classpath
34 | .project
35 | .metadata
36 | **/bin/
37 | tmp/
38 | *.tmp
39 | *.bak
40 | *.swp
41 | *~.nib
42 | local.properties
43 | .settings/
44 | .loadpath
45 | .externalToolBuilders/
46 | *.launch
47 |
48 | ## NetBeans
49 | **/nbproject/private/
50 | build/
51 | nbbuild/
52 | dist/
53 | nbdist/
54 | nbactions.xml
55 | nb-configuration.xml
56 |
57 | ## Gradle
58 |
59 | .gradle
60 | gradle-app.setting
61 | build/
62 |
63 | ## OS Specific
64 | .DS_Store
65 |
66 | ## log files
67 | desktop/simplewallet.log
68 | desktop/m*
69 | desktop/lightwallet.conf
70 |
71 |
72 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/screens/HistoryView.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.screens;
2 |
3 | import com.badlogic.gdx.scenes.scene2d.ui.Label;
4 | import com.badlogic.gdx.scenes.scene2d.ui.ScrollPane;
5 | import com.badlogic.gdx.scenes.scene2d.ui.Table;
6 | import com.jw.lightwallet.LightWallet;
7 |
8 | public class HistoryView {
9 |
10 | LightWallet game;
11 |
12 | Table historylayout;
13 |
14 | ScrollPane scroller;
15 | Table container;
16 |
17 | int padvalue;
18 |
19 |
20 | public HistoryView (LightWallet game) {
21 | this.game = game;
22 |
23 | historylayout = new Table();
24 | padvalue = 15;
25 |
26 | container = new Table();
27 | scroller = new ScrollPane(container, game.uiSkin);
28 |
29 |
30 | historylayout.add(new Label("Transaction history (click to copy txid)", game.uiSkin)).row();
31 | historylayout.add(new Label("Type | Amount | Transaction ID", game.uiSkin)).row();
32 | historylayout.add(scroller);
33 |
34 |
35 | }
36 |
37 |
38 | public Table getContainer() {
39 | return container;
40 | }
41 |
42 |
43 | public void setContainer(Table container) {
44 | this.container = container;
45 | }
46 |
47 |
48 |
49 | }
50 |
--------------------------------------------------------------------------------
/html/webapp/styles.css:
--------------------------------------------------------------------------------
1 | canvas {
2 | cursor: default;
3 | outline: none;
4 | }
5 |
6 | body {
7 | background-color: #222222;
8 | }
9 |
10 | .superdev {
11 | color: rgb(37,37,37);
12 | text-shadow: 0px 1px 1px rgba(250,250,250,0.1);
13 | font-size: 50pt;
14 | display: block;
15 | position: relative;
16 | text-decoration: none;
17 | background-color: rgb(83,87,93);
18 | box-shadow: 0px 3px 0px 0px rgb(34,34,34),
19 | 0px 7px 10px 0px rgb(17,17,17),
20 | inset 0px 1px 1px 0px rgba(250, 250, 250, .2),
21 | inset 0px -12px 35px 0px rgba(0, 0, 0, .5);
22 | width: 70px;
23 | height: 70px;
24 | border: 0;
25 | border-radius: 35px;
26 | text-align: center;
27 | line-height: 68px;
28 | }
29 |
30 | .superdev:active {
31 | box-shadow: 0px 0px 0px 0px rgb(34,34,34),
32 | 0px 3px 7px 0px rgb(17,17,17),
33 | inset 0px 1px 1px 0px rgba(250, 250, 250, .2),
34 | inset 0px -10px 35px 5px rgba(0, 0, 0, .5);
35 | background-color: rgb(83,87,93);
36 | top: 3px;
37 | color: #fff;
38 | text-shadow: 0px 0px 3px rgb(250,250,250);
39 | }
40 |
41 | .superdev:hover {
42 | background-color: rgb(100,100,100);
43 | }
44 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/utils/WalletValues.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.utils;
2 |
3 | public class WalletValues {
4 |
5 | String name;
6 | String pw;
7 | String address;
8 | String viewkey;
9 | String seed;
10 | String node;
11 | String useragent;
12 |
13 |
14 | public String getName() {
15 | return name;
16 | }
17 | public void setName(String name) {
18 | this.name = name;
19 | }
20 | public String getPw() {
21 | return pw;
22 | }
23 | public void setPw(String pw) {
24 | this.pw = pw;
25 | }
26 | public String getAddress() {
27 | return address;
28 | }
29 | public void setAddress(String address) {
30 | this.address = address;
31 | }
32 | public String getViewkey() {
33 | return viewkey;
34 | }
35 | public void setViewkey(String viewkey) {
36 | this.viewkey = viewkey;
37 | }
38 | public String getSeed() {
39 | return seed;
40 | }
41 | public void setSeed(String seed) {
42 | this.seed = seed;
43 | }
44 | public String getNode() {
45 | return node;
46 | }
47 | public void setNode(String node) {
48 | this.node = node;
49 | }
50 | public String getUserAgent() {
51 | return useragent;
52 | }
53 | public void setUserAgent(String useragent) {
54 | this.useragent = useragent;
55 | }
56 |
57 |
58 | }
59 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/utils/DaemonValues.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.utils;
2 |
3 | import com.badlogic.gdx.Gdx;
4 | import com.jw.lightwallet.LightWallet;
5 |
6 | public class DaemonValues {
7 |
8 | int blockheight;
9 | long diff;
10 | long hashrate;
11 | long lastblocktime;
12 | long lastblockreward;
13 | String status;
14 |
15 |
16 | public int getBlockheight() {
17 | return blockheight;
18 | }
19 | public void setBlockheight(int blockheight) {
20 | this.blockheight = blockheight;
21 | }
22 |
23 | public long getDiff() {
24 | return diff;
25 | }
26 | public void setDiff(long l) {
27 | this.diff = l;
28 | this.hashrate = l/120;
29 | }
30 | public float getHashrate() {
31 | return hashrate/1e6f;
32 | }
33 |
34 | public long getLastblocktime() {
35 | return lastblocktime;
36 | }
37 | public void setLastblocktime(long lastblocktime) {
38 | this.lastblocktime = lastblocktime;
39 | }
40 |
41 | public long getLastblockreward() {
42 | return lastblockreward;
43 | }
44 | public void setLastblockreward(long lastblockreward) {
45 | this.lastblockreward = lastblockreward;
46 | }
47 |
48 | public String getStatus() {
49 | return status;
50 | }
51 | public void setStatus(String status) {
52 | this.status = status;
53 | }
54 |
55 | }
56 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/utils/Tx.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.utils;
2 |
3 |
4 | public class Tx {
5 |
6 | public static enum Type {SPENT, RECEIVED};
7 | public Type type;
8 | public double amount;
9 | public String txid;
10 |
11 | public Tx() {
12 | type = null;
13 | amount = 0;
14 | txid = null;
15 |
16 | }
17 |
18 | public static Tx StringToTx(String txstring) {
19 | Tx tx = new Tx();
20 |
21 | // Get tx type
22 | if (txstring.split(" money")[0].split(" ")[2].equals("Received")) {
23 | tx.type = Type.RECEIVED;
24 | }
25 | else {tx.type = Type.SPENT;}
26 |
27 | // Get tx amount
28 | tx.amount = Double.parseDouble(txstring.split(": ")[1].split(",")[0]);
29 |
30 | // Get tx id
31 | String temptxid = txstring.split("<")[1];
32 | tx.txid = temptxid.substring(0, temptxid.length()-1);
33 |
34 | return tx;
35 | }
36 |
37 | public Type getType() {
38 | return type;
39 | }
40 |
41 | public void setType(Type type) {
42 | this.type = type;
43 | }
44 |
45 | public double getAmount() {
46 | return amount;
47 | }
48 |
49 | public void setAmount(long amount) {
50 | this.amount = amount;
51 | }
52 |
53 | public String getTxid() {
54 | return txid;
55 | }
56 |
57 | public void setTxid(String txid) {
58 | this.txid = txid;
59 | }
60 |
61 |
62 | }
63 |
--------------------------------------------------------------------------------
/desktop/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: "java"
2 |
3 | sourceCompatibility = 1.7
4 | sourceSets.main.java.srcDirs = [ "src/" ]
5 |
6 | project.ext.mainClassName = "com.jw.lightwallet.desktop.DesktopLauncher"
7 | project.ext.assetsDir = new File("../android/assets");
8 |
9 | task run(dependsOn: classes, type: JavaExec) {
10 | main = project.mainClassName
11 | classpath = sourceSets.main.runtimeClasspath
12 | standardInput = System.in
13 | workingDir = project.assetsDir
14 | ignoreExitValue = true
15 | }
16 |
17 | task dist(type: Jar) {
18 | from files(sourceSets.main.output.classesDir)
19 | from files(sourceSets.main.output.resourcesDir)
20 | from {configurations.compile.collect {zipTree(it)}}
21 | from files(project.assetsDir);
22 |
23 | manifest {
24 | attributes 'Main-Class': project.mainClassName
25 | }
26 | }
27 |
28 | dist.dependsOn classes
29 |
30 | eclipse {
31 | project {
32 | name = appName + "-desktop"
33 | linkedResource name: 'assets', type: '2', location: 'PARENT-1-PROJECT_LOC/android/assets'
34 | }
35 | }
36 |
37 | task afterEclipseImport(description: "Post processing after project generation", group: "IDE") {
38 | doLast {
39 | def classpath = new XmlParser().parse(file(".classpath"))
40 | new Node(classpath, "classpathentry", [ kind: 'src', path: 'assets' ]);
41 | def writer = new FileWriter(file(".classpath"))
42 | def printer = new XmlNodePrinter(new PrintWriter(writer))
43 | printer.setPreserveWhitespace(true)
44 | printer.print(classpath)
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/html/webapp/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | lightwallet
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 | ↻
13 |
14 |
15 |
16 |
17 |
32 |
33 |
--------------------------------------------------------------------------------
/html/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: "java"
2 | apply plugin: "jetty"
3 |
4 | gwt {
5 | gwtVersion='2.6.0' // Should match the gwt version used for building the gwt backend
6 | maxHeapSize="1G" // Default 256m is not enough for gwt compiler. GWT is HUNGRY
7 | minHeapSize="1G"
8 |
9 | src = files(file("src/")) // Needs to be in front of "modules" below.
10 | modules 'com.jw.lightwallet.GdxDefinition'
11 | devModules 'com.jw.lightwallet.GdxDefinitionSuperdev'
12 | project.webAppDirName = 'webapp'
13 |
14 | compiler {
15 | strict = true;
16 | enableClosureCompiler = true;
17 | disableCastChecking = true;
18 | }
19 | }
20 |
21 | task draftRun(type: JettyRunWar) {
22 | dependsOn draftWar
23 | dependsOn.remove('war')
24 | webApp=draftWar.archivePath
25 | daemon=true
26 | }
27 |
28 | task superDev(type: de.richsource.gradle.plugins.gwt.GwtSuperDev) {
29 | dependsOn draftRun
30 | doFirst {
31 | gwt.modules = gwt.devModules
32 | }
33 | }
34 |
35 | task dist(dependsOn: [clean, compileGwt]) {
36 | doLast {
37 | file("build/dist").mkdirs()
38 | copy {
39 | from "build/gwt/out"
40 | into "build/dist"
41 | }
42 | copy {
43 | from "webapp"
44 | into "build/dist"
45 | }
46 | copy {
47 | from "war"
48 | into "build/dist"
49 | }
50 | }
51 | }
52 |
53 | draftWar {
54 | from "war"
55 | }
56 |
57 | task addSource << {
58 | sourceSets.main.compileClasspath += files(project(':core').sourceSets.main.allJava.srcDirs)
59 | }
60 |
61 | tasks.compileGwt.dependsOn(addSource)
62 | tasks.draftCompileGwt.dependsOn(addSource)
63 |
64 | sourceCompatibility = 1.6
65 | sourceSets.main.java.srcDirs = [ "src/" ]
66 |
67 |
68 | eclipse.project {
69 | name = appName + "-html"
70 | }
71 |
--------------------------------------------------------------------------------
/android/proguard-project.txt:
--------------------------------------------------------------------------------
1 | # To enable ProGuard in your project, edit project.properties
2 | # to define the proguard.config property as described in that file.
3 | #
4 | # Add project specific ProGuard rules here.
5 | # By default, the flags in this file are appended to flags specified
6 | # in ${sdk.dir}/tools/proguard/proguard-android.txt
7 | # You can edit the include path and order by changing the ProGuard
8 | # include property in project.properties.
9 | #
10 | # For more details, see
11 | # http://developer.android.com/guide/developing/tools/proguard.html
12 |
13 | # Add any project specific keep options here:
14 |
15 | # If your project uses WebView with JS, uncomment the following
16 | # and specify the fully qualified class name to the JavaScript interface
17 | # class:
18 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
19 | # public *;
20 | #}
21 |
22 | -verbose
23 |
24 | -dontwarn android.support.**
25 | -dontwarn com.badlogic.gdx.backends.android.AndroidFragmentApplication
26 | -dontwarn com.badlogic.gdx.utils.GdxBuild
27 | -dontwarn com.badlogic.gdx.physics.box2d.utils.Box2DBuild
28 | -dontwarn com.badlogic.gdx.jnigen.BuildTarget*
29 | -dontwarn com.badlogic.gdx.graphics.g2d.freetype.FreetypeBuild
30 |
31 | -keep class com.badlogic.gdx.controllers.android.AndroidControllers
32 |
33 | -keepclassmembers class com.badlogic.gdx.backends.android.AndroidInput* {
34 | (com.badlogic.gdx.Application, android.content.Context, java.lang.Object, com.badlogic.gdx.backends.android.AndroidApplicationConfiguration);
35 | }
36 |
37 | -keepclassmembers class com.badlogic.gdx.physics.box2d.World {
38 | boolean contactFilter(long, long);
39 | void beginContact(long);
40 | void endContact(long);
41 | void preSolve(long, long);
42 | void postSolve(long, long);
43 | boolean reportFixture(long);
44 | float reportRayFixture(long, float, float, float, float, float);
45 | }
46 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/wallet/WalletSaveRPC.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.wallet;
2 |
3 | import com.badlogic.gdx.Gdx;
4 | import com.badlogic.gdx.Net.HttpMethods;
5 | import com.badlogic.gdx.Net.HttpRequest;
6 | import com.badlogic.gdx.Net.HttpResponse;
7 | import com.badlogic.gdx.Net.HttpResponseListener;
8 | import com.badlogic.gdx.scenes.scene2d.ui.Label;
9 | import com.badlogic.gdx.scenes.scene2d.ui.Label.LabelStyle;
10 | import com.jw.lightwallet.LightWallet;
11 |
12 |
13 | public class WalletSaveRPC {
14 | LightWallet game;
15 | public String swaddress;
16 | String response;
17 | String store;
18 |
19 | public WalletSaveRPC (LightWallet game) {
20 | this.game = game;
21 | swaddress = "http://localhost:19091/json_rpc";
22 | store = "{\"jsonrpc\":\"2.0\",\"id\":\"test\",\"method\":\"store\",\"params\":[]}";
23 | // store = "{\"jsonrpc\":\"2.0\",\"id\":\"test\",\"user-agent\":" + game.walletvalues.getUserAgent() + ",\"method\":\"store\",\"params\":[]}";
24 | }
25 |
26 | public void trysave (final Label savestatuslabel) {
27 | HttpRequest httpGet = new HttpRequest(HttpMethods.POST);
28 | httpGet.setUrl(swaddress);
29 | httpGet.setContent(store);
30 | httpGet.setHeader("User-Agent", game.walletvalues.getUserAgent());
31 |
32 | Gdx.net.sendHttpRequest (httpGet, new HttpResponseListener() {
33 | public void handleHttpResponse(HttpResponse httpResponse) {
34 | response = httpResponse.getResultAsString();
35 | // System.out.print("Save response: " + response);
36 | savestatuslabel.setText("Successfully saved");
37 | savestatuslabel.setStyle(game.uiSkin.get("greenlabel", LabelStyle.class));
38 | }
39 |
40 | public void failed(Throwable t) {
41 | response = "failed";
42 | savestatuslabel.setText("Save failed");
43 | savestatuslabel.setStyle(game.uiSkin.get("redlabel", LabelStyle.class));
44 | }
45 |
46 | @Override
47 | public void cancelled() {
48 | // TODO Auto-generated method stub
49 | }
50 | });
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/daemon/BlockHeader.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.daemon;
2 |
3 | public class BlockHeader {
4 |
5 | int depth;
6 | long difficulty;
7 | String hash;
8 | int height;
9 | int major_version;
10 | int minor_version;
11 | int nonce;
12 | boolean orphan_status;
13 | String prev_hash;
14 | long reward;
15 | long timestamp;
16 |
17 |
18 | public int getDepth() {
19 | return depth;
20 | }
21 | public void setDepth(int depth) {
22 | this.depth = depth;
23 | }
24 | public long getDifficulty() {
25 | return difficulty;
26 | }
27 | public void setDifficulty(int difficulty) {
28 | System.out.println("Diff is now" + difficulty);
29 | this.difficulty = difficulty;
30 | }
31 | public String getHash() {
32 | return hash;
33 | }
34 | public void setHash(String hash) {
35 | this.hash = hash;
36 | }
37 | public int getHeight() {
38 | return height;
39 | }
40 | public void setHeight(int height) {
41 | this.height = height;
42 | }
43 | public int getMajor_version() {
44 | return major_version;
45 | }
46 | public void setMajor_version(int major_version) {
47 | this.major_version = major_version;
48 | }
49 | public int getMinor_version() {
50 | return minor_version;
51 | }
52 | public void setMinor_version(int minor_version) {
53 | this.minor_version = minor_version;
54 | }
55 | public int getNonce() {
56 | return nonce;
57 | }
58 | public void setNonce(int nonce) {
59 | this.nonce = nonce;
60 | }
61 | public boolean isOrphan_status() {
62 | return orphan_status;
63 | }
64 | public void setOrphan_status(boolean orphan_status) {
65 | this.orphan_status = orphan_status;
66 | }
67 | public String getPrev_hash() {
68 | return prev_hash;
69 | }
70 | public void setPrev_hash(String prev_hash) {
71 | this.prev_hash = prev_hash;
72 | }
73 | public long getReward() {
74 | return reward;
75 | }
76 | public void setReward(long reward) {
77 | this.reward = reward;
78 | }
79 | public long getTimestamp() {
80 | return timestamp;
81 | }
82 | public void setTimestamp(long timestamp) {
83 | this.timestamp = timestamp;
84 | }
85 |
86 |
87 |
88 | }
89 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/daemon/DaemonRPC.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.daemon;
2 |
3 | import com.badlogic.gdx.Gdx;
4 | import com.badlogic.gdx.Net.HttpMethods;
5 | import com.badlogic.gdx.Net.HttpRequest;
6 | import com.badlogic.gdx.Net.HttpResponse;
7 | import com.badlogic.gdx.Net.HttpResponseListener;
8 | import com.google.gson.Gson;
9 | import com.jw.lightwallet.daemon.DaemonResponse;
10 | import com.jw.lightwallet.utils.DaemonValues;
11 |
12 | public class DaemonRPC {
13 | public String address;
14 | String response;
15 | String getlastblock;
16 | Gson gson;
17 | DaemonResponse daemonresponse = new DaemonResponse();
18 |
19 | public DaemonRPC () {
20 | // address = "http://node.moneroclub.com:8880/json_rpc";
21 | // address = "http://localhost:18081/json_rpc";
22 | getlastblock = "{\"jsonrpc\":\"2.0\",\"id\":\"test\",\"method\":\"getlastblockheader\",\"params\":[]}";
23 | }
24 |
25 | public void getinfo (final DaemonValues daemonvalues, String nodeaddress) {
26 | HttpRequest httpGet = new HttpRequest(HttpMethods.POST);
27 | httpGet.setUrl(nodeaddress + "/json_rpc");
28 | httpGet.setContent(getlastblock);
29 |
30 | Gdx.net.sendHttpRequest (httpGet, new HttpResponseListener() {
31 | public void handleHttpResponse(HttpResponse httpResponse) {
32 | response = httpResponse.getResultAsString();
33 | // System.out.println("1st time response" + response);
34 | daemonvalues.setBlockheight(Integer.parseInt(response.split("height\": ")[1].split(",")[0]));
35 | daemonvalues.setDiff(Long.parseLong(response.split("difficulty\": ")[1].split(",")[0]));
36 | daemonvalues.setLastblocktime(Long.parseLong(response.split("difficulty\": ")[1].split(",")[0]));
37 | daemonvalues.setLastblockreward(Long.parseLong(response.split("reward\": ")[1].split(",")[0]));
38 | daemonvalues.setStatus("OK");
39 | }
40 |
41 | public void failed(Throwable t) {
42 | response = "failed";
43 | System.out.print("Failed response status is: " + response);
44 | //do stuff here based on the failed attempt
45 | }
46 |
47 | @Override
48 | public void cancelled() {
49 | // TODO Auto-generated method stub
50 | }
51 | });
52 | }
53 | }
54 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/screens/AbstractScreen.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.screens;
2 |
3 | import com.badlogic.gdx.Gdx;
4 | import com.badlogic.gdx.Screen;
5 | import com.badlogic.gdx.graphics.GL20;
6 | import com.badlogic.gdx.graphics.g2d.BitmapFont;
7 | import com.jw.lightwallet.LightWallet;
8 |
9 | public class AbstractScreen implements Screen {
10 | protected LightWallet game;
11 | protected BitmapFont font;
12 | protected int w;
13 | protected int h;
14 | protected float aspect;
15 | protected float accum5s;
16 | protected float accum10s;
17 | protected float accum60s;
18 |
19 | public AbstractScreen (final LightWallet game) {
20 | this.game = game;
21 | this.font = new BitmapFont(Gdx.files.internal("assets/fonts/bauchaomaicha.fnt"));
22 | this.w = Gdx.graphics.getWidth();
23 | this.h = Gdx.graphics.getHeight();
24 | this.aspect = w/h;
25 | this.accum5s = 0;
26 | this.accum10s = 0;
27 | this.accum60s = 0;
28 | }
29 |
30 | @Override
31 | public void show() {
32 | // TODO Auto-generated method stub
33 | Gdx.app.log(LightWallet.LOG, "Showing screen: " + this.getClass().getName());
34 | }
35 |
36 | @Override
37 | public void render(float delta) {
38 | Gdx.gl.glClearColor(0, 0, 0, 1);
39 | Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT);
40 | accum5s = accum5s + delta;
41 | accum10s = accum10s + delta;
42 | accum60s = accum60s + delta;
43 | }
44 |
45 | @Override
46 | public void resize(int width, int height) {
47 | // TODO Auto-generated method stub
48 | Gdx.app.log(LightWallet.LOG, "Resizing screen " + this.getClass().getName() + " to " + width + ", " + height);
49 | }
50 |
51 | @Override
52 | public void pause() {
53 | // TODO Auto-generated method stub
54 | Gdx.app.log(LightWallet.LOG, "Pausing screen: " + this.getClass().getName());
55 | }
56 |
57 | @Override
58 | public void resume() {
59 | // TODO Auto-generated method stub
60 | Gdx.app.log(LightWallet.LOG, "Resuming screen: " + this.getClass().getName());
61 | }
62 |
63 | @Override
64 | public void hide() {
65 | // TODO Auto-generated method stub
66 | Gdx.app.log(LightWallet.LOG, "Hiding screen: " + this.getClass().getName());
67 | }
68 |
69 | @Override
70 | public void dispose() {
71 | // TODO Auto-generated method stub
72 | Gdx.app.log(LightWallet.LOG, "Disposing screen: " + this.getClass().getName());
73 | }
74 |
75 | }
76 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # LightWallet GUI
2 | **Update: 2017-01-07 LightWallet is no longer being maintained, and is expected to stop working after the upcoming hardfork enabling RingCT. Please use the official GUI for now (which also works with a remote node), or wait for another third party GUI by Jaxx or someone else to be released soon.**
3 |
4 | This is a GUI frontend that runs on top of simplewallet (in RPC mode). It is designed to work with a remote bitmonerod node by default, so that it can function as a lightweight wallet for most users. By default it uses Atrides open node at http://node.moneroworld.com:18081, but you can change the node it uses to a local node during setup or at any launch; to use a local bitmonerod instance set it as http://localhost:18081.
5 |
6 | **This program is an alpha version, and although I don't think there is really any way to screw up your wallet, please exercise some modicum of caution.**
7 |
8 | ## Installation
9 | ### Windows, Linux, and Mac
10 | The requirements for running the program using the jar file release is a java virtual machine installed v1.7+, and monero-wallet-cli v0.10+ in the same directory. If you also want to run a local daemon you'll monerod.exe/monerod binary. The wallet and daemon files can be downloaded here: https://github.com/monero-project/bitmonero/releases
11 |
12 | If you're using the binary LightWallet.exe, you still need to have monero-wallet-cli.exe in the same directory.
13 |
14 | ## Running
15 | It should be OK to launch the program with an instance of monerod and/or monero-wallet-cli running.
16 |
17 | On the initial run, it will prompt you to create a new wallet or to import one by typing/copying in the path of the keys file or importing a 25 word mnemonic seed. This will create several files in the same directory as LightWallet and monero-wallet-cli, including lightwallet.conf. If you ever want to create or import a new wallet, simply delete lightwallet.conf.
18 |
19 | ## Known issues
20 | If you manage to crash the program, you will probably get an instance of monero-wallet-cli(.exe) hanging around, so to get rid of it you will need to go into the task manager processes tab and end the monero-wallet-cli process on windows, "ps -A | grep monero-wallet-cli" to get PID and then "kill PID" or "killall monero-wallet-cli" on linux, or restart your computer.
21 |
22 | ## Future Work
23 | Transaction history has been disabled for the time being. If you want to parse your tx history check monero-wallet-cli.log in the same directory.
24 |
--------------------------------------------------------------------------------
/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if "%DEBUG%" == "" @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if "%OS%"=="Windows_NT" setlocal
10 |
11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
12 | set DEFAULT_JVM_OPTS=
13 |
14 | set DIRNAME=%~dp0
15 | if "%DIRNAME%" == "" set DIRNAME=.
16 | set APP_BASE_NAME=%~n0
17 | set APP_HOME=%DIRNAME%
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if "%ERRORLEVEL%" == "0" goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:"=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist "%JAVA_EXE%" goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windowz variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 | if "%@eval[2+2]" == "4" goto 4NT_args
53 |
54 | :win9xME_args
55 | @rem Slurp the command line arguments.
56 | set CMD_LINE_ARGS=
57 | set _SKIP=2
58 |
59 | :win9xME_args_slurp
60 | if "x%~1" == "x" goto execute
61 |
62 | set CMD_LINE_ARGS=%*
63 | goto execute
64 |
65 | :4NT_args
66 | @rem Get arguments from the 4NT Shell from JP Software
67 | set CMD_LINE_ARGS=%$
68 |
69 | :execute
70 | @rem Setup the command line
71 |
72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
73 |
74 | @rem Execute Gradle
75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
76 |
77 | :end
78 | @rem End local scope for the variables with windows NT shell
79 | if "%ERRORLEVEL%"=="0" goto mainEnd
80 |
81 | :fail
82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
83 | rem the _cmd.exe /c_ return code!
84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
85 | exit /b 1
86 |
87 | :mainEnd
88 | if "%OS%"=="Windows_NT" endlocal
89 |
90 | :omega
91 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/LightWallet.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet;
2 |
3 | import java.io.BufferedReader;
4 | import java.io.File;
5 | import java.io.FileReader;
6 | import java.io.IOException;
7 |
8 | import com.badlogic.gdx.Game;
9 | import com.badlogic.gdx.Gdx;
10 | import com.badlogic.gdx.scenes.scene2d.ui.Skin;
11 | import com.jw.lightwallet.screens.PasswordScreen;
12 | import com.jw.lightwallet.screens.WizardScreen;
13 | import com.jw.lightwallet.utils.WalletValues;
14 |
15 | public class LightWallet extends Game {
16 |
17 | public static final String LOG = LightWallet.class.getSimpleName(); // Logging constant
18 | public Skin uiSkin;
19 |
20 | public String dir;
21 | public String os;
22 | public String simplewalletloc;
23 |
24 | public WalletValues walletvalues;
25 |
26 | @Override
27 | public void create () {
28 |
29 | // Object to store wallet values
30 | walletvalues = new WalletValues();
31 |
32 | // Get directory where program launched
33 | dir = System.getProperty("user.dir");
34 | os = System.getProperty("os.name");
35 |
36 | if (os.contains("Windows")) {
37 | simplewalletloc = dir + "\\" + "monero-wallet-cli.exe";
38 | } else {
39 | simplewalletloc = dir + "/" + "monero-wallet-cli";
40 | }
41 | System.out.println(simplewalletloc);
42 |
43 | // Initialize logger and user interface skin
44 | Gdx.app.log(LightWallet.LOG, "Launching application in " + dir + " on " + os);
45 | uiSkin = new Skin(Gdx.files.internal("assets/skin/uiskin.json"));
46 |
47 | // Check if config file exists, if not launch setup wizard
48 | File f = new File("lightwallet.conf");
49 |
50 | if(f.exists() && !f.isDirectory()) {
51 | try (BufferedReader br = new BufferedReader(new FileReader(f))) {
52 | String line;
53 | while ((line = br.readLine()) != null) {
54 | if (line.contains("name: ")) {walletvalues.setName(line.split("name: ")[1]);}
55 | if (line.contains("Wallet address: ")) {walletvalues.setAddress(line.split("address: ")[1]);}
56 | if (line.contains("view key: ")) {walletvalues.setViewkey(line.split("view key: ")[1]);}
57 | if (line.contains("Node address: ")) {walletvalues.setNode(line.split("address: ")[1]);}
58 | if (line.contains("User agent: ")) {walletvalues.setUserAgent(line.split("User agent: ")[1]);}
59 | }
60 | } catch (IOException e) {
61 | // TODO Auto-generated catch block
62 | e.printStackTrace();
63 | }
64 | Gdx.app.log(LightWallet.LOG, "Node address on startup is: " + walletvalues.getAddress());
65 | setScreen(new PasswordScreen(this));
66 | }
67 |
68 | else {setScreen(new WizardScreen(this));}
69 |
70 | }
71 |
72 |
73 | }
74 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/wallet/BalanceRPC.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.wallet;
2 |
3 | import com.badlogic.gdx.Gdx;
4 | import com.badlogic.gdx.Net.HttpMethods;
5 | import com.badlogic.gdx.Net.HttpRequest;
6 | import com.badlogic.gdx.Net.HttpResponse;
7 | import com.badlogic.gdx.Net.HttpResponseListener;
8 | import com.google.gson.Gson;
9 | import com.jw.lightwallet.utils.BalanceValues;
10 | import com.jw.lightwallet.LightWallet;
11 |
12 |
13 |
14 | public class BalanceRPC {
15 | LightWallet game;
16 | public String swaddress;
17 | String response;
18 | String getbalance;
19 |
20 | public BalanceRPC (LightWallet game) {
21 | this.game = game;
22 | swaddress = "http://localhost:19091/json_rpc";
23 | getbalance = "{\"jsonrpc\":\"2.0\",\"id\":\"test\",\"method\":\"getbalance\",\"params\":[]}";
24 | }
25 |
26 | public void getinfo (final BalanceValues balancevalues) {
27 | HttpRequest httpGet = new HttpRequest(HttpMethods.POST);
28 | httpGet.setUrl(swaddress);
29 | httpGet.setContent(getbalance);
30 | httpGet.setHeader("User-Agent", game.walletvalues.getUserAgent());
31 |
32 | Gdx.net.sendHttpRequest (httpGet, new HttpResponseListener() {
33 | public void handleHttpResponse(HttpResponse httpResponse) {
34 | response = httpResponse.getResultAsString();
35 | // Gdx.app.log(LightWallet.LOG, "Checked: " + balancevalues.getChecked());
36 | // Gdx.app.log(LightWallet.LOG, "Balance is: " + response);
37 | // BalanceResponse balanceresponse = new Gson().fromJson(response, BalanceResponse.class);
38 | // balancevalues.setBalance(balanceresponse.getResult().getBalance());
39 | // balancevalues.setUnlockedbalance(balanceresponse.getResult().getUnlockedbalance());
40 | // Gdx.app.log(LightWallet.LOG, response.split("\"balance\": ")[1].split(",")[0]);
41 | balancevalues.setBalance(Long.parseLong(response.split("\"balance\": ")[1].split(",")[0]));
42 | // Gdx.app.log(LightWallet.LOG, response.split("unlocked_balance\": ")[1].split("}")[0].replaceAll("\\s+",""));
43 | balancevalues.setUnlockedbalance(Long.parseLong(response.split("unlocked_balance\": ")[1].split("}")[0].replaceAll("\\s+","")));
44 | Gdx.app.log(LightWallet.LOG, "Setting checked true.");
45 | balancevalues.setChecked(true);
46 | }
47 |
48 | public void failed(Throwable t) {
49 | response = "failed";
50 | Gdx.app.log(LightWallet.LOG, "Failed - setting checked false.");
51 | Gdx.app.log(LightWallet.LOG, t.getMessage());
52 | balancevalues.setChecked(false);
53 | }
54 |
55 | @Override
56 | public void cancelled() {
57 | // TODO Auto-generated method stub
58 | }
59 | });
60 | }
61 | }
62 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/screens/DaemonView.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.screens;
2 |
3 | import com.badlogic.gdx.Gdx;
4 | import com.badlogic.gdx.scenes.scene2d.ui.Label;
5 | import com.badlogic.gdx.scenes.scene2d.ui.Label.LabelStyle;
6 | import com.badlogic.gdx.scenes.scene2d.ui.Skin;
7 | import com.badlogic.gdx.scenes.scene2d.ui.Table;
8 | import com.jw.lightwallet.LightWallet;
9 | import com.jw.lightwallet.utils.DaemonValues;
10 |
11 | import java.text.DecimalFormat;
12 |
13 | public class DaemonView {
14 |
15 | LightWallet game;
16 |
17 | Table daemonlayout;
18 |
19 | Label nodelabel;
20 | Label nodevalue;
21 | Label statuslabel;
22 | Label statusvalue;
23 | Label heightlabel;
24 | Label heightvalue;
25 | Label hashratelabel;
26 | Label hashratevalue;
27 | Label timelabel;
28 | Label timevalue;
29 | Label rewardlabel;
30 | Label rewardvalue;
31 |
32 | int padvalue;
33 |
34 |
35 | public DaemonView (final LightWallet game) {
36 |
37 | this.game = game;
38 |
39 | daemonlayout = new Table();
40 | padvalue = 15;
41 |
42 |
43 | nodelabel = new Label("Node address: ", game.uiSkin);
44 | nodevalue = new Label(null, game.uiSkin);
45 | daemonlayout.add(nodelabel).pad(padvalue);
46 | daemonlayout.add(nodevalue).pad(padvalue).row();
47 |
48 | statuslabel = new Label("Node status: ", game.uiSkin);
49 | statusvalue = new Label(null, game.uiSkin);
50 | daemonlayout.add(statuslabel).pad(padvalue);
51 | daemonlayout.add(statusvalue).pad(padvalue).row();
52 |
53 | heightlabel = new Label("Block height: ", game.uiSkin);
54 | heightvalue = new Label(null, game.uiSkin);
55 | daemonlayout.add(heightlabel).pad(padvalue);
56 | daemonlayout.add(heightvalue).pad(padvalue).row();
57 |
58 | hashratelabel = new Label("Network hashrate: ", game.uiSkin);
59 | hashratevalue = new Label(null, game.uiSkin);
60 | daemonlayout.add(hashratelabel).pad(padvalue);
61 | daemonlayout.add(hashratevalue).pad(padvalue).row();
62 |
63 | timelabel = new Label("Last block time: ", game.uiSkin);
64 | timevalue = new Label(null, game.uiSkin);
65 | daemonlayout.add(timelabel).pad(padvalue);
66 | daemonlayout.add(timevalue).pad(padvalue).row();
67 |
68 | rewardlabel = new Label("Last reward: ", game.uiSkin);
69 | rewardvalue = new Label(null, game.uiSkin);
70 | daemonlayout.add(rewardlabel).pad(padvalue);
71 | daemonlayout.add(rewardvalue).pad(padvalue);
72 |
73 | }
74 |
75 | public void Update(DaemonValues daemonvalues) {
76 | nodevalue.setText(game.walletvalues.getNode());
77 | statusvalue.setText(daemonvalues.getStatus());
78 | Gdx.app.log(LightWallet.LOG, "Status value is: " + statusvalue.getText());
79 | if (statusvalue.getText().toString().equals("OK")) {statusvalue.setStyle(game.uiSkin.get("greenlabel", LabelStyle.class));}
80 | heightvalue.setText(String.valueOf(daemonvalues.getBlockheight()));
81 | hashratevalue.setText(new DecimalFormat("##.##").format(daemonvalues.getHashrate()) + " Mh/s");
82 | timevalue.setText(String.valueOf(new java.util.Date(daemonvalues.getLastblocktime()*1000)));
83 | rewardvalue.setText(new DecimalFormat("##.##").format(daemonvalues.getLastblockreward()/1e12) + " XMR");
84 | }
85 |
86 | }
87 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/screens/WalletView.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.screens;
2 |
3 | import com.badlogic.gdx.Gdx;
4 | import com.badlogic.gdx.scenes.scene2d.InputEvent;
5 | import com.badlogic.gdx.scenes.scene2d.ui.Label;
6 | import com.badlogic.gdx.scenes.scene2d.ui.Table;
7 | import com.badlogic.gdx.scenes.scene2d.ui.TextButton;
8 | import com.badlogic.gdx.scenes.scene2d.utils.ClickListener;
9 | import com.jw.lightwallet.LightWallet;
10 | import com.jw.lightwallet.wallet.WalletSaveRPC;
11 |
12 | public class WalletView {
13 | LightWallet game;
14 | WalletSaveRPC walletsaverpc;
15 |
16 | Table walletlayout;
17 |
18 | Label namelabel;
19 | Label namevalue;
20 | TextButton addresslabel;
21 | Label addressvalue;
22 | Label synclabel;
23 | Label syncvalue;
24 | Label unlockedlabel;
25 | Label unlockedvalue;
26 | Label balancelabel;
27 | Label balancevalue;
28 | Label calcedlabel;
29 | Label calcedvalue;
30 | TextButton savewalletbtn;
31 | Label savewalletlabel;
32 |
33 | int padvalue;
34 |
35 |
36 | public WalletView (final LightWallet game, final WalletSaveRPC walletsaverpc) {
37 | this.game = game;
38 | this.walletsaverpc = walletsaverpc;
39 |
40 | walletlayout = new Table();
41 | padvalue = 12;
42 |
43 | namelabel = new Label("Name: ", game.uiSkin);
44 | namevalue = new Label(game.walletvalues.getName(), game.uiSkin);
45 | walletlayout.add(namelabel).pad(padvalue);
46 | walletlayout.add(namevalue).pad(padvalue).row();
47 |
48 | addresslabel = new TextButton("Address (click to copy): ", game.uiSkin);
49 | addressvalue = new Label(game.walletvalues.getAddress(), game.uiSkin);
50 | addressvalue.setFontScale(0.6f, 0.6f);
51 | walletlayout.add(addresslabel).pad(padvalue);
52 | walletlayout.add(addressvalue).pad(padvalue).row();
53 |
54 | synclabel = new Label("Wallet sync: ", game.uiSkin);
55 | syncvalue = new Label("0 / A lot", game.uiSkin, "redlabel");
56 | walletlayout.add(synclabel).pad(padvalue);
57 | walletlayout.add(syncvalue).pad(padvalue).row();
58 |
59 | unlockedlabel = new Label("Unlocked balance: ", game.uiSkin);
60 | unlockedvalue = new Label("Loading...", game.uiSkin, "redlabel");
61 | walletlayout.add(unlockedlabel).pad(padvalue);
62 | walletlayout.add(unlockedvalue).pad(padvalue).row();
63 |
64 | balancelabel = new Label("Balance: ", game.uiSkin);
65 | balancevalue = new Label("Loading...", game.uiSkin, "redlabel");
66 | walletlayout.add(balancelabel).pad(padvalue);
67 | walletlayout.add(balancevalue).pad(padvalue).row();
68 |
69 | calcedlabel = new Label("Calculated balance: ", game.uiSkin);
70 | calcedvalue = new Label("None", game.uiSkin);
71 | walletlayout.add(calcedlabel).pad(padvalue);
72 | walletlayout.add(calcedvalue).pad(padvalue).row();
73 |
74 | savewalletbtn = new TextButton("Save (attempts autosave every 60 s)", game.uiSkin);
75 | savewalletlabel = new Label("Not saved :(", game.uiSkin, "redlabel");
76 | walletlayout.add(savewalletbtn);
77 | walletlayout.add(savewalletlabel);
78 |
79 | walletlayout.add(new Label("", game.uiSkin)).fill().expand();
80 |
81 | savewalletbtn.addListener(new ClickListener() {
82 | @Override
83 | public void clicked (InputEvent event, float x, float y) {
84 | walletsaverpc.trysave(savewalletlabel);
85 | }
86 | });
87 |
88 | addresslabel.addListener(new ClickListener() {
89 | @Override
90 | public void clicked (InputEvent event, float x, float y) {
91 | Gdx.app.getClipboard().setContents(game.walletvalues.getAddress());
92 | }
93 | });
94 |
95 | }
96 |
97 |
98 | public Label getSavewalletlabel() {
99 | return savewalletlabel;
100 | }
101 |
102 |
103 | public void setSavewalletlabel(Label savewalletlabel) {
104 | this.savewalletlabel = savewalletlabel;
105 | }
106 | }
107 |
--------------------------------------------------------------------------------
/android/assets/skin/uiskin.atlas:
--------------------------------------------------------------------------------
1 | uiskin.png
2 | size: 256,128
3 | format: RGBA8888
4 | filter: Linear,Linear
5 | repeat: none
6 | check-off
7 | rotate: false
8 | xy: 11, 5
9 | size: 14, 14
10 | orig: 14, 14
11 | offset: 0, 0
12 | index: -1
13 | textfield
14 | rotate: false
15 | xy: 11, 5
16 | size: 14, 14
17 | split: 3, 3, 3, 3
18 | orig: 14, 14
19 | offset: 0, 0
20 | index: -1
21 | check-on
22 | rotate: false
23 | xy: 125, 35
24 | size: 14, 14
25 | orig: 14, 14
26 | offset: 0, 0
27 | index: -1
28 | cursor
29 | rotate: false
30 | xy: 23, 1
31 | size: 3, 3
32 | split: 1, 1, 1, 1
33 | orig: 3, 3
34 | offset: 0, 0
35 | index: -1
36 | default
37 | rotate: false
38 | xy: 1, 50
39 | size: 254, 77
40 | orig: 254, 77
41 | offset: 0, 0
42 | index: -1
43 | default-pane
44 | rotate: false
45 | xy: 11, 1
46 | size: 5, 3
47 | split: 1, 1, 1, 1
48 | orig: 5, 3
49 | offset: 0, 0
50 | index: -1
51 | default-rect-pad
52 | rotate: false
53 | xy: 11, 1
54 | size: 5, 3
55 | split: 1, 1, 1, 1
56 | orig: 5, 3
57 | offset: 0, 0
58 | index: -1
59 | default-pane-noborder
60 | rotate: false
61 | xy: 170, 44
62 | size: 1, 1
63 | split: 0, 0, 0, 0
64 | orig: 1, 1
65 | offset: 0, 0
66 | index: -1
67 | default-rect
68 | rotate: false
69 | xy: 38, 25
70 | size: 3, 3
71 | split: 1, 1, 1, 1
72 | orig: 3, 3
73 | offset: 0, 0
74 | index: -1
75 | default-rect-down
76 | rotate: false
77 | xy: 170, 46
78 | size: 3, 3
79 | split: 1, 1, 1, 1
80 | orig: 3, 3
81 | offset: 0, 0
82 | index: -1
83 | default-round
84 | rotate: false
85 | xy: 112, 29
86 | size: 12, 20
87 | split: 5, 5, 5, 4
88 | pad: 4, 4, 1, 1
89 | orig: 12, 20
90 | offset: 0, 0
91 | index: -1
92 | default-round-down
93 | rotate: false
94 | xy: 99, 29
95 | size: 12, 20
96 | split: 5, 5, 5, 4
97 | pad: 4, 4, 1, 1
98 | orig: 12, 20
99 | offset: 0, 0
100 | index: -1
101 | default-round-large
102 | rotate: false
103 | xy: 57, 29
104 | size: 20, 20
105 | split: 5, 5, 5, 4
106 | orig: 20, 20
107 | offset: 0, 0
108 | index: -1
109 | default-scroll
110 | rotate: false
111 | xy: 78, 29
112 | size: 20, 20
113 | split: 2, 2, 2, 2
114 | orig: 20, 20
115 | offset: 0, 0
116 | index: -1
117 | default-select
118 | rotate: false
119 | xy: 29, 29
120 | size: 27, 20
121 | split: 4, 14, 4, 4
122 | orig: 27, 20
123 | offset: 0, 0
124 | index: -1
125 | default-select-selection
126 | rotate: false
127 | xy: 26, 16
128 | size: 3, 3
129 | split: 1, 1, 1, 1
130 | orig: 3, 3
131 | offset: 0, 0
132 | index: -1
133 | default-slider
134 | rotate: false
135 | xy: 29, 20
136 | size: 8, 8
137 | split: 2, 2, 2, 2
138 | orig: 8, 8
139 | offset: 0, 0
140 | index: -1
141 | default-slider-knob
142 | rotate: false
143 | xy: 1, 1
144 | size: 9, 18
145 | orig: 9, 18
146 | offset: 0, 0
147 | index: -1
148 | default-splitpane
149 | rotate: false
150 | xy: 17, 1
151 | size: 5, 3
152 | split: 0, 5, 0, 0
153 | orig: 5, 3
154 | offset: 0, 0
155 | index: -1
156 | default-splitpane-vertical
157 | rotate: false
158 | xy: 125, 29
159 | size: 3, 5
160 | split: 0, 0, 0, 5
161 | orig: 3, 5
162 | offset: 0, 0
163 | index: -1
164 | default-window
165 | rotate: false
166 | xy: 1, 20
167 | size: 27, 29
168 | split: 4, 3, 20, 3
169 | orig: 27, 29
170 | offset: 0, 0
171 | index: -1
172 | selection
173 | rotate: false
174 | xy: 174, 48
175 | size: 1, 1
176 | orig: 1, 1
177 | offset: 0, 0
178 | index: -1
179 | tree-minus
180 | rotate: false
181 | xy: 140, 35
182 | size: 14, 14
183 | orig: 14, 14
184 | offset: 0, 0
185 | index: -1
186 | tree-plus
187 | rotate: false
188 | xy: 155, 35
189 | size: 14, 14
190 | orig: 14, 14
191 | offset: 0, 0
192 | index: -1
193 | white
194 | rotate: false
195 | xy: 129, 31
196 | size: 3, 3
197 | orig: 3, 3
198 | offset: 0, 0
199 | index: -1
--------------------------------------------------------------------------------
/desktop/assets/skin/uiskin.atlas:
--------------------------------------------------------------------------------
1 | uiskin.png
2 | size: 256,128
3 | format: RGBA8888
4 | filter: Linear,Linear
5 | repeat: none
6 | check-off
7 | rotate: false
8 | xy: 11, 5
9 | size: 14, 14
10 | orig: 14, 14
11 | offset: 0, 0
12 | index: -1
13 | textfield
14 | rotate: false
15 | xy: 11, 5
16 | size: 14, 14
17 | split: 3, 3, 3, 3
18 | orig: 14, 14
19 | offset: 0, 0
20 | index: -1
21 | check-on
22 | rotate: false
23 | xy: 125, 35
24 | size: 14, 14
25 | orig: 14, 14
26 | offset: 0, 0
27 | index: -1
28 | cursor
29 | rotate: false
30 | xy: 23, 1
31 | size: 3, 3
32 | split: 1, 1, 1, 1
33 | orig: 3, 3
34 | offset: 0, 0
35 | index: -1
36 | default
37 | rotate: false
38 | xy: 1, 50
39 | size: 254, 77
40 | orig: 254, 77
41 | offset: 0, 0
42 | index: -1
43 | default-pane
44 | rotate: false
45 | xy: 11, 1
46 | size: 5, 3
47 | split: 1, 1, 1, 1
48 | orig: 5, 3
49 | offset: 0, 0
50 | index: -1
51 | default-rect-pad
52 | rotate: false
53 | xy: 11, 1
54 | size: 5, 3
55 | split: 1, 1, 1, 1
56 | orig: 5, 3
57 | offset: 0, 0
58 | index: -1
59 | default-pane-noborder
60 | rotate: false
61 | xy: 170, 44
62 | size: 1, 1
63 | split: 0, 0, 0, 0
64 | orig: 1, 1
65 | offset: 0, 0
66 | index: -1
67 | default-rect
68 | rotate: false
69 | xy: 38, 25
70 | size: 3, 3
71 | split: 1, 1, 1, 1
72 | orig: 3, 3
73 | offset: 0, 0
74 | index: -1
75 | default-rect-down
76 | rotate: false
77 | xy: 170, 46
78 | size: 3, 3
79 | split: 1, 1, 1, 1
80 | orig: 3, 3
81 | offset: 0, 0
82 | index: -1
83 | default-round
84 | rotate: false
85 | xy: 112, 29
86 | size: 12, 20
87 | split: 5, 5, 5, 4
88 | pad: 4, 4, 1, 1
89 | orig: 12, 20
90 | offset: 0, 0
91 | index: -1
92 | default-round-down
93 | rotate: false
94 | xy: 99, 29
95 | size: 12, 20
96 | split: 5, 5, 5, 4
97 | pad: 4, 4, 1, 1
98 | orig: 12, 20
99 | offset: 0, 0
100 | index: -1
101 | default-round-large
102 | rotate: false
103 | xy: 57, 29
104 | size: 20, 20
105 | split: 5, 5, 5, 4
106 | orig: 20, 20
107 | offset: 0, 0
108 | index: -1
109 | default-scroll
110 | rotate: false
111 | xy: 78, 29
112 | size: 20, 20
113 | split: 2, 2, 2, 2
114 | orig: 20, 20
115 | offset: 0, 0
116 | index: -1
117 | default-select
118 | rotate: false
119 | xy: 29, 29
120 | size: 27, 20
121 | split: 4, 14, 4, 4
122 | orig: 27, 20
123 | offset: 0, 0
124 | index: -1
125 | default-select-selection
126 | rotate: false
127 | xy: 26, 16
128 | size: 3, 3
129 | split: 1, 1, 1, 1
130 | orig: 3, 3
131 | offset: 0, 0
132 | index: -1
133 | default-slider
134 | rotate: false
135 | xy: 29, 20
136 | size: 8, 8
137 | split: 2, 2, 2, 2
138 | orig: 8, 8
139 | offset: 0, 0
140 | index: -1
141 | default-slider-knob
142 | rotate: false
143 | xy: 1, 1
144 | size: 9, 18
145 | orig: 9, 18
146 | offset: 0, 0
147 | index: -1
148 | default-splitpane
149 | rotate: false
150 | xy: 17, 1
151 | size: 5, 3
152 | split: 0, 5, 0, 0
153 | orig: 5, 3
154 | offset: 0, 0
155 | index: -1
156 | default-splitpane-vertical
157 | rotate: false
158 | xy: 125, 29
159 | size: 3, 5
160 | split: 0, 0, 0, 5
161 | orig: 3, 5
162 | offset: 0, 0
163 | index: -1
164 | default-window
165 | rotate: false
166 | xy: 1, 20
167 | size: 27, 29
168 | split: 4, 3, 20, 3
169 | orig: 27, 29
170 | offset: 0, 0
171 | index: -1
172 | selection
173 | rotate: false
174 | xy: 174, 48
175 | size: 1, 1
176 | orig: 1, 1
177 | offset: 0, 0
178 | index: -1
179 | tree-minus
180 | rotate: false
181 | xy: 140, 35
182 | size: 14, 14
183 | orig: 14, 14
184 | offset: 0, 0
185 | index: -1
186 | tree-plus
187 | rotate: false
188 | xy: 155, 35
189 | size: 14, 14
190 | orig: 14, 14
191 | offset: 0, 0
192 | index: -1
193 | white
194 | rotate: false
195 | xy: 129, 31
196 | size: 3, 3
197 | orig: 3, 3
198 | offset: 0, 0
199 | index: -1
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/screens/PasswordScreen.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.screens;
2 |
3 | import com.badlogic.gdx.Gdx;
4 | import com.badlogic.gdx.graphics.Texture;
5 | import com.badlogic.gdx.scenes.scene2d.InputEvent;
6 | import com.badlogic.gdx.scenes.scene2d.Stage;
7 | import com.badlogic.gdx.scenes.scene2d.ui.Image;
8 | import com.badlogic.gdx.scenes.scene2d.ui.Label;
9 | import com.badlogic.gdx.scenes.scene2d.ui.Skin;
10 | import com.badlogic.gdx.scenes.scene2d.ui.Table;
11 | import com.badlogic.gdx.scenes.scene2d.ui.TextButton;
12 | import com.badlogic.gdx.scenes.scene2d.ui.TextField;
13 | import com.badlogic.gdx.scenes.scene2d.utils.ClickListener;
14 | import com.jw.lightwallet.LightWallet;
15 |
16 | public class PasswordScreen extends AbstractScreen {
17 |
18 | Stage stage;
19 | Table screenlayout;
20 | Skin uiSkin;
21 | int padvalue;
22 |
23 | Image logo;
24 | Texture logotex;
25 |
26 | Table textcontainer;
27 | String instruction;
28 | Label instructionlabel;
29 |
30 | Table inputtable;
31 |
32 | Label pwlabel;
33 | TextField pwtext;
34 | String pw;
35 |
36 | Label nodelabel;
37 | TextField nodetext;
38 | String node;
39 |
40 | Table buttontable;
41 | TextButton createbutton;
42 |
43 |
44 | public PasswordScreen(final LightWallet game) {
45 | super(game);
46 | System.out.print("CreateScreen creating.");
47 |
48 | uiSkin = new Skin(Gdx.files.internal("assets/skin/uiskin.json"));
49 | padvalue = 20;
50 |
51 | stage = new Stage();
52 | Gdx.input.setInputProcessor(stage);
53 |
54 | screenlayout = new Table();
55 |
56 | logo = new Image(new Texture(Gdx.files.internal("assets/logo.png")));
57 | //logo.scaleBy(0.02f);
58 |
59 | instruction = "Please enter your password in the password field below for the wallet" + game.walletvalues.getName() + ". "
60 | + "The node listed in lightwallet.conf is listed below as well; you may update it now if you like.";
61 |
62 | instructionlabel= new Label(instruction, uiSkin);
63 | instructionlabel.setWrap(true);
64 | textcontainer = new Table();
65 | textcontainer.add(instructionlabel).width(600);
66 |
67 | inputtable = new Table();
68 |
69 | pwlabel = new Label("Password: ", uiSkin);
70 | pwtext = new TextField("", uiSkin);
71 | pwtext.setPasswordMode(true);
72 | pwtext.setPasswordCharacter((char) 42);
73 |
74 | nodelabel = new Label("Node address: ", uiSkin);
75 | nodetext = new TextField(game.walletvalues.getNode(), uiSkin);
76 |
77 | inputtable.add(pwlabel).width(200);
78 | inputtable.add(pwtext).width(400).row();
79 |
80 | inputtable.add(nodelabel).width(200);
81 | inputtable.add(nodetext).width(400).row();
82 |
83 | buttontable = new Table();
84 | createbutton = new TextButton("Proceed", uiSkin);
85 | createbutton.addListener(new ClickListener() {
86 | @Override
87 | public void clicked (InputEvent event, float x, float y) {
88 | pw = pwtext.getText();
89 | node = nodetext.getText();
90 | game.walletvalues.setPw(pw);
91 | game.walletvalues.setNode(node);
92 | game.setScreen(new MainScreen(game));
93 | }
94 | });
95 | buttontable.add(createbutton).width(150);
96 |
97 | screenlayout.add(logo).pad(10).width(200).height(70).center().row();
98 | screenlayout.add(textcontainer).pad(padvalue).row();
99 | screenlayout.add(inputtable).pad(padvalue).row();
100 | screenlayout.add(buttontable).pad(padvalue).row();
101 |
102 | screenlayout.setFillParent(true);
103 | stage.addActor(screenlayout);
104 |
105 |
106 | }
107 |
108 | public void show() {
109 | super.show();
110 |
111 | }
112 |
113 | public void render(float delta) {
114 | super.render(delta);
115 |
116 | stage.draw();
117 | stage.act(delta);
118 |
119 | }
120 |
121 | public void dispose() {
122 | super.dispose();
123 |
124 | }
125 |
126 | }
127 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/screens/WizardScreen.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.screens;
2 |
3 | import com.badlogic.gdx.Gdx;
4 | import com.badlogic.gdx.graphics.Texture;
5 | import com.badlogic.gdx.scenes.scene2d.InputEvent;
6 | import com.badlogic.gdx.scenes.scene2d.Stage;
7 | import com.badlogic.gdx.scenes.scene2d.ui.Image;
8 | import com.badlogic.gdx.scenes.scene2d.ui.Label;
9 | import com.badlogic.gdx.scenes.scene2d.ui.Skin;
10 | import com.badlogic.gdx.scenes.scene2d.ui.Table;
11 | import com.badlogic.gdx.scenes.scene2d.ui.TextButton;
12 | import com.badlogic.gdx.scenes.scene2d.utils.ClickListener;
13 | import com.jw.lightwallet.LightWallet;
14 |
15 | public class WizardScreen extends AbstractScreen {
16 |
17 | // Layout stuff
18 | Stage stage;
19 | Table screenlayout;
20 | Skin uiSkin;
21 | int padvalue;
22 |
23 | Image logo;
24 | Texture logotex;
25 |
26 | Table textcontainer;
27 | Label wizardlabel;
28 | String wizardtext;
29 |
30 | Table buttontable;
31 | TextButton createbutton;
32 | TextButton importkeysbutton;
33 | TextButton importseedbutton;
34 |
35 |
36 | public WizardScreen(final LightWallet game) {
37 | super(game);
38 |
39 | uiSkin = new Skin(Gdx.files.internal("assets/skin/uiskin.json"));
40 | padvalue = 20;
41 |
42 | stage = new Stage();
43 | Gdx.input.setInputProcessor(stage);
44 |
45 | screenlayout = new Table();
46 |
47 | logo = new Image(new Texture(Gdx.files.internal("assets/logo.png")));
48 |
49 |
50 | wizardtext = "Hello. It seems this is the either the first time you are launching LightWallet or you have deleted your lightwallet.conf file. "
51 | + "You must have a copy of monero-wallet-cli executable in the same directory as the LightWallet executable. "
52 | + "Please select from the options below whether you would like to create a new wallet, import a wallet from a .keys file, "
53 | + "or import a wallet using your 25-word mnemonic seed.";
54 |
55 | wizardlabel = new Label(wizardtext, uiSkin);
56 | wizardlabel.setWrap(true);
57 | textcontainer = new Table();
58 | textcontainer.add(wizardlabel).width(600);
59 |
60 | buttontable = new Table();
61 | createbutton = new TextButton("Create", uiSkin);
62 | createbutton.addListener(new ClickListener() {
63 | @Override
64 | public void clicked (InputEvent event, float x, float y) {
65 | game.setScreen(new CreateScreen(game));
66 | }
67 | });
68 | createbutton.pad(padvalue);
69 |
70 | importkeysbutton = new TextButton("Import .keys", uiSkin);
71 | importkeysbutton.addListener(new ClickListener() {
72 | @Override
73 | public void clicked (InputEvent event, float x, float y) {
74 | game.setScreen(new ImportKeysScreen(game));
75 | }
76 | });
77 | importkeysbutton.pad(padvalue);
78 |
79 | importseedbutton = new TextButton("Import seed", uiSkin);
80 | importseedbutton.addListener(new ClickListener() {
81 | @Override
82 | public void clicked (InputEvent event, float x, float y) {
83 | game.setScreen(new ImportSeedScreen(game));
84 | }
85 | });
86 | importseedbutton.pad(padvalue);
87 |
88 | buttontable.add(createbutton).width(150);
89 | buttontable.add(importkeysbutton).width(150);
90 | buttontable.add(importseedbutton).width(150);
91 |
92 | screenlayout.add(logo).pad(10).center().row();
93 | screenlayout.add(textcontainer).pad(padvalue).row();
94 | screenlayout.add(buttontable).pad(padvalue).row();
95 |
96 | screenlayout.setFillParent(true);
97 | stage.addActor(screenlayout);
98 |
99 | }
100 |
101 | public void show() {
102 | super.show();
103 |
104 | }
105 |
106 | public void render(float delta) {
107 | super.render(delta);
108 |
109 | stage.draw();
110 | stage.act(delta);
111 |
112 | }
113 |
114 | public void dispose() {
115 | super.dispose();
116 |
117 | }
118 |
119 | }
120 |
--------------------------------------------------------------------------------
/android/assets/skin/uiskin.json:
--------------------------------------------------------------------------------
1 | {
2 | com.badlogic.gdx.graphics.g2d.BitmapFont: {
3 | default-font: { file: default.fnt },
4 | tiny-font: { file: tiny.fnt }
5 | },
6 | com.badlogic.gdx.graphics.Color: {
7 | green: { a: 1, b: 0, g: 1, r: 0 },
8 | white: { a: 1, b: 1, g: 1, r: 1 },
9 | red: { a: 1, b: 0, g: 0, r: 1 },
10 | black: { a: 1, b: 0, g: 0, r: 0 },
11 | blue: {a: 1, b: 0.9, g: 0.4, r: 0 }
12 | },
13 | com.badlogic.gdx.scenes.scene2d.ui.Skin$TintedDrawable: {
14 | dialogDim: { name: white, color: { r: 0, g: 0, b: 0, a: 0.45 } },
15 | },
16 | com.badlogic.gdx.scenes.scene2d.ui.Button$ButtonStyle: {
17 | default: { down: default-round-down, up: default-round },
18 | toggle: { down: default-round-down, checked: default-round-down, up: default-round }
19 | },
20 | com.badlogic.gdx.scenes.scene2d.ui.TextButton$TextButtonStyle: {
21 | default: { down: default-round-down, up: default-round, font: default-font, fontColor: white, overFontColor: blue},
22 | tinytext: { down: default-round-down, up: default-round, font: tiny-font, fontColor: white, overFontColor: blue},
23 | toggle: { down: default-round-down, up: default-round, checked: default-round-down, font: default-font, fontColor: white, downFontColor: red }
24 | },
25 | com.badlogic.gdx.scenes.scene2d.ui.ScrollPane$ScrollPaneStyle: {
26 | default: { vScroll: default-scroll, hScrollKnob: default-round-large, background: default-rect, hScroll: default-scroll, vScrollKnob: default-round-large }
27 | },
28 | com.badlogic.gdx.scenes.scene2d.ui.SelectBox$SelectBoxStyle: {
29 | default: {
30 | font: default-font, fontColor: white, background: default-select,
31 | scrollStyle: default,
32 | listStyle: { font: default-font, selection: default-select-selection }
33 | }
34 | },
35 | com.badlogic.gdx.scenes.scene2d.ui.SplitPane$SplitPaneStyle: {
36 | default-vertical: { handle: default-splitpane-vertical },
37 | default-horizontal: { handle: default-splitpane }
38 | },
39 | com.badlogic.gdx.scenes.scene2d.ui.Window$WindowStyle: {
40 | default: { titleFont: default-font, background: default-window, titleFontColor: white },
41 | dialog: { titleFont: default-font, background: default-window, titleFontColor: white, stageBackground: dialogDim }
42 | },
43 | com.badlogic.gdx.scenes.scene2d.ui.ProgressBar$ProgressBarStyle: {
44 | default-horizontal: { background: default-slider, knob: default-slider-knob },
45 | default-vertical: { background: default-slider, knob: default-round-large }
46 | },
47 | com.badlogic.gdx.scenes.scene2d.ui.Slider$SliderStyle: {
48 | default-horizontal: { background: default-slider, knob: default-slider-knob },
49 | default-vertical: { background: default-slider, knob: default-round-large }
50 | },
51 | com.badlogic.gdx.scenes.scene2d.ui.Label$LabelStyle: {
52 | default: { font: default-font, fontColor: white }
53 | redlabel: { font: default-font, fontColor: red }
54 | bluelabel: { font: default-font, fontColor: blue }
55 | greenlabel: { font: default-font, fontColor: green }
56 | },
57 | com.badlogic.gdx.scenes.scene2d.ui.TextField$TextFieldStyle: {
58 | default: { selection: selection, background: textfield, font: default-font, fontColor: white, cursor: cursor }
59 | tinytext: { selection: selection, background: textfield, font: tiny-font, fontColor: white, cursor: cursor }
60 | },
61 | com.badlogic.gdx.scenes.scene2d.ui.CheckBox$CheckBoxStyle: {
62 | default: { checkboxOn: check-on, checkboxOff: check-off, font: default-font, fontColor: white }
63 | },
64 | com.badlogic.gdx.scenes.scene2d.ui.List$ListStyle: {
65 | default: { fontColorUnselected: white, selection: selection, fontColorSelected: white, font: default-font }
66 | },
67 | com.badlogic.gdx.scenes.scene2d.ui.Touchpad$TouchpadStyle: {
68 | default: { background: default-pane, knob: default-round-large }
69 | },
70 | com.badlogic.gdx.scenes.scene2d.ui.Tree$TreeStyle: {
71 | default: { minus: tree-minus, plus: tree-plus, selection: default-select-selection }
72 | },
73 | com.badlogic.gdx.scenes.scene2d.ui.TextTooltip$TextTooltipStyle: {
74 | default: {
75 | label: { font: default-font, fontColor: white },
76 | background: default-pane
77 | }
78 | },
79 | }
--------------------------------------------------------------------------------
/desktop/assets/skin/uiskin.json:
--------------------------------------------------------------------------------
1 | {
2 | com.badlogic.gdx.graphics.g2d.BitmapFont: {
3 | default-font: { file: default.fnt },
4 | tiny-font: { file: tiny.fnt }
5 | },
6 | com.badlogic.gdx.graphics.Color: {
7 | green: { a: 1, b: 0, g: 1, r: 0 },
8 | white: { a: 1, b: 1, g: 1, r: 1 },
9 | red: { a: 1, b: 0, g: 0, r: 1 },
10 | black: { a: 1, b: 0, g: 0, r: 0 },
11 | blue: {a: 1, b: 0.9, g: 0.4, r: 0 }
12 | },
13 | com.badlogic.gdx.scenes.scene2d.ui.Skin$TintedDrawable: {
14 | dialogDim: { name: white, color: { r: 0, g: 0, b: 0, a: 0.45 } },
15 | },
16 | com.badlogic.gdx.scenes.scene2d.ui.Button$ButtonStyle: {
17 | default: { down: default-round-down, up: default-round },
18 | toggle: { down: default-round-down, checked: default-round-down, up: default-round }
19 | },
20 | com.badlogic.gdx.scenes.scene2d.ui.TextButton$TextButtonStyle: {
21 | default: { down: default-round-down, up: default-round, font: default-font, fontColor: white, overFontColor: blue},
22 | tinytext: { down: default-round-down, up: default-round, font: tiny-font, fontColor: white, overFontColor: blue},
23 | toggle: { down: default-round-down, up: default-round, checked: default-round-down, font: default-font, fontColor: white, downFontColor: red }
24 | },
25 | com.badlogic.gdx.scenes.scene2d.ui.ScrollPane$ScrollPaneStyle: {
26 | default: { vScroll: default-scroll, hScrollKnob: default-round-large, background: default-rect, hScroll: default-scroll, vScrollKnob: default-round-large }
27 | },
28 | com.badlogic.gdx.scenes.scene2d.ui.SelectBox$SelectBoxStyle: {
29 | default: {
30 | font: default-font, fontColor: white, background: default-select,
31 | scrollStyle: default,
32 | listStyle: { font: default-font, selection: default-select-selection }
33 | }
34 | },
35 | com.badlogic.gdx.scenes.scene2d.ui.SplitPane$SplitPaneStyle: {
36 | default-vertical: { handle: default-splitpane-vertical },
37 | default-horizontal: { handle: default-splitpane }
38 | },
39 | com.badlogic.gdx.scenes.scene2d.ui.Window$WindowStyle: {
40 | default: { titleFont: default-font, background: default-window, titleFontColor: white },
41 | dialog: { titleFont: default-font, background: default-window, titleFontColor: white, stageBackground: dialogDim }
42 | },
43 | com.badlogic.gdx.scenes.scene2d.ui.ProgressBar$ProgressBarStyle: {
44 | default-horizontal: { background: default-slider, knob: default-slider-knob },
45 | default-vertical: { background: default-slider, knob: default-round-large }
46 | },
47 | com.badlogic.gdx.scenes.scene2d.ui.Slider$SliderStyle: {
48 | default-horizontal: { background: default-slider, knob: default-slider-knob },
49 | default-vertical: { background: default-slider, knob: default-round-large }
50 | },
51 | com.badlogic.gdx.scenes.scene2d.ui.Label$LabelStyle: {
52 | default: { font: default-font, fontColor: white }
53 | redlabel: { font: default-font, fontColor: red }
54 | bluelabel: { font: default-font, fontColor: blue }
55 | greenlabel: { font: default-font, fontColor: green }
56 | },
57 | com.badlogic.gdx.scenes.scene2d.ui.TextField$TextFieldStyle: {
58 | default: { selection: selection, background: textfield, font: default-font, fontColor: white, cursor: cursor }
59 | tinytext: { selection: selection, background: textfield, font: tiny-font, fontColor: white, cursor: cursor }
60 | },
61 | com.badlogic.gdx.scenes.scene2d.ui.CheckBox$CheckBoxStyle: {
62 | default: { checkboxOn: check-on, checkboxOff: check-off, font: default-font, fontColor: white }
63 | },
64 | com.badlogic.gdx.scenes.scene2d.ui.List$ListStyle: {
65 | default: { fontColorUnselected: white, selection: selection, fontColorSelected: white, font: default-font }
66 | },
67 | com.badlogic.gdx.scenes.scene2d.ui.Touchpad$TouchpadStyle: {
68 | default: { background: default-pane, knob: default-round-large }
69 | },
70 | com.badlogic.gdx.scenes.scene2d.ui.Tree$TreeStyle: {
71 | default: { minus: tree-minus, plus: tree-plus, selection: default-select-selection }
72 | },
73 | com.badlogic.gdx.scenes.scene2d.ui.TextTooltip$TextTooltipStyle: {
74 | default: {
75 | label: { font: default-font, fontColor: white },
76 | background: default-pane
77 | }
78 | },
79 | }
--------------------------------------------------------------------------------
/android/build.gradle:
--------------------------------------------------------------------------------
1 | android {
2 | buildToolsVersion "24.0.3"
3 | compileSdkVersion 23
4 | sourceSets {
5 | main {
6 | manifest.srcFile 'AndroidManifest.xml'
7 | java.srcDirs = ['src']
8 | aidl.srcDirs = ['src']
9 | renderscript.srcDirs = ['src']
10 | res.srcDirs = ['res']
11 | assets.srcDirs = ['assets']
12 | jniLibs.srcDirs = ['libs']
13 | }
14 |
15 | instrumentTest.setRoot('tests')
16 | }
17 | defaultConfig {
18 | applicationId "com.jw.lightwallet"
19 | minSdkVersion 8
20 | targetSdkVersion 23
21 | }
22 | }
23 |
24 |
25 | // called every time gradle gets executed, takes the native dependencies of
26 | // the natives configuration, and extracts them to the proper libs/ folders
27 | // so they get packed with the APK.
28 | task copyAndroidNatives() {
29 | file("libs/armeabi/").mkdirs();
30 | file("libs/armeabi-v7a/").mkdirs();
31 | file("libs/arm64-v8a/").mkdirs();
32 | file("libs/x86_64/").mkdirs();
33 | file("libs/x86/").mkdirs();
34 |
35 | configurations.natives.files.each { jar ->
36 | def outputDir = null
37 | if(jar.name.endsWith("natives-arm64-v8a.jar")) outputDir = file("libs/arm64-v8a")
38 | if(jar.name.endsWith("natives-armeabi-v7a.jar")) outputDir = file("libs/armeabi-v7a")
39 | if(jar.name.endsWith("natives-armeabi.jar")) outputDir = file("libs/armeabi")
40 | if(jar.name.endsWith("natives-x86_64.jar")) outputDir = file("libs/x86_64")
41 | if(jar.name.endsWith("natives-x86.jar")) outputDir = file("libs/x86")
42 | if(outputDir != null) {
43 | copy {
44 | from zipTree(jar)
45 | into outputDir
46 | include "*.so"
47 | }
48 | }
49 | }
50 | }
51 |
52 | task run(type: Exec) {
53 | def path
54 | def localProperties = project.file("../local.properties")
55 | if (localProperties.exists()) {
56 | Properties properties = new Properties()
57 | localProperties.withInputStream { instr ->
58 | properties.load(instr)
59 | }
60 | def sdkDir = properties.getProperty('sdk.dir')
61 | if (sdkDir) {
62 | path = sdkDir
63 | } else {
64 | path = "$System.env.ANDROID_HOME"
65 | }
66 | } else {
67 | path = "$System.env.ANDROID_HOME"
68 | }
69 |
70 | def adb = path + "/platform-tools/adb"
71 | commandLine "$adb", 'shell', 'am', 'start', '-n', 'com.jw.lightwallet/com.jw.lightwallet.AndroidLauncher'
72 | }
73 |
74 | // sets up the Android Eclipse project, using the old Ant based build.
75 | eclipse {
76 | // need to specify Java source sets explicitly, SpringSource Gradle Eclipse plugin
77 | // ignores any nodes added in classpath.file.withXml
78 | sourceSets {
79 | main {
80 | java.srcDirs "src", 'gen'
81 | }
82 | }
83 |
84 | jdt {
85 | sourceCompatibility = 1.6
86 | targetCompatibility = 1.6
87 | }
88 |
89 | classpath {
90 | plusConfigurations += [ project.configurations.compile ]
91 | containers 'com.android.ide.eclipse.adt.ANDROID_FRAMEWORK', 'com.android.ide.eclipse.adt.LIBRARIES'
92 | }
93 |
94 | project {
95 | name = appName + "-android"
96 | natures 'com.android.ide.eclipse.adt.AndroidNature'
97 | buildCommands.clear();
98 | buildCommand "com.android.ide.eclipse.adt.ResourceManagerBuilder"
99 | buildCommand "com.android.ide.eclipse.adt.PreCompilerBuilder"
100 | buildCommand "org.eclipse.jdt.core.javabuilder"
101 | buildCommand "com.android.ide.eclipse.adt.ApkBuilder"
102 | }
103 | }
104 |
105 | // sets up the Android Idea project, using the old Ant based build.
106 | idea {
107 | module {
108 | sourceDirs += file("src");
109 | scopes = [ COMPILE: [plus:[project.configurations.compile]]]
110 |
111 | iml {
112 | withXml {
113 | def node = it.asNode()
114 | def builder = NodeBuilder.newInstance();
115 | builder.current = node;
116 | builder.component(name: "FacetManager") {
117 | facet(type: "android", name: "Android") {
118 | configuration {
119 | option(name: "UPDATE_PROPERTY_FILES", value:"true")
120 | }
121 | }
122 | }
123 | }
124 | }
125 | }
126 | }
127 |
--------------------------------------------------------------------------------
/gradlew:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | ##############################################################################
4 | ##
5 | ## Gradle start up script for UN*X
6 | ##
7 | ##############################################################################
8 |
9 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
10 | DEFAULT_JVM_OPTS=""
11 |
12 | APP_NAME="Gradle"
13 | APP_BASE_NAME=`basename "$0"`
14 |
15 | # Use the maximum available, or set MAX_FD != -1 to use that value.
16 | MAX_FD="maximum"
17 |
18 | warn ( ) {
19 | echo "$*"
20 | }
21 |
22 | die ( ) {
23 | echo
24 | echo "$*"
25 | echo
26 | exit 1
27 | }
28 |
29 | # OS specific support (must be 'true' or 'false').
30 | cygwin=false
31 | msys=false
32 | darwin=false
33 | case "`uname`" in
34 | CYGWIN* )
35 | cygwin=true
36 | ;;
37 | Darwin* )
38 | darwin=true
39 | ;;
40 | MINGW* )
41 | msys=true
42 | ;;
43 | esac
44 |
45 | # For Cygwin, ensure paths are in UNIX format before anything is touched.
46 | if $cygwin ; then
47 | [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
48 | fi
49 |
50 | # Attempt to set APP_HOME
51 | # Resolve links: $0 may be a link
52 | PRG="$0"
53 | # Need this for relative symlinks.
54 | while [ -h "$PRG" ] ; do
55 | ls=`ls -ld "$PRG"`
56 | link=`expr "$ls" : '.*-> \(.*\)$'`
57 | if expr "$link" : '/.*' > /dev/null; then
58 | PRG="$link"
59 | else
60 | PRG=`dirname "$PRG"`"/$link"
61 | fi
62 | done
63 | SAVED="`pwd`"
64 | cd "`dirname \"$PRG\"`/" >&-
65 | APP_HOME="`pwd -P`"
66 | cd "$SAVED" >&-
67 |
68 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
69 |
70 | # Determine the Java command to use to start the JVM.
71 | if [ -n "$JAVA_HOME" ] ; then
72 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
73 | # IBM's JDK on AIX uses strange locations for the executables
74 | JAVACMD="$JAVA_HOME/jre/sh/java"
75 | else
76 | JAVACMD="$JAVA_HOME/bin/java"
77 | fi
78 | if [ ! -x "$JAVACMD" ] ; then
79 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
80 |
81 | Please set the JAVA_HOME variable in your environment to match the
82 | location of your Java installation."
83 | fi
84 | else
85 | JAVACMD="java"
86 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
87 |
88 | Please set the JAVA_HOME variable in your environment to match the
89 | location of your Java installation."
90 | fi
91 |
92 | # Increase the maximum file descriptors if we can.
93 | if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
94 | MAX_FD_LIMIT=`ulimit -H -n`
95 | if [ $? -eq 0 ] ; then
96 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
97 | MAX_FD="$MAX_FD_LIMIT"
98 | fi
99 | ulimit -n $MAX_FD
100 | if [ $? -ne 0 ] ; then
101 | warn "Could not set maximum file descriptor limit: $MAX_FD"
102 | fi
103 | else
104 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
105 | fi
106 | fi
107 |
108 | # For Darwin, add options to specify how the application appears in the dock
109 | if $darwin; then
110 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
111 | fi
112 |
113 | # For Cygwin, switch paths to Windows format before running java
114 | if $cygwin ; then
115 | APP_HOME=`cygpath --path --mixed "$APP_HOME"`
116 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
117 |
118 | # We build the pattern for arguments to be converted via cygpath
119 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
120 | SEP=""
121 | for dir in $ROOTDIRSRAW ; do
122 | ROOTDIRS="$ROOTDIRS$SEP$dir"
123 | SEP="|"
124 | done
125 | OURCYGPATTERN="(^($ROOTDIRS))"
126 | # Add a user-defined pattern to the cygpath arguments
127 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then
128 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
129 | fi
130 | # Now convert the arguments - kludge to limit ourselves to /bin/sh
131 | i=0
132 | for arg in "$@" ; do
133 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
134 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
135 |
136 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
137 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
138 | else
139 | eval `echo args$i`="\"$arg\""
140 | fi
141 | i=$((i+1))
142 | done
143 | case $i in
144 | (0) set -- ;;
145 | (1) set -- "$args0" ;;
146 | (2) set -- "$args0" "$args1" ;;
147 | (3) set -- "$args0" "$args1" "$args2" ;;
148 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
149 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
150 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
151 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
152 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
153 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
154 | esac
155 | fi
156 |
157 | # Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
158 | function splitJvmOpts() {
159 | JVM_OPTS=("$@")
160 | }
161 | eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
162 | JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
163 |
164 | exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
165 |
--------------------------------------------------------------------------------
/android/assets/skin/tiny.fnt:
--------------------------------------------------------------------------------
1 | info face="Droid Sans" size=11 bold=0 italic=0 charset="" unicode=0 stretchH=100 smooth=1 aa=1 padding=0,0,0,0 spacing=0,0
2 | common lineHeight=14 base=11 scaleW=512 scaleH=512 pages=1 packed=0
3 | page id=0 file="tiny.png"
4 | chars count=94
5 | char id=32 x=0 y=0 width=0 height=0 xoffset=0 yoffset=11 xadvance=3 page=0 chnl=0
6 | char id=124 x=0 y=0 width=2 height=13 xoffset=2 yoffset=2 xadvance=5 page=0 chnl=0
7 | char id=106 x=2 y=0 width=4 height=13 xoffset=-1 yoffset=2 xadvance=2 page=0 chnl=0
8 | char id=93 x=6 y=0 width=4 height=12 xoffset=0 yoffset=2 xadvance=3 page=0 chnl=0
9 | char id=91 x=10 y=0 width=4 height=12 xoffset=1 yoffset=2 xadvance=3 page=0 chnl=0
10 | char id=41 x=14 y=0 width=4 height=12 xoffset=0 yoffset=2 xadvance=3 page=0 chnl=0
11 | char id=40 x=18 y=0 width=3 height=12 xoffset=0 yoffset=2 xadvance=3 page=0 chnl=0
12 | char id=81 x=21 y=0 width=8 height=12 xoffset=1 yoffset=2 xadvance=9 page=0 chnl=0
13 | char id=74 x=29 y=0 width=5 height=12 xoffset=-1 yoffset=2 xadvance=3 page=0 chnl=0
14 | char id=36 x=34 y=0 width=6 height=11 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
15 | char id=125 x=40 y=0 width=5 height=11 xoffset=0 yoffset=3 xadvance=4 page=0 chnl=0
16 | char id=123 x=45 y=0 width=5 height=11 xoffset=1 yoffset=3 xadvance=4 page=0 chnl=0
17 | char id=121 x=50 y=0 width=8 height=11 xoffset=-1 yoffset=4 xadvance=6 page=0 chnl=0
18 | char id=113 x=58 y=0 width=7 height=11 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
19 | char id=112 x=65 y=0 width=7 height=11 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
20 | char id=103 x=72 y=0 width=7 height=11 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
21 | char id=35 x=79 y=0 width=9 height=10 xoffset=0 yoffset=2 xadvance=7 page=0 chnl=0
22 | char id=37 x=88 y=0 width=9 height=10 xoffset=0 yoffset=2 xadvance=9 page=0 chnl=0
23 | char id=92 x=97 y=0 width=7 height=10 xoffset=-1 yoffset=2 xadvance=4 page=0 chnl=0
24 | char id=64 x=104 y=0 width=10 height=10 xoffset=1 yoffset=3 xadvance=10 page=0 chnl=0
25 | char id=47 x=114 y=0 width=7 height=10 xoffset=-1 yoffset=2 xadvance=4 page=0 chnl=0
26 | char id=59 x=121 y=0 width=3 height=10 xoffset=0 yoffset=4 xadvance=3 page=0 chnl=0
27 | char id=33 x=124 y=0 width=4 height=10 xoffset=0 yoffset=2 xadvance=3 page=0 chnl=0
28 | char id=48 x=128 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
29 | char id=57 x=135 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
30 | char id=56 x=142 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
31 | char id=55 x=149 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
32 | char id=54 x=156 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
33 | char id=53 x=163 y=0 width=6 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
34 | char id=52 x=169 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
35 | char id=51 x=176 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
36 | char id=50 x=183 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
37 | char id=49 x=190 y=0 width=4 height=10 xoffset=1 yoffset=2 xadvance=6 page=0 chnl=0
38 | char id=108 x=194 y=0 width=2 height=10 xoffset=0 yoffset=2 xadvance=2 page=0 chnl=0
39 | char id=107 x=196 y=0 width=6 height=10 xoffset=0 yoffset=2 xadvance=5 page=0 chnl=0
40 | char id=105 x=202 y=0 width=4 height=10 xoffset=-1 yoffset=2 xadvance=2 page=0 chnl=0
41 | char id=104 x=206 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
42 | char id=102 x=213 y=0 width=5 height=10 xoffset=0 yoffset=2 xadvance=4 page=0 chnl=0
43 | char id=100 x=218 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
44 | char id=98 x=225 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
45 | char id=90 x=232 y=0 width=7 height=10 xoffset=1 yoffset=2 xadvance=7 page=0 chnl=0
46 | char id=89 x=239 y=0 width=10 height=10 xoffset=-1 yoffset=2 xadvance=7 page=0 chnl=0
47 | char id=88 x=249 y=0 width=9 height=10 xoffset=-1 yoffset=2 xadvance=6 page=0 chnl=0
48 | char id=87 x=258 y=0 width=12 height=10 xoffset=-1 yoffset=2 xadvance=9 page=0 chnl=0
49 | char id=86 x=270 y=0 width=10 height=10 xoffset=-1 yoffset=2 xadvance=7 page=0 chnl=0
50 | char id=85 x=280 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=8 page=0 chnl=0
51 | char id=84 x=288 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=5 page=0 chnl=0
52 | char id=82 x=295 y=0 width=7 height=10 xoffset=1 yoffset=2 xadvance=7 page=0 chnl=0
53 | char id=80 x=302 y=0 width=5 height=10 xoffset=1 yoffset=2 xadvance=6 page=0 chnl=0
54 | char id=79 x=307 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=9 page=0 chnl=0
55 | char id=78 x=315 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=8 page=0 chnl=0
56 | char id=77 x=323 y=0 width=10 height=10 xoffset=1 yoffset=2 xadvance=10 page=0 chnl=0
57 | char id=76 x=333 y=0 width=5 height=10 xoffset=1 yoffset=2 xadvance=5 page=0 chnl=0
58 | char id=75 x=338 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=7 page=0 chnl=0
59 | char id=73 x=346 y=0 width=4 height=10 xoffset=0 yoffset=2 xadvance=3 page=0 chnl=0
60 | char id=72 x=350 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=8 page=0 chnl=0
61 | char id=71 x=358 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=8 page=0 chnl=0
62 | char id=70 x=366 y=0 width=6 height=10 xoffset=1 yoffset=2 xadvance=5 page=0 chnl=0
63 | char id=69 x=372 y=0 width=6 height=10 xoffset=1 yoffset=2 xadvance=6 page=0 chnl=0
64 | char id=68 x=378 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=8 page=0 chnl=0
65 | char id=67 x=386 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=7 page=0 chnl=0
66 | char id=66 x=394 y=0 width=7 height=10 xoffset=1 yoffset=2 xadvance=7 page=0 chnl=0
67 | char id=65 x=401 y=0 width=10 height=10 xoffset=-1 yoffset=2 xadvance=7 page=0 chnl=0
68 | char id=38 x=411 y=0 width=8 height=9 xoffset=0 yoffset=3 xadvance=8 page=0 chnl=0
69 | char id=63 x=419 y=0 width=5 height=9 xoffset=0 yoffset=3 xadvance=5 page=0 chnl=0
70 | char id=116 x=424 y=0 width=5 height=9 xoffset=0 yoffset=3 xadvance=4 page=0 chnl=0
71 | char id=83 x=429 y=0 width=7 height=9 xoffset=0 yoffset=3 xadvance=6 page=0 chnl=0
72 | char id=58 x=436 y=0 width=2 height=8 xoffset=1 yoffset=4 xadvance=3 page=0 chnl=0
73 | char id=122 x=438 y=0 width=6 height=8 xoffset=0 yoffset=4 xadvance=5 page=0 chnl=0
74 | char id=120 x=444 y=0 width=6 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
75 | char id=119 x=450 y=0 width=10 height=8 xoffset=-1 yoffset=4 xadvance=8 page=0 chnl=0
76 | char id=118 x=460 y=0 width=8 height=8 xoffset=-1 yoffset=4 xadvance=6 page=0 chnl=0
77 | char id=117 x=468 y=0 width=7 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
78 | char id=115 x=475 y=0 width=6 height=8 xoffset=-1 yoffset=4 xadvance=5 page=0 chnl=0
79 | char id=114 x=481 y=0 width=4 height=8 xoffset=0 yoffset=4 xadvance=4 page=0 chnl=0
80 | char id=111 x=485 y=0 width=7 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
81 | char id=110 x=492 y=0 width=7 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
82 | char id=109 x=499 y=0 width=11 height=8 xoffset=0 yoffset=4 xadvance=10 page=0 chnl=0
83 | char id=101 x=0 y=13 width=7 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
84 | char id=99 x=7 y=13 width=5 height=8 xoffset=0 yoffset=4 xadvance=5 page=0 chnl=0
85 | char id=97 x=12 y=13 width=7 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
86 | char id=42 x=19 y=13 width=8 height=7 xoffset=-1 yoffset=2 xadvance=6 page=0 chnl=0
87 | char id=43 x=27 y=13 width=7 height=7 xoffset=-1 yoffset=4 xadvance=6 page=0 chnl=0
88 | char id=94 x=34 y=13 width=7 height=7 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
89 | char id=62 x=41 y=13 width=6 height=6 xoffset=1 yoffset=5 xadvance=6 page=0 chnl=0
90 | char id=60 x=47 y=13 width=6 height=6 xoffset=1 yoffset=5 xadvance=6 page=0 chnl=0
91 | char id=61 x=53 y=13 width=6 height=5 xoffset=1 yoffset=5 xadvance=6 page=0 chnl=0
92 | char id=44 x=59 y=13 width=3 height=5 xoffset=0 yoffset=9 xadvance=3 page=0 chnl=0
93 | char id=39 x=62 y=13 width=3 height=5 xoffset=1 yoffset=2 xadvance=3 page=0 chnl=0
94 | char id=34 x=65 y=13 width=5 height=5 xoffset=1 yoffset=2 xadvance=5 page=0 chnl=0
95 | char id=46 x=70 y=13 width=2 height=4 xoffset=1 yoffset=8 xadvance=3 page=0 chnl=0
96 | char id=96 x=72 y=13 width=4 height=4 xoffset=2 yoffset=1 xadvance=6 page=0 chnl=0
97 | char id=126 x=76 y=13 width=6 height=3 xoffset=1 yoffset=6 xadvance=6 page=0 chnl=0
98 | char id=95 x=82 y=13 width=7 height=3 xoffset=0 yoffset=11 xadvance=5 page=0 chnl=0
99 | char id=45 x=89 y=13 width=5 height=3 xoffset=0 yoffset=7 xadvance=4 page=0 chnl=0
100 | kernings count=-1
101 |
--------------------------------------------------------------------------------
/desktop/assets/skin/tiny.fnt:
--------------------------------------------------------------------------------
1 | info face="Droid Sans" size=11 bold=0 italic=0 charset="" unicode=0 stretchH=100 smooth=1 aa=1 padding=0,0,0,0 spacing=0,0
2 | common lineHeight=14 base=11 scaleW=512 scaleH=512 pages=1 packed=0
3 | page id=0 file="tiny.png"
4 | chars count=94
5 | char id=32 x=0 y=0 width=0 height=0 xoffset=0 yoffset=11 xadvance=3 page=0 chnl=0
6 | char id=124 x=0 y=0 width=2 height=13 xoffset=2 yoffset=2 xadvance=5 page=0 chnl=0
7 | char id=106 x=2 y=0 width=4 height=13 xoffset=-1 yoffset=2 xadvance=2 page=0 chnl=0
8 | char id=93 x=6 y=0 width=4 height=12 xoffset=0 yoffset=2 xadvance=3 page=0 chnl=0
9 | char id=91 x=10 y=0 width=4 height=12 xoffset=1 yoffset=2 xadvance=3 page=0 chnl=0
10 | char id=41 x=14 y=0 width=4 height=12 xoffset=0 yoffset=2 xadvance=3 page=0 chnl=0
11 | char id=40 x=18 y=0 width=3 height=12 xoffset=0 yoffset=2 xadvance=3 page=0 chnl=0
12 | char id=81 x=21 y=0 width=8 height=12 xoffset=1 yoffset=2 xadvance=9 page=0 chnl=0
13 | char id=74 x=29 y=0 width=5 height=12 xoffset=-1 yoffset=2 xadvance=3 page=0 chnl=0
14 | char id=36 x=34 y=0 width=6 height=11 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
15 | char id=125 x=40 y=0 width=5 height=11 xoffset=0 yoffset=3 xadvance=4 page=0 chnl=0
16 | char id=123 x=45 y=0 width=5 height=11 xoffset=1 yoffset=3 xadvance=4 page=0 chnl=0
17 | char id=121 x=50 y=0 width=8 height=11 xoffset=-1 yoffset=4 xadvance=6 page=0 chnl=0
18 | char id=113 x=58 y=0 width=7 height=11 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
19 | char id=112 x=65 y=0 width=7 height=11 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
20 | char id=103 x=72 y=0 width=7 height=11 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
21 | char id=35 x=79 y=0 width=9 height=10 xoffset=0 yoffset=2 xadvance=7 page=0 chnl=0
22 | char id=37 x=88 y=0 width=9 height=10 xoffset=0 yoffset=2 xadvance=9 page=0 chnl=0
23 | char id=92 x=97 y=0 width=7 height=10 xoffset=-1 yoffset=2 xadvance=4 page=0 chnl=0
24 | char id=64 x=104 y=0 width=10 height=10 xoffset=1 yoffset=3 xadvance=10 page=0 chnl=0
25 | char id=47 x=114 y=0 width=7 height=10 xoffset=-1 yoffset=2 xadvance=4 page=0 chnl=0
26 | char id=59 x=121 y=0 width=3 height=10 xoffset=0 yoffset=4 xadvance=3 page=0 chnl=0
27 | char id=33 x=124 y=0 width=4 height=10 xoffset=0 yoffset=2 xadvance=3 page=0 chnl=0
28 | char id=48 x=128 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
29 | char id=57 x=135 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
30 | char id=56 x=142 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
31 | char id=55 x=149 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
32 | char id=54 x=156 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
33 | char id=53 x=163 y=0 width=6 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
34 | char id=52 x=169 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
35 | char id=51 x=176 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
36 | char id=50 x=183 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
37 | char id=49 x=190 y=0 width=4 height=10 xoffset=1 yoffset=2 xadvance=6 page=0 chnl=0
38 | char id=108 x=194 y=0 width=2 height=10 xoffset=0 yoffset=2 xadvance=2 page=0 chnl=0
39 | char id=107 x=196 y=0 width=6 height=10 xoffset=0 yoffset=2 xadvance=5 page=0 chnl=0
40 | char id=105 x=202 y=0 width=4 height=10 xoffset=-1 yoffset=2 xadvance=2 page=0 chnl=0
41 | char id=104 x=206 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
42 | char id=102 x=213 y=0 width=5 height=10 xoffset=0 yoffset=2 xadvance=4 page=0 chnl=0
43 | char id=100 x=218 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
44 | char id=98 x=225 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
45 | char id=90 x=232 y=0 width=7 height=10 xoffset=1 yoffset=2 xadvance=7 page=0 chnl=0
46 | char id=89 x=239 y=0 width=10 height=10 xoffset=-1 yoffset=2 xadvance=7 page=0 chnl=0
47 | char id=88 x=249 y=0 width=9 height=10 xoffset=-1 yoffset=2 xadvance=6 page=0 chnl=0
48 | char id=87 x=258 y=0 width=12 height=10 xoffset=-1 yoffset=2 xadvance=9 page=0 chnl=0
49 | char id=86 x=270 y=0 width=10 height=10 xoffset=-1 yoffset=2 xadvance=7 page=0 chnl=0
50 | char id=85 x=280 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=8 page=0 chnl=0
51 | char id=84 x=288 y=0 width=7 height=10 xoffset=0 yoffset=2 xadvance=5 page=0 chnl=0
52 | char id=82 x=295 y=0 width=7 height=10 xoffset=1 yoffset=2 xadvance=7 page=0 chnl=0
53 | char id=80 x=302 y=0 width=5 height=10 xoffset=1 yoffset=2 xadvance=6 page=0 chnl=0
54 | char id=79 x=307 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=9 page=0 chnl=0
55 | char id=78 x=315 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=8 page=0 chnl=0
56 | char id=77 x=323 y=0 width=10 height=10 xoffset=1 yoffset=2 xadvance=10 page=0 chnl=0
57 | char id=76 x=333 y=0 width=5 height=10 xoffset=1 yoffset=2 xadvance=5 page=0 chnl=0
58 | char id=75 x=338 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=7 page=0 chnl=0
59 | char id=73 x=346 y=0 width=4 height=10 xoffset=0 yoffset=2 xadvance=3 page=0 chnl=0
60 | char id=72 x=350 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=8 page=0 chnl=0
61 | char id=71 x=358 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=8 page=0 chnl=0
62 | char id=70 x=366 y=0 width=6 height=10 xoffset=1 yoffset=2 xadvance=5 page=0 chnl=0
63 | char id=69 x=372 y=0 width=6 height=10 xoffset=1 yoffset=2 xadvance=6 page=0 chnl=0
64 | char id=68 x=378 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=8 page=0 chnl=0
65 | char id=67 x=386 y=0 width=8 height=10 xoffset=1 yoffset=2 xadvance=7 page=0 chnl=0
66 | char id=66 x=394 y=0 width=7 height=10 xoffset=1 yoffset=2 xadvance=7 page=0 chnl=0
67 | char id=65 x=401 y=0 width=10 height=10 xoffset=-1 yoffset=2 xadvance=7 page=0 chnl=0
68 | char id=38 x=411 y=0 width=8 height=9 xoffset=0 yoffset=3 xadvance=8 page=0 chnl=0
69 | char id=63 x=419 y=0 width=5 height=9 xoffset=0 yoffset=3 xadvance=5 page=0 chnl=0
70 | char id=116 x=424 y=0 width=5 height=9 xoffset=0 yoffset=3 xadvance=4 page=0 chnl=0
71 | char id=83 x=429 y=0 width=7 height=9 xoffset=0 yoffset=3 xadvance=6 page=0 chnl=0
72 | char id=58 x=436 y=0 width=2 height=8 xoffset=1 yoffset=4 xadvance=3 page=0 chnl=0
73 | char id=122 x=438 y=0 width=6 height=8 xoffset=0 yoffset=4 xadvance=5 page=0 chnl=0
74 | char id=120 x=444 y=0 width=6 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
75 | char id=119 x=450 y=0 width=10 height=8 xoffset=-1 yoffset=4 xadvance=8 page=0 chnl=0
76 | char id=118 x=460 y=0 width=8 height=8 xoffset=-1 yoffset=4 xadvance=6 page=0 chnl=0
77 | char id=117 x=468 y=0 width=7 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
78 | char id=115 x=475 y=0 width=6 height=8 xoffset=-1 yoffset=4 xadvance=5 page=0 chnl=0
79 | char id=114 x=481 y=0 width=4 height=8 xoffset=0 yoffset=4 xadvance=4 page=0 chnl=0
80 | char id=111 x=485 y=0 width=7 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
81 | char id=110 x=492 y=0 width=7 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
82 | char id=109 x=499 y=0 width=11 height=8 xoffset=0 yoffset=4 xadvance=10 page=0 chnl=0
83 | char id=101 x=0 y=13 width=7 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
84 | char id=99 x=7 y=13 width=5 height=8 xoffset=0 yoffset=4 xadvance=5 page=0 chnl=0
85 | char id=97 x=12 y=13 width=7 height=8 xoffset=0 yoffset=4 xadvance=6 page=0 chnl=0
86 | char id=42 x=19 y=13 width=8 height=7 xoffset=-1 yoffset=2 xadvance=6 page=0 chnl=0
87 | char id=43 x=27 y=13 width=7 height=7 xoffset=-1 yoffset=4 xadvance=6 page=0 chnl=0
88 | char id=94 x=34 y=13 width=7 height=7 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
89 | char id=62 x=41 y=13 width=6 height=6 xoffset=1 yoffset=5 xadvance=6 page=0 chnl=0
90 | char id=60 x=47 y=13 width=6 height=6 xoffset=1 yoffset=5 xadvance=6 page=0 chnl=0
91 | char id=61 x=53 y=13 width=6 height=5 xoffset=1 yoffset=5 xadvance=6 page=0 chnl=0
92 | char id=44 x=59 y=13 width=3 height=5 xoffset=0 yoffset=9 xadvance=3 page=0 chnl=0
93 | char id=39 x=62 y=13 width=3 height=5 xoffset=1 yoffset=2 xadvance=3 page=0 chnl=0
94 | char id=34 x=65 y=13 width=5 height=5 xoffset=1 yoffset=2 xadvance=5 page=0 chnl=0
95 | char id=46 x=70 y=13 width=2 height=4 xoffset=1 yoffset=8 xadvance=3 page=0 chnl=0
96 | char id=96 x=72 y=13 width=4 height=4 xoffset=2 yoffset=1 xadvance=6 page=0 chnl=0
97 | char id=126 x=76 y=13 width=6 height=3 xoffset=1 yoffset=6 xadvance=6 page=0 chnl=0
98 | char id=95 x=82 y=13 width=7 height=3 xoffset=0 yoffset=11 xadvance=5 page=0 chnl=0
99 | char id=45 x=89 y=13 width=5 height=3 xoffset=0 yoffset=7 xadvance=4 page=0 chnl=0
100 | kernings count=-1
101 |
--------------------------------------------------------------------------------
/android/assets/skin/default.fnt:
--------------------------------------------------------------------------------
1 | info face="Droid Sans" size=17 bold=0 italic=0 charset="" unicode=0 stretchH=100 smooth=1 aa=1 padding=0,0,0,0 spacing=1,1
2 | common lineHeight=20 base=18 scaleW=256 scaleH=128 pages=1 packed=0
3 | page id=0 file="default.png"
4 | chars count=96
5 | char id=32 x=0 y=0 width=0 height=0 xoffset=0 yoffset=16 xadvance=4 page=0 chnl=0
6 | char id=124 x=0 y=0 width=6 height=20 xoffset=1 yoffset=3 xadvance=9 page=0 chnl=0
7 | char id=106 x=6 y=0 width=9 height=20 xoffset=-4 yoffset=3 xadvance=4 page=0 chnl=0
8 | char id=81 x=15 y=0 width=15 height=19 xoffset=-2 yoffset=3 xadvance=12 page=0 chnl=0
9 | char id=74 x=30 y=0 width=11 height=19 xoffset=-5 yoffset=3 xadvance=4 page=0 chnl=0
10 | char id=125 x=41 y=0 width=10 height=18 xoffset=-3 yoffset=3 xadvance=6 page=0 chnl=0
11 | char id=123 x=51 y=0 width=10 height=18 xoffset=-3 yoffset=3 xadvance=6 page=0 chnl=0
12 | char id=93 x=61 y=0 width=8 height=18 xoffset=-3 yoffset=3 xadvance=5 page=0 chnl=0
13 | char id=91 x=69 y=0 width=8 height=18 xoffset=-2 yoffset=3 xadvance=5 page=0 chnl=0
14 | char id=41 x=77 y=0 width=9 height=18 xoffset=-3 yoffset=3 xadvance=5 page=0 chnl=0
15 | char id=40 x=86 y=0 width=9 height=18 xoffset=-3 yoffset=3 xadvance=5 page=0 chnl=0
16 | char id=64 x=95 y=0 width=18 height=17 xoffset=-3 yoffset=3 xadvance=14 page=0 chnl=0
17 | char id=121 x=113 y=0 width=13 height=17 xoffset=-3 yoffset=6 xadvance=8 page=0 chnl=0
18 | char id=113 x=126 y=0 width=13 height=17 xoffset=-3 yoffset=6 xadvance=9 page=0 chnl=0
19 | char id=112 x=139 y=0 width=13 height=17 xoffset=-2 yoffset=6 xadvance=9 page=0 chnl=0
20 | char id=103 x=152 y=0 width=13 height=17 xoffset=-3 yoffset=6 xadvance=8 page=0 chnl=0
21 | char id=38 x=165 y=0 width=16 height=16 xoffset=-3 yoffset=3 xadvance=11 page=0 chnl=0
22 | char id=37 x=181 y=0 width=18 height=16 xoffset=-3 yoffset=3 xadvance=14 page=0 chnl=0
23 | char id=36 x=199 y=0 width=12 height=16 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
24 | char id=63 x=211 y=0 width=11 height=16 xoffset=-3 yoffset=3 xadvance=7 page=0 chnl=0
25 | char id=33 x=222 y=0 width=7 height=16 xoffset=-2 yoffset=3 xadvance=4 page=0 chnl=0
26 | char id=48 x=229 y=0 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
27 | char id=57 x=242 y=0 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
28 | char id=56 x=0 y=20 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
29 | char id=54 x=13 y=20 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
30 | char id=53 x=26 y=20 width=12 height=16 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
31 | char id=51 x=38 y=20 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
32 | char id=100 x=51 y=20 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
33 | char id=98 x=64 y=20 width=13 height=16 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
34 | char id=85 x=77 y=20 width=14 height=16 xoffset=-2 yoffset=3 xadvance=11 page=0 chnl=0
35 | char id=83 x=91 y=20 width=13 height=16 xoffset=-3 yoffset=3 xadvance=8 page=0 chnl=0
36 | char id=79 x=104 y=20 width=15 height=16 xoffset=-2 yoffset=3 xadvance=12 page=0 chnl=0
37 | char id=71 x=119 y=20 width=14 height=16 xoffset=-2 yoffset=3 xadvance=11 page=0 chnl=0
38 | char id=67 x=133 y=20 width=13 height=16 xoffset=-2 yoffset=3 xadvance=10 page=0 chnl=0
39 | char id=127 x=146 y=20 width=12 height=15 xoffset=-2 yoffset=3 xadvance=10 page=0 chnl=0
40 | char id=35 x=158 y=20 width=15 height=15 xoffset=-3 yoffset=3 xadvance=10 page=0 chnl=0
41 | char id=92 x=173 y=20 width=11 height=15 xoffset=-3 yoffset=3 xadvance=6 page=0 chnl=0
42 | char id=47 x=184 y=20 width=11 height=15 xoffset=-3 yoffset=3 xadvance=6 page=0 chnl=0
43 | char id=59 x=195 y=20 width=8 height=15 xoffset=-3 yoffset=6 xadvance=4 page=0 chnl=0
44 | char id=55 x=203 y=20 width=13 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
45 | char id=52 x=216 y=20 width=14 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
46 | char id=50 x=230 y=20 width=13 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
47 | char id=49 x=243 y=20 width=9 height=15 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
48 | char id=116 x=0 y=36 width=10 height=15 xoffset=-3 yoffset=4 xadvance=5 page=0 chnl=0
49 | char id=108 x=10 y=36 width=6 height=15 xoffset=-2 yoffset=3 xadvance=4 page=0 chnl=0
50 | char id=107 x=16 y=36 width=12 height=15 xoffset=-2 yoffset=3 xadvance=8 page=0 chnl=0
51 | char id=105 x=28 y=36 width=7 height=15 xoffset=-2 yoffset=3 xadvance=4 page=0 chnl=0
52 | char id=104 x=35 y=36 width=12 height=15 xoffset=-2 yoffset=3 xadvance=10 page=0 chnl=0
53 | char id=102 x=47 y=36 width=11 height=15 xoffset=-3 yoffset=3 xadvance=5 page=0 chnl=0
54 | char id=90 x=58 y=36 width=13 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
55 | char id=89 x=71 y=36 width=13 height=15 xoffset=-3 yoffset=3 xadvance=8 page=0 chnl=0
56 | char id=88 x=84 y=36 width=14 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
57 | char id=87 x=98 y=36 width=19 height=15 xoffset=-3 yoffset=3 xadvance=15 page=0 chnl=0
58 | char id=86 x=117 y=36 width=14 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
59 | char id=84 x=131 y=36 width=13 height=15 xoffset=-3 yoffset=3 xadvance=8 page=0 chnl=0
60 | char id=82 x=144 y=36 width=13 height=15 xoffset=-2 yoffset=3 xadvance=10 page=0 chnl=0
61 | char id=80 x=157 y=36 width=12 height=15 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
62 | char id=78 x=169 y=36 width=14 height=15 xoffset=-2 yoffset=3 xadvance=12 page=0 chnl=0
63 | char id=77 x=183 y=36 width=17 height=15 xoffset=-2 yoffset=3 xadvance=14 page=0 chnl=0
64 | char id=76 x=200 y=36 width=11 height=15 xoffset=-2 yoffset=3 xadvance=8 page=0 chnl=0
65 | char id=75 x=211 y=36 width=13 height=15 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
66 | char id=73 x=224 y=36 width=10 height=15 xoffset=-3 yoffset=3 xadvance=5 page=0 chnl=0
67 | char id=72 x=234 y=36 width=14 height=15 xoffset=-2 yoffset=3 xadvance=11 page=0 chnl=0
68 | char id=70 x=0 y=51 width=11 height=15 xoffset=-2 yoffset=3 xadvance=8 page=0 chnl=0
69 | char id=69 x=11 y=51 width=11 height=15 xoffset=-2 yoffset=3 xadvance=8 page=0 chnl=0
70 | char id=68 x=22 y=51 width=14 height=15 xoffset=-2 yoffset=3 xadvance=11 page=0 chnl=0
71 | char id=66 x=36 y=51 width=13 height=15 xoffset=-2 yoffset=3 xadvance=10 page=0 chnl=0
72 | char id=65 x=49 y=51 width=15 height=15 xoffset=-3 yoffset=3 xadvance=10 page=0 chnl=0
73 | char id=58 x=64 y=51 width=7 height=13 xoffset=-2 yoffset=6 xadvance=4 page=0 chnl=0
74 | char id=117 x=71 y=51 width=12 height=13 xoffset=-2 yoffset=6 xadvance=10 page=0 chnl=0
75 | char id=115 x=83 y=51 width=11 height=13 xoffset=-3 yoffset=6 xadvance=7 page=0 chnl=0
76 | char id=111 x=94 y=51 width=13 height=13 xoffset=-3 yoffset=6 xadvance=9 page=0 chnl=0
77 | char id=101 x=107 y=51 width=13 height=13 xoffset=-3 yoffset=6 xadvance=9 page=0 chnl=0
78 | char id=99 x=120 y=51 width=12 height=13 xoffset=-3 yoffset=6 xadvance=7 page=0 chnl=0
79 | char id=97 x=132 y=51 width=12 height=13 xoffset=-3 yoffset=6 xadvance=9 page=0 chnl=0
80 | char id=60 x=144 y=51 width=13 height=12 xoffset=-3 yoffset=5 xadvance=9 page=0 chnl=0
81 | char id=122 x=157 y=51 width=11 height=12 xoffset=-3 yoffset=6 xadvance=7 page=0 chnl=0
82 | char id=120 x=168 y=51 width=13 height=12 xoffset=-3 yoffset=6 xadvance=8 page=0 chnl=0
83 | char id=119 x=181 y=51 width=17 height=12 xoffset=-3 yoffset=6 xadvance=12 page=0 chnl=0
84 | char id=118 x=198 y=51 width=13 height=12 xoffset=-3 yoffset=6 xadvance=8 page=0 chnl=0
85 | char id=114 x=211 y=51 width=10 height=12 xoffset=-2 yoffset=6 xadvance=6 page=0 chnl=0
86 | char id=110 x=221 y=51 width=12 height=12 xoffset=-2 yoffset=6 xadvance=10 page=0 chnl=0
87 | char id=109 x=233 y=51 width=17 height=12 xoffset=-2 yoffset=6 xadvance=15 page=0 chnl=0
88 | char id=94 x=0 y=66 width=13 height=11 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
89 | char id=62 x=13 y=66 width=13 height=11 xoffset=-3 yoffset=5 xadvance=9 page=0 chnl=0
90 | char id=42 x=26 y=66 width=13 height=10 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
91 | char id=43 x=39 y=66 width=13 height=10 xoffset=-3 yoffset=6 xadvance=9 page=0 chnl=0
92 | char id=61 x=52 y=66 width=13 height=8 xoffset=-3 yoffset=7 xadvance=9 page=0 chnl=0
93 | char id=39 x=65 y=66 width=6 height=8 xoffset=-2 yoffset=3 xadvance=3 page=0 chnl=0
94 | char id=34 x=71 y=66 width=9 height=8 xoffset=-2 yoffset=3 xadvance=6 page=0 chnl=0
95 | char id=44 x=80 y=66 width=8 height=7 xoffset=-3 yoffset=14 xadvance=4 page=0 chnl=0
96 | char id=126 x=88 y=66 width=13 height=6 xoffset=-3 yoffset=8 xadvance=9 page=0 chnl=0
97 | char id=46 x=101 y=66 width=7 height=6 xoffset=-2 yoffset=13 xadvance=4 page=0 chnl=0
98 | char id=96 x=108 y=66 width=8 height=6 xoffset=0 yoffset=2 xadvance=9 page=0 chnl=0
99 | char id=45 x=116 y=66 width=9 height=5 xoffset=-3 yoffset=10 xadvance=5 page=0 chnl=0
100 | char id=95 x=125 y=66 width=13 height=4 xoffset=-4 yoffset=17 xadvance=6 page=0 chnl=0
101 | kernings count=-1
--------------------------------------------------------------------------------
/desktop/assets/skin/default.fnt:
--------------------------------------------------------------------------------
1 | info face="Droid Sans" size=17 bold=0 italic=0 charset="" unicode=0 stretchH=100 smooth=1 aa=1 padding=0,0,0,0 spacing=1,1
2 | common lineHeight=20 base=18 scaleW=256 scaleH=128 pages=1 packed=0
3 | page id=0 file="default.png"
4 | chars count=96
5 | char id=32 x=0 y=0 width=0 height=0 xoffset=0 yoffset=16 xadvance=4 page=0 chnl=0
6 | char id=124 x=0 y=0 width=6 height=20 xoffset=1 yoffset=3 xadvance=9 page=0 chnl=0
7 | char id=106 x=6 y=0 width=9 height=20 xoffset=-4 yoffset=3 xadvance=4 page=0 chnl=0
8 | char id=81 x=15 y=0 width=15 height=19 xoffset=-2 yoffset=3 xadvance=12 page=0 chnl=0
9 | char id=74 x=30 y=0 width=11 height=19 xoffset=-5 yoffset=3 xadvance=4 page=0 chnl=0
10 | char id=125 x=41 y=0 width=10 height=18 xoffset=-3 yoffset=3 xadvance=6 page=0 chnl=0
11 | char id=123 x=51 y=0 width=10 height=18 xoffset=-3 yoffset=3 xadvance=6 page=0 chnl=0
12 | char id=93 x=61 y=0 width=8 height=18 xoffset=-3 yoffset=3 xadvance=5 page=0 chnl=0
13 | char id=91 x=69 y=0 width=8 height=18 xoffset=-2 yoffset=3 xadvance=5 page=0 chnl=0
14 | char id=41 x=77 y=0 width=9 height=18 xoffset=-3 yoffset=3 xadvance=5 page=0 chnl=0
15 | char id=40 x=86 y=0 width=9 height=18 xoffset=-3 yoffset=3 xadvance=5 page=0 chnl=0
16 | char id=64 x=95 y=0 width=18 height=17 xoffset=-3 yoffset=3 xadvance=14 page=0 chnl=0
17 | char id=121 x=113 y=0 width=13 height=17 xoffset=-3 yoffset=6 xadvance=8 page=0 chnl=0
18 | char id=113 x=126 y=0 width=13 height=17 xoffset=-3 yoffset=6 xadvance=9 page=0 chnl=0
19 | char id=112 x=139 y=0 width=13 height=17 xoffset=-2 yoffset=6 xadvance=9 page=0 chnl=0
20 | char id=103 x=152 y=0 width=13 height=17 xoffset=-3 yoffset=6 xadvance=8 page=0 chnl=0
21 | char id=38 x=165 y=0 width=16 height=16 xoffset=-3 yoffset=3 xadvance=11 page=0 chnl=0
22 | char id=37 x=181 y=0 width=18 height=16 xoffset=-3 yoffset=3 xadvance=14 page=0 chnl=0
23 | char id=36 x=199 y=0 width=12 height=16 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
24 | char id=63 x=211 y=0 width=11 height=16 xoffset=-3 yoffset=3 xadvance=7 page=0 chnl=0
25 | char id=33 x=222 y=0 width=7 height=16 xoffset=-2 yoffset=3 xadvance=4 page=0 chnl=0
26 | char id=48 x=229 y=0 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
27 | char id=57 x=242 y=0 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
28 | char id=56 x=0 y=20 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
29 | char id=54 x=13 y=20 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
30 | char id=53 x=26 y=20 width=12 height=16 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
31 | char id=51 x=38 y=20 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
32 | char id=100 x=51 y=20 width=13 height=16 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
33 | char id=98 x=64 y=20 width=13 height=16 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
34 | char id=85 x=77 y=20 width=14 height=16 xoffset=-2 yoffset=3 xadvance=11 page=0 chnl=0
35 | char id=83 x=91 y=20 width=13 height=16 xoffset=-3 yoffset=3 xadvance=8 page=0 chnl=0
36 | char id=79 x=104 y=20 width=15 height=16 xoffset=-2 yoffset=3 xadvance=12 page=0 chnl=0
37 | char id=71 x=119 y=20 width=14 height=16 xoffset=-2 yoffset=3 xadvance=11 page=0 chnl=0
38 | char id=67 x=133 y=20 width=13 height=16 xoffset=-2 yoffset=3 xadvance=10 page=0 chnl=0
39 | char id=127 x=146 y=20 width=12 height=15 xoffset=-2 yoffset=3 xadvance=10 page=0 chnl=0
40 | char id=35 x=158 y=20 width=15 height=15 xoffset=-3 yoffset=3 xadvance=10 page=0 chnl=0
41 | char id=92 x=173 y=20 width=11 height=15 xoffset=-3 yoffset=3 xadvance=6 page=0 chnl=0
42 | char id=47 x=184 y=20 width=11 height=15 xoffset=-3 yoffset=3 xadvance=6 page=0 chnl=0
43 | char id=59 x=195 y=20 width=8 height=15 xoffset=-3 yoffset=6 xadvance=4 page=0 chnl=0
44 | char id=55 x=203 y=20 width=13 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
45 | char id=52 x=216 y=20 width=14 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
46 | char id=50 x=230 y=20 width=13 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
47 | char id=49 x=243 y=20 width=9 height=15 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
48 | char id=116 x=0 y=36 width=10 height=15 xoffset=-3 yoffset=4 xadvance=5 page=0 chnl=0
49 | char id=108 x=10 y=36 width=6 height=15 xoffset=-2 yoffset=3 xadvance=4 page=0 chnl=0
50 | char id=107 x=16 y=36 width=12 height=15 xoffset=-2 yoffset=3 xadvance=8 page=0 chnl=0
51 | char id=105 x=28 y=36 width=7 height=15 xoffset=-2 yoffset=3 xadvance=4 page=0 chnl=0
52 | char id=104 x=35 y=36 width=12 height=15 xoffset=-2 yoffset=3 xadvance=10 page=0 chnl=0
53 | char id=102 x=47 y=36 width=11 height=15 xoffset=-3 yoffset=3 xadvance=5 page=0 chnl=0
54 | char id=90 x=58 y=36 width=13 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
55 | char id=89 x=71 y=36 width=13 height=15 xoffset=-3 yoffset=3 xadvance=8 page=0 chnl=0
56 | char id=88 x=84 y=36 width=14 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
57 | char id=87 x=98 y=36 width=19 height=15 xoffset=-3 yoffset=3 xadvance=15 page=0 chnl=0
58 | char id=86 x=117 y=36 width=14 height=15 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
59 | char id=84 x=131 y=36 width=13 height=15 xoffset=-3 yoffset=3 xadvance=8 page=0 chnl=0
60 | char id=82 x=144 y=36 width=13 height=15 xoffset=-2 yoffset=3 xadvance=10 page=0 chnl=0
61 | char id=80 x=157 y=36 width=12 height=15 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
62 | char id=78 x=169 y=36 width=14 height=15 xoffset=-2 yoffset=3 xadvance=12 page=0 chnl=0
63 | char id=77 x=183 y=36 width=17 height=15 xoffset=-2 yoffset=3 xadvance=14 page=0 chnl=0
64 | char id=76 x=200 y=36 width=11 height=15 xoffset=-2 yoffset=3 xadvance=8 page=0 chnl=0
65 | char id=75 x=211 y=36 width=13 height=15 xoffset=-2 yoffset=3 xadvance=9 page=0 chnl=0
66 | char id=73 x=224 y=36 width=10 height=15 xoffset=-3 yoffset=3 xadvance=5 page=0 chnl=0
67 | char id=72 x=234 y=36 width=14 height=15 xoffset=-2 yoffset=3 xadvance=11 page=0 chnl=0
68 | char id=70 x=0 y=51 width=11 height=15 xoffset=-2 yoffset=3 xadvance=8 page=0 chnl=0
69 | char id=69 x=11 y=51 width=11 height=15 xoffset=-2 yoffset=3 xadvance=8 page=0 chnl=0
70 | char id=68 x=22 y=51 width=14 height=15 xoffset=-2 yoffset=3 xadvance=11 page=0 chnl=0
71 | char id=66 x=36 y=51 width=13 height=15 xoffset=-2 yoffset=3 xadvance=10 page=0 chnl=0
72 | char id=65 x=49 y=51 width=15 height=15 xoffset=-3 yoffset=3 xadvance=10 page=0 chnl=0
73 | char id=58 x=64 y=51 width=7 height=13 xoffset=-2 yoffset=6 xadvance=4 page=0 chnl=0
74 | char id=117 x=71 y=51 width=12 height=13 xoffset=-2 yoffset=6 xadvance=10 page=0 chnl=0
75 | char id=115 x=83 y=51 width=11 height=13 xoffset=-3 yoffset=6 xadvance=7 page=0 chnl=0
76 | char id=111 x=94 y=51 width=13 height=13 xoffset=-3 yoffset=6 xadvance=9 page=0 chnl=0
77 | char id=101 x=107 y=51 width=13 height=13 xoffset=-3 yoffset=6 xadvance=9 page=0 chnl=0
78 | char id=99 x=120 y=51 width=12 height=13 xoffset=-3 yoffset=6 xadvance=7 page=0 chnl=0
79 | char id=97 x=132 y=51 width=12 height=13 xoffset=-3 yoffset=6 xadvance=9 page=0 chnl=0
80 | char id=60 x=144 y=51 width=13 height=12 xoffset=-3 yoffset=5 xadvance=9 page=0 chnl=0
81 | char id=122 x=157 y=51 width=11 height=12 xoffset=-3 yoffset=6 xadvance=7 page=0 chnl=0
82 | char id=120 x=168 y=51 width=13 height=12 xoffset=-3 yoffset=6 xadvance=8 page=0 chnl=0
83 | char id=119 x=181 y=51 width=17 height=12 xoffset=-3 yoffset=6 xadvance=12 page=0 chnl=0
84 | char id=118 x=198 y=51 width=13 height=12 xoffset=-3 yoffset=6 xadvance=8 page=0 chnl=0
85 | char id=114 x=211 y=51 width=10 height=12 xoffset=-2 yoffset=6 xadvance=6 page=0 chnl=0
86 | char id=110 x=221 y=51 width=12 height=12 xoffset=-2 yoffset=6 xadvance=10 page=0 chnl=0
87 | char id=109 x=233 y=51 width=17 height=12 xoffset=-2 yoffset=6 xadvance=15 page=0 chnl=0
88 | char id=94 x=0 y=66 width=13 height=11 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
89 | char id=62 x=13 y=66 width=13 height=11 xoffset=-3 yoffset=5 xadvance=9 page=0 chnl=0
90 | char id=42 x=26 y=66 width=13 height=10 xoffset=-3 yoffset=3 xadvance=9 page=0 chnl=0
91 | char id=43 x=39 y=66 width=13 height=10 xoffset=-3 yoffset=6 xadvance=9 page=0 chnl=0
92 | char id=61 x=52 y=66 width=13 height=8 xoffset=-3 yoffset=7 xadvance=9 page=0 chnl=0
93 | char id=39 x=65 y=66 width=6 height=8 xoffset=-2 yoffset=3 xadvance=3 page=0 chnl=0
94 | char id=34 x=71 y=66 width=9 height=8 xoffset=-2 yoffset=3 xadvance=6 page=0 chnl=0
95 | char id=44 x=80 y=66 width=8 height=7 xoffset=-3 yoffset=14 xadvance=4 page=0 chnl=0
96 | char id=126 x=88 y=66 width=13 height=6 xoffset=-3 yoffset=8 xadvance=9 page=0 chnl=0
97 | char id=46 x=101 y=66 width=7 height=6 xoffset=-2 yoffset=13 xadvance=4 page=0 chnl=0
98 | char id=96 x=108 y=66 width=8 height=6 xoffset=0 yoffset=2 xadvance=9 page=0 chnl=0
99 | char id=45 x=116 y=66 width=9 height=5 xoffset=-3 yoffset=10 xadvance=5 page=0 chnl=0
100 | char id=95 x=125 y=66 width=13 height=4 xoffset=-4 yoffset=17 xadvance=6 page=0 chnl=0
101 | kernings count=-1
--------------------------------------------------------------------------------
/android/assets/fonts/bauchaomaicha.fnt:
--------------------------------------------------------------------------------
1 | info face="Bauchaomaicha Regular" size=32 bold=0 italic=0 charset="" unicode=0 stretchH=100 smooth=1 aa=1 padding=0,0,0,0 spacing=0,0
2 | common lineHeight=20 base=16 scaleW=512 scaleH=512 pages=1 packed=0
3 | page id=0 file="bauchaomaicha.png"
4 | chars count=95
5 | char id=32 x=0 y=0 width=0 height=0 xoffset=0 yoffset=16 xadvance=4 page=0 chnl=0
6 | char id=35 x=0 y=0 width=26 height=20 xoffset=0 yoffset=-1 xadvance=28 page=0 chnl=0
7 | char id=36 x=26 y=0 width=10 height=20 xoffset=0 yoffset=-1 xadvance=10 page=0 chnl=0
8 | char id=92 x=36 y=0 width=12 height=20 xoffset=1 yoffset=-1 xadvance=14 page=0 chnl=0
9 | char id=64 x=48 y=0 width=18 height=20 xoffset=0 yoffset=-1 xadvance=18 page=0 chnl=0
10 | char id=47 x=66 y=0 width=12 height=20 xoffset=0 yoffset=-1 xadvance=12 page=0 chnl=0
11 | char id=125 x=78 y=0 width=9 height=20 xoffset=0 yoffset=-1 xadvance=10 page=0 chnl=0
12 | char id=123 x=87 y=0 width=9 height=20 xoffset=0 yoffset=-1 xadvance=10 page=0 chnl=0
13 | char id=93 x=96 y=0 width=6 height=20 xoffset=0 yoffset=-1 xadvance=6 page=0 chnl=0
14 | char id=91 x=102 y=0 width=6 height=20 xoffset=0 yoffset=-1 xadvance=6 page=0 chnl=0
15 | char id=41 x=108 y=0 width=6 height=20 xoffset=0 yoffset=-1 xadvance=6 page=0 chnl=0
16 | char id=40 x=114 y=0 width=5 height=20 xoffset=0 yoffset=-1 xadvance=6 page=0 chnl=0
17 | char id=124 x=119 y=0 width=4 height=19 xoffset=2 yoffset=0 xadvance=6 page=0 chnl=0
18 | char id=106 x=123 y=0 width=12 height=19 xoffset=-4 yoffset=2 xadvance=4 page=0 chnl=0
19 | char id=38 x=135 y=0 width=14 height=18 xoffset=0 yoffset=1 xadvance=12 page=0 chnl=0
20 | char id=81 x=149 y=0 width=14 height=18 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
21 | char id=127 x=163 y=0 width=18 height=16 xoffset=0 yoffset=1 xadvance=12 page=0 chnl=0
22 | char id=37 x=181 y=0 width=18 height=16 xoffset=0 yoffset=1 xadvance=18 page=0 chnl=0
23 | char id=63 x=199 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
24 | char id=33 x=209 y=0 width=4 height=16 xoffset=0 yoffset=1 xadvance=4 page=0 chnl=0
25 | char id=48 x=213 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
26 | char id=57 x=223 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
27 | char id=56 x=233 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
28 | char id=55 x=243 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
29 | char id=54 x=253 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
30 | char id=53 x=263 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
31 | char id=52 x=273 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
32 | char id=51 x=283 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
33 | char id=50 x=293 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
34 | char id=121 x=303 y=0 width=14 height=16 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
35 | char id=116 x=317 y=0 width=11 height=16 xoffset=-2 yoffset=1 xadvance=8 page=0 chnl=0
36 | char id=113 x=328 y=0 width=14 height=16 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
37 | char id=112 x=342 y=0 width=14 height=16 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
38 | char id=108 x=356 y=0 width=8 height=16 xoffset=-2 yoffset=1 xadvance=4 page=0 chnl=0
39 | char id=107 x=364 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
40 | char id=104 x=378 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
41 | char id=103 x=392 y=0 width=14 height=16 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
42 | char id=102 x=406 y=0 width=14 height=16 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
43 | char id=100 x=420 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
44 | char id=98 x=430 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
45 | char id=90 x=444 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
46 | char id=89 x=458 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
47 | char id=88 x=472 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
48 | char id=87 x=486 y=0 width=16 height=16 xoffset=-2 yoffset=1 xadvance=12 page=0 chnl=0
49 | char id=86 x=0 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
50 | char id=85 x=14 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
51 | char id=84 x=28 y=20 width=13 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
52 | char id=83 x=41 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
53 | char id=82 x=55 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
54 | char id=80 x=69 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
55 | char id=79 x=83 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
56 | char id=78 x=97 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
57 | char id=77 x=111 y=20 width=16 height=16 xoffset=-2 yoffset=1 xadvance=12 page=0 chnl=0
58 | char id=76 x=127 y=20 width=13 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
59 | char id=75 x=140 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
60 | char id=74 x=154 y=20 width=8 height=16 xoffset=0 yoffset=1 xadvance=8 page=0 chnl=0
61 | char id=73 x=162 y=20 width=8 height=16 xoffset=-2 yoffset=1 xadvance=4 page=0 chnl=0
62 | char id=72 x=170 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
63 | char id=71 x=184 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
64 | char id=70 x=198 y=20 width=13 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
65 | char id=69 x=211 y=20 width=13 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
66 | char id=68 x=224 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
67 | char id=67 x=238 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
68 | char id=66 x=252 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
69 | char id=65 x=266 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
70 | char id=49 x=280 y=20 width=6 height=15 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
71 | char id=105 x=286 y=20 width=8 height=15 xoffset=-2 yoffset=2 xadvance=4 page=0 chnl=0
72 | char id=42 x=294 y=20 width=11 height=14 xoffset=0 yoffset=-1 xadvance=12 page=0 chnl=0
73 | char id=43 x=305 y=20 width=12 height=12 xoffset=0 yoffset=3 xadvance=12 page=0 chnl=0
74 | char id=59 x=317 y=20 width=4 height=12 xoffset=0 yoffset=5 xadvance=4 page=0 chnl=0
75 | char id=122 x=321 y=20 width=9 height=12 xoffset=0 yoffset=5 xadvance=10 page=0 chnl=0
76 | char id=120 x=330 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
77 | char id=119 x=344 y=20 width=16 height=12 xoffset=-2 yoffset=5 xadvance=12 page=0 chnl=0
78 | char id=118 x=360 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
79 | char id=117 x=374 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
80 | char id=115 x=388 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
81 | char id=114 x=402 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
82 | char id=111 x=416 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
83 | char id=110 x=430 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
84 | char id=109 x=444 y=20 width=16 height=12 xoffset=-2 yoffset=5 xadvance=12 page=0 chnl=0
85 | char id=101 x=460 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
86 | char id=99 x=474 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
87 | char id=97 x=488 y=20 width=10 height=12 xoffset=0 yoffset=5 xadvance=10 page=0 chnl=0
88 | char id=62 x=498 y=20 width=7 height=10 xoffset=0 yoffset=5 xadvance=8 page=0 chnl=0
89 | char id=60 x=0 y=36 width=7 height=10 xoffset=0 yoffset=5 xadvance=8 page=0 chnl=0
90 | char id=58 x=7 y=36 width=4 height=10 xoffset=0 yoffset=5 xadvance=4 page=0 chnl=0
91 | char id=126 x=11 y=36 width=11 height=8 xoffset=0 yoffset=5 xadvance=12 page=0 chnl=0
92 | char id=61 x=22 y=36 width=12 height=8 xoffset=0 yoffset=5 xadvance=12 page=0 chnl=0
93 | char id=44 x=34 y=36 width=4 height=6 xoffset=0 yoffset=13 xadvance=4 page=0 chnl=0
94 | char id=39 x=38 y=36 width=4 height=6 xoffset=0 yoffset=-1 xadvance=6 page=0 chnl=0
95 | char id=96 x=42 y=36 width=7 height=6 xoffset=0 yoffset=-1 xadvance=8 page=0 chnl=0
96 | char id=34 x=49 y=36 width=8 height=6 xoffset=0 yoffset=-1 xadvance=10 page=0 chnl=0
97 | char id=94 x=57 y=36 width=9 height=5 xoffset=0 yoffset=2 xadvance=10 page=0 chnl=0
98 | char id=95 x=66 y=36 width=14 height=4 xoffset=0 yoffset=13 xadvance=14 page=0 chnl=0
99 | char id=45 x=80 y=36 width=12 height=4 xoffset=0 yoffset=7 xadvance=12 page=0 chnl=0
100 | char id=46 x=92 y=36 width=4 height=4 xoffset=0 yoffset=13 xadvance=4 page=0 chnl=0
101 | kernings count=-1
102 |
--------------------------------------------------------------------------------
/desktop/assets/fonts/bauchaomaicha.fnt:
--------------------------------------------------------------------------------
1 | info face="Bauchaomaicha Regular" size=32 bold=0 italic=0 charset="" unicode=0 stretchH=100 smooth=1 aa=1 padding=0,0,0,0 spacing=0,0
2 | common lineHeight=20 base=16 scaleW=512 scaleH=512 pages=1 packed=0
3 | page id=0 file="bauchaomaicha.png"
4 | chars count=95
5 | char id=32 x=0 y=0 width=0 height=0 xoffset=0 yoffset=16 xadvance=4 page=0 chnl=0
6 | char id=35 x=0 y=0 width=26 height=20 xoffset=0 yoffset=-1 xadvance=28 page=0 chnl=0
7 | char id=36 x=26 y=0 width=10 height=20 xoffset=0 yoffset=-1 xadvance=10 page=0 chnl=0
8 | char id=92 x=36 y=0 width=12 height=20 xoffset=1 yoffset=-1 xadvance=14 page=0 chnl=0
9 | char id=64 x=48 y=0 width=18 height=20 xoffset=0 yoffset=-1 xadvance=18 page=0 chnl=0
10 | char id=47 x=66 y=0 width=12 height=20 xoffset=0 yoffset=-1 xadvance=12 page=0 chnl=0
11 | char id=125 x=78 y=0 width=9 height=20 xoffset=0 yoffset=-1 xadvance=10 page=0 chnl=0
12 | char id=123 x=87 y=0 width=9 height=20 xoffset=0 yoffset=-1 xadvance=10 page=0 chnl=0
13 | char id=93 x=96 y=0 width=6 height=20 xoffset=0 yoffset=-1 xadvance=6 page=0 chnl=0
14 | char id=91 x=102 y=0 width=6 height=20 xoffset=0 yoffset=-1 xadvance=6 page=0 chnl=0
15 | char id=41 x=108 y=0 width=6 height=20 xoffset=0 yoffset=-1 xadvance=6 page=0 chnl=0
16 | char id=40 x=114 y=0 width=5 height=20 xoffset=0 yoffset=-1 xadvance=6 page=0 chnl=0
17 | char id=124 x=119 y=0 width=4 height=19 xoffset=2 yoffset=0 xadvance=6 page=0 chnl=0
18 | char id=106 x=123 y=0 width=12 height=19 xoffset=-4 yoffset=2 xadvance=4 page=0 chnl=0
19 | char id=38 x=135 y=0 width=14 height=18 xoffset=0 yoffset=1 xadvance=12 page=0 chnl=0
20 | char id=81 x=149 y=0 width=14 height=18 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
21 | char id=127 x=163 y=0 width=18 height=16 xoffset=0 yoffset=1 xadvance=12 page=0 chnl=0
22 | char id=37 x=181 y=0 width=18 height=16 xoffset=0 yoffset=1 xadvance=18 page=0 chnl=0
23 | char id=63 x=199 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
24 | char id=33 x=209 y=0 width=4 height=16 xoffset=0 yoffset=1 xadvance=4 page=0 chnl=0
25 | char id=48 x=213 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
26 | char id=57 x=223 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
27 | char id=56 x=233 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
28 | char id=55 x=243 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
29 | char id=54 x=253 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
30 | char id=53 x=263 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
31 | char id=52 x=273 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
32 | char id=51 x=283 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
33 | char id=50 x=293 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
34 | char id=121 x=303 y=0 width=14 height=16 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
35 | char id=116 x=317 y=0 width=11 height=16 xoffset=-2 yoffset=1 xadvance=8 page=0 chnl=0
36 | char id=113 x=328 y=0 width=14 height=16 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
37 | char id=112 x=342 y=0 width=14 height=16 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
38 | char id=108 x=356 y=0 width=8 height=16 xoffset=-2 yoffset=1 xadvance=4 page=0 chnl=0
39 | char id=107 x=364 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
40 | char id=104 x=378 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
41 | char id=103 x=392 y=0 width=14 height=16 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
42 | char id=102 x=406 y=0 width=14 height=16 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
43 | char id=100 x=420 y=0 width=10 height=16 xoffset=0 yoffset=1 xadvance=10 page=0 chnl=0
44 | char id=98 x=430 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
45 | char id=90 x=444 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
46 | char id=89 x=458 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
47 | char id=88 x=472 y=0 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
48 | char id=87 x=486 y=0 width=16 height=16 xoffset=-2 yoffset=1 xadvance=12 page=0 chnl=0
49 | char id=86 x=0 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
50 | char id=85 x=14 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
51 | char id=84 x=28 y=20 width=13 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
52 | char id=83 x=41 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
53 | char id=82 x=55 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
54 | char id=80 x=69 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
55 | char id=79 x=83 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
56 | char id=78 x=97 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
57 | char id=77 x=111 y=20 width=16 height=16 xoffset=-2 yoffset=1 xadvance=12 page=0 chnl=0
58 | char id=76 x=127 y=20 width=13 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
59 | char id=75 x=140 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
60 | char id=74 x=154 y=20 width=8 height=16 xoffset=0 yoffset=1 xadvance=8 page=0 chnl=0
61 | char id=73 x=162 y=20 width=8 height=16 xoffset=-2 yoffset=1 xadvance=4 page=0 chnl=0
62 | char id=72 x=170 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
63 | char id=71 x=184 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
64 | char id=70 x=198 y=20 width=13 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
65 | char id=69 x=211 y=20 width=13 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
66 | char id=68 x=224 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
67 | char id=67 x=238 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
68 | char id=66 x=252 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
69 | char id=65 x=266 y=20 width=14 height=16 xoffset=-2 yoffset=1 xadvance=10 page=0 chnl=0
70 | char id=49 x=280 y=20 width=6 height=15 xoffset=0 yoffset=2 xadvance=6 page=0 chnl=0
71 | char id=105 x=286 y=20 width=8 height=15 xoffset=-2 yoffset=2 xadvance=4 page=0 chnl=0
72 | char id=42 x=294 y=20 width=11 height=14 xoffset=0 yoffset=-1 xadvance=12 page=0 chnl=0
73 | char id=43 x=305 y=20 width=12 height=12 xoffset=0 yoffset=3 xadvance=12 page=0 chnl=0
74 | char id=59 x=317 y=20 width=4 height=12 xoffset=0 yoffset=5 xadvance=4 page=0 chnl=0
75 | char id=122 x=321 y=20 width=9 height=12 xoffset=0 yoffset=5 xadvance=10 page=0 chnl=0
76 | char id=120 x=330 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
77 | char id=119 x=344 y=20 width=16 height=12 xoffset=-2 yoffset=5 xadvance=12 page=0 chnl=0
78 | char id=118 x=360 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
79 | char id=117 x=374 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
80 | char id=115 x=388 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
81 | char id=114 x=402 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
82 | char id=111 x=416 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
83 | char id=110 x=430 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
84 | char id=109 x=444 y=20 width=16 height=12 xoffset=-2 yoffset=5 xadvance=12 page=0 chnl=0
85 | char id=101 x=460 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
86 | char id=99 x=474 y=20 width=14 height=12 xoffset=-2 yoffset=5 xadvance=10 page=0 chnl=0
87 | char id=97 x=488 y=20 width=10 height=12 xoffset=0 yoffset=5 xadvance=10 page=0 chnl=0
88 | char id=62 x=498 y=20 width=7 height=10 xoffset=0 yoffset=5 xadvance=8 page=0 chnl=0
89 | char id=60 x=0 y=36 width=7 height=10 xoffset=0 yoffset=5 xadvance=8 page=0 chnl=0
90 | char id=58 x=7 y=36 width=4 height=10 xoffset=0 yoffset=5 xadvance=4 page=0 chnl=0
91 | char id=126 x=11 y=36 width=11 height=8 xoffset=0 yoffset=5 xadvance=12 page=0 chnl=0
92 | char id=61 x=22 y=36 width=12 height=8 xoffset=0 yoffset=5 xadvance=12 page=0 chnl=0
93 | char id=44 x=34 y=36 width=4 height=6 xoffset=0 yoffset=13 xadvance=4 page=0 chnl=0
94 | char id=39 x=38 y=36 width=4 height=6 xoffset=0 yoffset=-1 xadvance=6 page=0 chnl=0
95 | char id=96 x=42 y=36 width=7 height=6 xoffset=0 yoffset=-1 xadvance=8 page=0 chnl=0
96 | char id=34 x=49 y=36 width=8 height=6 xoffset=0 yoffset=-1 xadvance=10 page=0 chnl=0
97 | char id=94 x=57 y=36 width=9 height=5 xoffset=0 yoffset=2 xadvance=10 page=0 chnl=0
98 | char id=95 x=66 y=36 width=14 height=4 xoffset=0 yoffset=13 xadvance=14 page=0 chnl=0
99 | char id=45 x=80 y=36 width=12 height=4 xoffset=0 yoffset=7 xadvance=12 page=0 chnl=0
100 | char id=46 x=92 y=36 width=4 height=4 xoffset=0 yoffset=13 xadvance=4 page=0 chnl=0
101 | kernings count=-1
102 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/screens/TransactionView.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.screens;
2 |
3 | import com.badlogic.gdx.Gdx;
4 | import com.badlogic.gdx.Input.Keys;
5 | import com.badlogic.gdx.Net.HttpMethods;
6 | import com.badlogic.gdx.Net.HttpRequest;
7 | import com.badlogic.gdx.Net.HttpResponse;
8 | import com.badlogic.gdx.Net.HttpResponseListener;
9 | import com.badlogic.gdx.scenes.scene2d.InputEvent;
10 | import com.badlogic.gdx.scenes.scene2d.Stage;
11 | import com.badlogic.gdx.scenes.scene2d.ui.Dialog;
12 | import com.badlogic.gdx.scenes.scene2d.ui.Label;
13 | import com.badlogic.gdx.scenes.scene2d.ui.Table;
14 | import com.badlogic.gdx.scenes.scene2d.ui.TextButton;
15 | import com.badlogic.gdx.scenes.scene2d.ui.TextField;
16 | import com.badlogic.gdx.scenes.scene2d.utils.ClickListener;
17 | import com.google.gson.Gson;
18 | import com.jw.lightwallet.LightWallet;
19 | import com.jw.lightwallet.tx.TxResponse;
20 | import com.jw.lightwallet.utils.BalanceValues;
21 |
22 | public class TransactionView {
23 |
24 | LightWallet game;
25 | Stage stage;
26 | BalanceValues balancevalues;
27 |
28 | Table txlayout;
29 |
30 | Label addresslabel;
31 | TextField addressvalue;
32 | Label amountlabel;
33 | TextField amountvalue;
34 | Label mixinlabel;
35 | TextField mixinvalue;
36 | Label idlabel;
37 | TextField idvalue;
38 |
39 | TextButton sendbtn;
40 | String response;
41 | String failresponse;
42 |
43 | int padvalue;
44 |
45 |
46 | public TransactionView (final LightWallet game, final Stage stage, final BalanceValues balancevalues) {
47 | this.game = game;
48 | this.stage = stage;
49 | this.balancevalues = balancevalues;
50 |
51 | txlayout = new Table();
52 | padvalue = 15;
53 |
54 | addresslabel = new Label("Send to\naddress: ", game.uiSkin);
55 | addressvalue = new TextField("", game.uiSkin, "tinytext");
56 | txlayout.add(addresslabel).pad(padvalue).width(60);
57 | txlayout.add(addressvalue).pad(padvalue).width(650).row();
58 |
59 | amountlabel = new Label("Send amount XMR: ", game.uiSkin);
60 | amountvalue = new TextField("", game.uiSkin);
61 | txlayout.add(amountlabel).pad(padvalue).width(100);
62 | txlayout.add(amountvalue).pad(padvalue).width(100).row();
63 |
64 | mixinlabel = new Label("Mixin level (default 4, minimum 2): ", game.uiSkin);
65 | mixinvalue = new TextField("4", game.uiSkin);
66 | txlayout.add(mixinlabel).pad(padvalue).width(100);
67 | txlayout.add(mixinvalue).pad(padvalue).width(50).row();
68 |
69 | idlabel = new Label("Payment id: ", game.uiSkin);
70 | idvalue = new TextField("", game.uiSkin, "tinytext");
71 | txlayout.add(idlabel).pad(padvalue).width(100);
72 | txlayout.add(idvalue).pad(padvalue).width(600).row();
73 |
74 | sendbtn = new TextButton("Send payment!", game.uiSkin);
75 | txlayout.add(new Label("", game.uiSkin));
76 | txlayout.add(sendbtn).width(400);
77 |
78 | // Setup popup for bad addresses
79 | final Dialog badaddress = new Dialog("Bad address!", game.uiSkin, "dialog") {
80 | public void result(Object obj) {
81 | System.out.println("result "+obj);
82 | }
83 | };
84 | Label badaddresslabel = new Label("Monero addresses begin with a '4' and are 95 characters long.", game.uiSkin);
85 | badaddresslabel.setWrap(true);
86 | badaddress.add(badaddresslabel).width(400).row();
87 | badaddress.button("Continue", true).addListener(new ClickListener() {
88 | @Override
89 | public void clicked (InputEvent event, float x, float y) {
90 | badaddress.remove();
91 | }
92 | });
93 | badaddress.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
94 |
95 | // Setup popup for bad amount
96 | final Dialog badamount = new Dialog("Bad amount!", game.uiSkin, "dialog") {
97 | public void result(Object obj) {
98 | System.out.println("result "+obj);
99 | }
100 | };
101 | Label badamountlabel = new Label("Amount must be greater than 0.01 and less than current unlocked balance (minus fee).", game.uiSkin);
102 | badamountlabel.setWrap(true);
103 | badamount.add(badamountlabel).width(400).row();
104 | badamount.button("Continue", true).addListener(new ClickListener() {
105 | @Override
106 | public void clicked (InputEvent event, float x, float y) {
107 | badamount.remove();
108 | }
109 | });
110 | badamount.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
111 |
112 | // Setup popup for bad mixin
113 | final Dialog badmixin = new Dialog("Bad mixin!", game.uiSkin, "dialog") {
114 | public void result(Object obj) {
115 | System.out.println("result "+obj);
116 | }
117 | };
118 | Label badmixinlabel = new Label("Mixin must be an integer between 2 and 99.", game.uiSkin);
119 | badmixinlabel.setWrap(true);
120 | badmixin.add(badmixinlabel).width(400).row();
121 | badmixin.button("Continue", true).addListener(new ClickListener() {
122 | @Override
123 | public void clicked (InputEvent event, float x, float y) {
124 | badmixin.remove();
125 | }
126 | });
127 | badmixin.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
128 |
129 | // Setup popup for bad tx id
130 | final Dialog badpayid = new Dialog("Bad payment ID!", game.uiSkin, "dialog") {
131 | public void result(Object obj) {
132 | System.out.println("result "+obj);
133 | }
134 | };
135 | Label badpayidlabel = new Label("Payment ID must be 64 characters and only contain 0-9 and a-f.", game.uiSkin);
136 | badpayidlabel.setWrap(true);
137 | badpayid.add(badpayidlabel).width(400).row();
138 | badpayid.button("Continue", true).addListener(new ClickListener() {
139 | @Override
140 | public void clicked (InputEvent event, float x, float y) {
141 | badpayid.remove();
142 | }
143 | });
144 | badpayid.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
145 |
146 | sendbtn.addListener(new ClickListener() {
147 | @Override
148 | public void clicked (InputEvent event, float x, float y) {
149 | // Setup flags to check each tx input
150 | boolean isAddressGood = false;
151 | boolean isAmountGood = false;
152 | boolean isMixinGood = false;
153 | boolean isIdGood = false;
154 |
155 | // Check address and make badaddress popup if bad
156 | String address = addressvalue.getText();
157 | if (address.length() == 95) {
158 | if (address.substring(0, 1).equals("4")) {
159 | isAddressGood = true;
160 | } else {
161 | badaddress.show(stage);
162 | }
163 | } else {
164 | badaddress.show(stage);
165 | }
166 |
167 | // Check amount and make badamount popup if amount is non-numeric or too big
168 | long amount = 0;
169 | try {
170 | amount = (long)(Double.parseDouble(amountvalue.getText())*1e12);
171 | } catch (java.lang.NumberFormatException e) {
172 | System.out.print("No amount :(");
173 | }
174 | if (amount > 2e10 && amount < balancevalues.getUnlockedbalance()-1e10) {
175 | System.out.println("Amount is: " + amount + ", and balance is: " + balancevalues.getUnlockedbalance());
176 | isAmountGood = true;
177 | } else {
178 | badamount.show(stage);
179 | }
180 |
181 | int mixin = 4;
182 | try {
183 | mixin = Integer.parseInt(mixinvalue.getText());
184 | } catch (java.lang.NumberFormatException e) {
185 | System.out.print("No mixin :(");
186 | }
187 | if (mixin > 1 && mixin < 100) {
188 | isMixinGood = true;
189 | } else {
190 | badmixin.show(stage);
191 | }
192 |
193 | String id = idvalue.getText();
194 | if (id.length() == 0 || (id.length() == 64 && id.matches("\\p{XDigit}+"))) {
195 | isIdGood = true;
196 | } else {
197 | badpayid.show(stage);
198 | }
199 |
200 | System.out.println(address + "\n" + amount + "\n" + mixin + "\n" + id);
201 | System.out.println(String.format("%d", amount));
202 | System.out.println(isAddressGood + " " + isAmountGood + " " + isMixinGood + " " + isIdGood);
203 | String swaddress = "http://localhost:19091/json_rpc";
204 | String getbalance = String.format("{\"jsonrpc\":\"2.0\",\"id\":\"test\",\"method\":\"transfer\",\"params\":{"
205 | + "\"destinations\":[{\"amount\":%d,\"address\":\"%s\"}],\"fee\":100000000000,\"mixin\":%d,\"unlock_time\":0,"
206 | + "\"payment_id\":\"%s\"}", (long)(amount), address, mixin, id);
207 |
208 | if (isAddressGood && isAmountGood && isMixinGood && isIdGood) {
209 | System.out.println("Starting RPC call...");
210 | System.out.println(getbalance);
211 | HttpRequest httpGet = new HttpRequest(HttpMethods.POST);
212 | httpGet.setUrl(swaddress);
213 | httpGet.setContent(getbalance);
214 | httpGet.setTimeOut(2500);
215 | httpGet.setHeader("User-Agent", game.walletvalues.getUserAgent());
216 |
217 |
218 | Gdx.net.sendHttpRequest (httpGet, new HttpResponseListener() {
219 | public void handleHttpResponse(HttpResponse httpResponse) {
220 | response = httpResponse.getResultAsString();
221 | System.out.println("Success response is: " + response);
222 | TxResponse txresponse = new Gson().fromJson(response, TxResponse.class);
223 |
224 | System.out.println(txresponse.getResult().getTx_hash());
225 |
226 | String txid = txresponse.getResult().getTx_hash().substring(1, txresponse.getResult().getTx_hash().length()-1);;
227 |
228 | }
229 |
230 | public void failed(Throwable t) {
231 | failresponse = "failed";
232 | System.out.println("Failed response status is: " + failresponse);
233 |
234 | final Dialog errorpopup = new Dialog("Failed transaction!", game.uiSkin, "dialog") {
235 | public void result(Object obj) {
236 | System.out.println("result "+obj);
237 | }
238 | };
239 | Label errorpopuplabel = new Label("Transaction failed, please try again, maybe with a smaller amount.", game.uiSkin);
240 | errorpopuplabel.setWrap(true);
241 | errorpopup.add(errorpopuplabel).width(400).row();
242 | errorpopup.button("Continue", true).addListener(new ClickListener() {
243 | @Override
244 | public void clicked (InputEvent event, float x, float y) {
245 | errorpopup.remove();
246 | }
247 | });
248 | errorpopup.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
249 | errorpopup.show(stage);
250 | }
251 |
252 | @Override
253 | public void cancelled() {
254 | // TODO Auto-generated method stub
255 | }
256 | });
257 | }
258 | }
259 | });
260 |
261 | }
262 |
263 | }
264 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/screens/CreateScreen.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.screens;
2 |
3 | import java.io.BufferedReader;
4 | import java.io.IOException;
5 | import java.io.InputStreamReader;
6 | import java.io.OutputStreamWriter;
7 | import java.io.PrintWriter;
8 | import java.io.Writer;
9 | import java.security.MessageDigest;
10 | import java.security.NoSuchAlgorithmException;
11 |
12 | import com.badlogic.gdx.Gdx;
13 | import com.badlogic.gdx.Input.Keys;
14 | import com.badlogic.gdx.graphics.Texture;
15 | import com.badlogic.gdx.scenes.scene2d.InputEvent;
16 | import com.badlogic.gdx.scenes.scene2d.Stage;
17 | import com.badlogic.gdx.scenes.scene2d.ui.Dialog;
18 | import com.badlogic.gdx.scenes.scene2d.ui.Image;
19 | import com.badlogic.gdx.scenes.scene2d.ui.Label;
20 | import com.badlogic.gdx.scenes.scene2d.ui.Skin;
21 | import com.badlogic.gdx.scenes.scene2d.ui.Table;
22 | import com.badlogic.gdx.scenes.scene2d.ui.TextButton;
23 | import com.badlogic.gdx.scenes.scene2d.ui.TextField;
24 | import com.badlogic.gdx.scenes.scene2d.utils.ClickListener;
25 | import com.jw.lightwallet.LightWallet;
26 | import com.jw.lightwallet.utils.Constants;
27 |
28 | public class CreateScreen extends AbstractScreen {
29 |
30 | Stage stage;
31 | Table screenlayout;
32 | Skin uiSkin;
33 | int padvalue;
34 |
35 | Image logo;
36 | Texture logotex;
37 |
38 | Table textcontainer;
39 | String instruction;
40 | Label instructionlabel;
41 |
42 | Table inputtable;
43 | Label namelabel;
44 | TextField nametext;
45 | String name;
46 | Label pwlabel;
47 | TextField pwtext;
48 | String pw;
49 | Label pwrptlabel;
50 | TextField pwrpttext;
51 | String pwrpt;
52 | Label nodelabel;
53 | TextField nodetext;
54 |
55 | Table buttontable;
56 | TextButton createbutton;
57 | TextButton gobackbutton;
58 |
59 |
60 | public CreateScreen(final LightWallet game) {
61 | super(game);
62 | System.out.print("CreateScreen creating.");
63 |
64 | uiSkin = new Skin(Gdx.files.internal("assets/skin/uiskin.json"));
65 | padvalue = 20;
66 |
67 | stage = new Stage();
68 | Gdx.input.setInputProcessor(stage);
69 |
70 | screenlayout = new Table();
71 |
72 | logo = new Image(new Texture(Gdx.files.internal("assets/logo.png")));
73 | //logo.scaleBy(0.02f);
74 |
75 | instruction = "Please enter a name for your wallet in the \"Wallet name\" field. This is typically wallet.bin, "
76 | + "but you can make it whatever you like (as long as it is alphanumberic and periods only). "
77 | + "Then please enter a strong password for your wallet that you will use to unlock, and then repeat it to ensure it is correct. "
78 | + "Your password can be any combination of characters and symbols on your keyboard (I think). "
79 | + "The default bitmonerod node is set for moneroworld, if you want to run a local daemon change the node field to http://localhost:18081.";
80 |
81 | instructionlabel= new Label(instruction, uiSkin);
82 | instructionlabel.setWrap(true);
83 | textcontainer = new Table();
84 | textcontainer.add(instructionlabel).width(600);
85 |
86 | inputtable = new Table();
87 | namelabel = new Label("Wallet name: ", uiSkin);
88 | nametext = new TextField("", uiSkin);
89 | pwlabel = new Label("Password: ", uiSkin);
90 | pwtext = new TextField("", uiSkin);
91 | pwtext.setPasswordMode(true);
92 | pwtext.setPasswordCharacter((char) 42);
93 | pwrptlabel = new Label("Repeat password: ", uiSkin);
94 | pwrpttext = new TextField("", uiSkin);
95 | pwrpttext.setPasswordMode(true);
96 | pwrpttext.setPasswordCharacter((char) 42);
97 | nodelabel = new Label("Node address: ", uiSkin);
98 | nodetext = new TextField(Constants.moneroclubdmn, uiSkin);
99 | inputtable.add(namelabel).width(200);
100 | inputtable.add(nametext).width(400).row();
101 | inputtable.add(pwlabel).width(200);
102 | inputtable.add(pwtext).width(400).row();
103 | inputtable.add(pwrptlabel).width(200);
104 | inputtable.add(pwrpttext).width(400).row();
105 | inputtable.add(nodelabel).width(200);
106 | inputtable.add(nodetext).width(400).row();
107 |
108 | buttontable = new Table();
109 | createbutton = new TextButton("Create!", uiSkin);
110 | createbutton.addListener(new ClickListener() {
111 | @Override
112 | public void clicked (InputEvent event, float x, float y) {
113 | name = nametext.getText();
114 | pw = pwtext.getText();
115 | pwrpt = pwrpttext.getText();
116 | if (name.length() > 0 && pw.equals(pwrpt)) {
117 | System.out.println(name + ", " + pw + ", " + pwrpt);
118 | CreateWallet(name, pw, game.simplewalletloc);
119 | }
120 | //game.setScreen(game.getCreateScreen());
121 | }
122 | });
123 | gobackbutton = new TextButton("Cancel", uiSkin);
124 | gobackbutton.addListener(new ClickListener() {
125 | @Override
126 | public void clicked (InputEvent event, float x, float y) {
127 | game.setScreen(new WizardScreen(game));
128 | }
129 | });
130 | buttontable.add(createbutton).width(150);
131 | buttontable.add(gobackbutton).width(150);
132 |
133 | screenlayout.add(logo).pad(10).width(200).height(70).center().row();
134 | screenlayout.add(textcontainer).pad(padvalue).row();
135 | screenlayout.add(inputtable).pad(padvalue).row();
136 | screenlayout.add(buttontable).pad(padvalue).row();
137 |
138 | screenlayout.setFillParent(true);
139 | stage.addActor(screenlayout);
140 |
141 |
142 | }
143 |
144 | public void show() {
145 | super.show();
146 |
147 | }
148 |
149 | public void render(float delta) {
150 | super.render(delta);
151 |
152 | stage.draw();
153 | stage.act(delta);
154 |
155 | }
156 |
157 | public void dispose() {
158 | super.dispose();
159 |
160 | }
161 |
162 | public void CreateWallet(String name, String pw, String simplewalletloc) {
163 |
164 | int i = 0;
165 | boolean flag = false;
166 | String str = null;
167 | String seed = "";
168 |
169 | Dialog success_dialog = new Dialog("Success!", uiSkin, "dialog") {
170 | public void result(Object obj) {
171 | System.out.println("result "+obj);
172 | }
173 | };
174 | Label success_label = new Label("Wallet successfully created. " + name + " file is your binary wallet file. "
175 | + name + ".keys is your keys file; "
176 | + "the keys file is password protected and you can restore your binary wallet file with it. "
177 | + " A text file named " + name + "info.txt has also been created. This file contains your wallet recovery seed and view key. "
178 | + "Please encrypt this file or print it and delete it. Your wallet seed allows wallet recovery and bypasses your password."
179 | + "The text file " + name + "txs.txt is empty, but will contain your tx history after syncing the wallet and making txs. "
180 | + "A file named lightwallet.conf has also been created; this file specifies the wallet and node currently in use.", uiSkin);
181 | success_label.setWrap(true);
182 | success_dialog.add(success_label).width(400).row();
183 | success_dialog.button("Continue", true).addListener(new ClickListener() {
184 | @Override
185 | public void clicked (InputEvent event, float x, float y) {
186 | game.setScreen(new MainScreen(game));
187 | uiSkin.dispose();
188 | stage.dispose();
189 | }
190 | });
191 | success_dialog.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
192 |
193 |
194 |
195 | System.out.println("Starting creator");
196 |
197 | try {
198 | Process wp = Runtime.getRuntime().exec(simplewalletloc + " --generate-new-wallet " + name + " --password " + pw);
199 | Writer wr = new OutputStreamWriter( wp.getOutputStream() );
200 | BufferedReader rd = new BufferedReader( new InputStreamReader( wp.getInputStream() ) );
201 |
202 | System.out.println("Here is the standard output of the command:\n");
203 | while (true) {
204 | str = rd.readLine();
205 | System.out.println(i + " " + str);
206 | i += 1;
207 | if (str.contains("Japanese")) {
208 | break;
209 | }
210 | }
211 | wr.write( "0\n" );
212 | wr.flush();
213 |
214 | while (true) {
215 | str = rd.readLine();
216 | System.out.println(i + " " + str);
217 | i += 1;
218 | if (str.contains("*****") && flag == true) {break;}
219 | if (str.contains("*****")) {flag = true;}
220 | if (str.contains("new wallet:")) {
221 | game.walletvalues.setAddress(str.split("wallet: ")[1]);
222 | }
223 | if (str.contains("View key:")) {
224 | game.walletvalues.setViewkey(str.split("key: ")[1]);
225 | }
226 | if (i >=23 && i <=26) {seed += " " + str;}
227 | }
228 |
229 | wr.write( "exit\n" );
230 | wr.flush();
231 |
232 | String rando = name + Double.toString(Math.random());
233 | MessageDigest md = null;
234 | try {
235 | md = MessageDigest.getInstance("SHA-256");
236 | } catch (NoSuchAlgorithmException e) {
237 | // TODO Auto-generated catch block
238 | e.printStackTrace();
239 | }
240 | md.update(rando.getBytes("UTF-8")); // Change this to "UTF-16" if needed
241 | byte[] digest = md.digest();
242 |
243 | game.walletvalues.setName(name);
244 | game.walletvalues.setPw(pw);
245 | game.walletvalues.setSeed(seed);
246 | game.walletvalues.setNode(nodetext.getText());
247 | game.walletvalues.setUserAgent(digest.toString());
248 |
249 | PrintWriter infowriter = new PrintWriter(name + "info.txt", "UTF-8");
250 | infowriter.println("Wallet name: " + name);
251 | infowriter.println("Wallet pw: " + pw);
252 | infowriter.println("Wallet address: " + game.walletvalues.getAddress());
253 | infowriter.println("Wallet view key: " + game.walletvalues.getViewkey());
254 | infowriter.println("Wallet seed: " + game.walletvalues.getSeed());
255 | infowriter.close();
256 |
257 | PrintWriter confwriter = new PrintWriter("lightwallet.conf", "UTF-8");
258 | confwriter.println("Wallet name: " + name);
259 | confwriter.println("Wallet address: " + game.walletvalues.getAddress());
260 | confwriter.println("Wallet view key: " + game.walletvalues.getViewkey());
261 | confwriter.println("Node address: " + nodetext.getText());
262 | confwriter.println("User agent: " + digest.toString());
263 | confwriter.close();
264 |
265 | PrintWriter txwriter = new PrintWriter(name + "tx.txt", "UTF-8");
266 | txwriter.println("Transaction history (Type | Amount | Tx ID): ");
267 | txwriter.close();
268 |
269 | wp.destroy();
270 |
271 | success_dialog.show(stage);
272 | }
273 |
274 | catch (IOException e) {
275 | System.out.println("exception happened - here's what I know: ");
276 | e.printStackTrace();
277 | }
278 | Gdx.app.log(LightWallet.LOG, "Address is: " + game.walletvalues.getAddress());
279 | Gdx.app.log(LightWallet.LOG, "Seed is: " + game.walletvalues.getSeed());
280 | }
281 |
282 |
283 | }
284 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/screens/ImportKeysScreen.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.screens;
2 |
3 | import java.io.BufferedReader;
4 | import java.io.File;
5 | import java.io.IOException;
6 | import java.io.InputStreamReader;
7 | import java.io.OutputStreamWriter;
8 | import java.io.PrintWriter;
9 | import java.io.Writer;
10 | import java.nio.file.Files;
11 | import java.nio.file.StandardCopyOption;
12 | import java.security.MessageDigest;
13 | import java.security.NoSuchAlgorithmException;
14 |
15 | import com.badlogic.gdx.Gdx;
16 | import com.badlogic.gdx.Input.Keys;
17 | import com.badlogic.gdx.graphics.Texture;
18 | import com.badlogic.gdx.scenes.scene2d.InputEvent;
19 | import com.badlogic.gdx.scenes.scene2d.Stage;
20 | import com.badlogic.gdx.scenes.scene2d.ui.Dialog;
21 | import com.badlogic.gdx.scenes.scene2d.ui.Image;
22 | import com.badlogic.gdx.scenes.scene2d.ui.Label;
23 | import com.badlogic.gdx.scenes.scene2d.ui.Skin;
24 | import com.badlogic.gdx.scenes.scene2d.ui.Table;
25 | import com.badlogic.gdx.scenes.scene2d.ui.TextButton;
26 | import com.badlogic.gdx.scenes.scene2d.ui.TextField;
27 | import com.badlogic.gdx.scenes.scene2d.utils.ClickListener;
28 | import com.jw.lightwallet.LightWallet;
29 | import com.jw.lightwallet.utils.Constants;
30 |
31 | public class ImportKeysScreen extends AbstractScreen {
32 |
33 | Stage stage;
34 | Table screenlayout;
35 | int padvalue;
36 |
37 | Image logo;
38 | Texture logotex;
39 |
40 | Table textcontainer;
41 | String instruction;
42 | Label instructionlabel;
43 |
44 | Table inputtable;
45 | Label pathlabel;
46 | TextField pathtext;
47 | String path;
48 | Label pwlabel;
49 | TextField pwtext;
50 | String pw;
51 | Label nodelabel;
52 | TextField nodetext;
53 |
54 | Table buttontable;
55 | TextButton importbutton;
56 | TextButton gobackbutton;
57 |
58 |
59 | public ImportKeysScreen(final LightWallet game) {
60 | super(game);
61 |
62 | padvalue = 20;
63 |
64 | stage = new Stage();
65 | Gdx.input.setInputProcessor(stage);
66 |
67 | screenlayout = new Table();
68 |
69 | logo = new Image(new Texture(Gdx.files.internal("assets/logo.png")));
70 | //logo.scaleBy(0.02f);
71 |
72 | instruction = "Please enter the full path location of your .keys file to import in the file location field; , "
73 | + "for instance: C:\\Users\\jw\\secretstuff\\wallet.keys or /home/jw/secretstuff/wallet.keys. "
74 | + "Then please enter your password to unlock the wallet. "
75 | + "The wallet keys file will be copied to the local directory and a new binary file will be created. "
76 | + "The default bitmonerod node is set for moneroworld, if you want to run a local daemon change the node field to http://localhost:18081.";
77 |
78 | instructionlabel= new Label(instruction, game.uiSkin);
79 | instructionlabel.setWrap(true);
80 | textcontainer = new Table();
81 | textcontainer.add(instructionlabel).width(600);
82 |
83 | inputtable = new Table();
84 |
85 | pathlabel = new Label("Wallet path: ", game.uiSkin);
86 | pathtext = new TextField("", game.uiSkin);
87 |
88 | pwlabel = new Label("Password: ", game.uiSkin);
89 | pwtext = new TextField("", game.uiSkin);
90 | pwtext.setPasswordMode(true);
91 | pwtext.setPasswordCharacter((char) 42);
92 |
93 | nodelabel = new Label("Node address: ", game.uiSkin);
94 | nodetext = new TextField(Constants.moneroclubdmn, game.uiSkin);
95 |
96 | inputtable.add(pathlabel).width(200);
97 | inputtable.add(pathtext).width(400).row();
98 | inputtable.add(pwlabel).width(200);
99 | inputtable.add(pwtext).width(400).row();
100 | inputtable.add(nodelabel).width(200);
101 | inputtable.add(nodetext).width(400).row();
102 |
103 | buttontable = new Table();
104 |
105 | importbutton = new TextButton("Import!", game.uiSkin);
106 | importbutton.addListener(new ClickListener() {
107 | @Override
108 | public void clicked (InputEvent event, float x, float y) {
109 | path = pathtext.getText();
110 | pw = pwtext.getText();
111 | System.out.println(path + ", " + pw);
112 | ImportWallet(path, pw, game.simplewalletloc);
113 | }
114 | });
115 |
116 | gobackbutton = new TextButton("Cancel", game.uiSkin);
117 | gobackbutton.addListener(new ClickListener() {
118 | @Override
119 | public void clicked (InputEvent event, float x, float y) {
120 | game.setScreen(new WizardScreen(game));
121 | }
122 | });
123 |
124 | buttontable.add(importbutton).width(150);
125 | buttontable.add(gobackbutton).width(150);
126 |
127 | screenlayout.add(logo).pad(10).width(200).height(70).center().row();
128 | screenlayout.add(textcontainer).pad(padvalue).row();
129 | screenlayout.add(inputtable).pad(padvalue).row();
130 | screenlayout.add(buttontable).pad(padvalue).row();
131 |
132 | screenlayout.setFillParent(true);
133 | stage.addActor(screenlayout);
134 |
135 |
136 | }
137 |
138 | public void show() {
139 | super.show();
140 |
141 | }
142 |
143 | public void render(float delta) {
144 | super.render(delta);
145 |
146 | stage.draw();
147 | stage.act(delta);
148 |
149 | }
150 |
151 | public void dispose() {
152 | super.dispose();
153 |
154 | }
155 |
156 | public void ImportWallet(String path, String pw, String simplewalletloc) {
157 |
158 | // Initialize variables local to ImportWallet function
159 | int i = 0;
160 | String str = null;
161 |
162 | File file = new File(path);
163 | String fname = file.getName();
164 | String name = null;
165 |
166 |
167 | // Create success and failure dialogs to show based on outcome
168 | Dialog successdialog = new Dialog("Success!", game.uiSkin, "dialog") {
169 | public void result(Object obj) {
170 | System.out.println("result "+obj);
171 | }
172 | };
173 | Label successlabel = new Label("", game.uiSkin);
174 | successlabel.setWrap(true);
175 | successdialog.add(successlabel).width(400).row();
176 | successdialog.button("Continue", true).addListener(new ClickListener() {
177 | @Override
178 | public void clicked (InputEvent event, float x, float y) {
179 | game.setScreen(new MainScreen(game));
180 | stage.dispose();
181 | }
182 | });
183 | successdialog.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
184 |
185 | Dialog failuredialog = new Dialog("Utter failure!", game.uiSkin, "dialog") {
186 | public void result(Object obj) {
187 | System.out.println("result "+obj);
188 | }
189 | };
190 | Label failurelabel = new Label("Wallet import failed. Click to start over.", game.uiSkin);
191 | failurelabel.setWrap(true);
192 | failuredialog.add(failurelabel).width(400).row();
193 | failuredialog.button("Continue", true).addListener(new ClickListener() {
194 | @Override
195 | public void clicked (InputEvent event, float x, float y) {
196 | game.setScreen(new WizardScreen(game));
197 | stage.dispose();
198 | }
199 | });
200 | failuredialog.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
201 |
202 |
203 | // Try to parse wallet path for name of wallet and if fail throw failure screen
204 | try {
205 | name = fname.substring(0, fname.lastIndexOf('.'));
206 | }
207 | catch (Exception e) {
208 | failuredialog.show(stage);
209 | e.printStackTrace();
210 | return;
211 | }
212 |
213 |
214 | try {
215 | Files.copy(file.toPath(), new File(file.getName()).toPath(), StandardCopyOption.REPLACE_EXISTING);
216 | }
217 | catch (IOException e) {
218 | failuredialog.show(stage);
219 | e.printStackTrace();
220 | return;
221 | }
222 |
223 |
224 | try {
225 | Process wp = Runtime.getRuntime().exec(simplewalletloc + " --wallet-file " + name + " --password " + pw + " --daemon-address http://localhost:66666");
226 | Writer wr = new OutputStreamWriter( wp.getOutputStream() );
227 | BufferedReader rd = new BufferedReader( new InputStreamReader( wp.getInputStream() ) );
228 |
229 | System.out.println("Here is the standard output of the command:\n");
230 | while (true) {
231 | str = rd.readLine();
232 | System.out.println(i + " " + str);
233 | if (str.contains("Opened wallet:")) {
234 | game.walletvalues.setAddress(str.split("wallet: ")[1]);
235 | }
236 | i += 1;
237 | if (i > 3 && str.contains("****")) {
238 | break;
239 | }
240 | }
241 | str = rd.readLine();
242 | str = rd.readLine();
243 | str = rd.readLine();
244 | str = rd.readLine();
245 | str = rd.readLine();
246 |
247 | wr.write( "viewkey\n" );
248 | wr.flush();
249 |
250 | str = rd.readLine();
251 | // str = rd.readLine();
252 | // System.out.println(i + " " + str.split(": ")[1]);
253 | System.out.println(i + " " + str);
254 | i += 1;
255 | // game.walletvalues.setViewkey(str.split(": ")[1]);
256 | game.walletvalues.setViewkey(str);
257 | str = rd.readLine();
258 |
259 | wr.write( "seed\n" );
260 | wr.flush();
261 |
262 | // str = rd.readLine();
263 | // System.out.println(i + " " + str.substring(str.indexOf(":"), str.length()));
264 | System.out.println(i + " " + str);
265 | i += 1;
266 | // game.walletvalues.setSeed(str.substring(str.indexOf(":"), str.length()));
267 | game.walletvalues.setSeed(str);
268 |
269 | wr.write( "exit\n" );
270 | wr.flush();
271 |
272 | String rando = name + Double.toString(Math.random());
273 | MessageDigest md = null;
274 | try {
275 | md = MessageDigest.getInstance("SHA-256");
276 | } catch (NoSuchAlgorithmException e) {
277 | // TODO Auto-generated catch block
278 | e.printStackTrace();
279 | }
280 | md.update(rando.getBytes("UTF-8")); // Change this to "UTF-16" if needed
281 | byte[] digest = md.digest();
282 |
283 | game.walletvalues.setName(name);
284 | game.walletvalues.setPw(pw);
285 | game.walletvalues.setNode(nodetext.getText());
286 | game.walletvalues.setUserAgent(digest.toString());
287 |
288 |
289 | PrintWriter infowriter = new PrintWriter(name + "info.txt", "UTF-8");
290 | infowriter.println("Wallet name: " + name);
291 | infowriter.println("Wallet pw: " + pw);
292 | infowriter.println("Wallet address: " + game.walletvalues.getAddress());
293 | infowriter.println("Wallet view key: " + game.walletvalues.getViewkey());
294 | infowriter.println("Wallet seed: " + game.walletvalues.getSeed());
295 | infowriter.close();
296 |
297 | PrintWriter confwriter = new PrintWriter("lightwallet.conf", "UTF-8");
298 | confwriter.println("Wallet name: " + name);
299 | confwriter.println("Wallet address: " + game.walletvalues.getAddress());
300 | confwriter.println("Wallet view key: " + game.walletvalues.getViewkey());
301 | confwriter.println("Node address: " + nodetext.getText());
302 | confwriter.println("User agent: " + digest.toString());
303 | confwriter.close();
304 |
305 | PrintWriter txwriter = new PrintWriter(name + "tx.txt", "UTF-8");
306 | txwriter.println("Transaction history (Type | Amount | Tx ID): ");
307 | txwriter.close();
308 |
309 | wp.destroy();
310 |
311 | successlabel.setText("Wallet successfully imported. " + game.walletvalues.getName() + " file is your binary wallet file. "
312 | + game.walletvalues.getName() + ".keys is your keys file; "
313 | + "the keys file is password protected and you can restore your binary wallet file with it. "
314 | + " A text file named " + game.walletvalues.getName() + "info.txt has also been created. "
315 | + "This file contains your wallet recovery seed and view key. "
316 | + "Please encrypt this file or print it and delete it. Your wallet seed allows wallet recovery and bypasses your password."
317 | + "The text file " + game.walletvalues.getName() + "txs.txt is empty, but will contain your tx history after syncing the wallet. "
318 | + "A file named lightwallet.conf has also been created; this file specifies the wallet and node currently in use.");
319 | successdialog.show(stage);
320 | }
321 |
322 | catch (IOException e) {
323 | System.out.println("exception happened - here's what I know: ");
324 | e.printStackTrace();
325 | failuredialog.show(stage);
326 | return;
327 | }
328 |
329 | Gdx.app.log(LightWallet.LOG, "Address is: " + game.walletvalues.getAddress());
330 | Gdx.app.log(LightWallet.LOG, "Seed is: " + game.walletvalues.getSeed());
331 | }
332 |
333 | }
334 |
--------------------------------------------------------------------------------
/core/src/com/jw/lightwallet/screens/ImportSeedScreen.java:
--------------------------------------------------------------------------------
1 | package com.jw.lightwallet.screens;
2 |
3 | import java.io.BufferedReader;
4 | import java.io.File;
5 | import java.io.IOException;
6 | import java.io.InputStreamReader;
7 | import java.io.OutputStreamWriter;
8 | import java.io.PrintWriter;
9 | import java.io.Writer;
10 | import java.nio.file.Files;
11 | import java.nio.file.StandardCopyOption;
12 | import java.security.MessageDigest;
13 | import java.security.NoSuchAlgorithmException;
14 |
15 | import com.badlogic.gdx.Gdx;
16 | import com.badlogic.gdx.Input.Keys;
17 | import com.badlogic.gdx.graphics.Texture;
18 | import com.badlogic.gdx.scenes.scene2d.InputEvent;
19 | import com.badlogic.gdx.scenes.scene2d.Stage;
20 | import com.badlogic.gdx.scenes.scene2d.ui.Dialog;
21 | import com.badlogic.gdx.scenes.scene2d.ui.Image;
22 | import com.badlogic.gdx.scenes.scene2d.ui.Label;
23 | import com.badlogic.gdx.scenes.scene2d.ui.Table;
24 | import com.badlogic.gdx.scenes.scene2d.ui.TextButton;
25 | import com.badlogic.gdx.scenes.scene2d.ui.TextField;
26 | import com.badlogic.gdx.scenes.scene2d.utils.ClickListener;
27 | import com.jw.lightwallet.LightWallet;
28 | import com.jw.lightwallet.utils.Constants;
29 |
30 | public class ImportSeedScreen extends AbstractScreen {
31 |
32 | Stage stage;
33 | Table screenlayout;
34 | int padvalue;
35 |
36 | Image logo;
37 | Texture logotex;
38 |
39 | Table textcontainer;
40 | String instruction;
41 | Label instructionlabel;
42 |
43 | Table inputtable;
44 | Label namelabel;
45 | TextField nametext;
46 | String name;
47 | Label seedlabel;
48 | TextField seedtext;
49 | String seed;
50 | Label pwlabel;
51 | TextField pwtext;
52 | String pw;
53 | Label pwrptlabel;
54 | TextField pwrpttext;
55 | String pwrpt;
56 | Label nodelabel;
57 | TextField nodetext;
58 |
59 | Table buttontable;
60 | TextButton importbutton;
61 | TextButton gobackbutton;
62 |
63 | public ImportSeedScreen(final LightWallet game) {
64 | super(game);
65 |
66 | padvalue = 20;
67 |
68 | stage = new Stage();
69 | Gdx.input.setInputProcessor(stage);
70 |
71 | screenlayout = new Table();
72 |
73 | logo = new Image(new Texture(Gdx.files.internal("assets/logo.png")));
74 | //logo.scaleBy(0.02f);
75 |
76 | instruction = "Please enter a name for your wallet, the 25 word mnemonic seed to import in the seed field, "
77 | + " a password to unlock the wallet in the password field, "
78 | + "and then repeat the password to make sure you have it correct, this will be used to encrypt your newly restored wallet files. "
79 | + "The default bitmonerod node is set for moneroworld, if you want to run a local daemon change the node field to http://localhost:18081.";
80 |
81 | instructionlabel= new Label(instruction, game.uiSkin);
82 | instructionlabel.setWrap(true);
83 | textcontainer = new Table();
84 | textcontainer.add(instructionlabel).width(600);
85 |
86 | inputtable = new Table();
87 |
88 | namelabel = new Label("Wallet name: ", game.uiSkin);
89 | nametext = new TextField("", game.uiSkin);
90 |
91 | seedlabel = new Label("Wallet seed: ", game.uiSkin);
92 | seedtext = new TextField("", game.uiSkin);
93 |
94 | pwlabel = new Label("Password: ", game.uiSkin);
95 | pwtext = new TextField("", game.uiSkin);
96 | pwtext.setPasswordMode(true);
97 | pwtext.setPasswordCharacter((char) 42);
98 |
99 | pwrptlabel = new Label("Repeat password: ", game.uiSkin);
100 | pwrpttext = new TextField("", game.uiSkin);
101 | pwrpttext.setPasswordMode(true);
102 | pwrpttext.setPasswordCharacter((char) 42);
103 |
104 | nodelabel = new Label("Node address: ", game.uiSkin);
105 | nodetext = new TextField(Constants.moneroclubdmn, game.uiSkin);
106 |
107 | inputtable.add(namelabel).width(200);
108 | inputtable.add(nametext).width(400).row();
109 | inputtable.add(seedlabel).width(200);
110 | inputtable.add(seedtext).width(400).row();
111 | inputtable.add(pwlabel).width(200);
112 | inputtable.add(pwtext).width(400).row();
113 | inputtable.add(pwrptlabel).width(200);
114 | inputtable.add(pwrpttext).width(400).row();
115 | inputtable.add(nodelabel).width(200);
116 | inputtable.add(nodetext).width(400).row();
117 |
118 | buttontable = new Table();
119 |
120 | // Create check entries dialog
121 | final Dialog checkdialog = new Dialog("Check your inputs!", game.uiSkin, "dialog") {
122 | public void result(Object obj) {
123 | System.out.println("result "+obj);
124 | }
125 | };
126 | Label checklabel = new Label("Please check that you have entered a valid file name, that your seed is 25 words"
127 | + ", and that the passwords you have input are the same, then try again.", game.uiSkin);
128 | checklabel.setWrap(true);
129 | checkdialog.add(checklabel).width(400).row();
130 | checkdialog.button("Continue", true).addListener(new ClickListener() {
131 | @Override
132 | public void clicked (InputEvent event, float x, float y) {
133 | checkdialog.remove();
134 | }
135 | });
136 | checkdialog.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
137 |
138 | importbutton = new TextButton("Import!", game.uiSkin);
139 | importbutton.addListener(new ClickListener() {
140 | @Override
141 | public void clicked (InputEvent event, float x, float y) {
142 | name = nametext.getText();
143 | seed = seedtext.getText();
144 | pw = pwtext.getText();
145 | pwrpt = pwrpttext.getText();
146 | System.out.println(seed + ", " + pw);
147 | if (name.length() > 0 && seed.trim().split("\\s+").length == 25 && pw.equals(pwrpt)) {
148 | ImportWallet(seed, pw, game.simplewalletloc);
149 | } else {checkdialog.show(stage);}
150 | }
151 | });
152 |
153 | gobackbutton = new TextButton("Cancel", game.uiSkin);
154 | gobackbutton.addListener(new ClickListener() {
155 | @Override
156 | public void clicked (InputEvent event, float x, float y) {
157 | game.setScreen(new WizardScreen(game));
158 | }
159 | });
160 |
161 | buttontable.add(importbutton).width(150);
162 | buttontable.add(gobackbutton).width(150);
163 |
164 | screenlayout.add(logo).pad(10).width(200).height(70).center().row();
165 | screenlayout.add(textcontainer).pad(padvalue).row();
166 | screenlayout.add(inputtable).pad(padvalue).row();
167 | screenlayout.add(buttontable).pad(padvalue).row();
168 |
169 | screenlayout.setFillParent(true);
170 | stage.addActor(screenlayout);
171 |
172 |
173 | }
174 |
175 | public void show() {
176 | super.show();
177 |
178 | }
179 |
180 | public void render(float delta) {
181 | super.render(delta);
182 |
183 | stage.draw();
184 | stage.act(delta);
185 |
186 | }
187 |
188 | public void dispose() {
189 | super.dispose();
190 |
191 | }
192 |
193 | public void ImportWallet(String path, String pw, String simplewalletloc) {
194 |
195 | // Initialize variables local to ImportWallet function
196 | int i = 0;
197 | String str = null;
198 |
199 | // Create success and failure dialogs to show based on outcome
200 | Dialog successdialog = new Dialog("Success!", game.uiSkin, "dialog") {
201 | public void result(Object obj) {
202 | System.out.println("result "+obj);
203 | }
204 | };
205 | Label successlabel = new Label("", game.uiSkin);
206 | successlabel.setWrap(true);
207 | successdialog.add(successlabel).width(400).row();
208 | successdialog.button("Continue", true).addListener(new ClickListener() {
209 | @Override
210 | public void clicked (InputEvent event, float x, float y) {
211 | game.setScreen(new MainScreen(game));
212 | stage.dispose();
213 | }
214 | });
215 | successdialog.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
216 |
217 | Dialog failuredialog = new Dialog("Utter failure!", game.uiSkin, "dialog") {
218 | public void result(Object obj) {
219 | System.out.println("result "+obj);
220 | }
221 | };
222 | Label failurelabel = new Label("Wallet import failed. Click to start over.", game.uiSkin);
223 | failurelabel.setWrap(true);
224 | failuredialog.add(failurelabel).width(400).row();
225 | failuredialog.button("Continue", true).addListener(new ClickListener() {
226 | @Override
227 | public void clicked (InputEvent event, float x, float y) {
228 | game.setScreen(new WizardScreen(game));
229 | stage.dispose();
230 | }
231 | });
232 | failuredialog.key(Keys.ENTER, true); //sends "true" when the ENTER key is pressed
233 |
234 |
235 | try {
236 | Process wp = Runtime.getRuntime().exec(simplewalletloc + " --restore-deterministic-wallet --wallet-file " + name + " --password " + pw + " --daemon-address http://localhost:66666");
237 | Writer wr = new OutputStreamWriter( wp.getOutputStream() );
238 | BufferedReader rd = new BufferedReader( new InputStreamReader( wp.getInputStream() ) );
239 |
240 | System.out.println("Here is the standard output of the command:\n");
241 |
242 | while (true) {
243 | str = rd.readLine();
244 | System.out.println(i + " " + str);
245 | i += 1;
246 | if (i > 0 && str.contains("Logging at")) {
247 | break;
248 | }
249 | }
250 |
251 | wr.write( seed + "\n" );
252 | wr.flush();
253 | wr.write("0\n" );
254 | wr.flush();
255 |
256 |
257 |
258 | while (true) {
259 | str = rd.readLine();
260 | System.out.println(i + " " + str);
261 | if (str.contains("new wallet:")) {
262 | game.walletvalues.setAddress(str.split("wallet: ")[1]);
263 | }
264 | if (str.contains("View key:")) {
265 | game.walletvalues.setViewkey(str.split(": ")[1]);
266 | }
267 | i += 1;
268 | if (i > 5 && str.contains("****")) {
269 | break;
270 | }
271 | }
272 |
273 | str = rd.readLine();
274 | i += 1;
275 |
276 | wr.write( "exit\n" );
277 | wr.flush();
278 |
279 | MessageDigest md = null;
280 | String rando = name + Double.toString(Math.random());
281 | try {
282 | md = MessageDigest.getInstance("SHA-256");
283 | } catch (NoSuchAlgorithmException e) {
284 | // TODO Auto-generated catch block
285 | e.printStackTrace();
286 | }
287 | md.update(rando.getBytes("UTF-8")); // Change this to "UTF-16" if needed
288 | byte[] digest = md.digest();
289 |
290 | game.walletvalues.setName(name);
291 | game.walletvalues.setPw(pw);
292 | game.walletvalues.setSeed(seed);
293 | game.walletvalues.setNode(nodetext.getText());
294 | game.walletvalues.setUserAgent(digest.toString());
295 |
296 |
297 | PrintWriter infowriter = new PrintWriter(name + "info.txt", "UTF-8");
298 | infowriter.println("Wallet name: " + name);
299 | infowriter.println("Wallet pw: " + pw);
300 | infowriter.println("Wallet address: " + game.walletvalues.getAddress());
301 | infowriter.println("Wallet view key: " + game.walletvalues.getViewkey());
302 | infowriter.println("Wallet seed: " + game.walletvalues.getSeed());
303 | infowriter.close();
304 |
305 | PrintWriter confwriter = new PrintWriter("lightwallet.conf", "UTF-8");
306 | confwriter.println("Wallet name: " + name);
307 | confwriter.println("Wallet address: " + game.walletvalues.getAddress());
308 | confwriter.println("Wallet view key: " + game.walletvalues.getViewkey());
309 | confwriter.println("Node address: " + nodetext.getText());
310 | confwriter.println("User agent: " + digest.toString());
311 | confwriter.close();
312 |
313 | PrintWriter txwriter = new PrintWriter(name + "tx.txt", "UTF-8");
314 | txwriter.println("Transaction history (Type | Amount | Tx ID): ");
315 | txwriter.close();
316 |
317 | wp.destroy();
318 |
319 | successlabel.setText("Wallet successfully imported. " + game.walletvalues.getName() + " file is your binary wallet file. "
320 | + game.walletvalues.getName() + ".keys is your keys file; "
321 | + "the keys file is password protected and you can restore your binary wallet file with it. "
322 | + " A text file named " + game.walletvalues.getName() + "info.txt has also been created. "
323 | + "This file contains your wallet recovery seed and view key. "
324 | + "Please encrypt this file or print it and delete it. Your wallet seed allows wallet recovery and bypasses your password."
325 | + "The text file " + game.walletvalues.getName() + "txs.txt is empty, but will contain your tx history after syncing the wallet. "
326 | + "A file named lightwallet.conf has also been created; this file specifies the wallet and node currently in use.");
327 | successdialog.show(stage);
328 | }
329 |
330 | catch (Exception e) {
331 | System.out.println("exception happened - here's what I know: ");
332 | e.printStackTrace();
333 | failuredialog.show(stage);
334 | return;
335 | }
336 |
337 | Gdx.app.log(LightWallet.LOG, "Address is: " + game.walletvalues.getAddress());
338 | Gdx.app.log(LightWallet.LOG, "Seed is: " + game.walletvalues.getSeed());
339 | }
340 |
341 | }
342 |
--------------------------------------------------------------------------------