Skip to content

Commit 0f29cca

Browse files
committed
FreeWallet Classic updates
- Add `setCounterpartyAPI()` to get counterparty API information - Update welcome screen to clearly indicate “FreeWallet Classic” - Update about screen to indicate “FreeWallet Classic” and current wallet and API versions - Update app window title bar to indicate “FreeWallet Classic” - Update `checkWalletUpgrade()` to only check for updates to “FreeWallet Classic” - Update package.json info to indicate “FreeWallet Classic” - Renamed linux desktop install file to FreeWallet-Classic.desktop - Updated linux installer scripts to install “FreeWallet Classic” - Updated build.sh to copy `FreeWallet-Classic.desktop` file to linux app build - Update “new version is available” notification filename to FreeWallet-Classic - bump version number to 0.9.38
1 parent 7c8b9fc commit 0f29cca

11 files changed

Lines changed: 84 additions & 53 deletions

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
FreeWallet - Desktop Wallet
1+
FreeWallet Classic - Desktop Wallet
22
---
3-
FreeWallet is a free wallet which supports Bitcoin and Counterparty.
3+
FreeWallet Classic is a free wallet which supports Bitcoin and Counterparty Classic.
44

55
Installation Instructions
66
---
77
```
8-
Windows : Download FreeWallet.exe, run it, complete the installer.
9-
Mac/OSX : Download FreeWallet.dmg, mount, and drag FreeWallet app to 'Applications' folder
10-
Linux : Download FreeWallet.tgz, extract it, run FreeWallet/install.sh
8+
Windows : Download FreeWallet-Classic.exe, run it, complete the installer.
9+
Mac/OSX : Download FreeWallet-Classic.dmg, mount, and drag FreeWallet-Classic app to 'Applications' folder
10+
Linux : Download FreeWallet-Classic.tgz, extract it, run FreeWallet-Classic/install.sh
1111
```
1212

1313
Build Notes
@@ -29,10 +29,10 @@ https://github.com/nwjs-ffmpeg-prebuilt/nwjs-ffmpeg-prebuilt/releases
2929
Generate checksum.txt file
3030
---
3131
```
32-
sha256sum FreeWallet.linux32.tgz > checksums.txt
33-
sha256sum FreeWallet.linux64.tgz >> checksums.txt
34-
sha256sum FreeWallet.osx64.dmg >> checksums.txt
35-
sha256sum FreeWallet.win32.exe >> checksums.txt
36-
sha256sum FreeWallet.win64.exe >> checksums.txt
32+
sha256sum FreeWallet-Classic.linux32.tgz > checksums.txt
33+
sha256sum FreeWallet-Classic.linux64.tgz >> checksums.txt
34+
sha256sum FreeWallet-Classic.osx64.dmg >> checksums.txt
35+
sha256sum FreeWallet-Classic.win32.exe >> checksums.txt
36+
sha256sum FreeWallet-Classic.win64.exe >> checksums.txt
3737
```
3838

build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ while true; do
249249
cp -a * /tmp/$app_name/
250250
echo "### Copying additional files to install directory..."
251251
cd $base_dir/misc/
252-
cp FreeWallet.png install.sh FreeWallet.desktop /tmp/$app_name/
252+
cp FreeWallet.png install.sh FreeWallet-Classic.desktop /tmp/$app_name/
253253
cd /tmp
254254
tar -cvzf $app_name.x$bits.tgz $app_name
255255
cp $app_name.x$bits.tgz $base_dir/builds/$app_name/linux$bits/

html/about.html

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11

22
<center>
3-
<p>FreeWallet is a free wallet which supports Bitcoin and Counterparty.</p>
3+
<p>FreeWallet Classic is a free wallet which supports Bitcoin and Counterparty Classic.</p>
44
<a href="https://freewallet.io"><img src="images/logo.png" height="100" style="margin-bottom: 5px"></a>
5-
<div id="fw_version"></div>
5+
<br>Classic Version (<span id="fw_version"></span>)
6+
<br>Counterparty API Version (<span id="cp_version"></span>)
67
<hr size=1 class="spacer">
7-
<p>Freewallet uses public APIs available from the following providers:</p>
8+
<p>Freewallet Classic uses public APIs available from the following providers:</p>
89
<div>
910
<a target="_blank" href="https://tokenscan.io"><img class="about-logo" src="images/tokenscan-color-500.png"></a>
1011
<a target="_blank" href="https://coindaddy.io"><img class="about-logo" src="images/coindaddy-500.jpg"></a>
@@ -16,7 +17,7 @@
1617
</div>
1718
<br>
1819
<div class="alert alert-info">
19-
FreeWallet includes an <i>optional</i> 'Automatic Donation System'<br>
20+
FreeWallet Classic includes an <i>optional</i> 'Automatic Donation System'<br>
2021
You can edit your automatic donation preferences at Settings->Preferences<br>
2122
<i class="fa fa-heart"></i> All donations are appreciated and support hosting and additional development <i class="fa fa-heart"></i>
2223
</div>
@@ -52,18 +53,23 @@
5253
var address = '1FWDonkMbC6hL64JiysuggHnUAw2CKWszs',
5354
debug = $('#btn-debug'),
5455
update = $('#btn-update'),
55-
version = (is_nwjs()) ? 'Version ' + nw.App.manifest.version : 'Development Build';
56+
apiInfo = FW.COUNTERPARTY_API;
57+
58+
// Set the FreeWallet and API version information
59+
var fw_version = (is_nwjs()) ? nw.App.manifest.version : 'Development Build',
60+
cp_version = apiInfo.version_major + '.' + apiInfo.version_minor + '.' + apiInfo.version_revision;
5661

5762
// Display current version number
58-
$('#fw_version').html(version);
63+
$('#fw_version').html(fw_version);
64+
$('#cp_version').html(cp_version);
5965

6066
// Handle showing/hiding the debug button
6167
if(is_nwjs()){
6268
debug.click($.debounce(100,function(e){
6369
nw.Window.get().showDevTools();
6470
}));
6571
update.click($.debounce(100,function(e){
66-
checkWalletUpgrade(version, true);
72+
checkWalletUpgrade(fw_version, true);
6773
}));
6874
} else {
6975
debug.hide();

html/settings.html

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -554,6 +554,7 @@
554554
return;
555555
var net = $(this).val();
556556
setWalletNetwork(net);
557+
setCounterpartyAPI(net);
557558
});
558559

559560
// Handle Updating the auto-lock function
@@ -721,6 +722,11 @@
721722
}
722723
});
723724

725+
// Handle updating CP API info if the API url changes
726+
$('#mainnet-cp-host').change(function(){
727+
setCounterpartyAPI(FW.WALLET_NETWORK);
728+
});
729+
724730
// Handle resetting donate amount
725731
$('#reset-donate-amount').click(function(){
726732
FW.DONATE_AMOUNT = FW.DONATE_DEFAULT;

html/welcome.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<div class="text-center">
22
<img src="images/logo.png" style="width:200px;margin-bottom:20px;">
3-
<p>FreeWallet is a free wallet for Bitcoin and Counterparty, the world’s first protocol for decentralized financial tools.</p>
3+
<p>FreeWallet Classic is a free wallet for Bitcoin and Counterparty Classic, the world’s first protocol for decentralized financial tools.</p>
44
<div class="row">
55
<div class="col-xs-12 col-sm-6">
66
<h3><i class="fa fa-lock"></i> Secure</h3>

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<head>
44
<meta charset="UTF-8"/>
55
<meta http-equiv="X-UA-Compatible" content="IE=edge">
6-
<title>FreeWallet</title>
6+
<title>FreeWallet Classic</title>
77
<meta name="robots" content="index, follow">
88
<meta name="viewport" content="width=device-width, initial-scale=1.0">
99
<link type="image/ico" rel="icon" href="images/favicon.ico">

js/freewallet-desktop.js

Lines changed: 28 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -60,21 +60,21 @@ FW.WALLET_HISTORY = JSON.parse(ls.getItem('walletHistory')) || [];
6060
// Define default server info
6161
FW.WALLET_SERVER_INFO_DEFAULT = {
6262
mainnet: {
63-
host: 'public.tokenscan.io',
63+
host: 'classic-api.tokenscan.io',
6464
port: 4001,
6565
user: 'rpc',
6666
pass: 'rpc',
6767
ssl: true,
68-
api_host: 'tokenscan.io',
68+
api_host: 'classic.tokenscan.io',
6969
api_ssl: true
7070
},
7171
testnet: {
72-
host: 'public.tokenscan.io',
72+
host: 'classic-api.tokenscan.io',
7373
port: 14001,
7474
user: 'rpc',
7575
pass: 'rpc',
7676
ssl: true,
77-
api_host: 'testnet.tokenscan.io',
77+
api_host: 'classic-testnet.tokenscan.io',
7878
api_ssl: true
7979
}
8080
};
@@ -176,6 +176,9 @@ FW.ASSET_DIVISIBLE = {};
176176
FW.ASSET_DIVISIBLE['BTC'] = true;
177177
FW.ASSET_DIVISIBLE['XCP'] = true;
178178

179+
// Define placeholder for current API information
180+
FW.COUNTERPARTY_API = {};
181+
179182
// Start loading the wallet
180183
$(document).ready(function(){
181184

@@ -203,6 +206,9 @@ $(document).ready(function(){
203206
// Setup the explorer API url
204207
setExplorerAPI(FW.WALLET_NETWORK);
205208

209+
// Get info on the Counterparty API
210+
setCounterpartyAPI(FW.WALLET_NETWORK);
211+
206212
// Initialize the wallet
207213
initWallet();
208214

@@ -228,10 +234,23 @@ function setExplorerAPI( network ){
228234
FW.EXPLORER_API = getExplorerAPI(network);
229235
}
230236

237+
// Handle getting Counterparty API information
238+
function setCounterpartyAPI(network){
239+
var data = {
240+
method: "get_running_info",
241+
jsonrpc: "2.0",
242+
id: 0
243+
};
244+
cpRequest(network, data, function(o){
245+
if(o && o.result)
246+
FW.COUNTERPARTY_API = o.result;
247+
});
248+
}
249+
231250
// Handle checking for an updated wallet version
232251
function checkWalletUpgrade(version, message){
233252
$.ajax({
234-
url: "https://freewallet.io/releases/current",
253+
url: "https://freewallet.io/releases/classic/current",
235254
cache: false
236255
}).done(function(current){
237256
// Only proceed if we have a response/version
@@ -3604,7 +3623,7 @@ function dialogComingSoon(){
36043623
function dialogAbout(){
36053624
BootstrapDialog.show({
36063625
type: 'type-default',
3607-
title: '<i class="fa fa-lg fa-fw fa-info-circle"></i> About FreeWallet',
3626+
title: '<i class="fa fa-lg fa-fw fa-info-circle"></i> About FreeWallet Classic',
36083627
id: 'dialog-about',
36093628
closeByBackdrop: false,
36103629
message: $('<div></div>').load('html/about.html')
@@ -3916,7 +3935,7 @@ function dialogUpdateAvailable(version){
39163935
os = require('os'),
39173936
plat = os.platform(),
39183937
arch = os.arch(),
3919-
file = 'FreeWallet.',
3938+
file = 'FreeWallet-Classic.',
39203939
url = 'https://github.com/jdogresorg/freewallet-desktop/releases/download/v' + version + '/';
39213940
// Determine the correct file to download based off platform and architecture
39223941
if(plat=='darwin'){
@@ -3931,7 +3950,7 @@ function dialogUpdateAvailable(version){
39313950
url += file;
39323951
nw.Shell.openExternal(url);
39333952
} else {
3934-
var url = 'https://github.com/jdogresorg/freewallet/releases/tag/v' + version;
3953+
var url = 'https://github.com/jdogresorg/freewallet-desktop/releases/tag/v' + version;
39353954
window.open(url);
39363955
}
39373956
}
@@ -4424,7 +4443,7 @@ function dialogWelcome(){
44244443
cssClass: 'dialog-welcome',
44254444
closable: false,
44264445
closeByBackdrop: false,
4427-
title: '<i class="fa fa-lg fa-fw fa-info-circle"></i> Welcome to FreeWallet',
4446+
title: '<i class="fa fa-lg fa-fw fa-info-circle"></i> Welcome to FreeWallet Classic',
44284447
message: $('<div></div>').load('html/welcome.html'),
44294448
buttons:[{
44304449
label: 'Login to Existing Wallet',
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
[Desktop Entry]
22
Type=Application
33
Version=1.0
4-
Name=FreeWallet
4+
Name=FreeWallet Classic
55
Comment=by Jeremy Johnson <j-dog@j-dog.net>
6-
Exec=/usr/share/FreeWallet/FreeWallet %U
7-
Icon=/usr/share/icons/FreeWallet/FreeWallet.png
6+
Exec=/usr/share/FreeWallet-Classic/FreeWallet-Classic %U
7+
Icon=/usr/share/icons/FreeWallet-Classic/FreeWallet.png
88
Terminal=false
99
Categories=Office;
1010
MimeType=x-scheme-handler/bitcoin;x-scheme-handler/counterparty;x-scheme-handler/freewallet;
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
1-
; FreeWallet.iss
1+
; FreeWallet-Classic.iss
22
;
33
; Config file for creating a windows installer file for tbe
44
;
55

66

77
[Setup]
8-
AppName=FreeWallet
9-
AppVersion=0.9.2
10-
DefaultDirName={pf}\FreeWallet
8+
AppName=FreeWallet Classic
9+
AppVersion=0.9.38
10+
DefaultDirName={pf}\FreeWallet Classic
1111
DefaultGroupName=FreeWallet
12-
UninstallDisplayIcon={app}\FreeWallet.exe
12+
UninstallDisplayIcon={app}\FreeWallet-Classic.exe
1313
Compression=lzma2
1414
SolidCompression=yes
1515
OutputDir=C:\Users\J-Dog\Desktop\
16-
OutputBaseFilename=FreeWallet
16+
OutputBaseFilename=FreeWallet Classic
1717

1818
; "ArchitecturesInstallIn64BitMode=x64" requests that the install be
1919
; done in "64-bit mode" on x64, meaning it should use the native
@@ -49,5 +49,5 @@ Source: "C:\Users\J-Dog\Desktop\FreeWallet\*"; DestDir: "{app}"; Flags: ignoreve
4949

5050
; Setup icon group and icon on desktop
5151
[Icons]
52-
Name: "{group}\FreeWallet"; Filename: "{app}\FreeWallet.exe"
53-
Name: "{commondesktop}\FreeWallet"; Filename: "{app}\FreeWallet.exe"
52+
Name: "{group}\FreeWallet Classic"; Filename: "{app}\FreeWallet-Classic.exe"
53+
Name: "{commondesktop}\FreeWallet Classic"; Filename: "{app}\FreeWallet-Classic.exe"

misc/install.sh

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,18 @@
44
###########################################################
55
basedir=/usr/share
66
echo "### Creating installation directories..."
7-
mkdir -vp $basedir/FreeWallet
8-
mkdir -vp $basedir/icons/FreeWallet
7+
mkdir -vp $basedir/FreeWallet-Classic
8+
mkdir -vp $basedir/icons/FreeWallet-Classic
99
mkdir -vp $basedir/applications
10-
echo "### Installing FreeWallet..."
11-
cp -a * $basedir/FreeWallet/
12-
cp FreeWallet.png $basedir/icons/FreeWallet/
10+
echo "### Installing FreeWallet Classic..."
11+
cp -a * $basedir/FreeWallet-Classic/
12+
cp FreeWallet.png $basedir/icons/FreeWallet-Classic/
1313
echo "### Integrating FreeWallet with linux desktop..."
14-
cp FreeWallet.desktop $basedir/applications
14+
cp FreeWallet-Classic.desktop $basedir/applications
1515
echo "### Setting file permissions..."
16-
chmod 644 $basedir/icons/FreeWallet/FreeWallet.png
17-
chmod 644 $basedir/applications/FreeWallet.desktop
18-
chmod 755 $basedir/FreeWallet/*
16+
chmod 644 $basedir/icons/FreeWallet-Classic/FreeWallet.png
17+
chmod 644 $basedir/applications/FreeWallet-Classic.desktop
18+
chmod 755 $basedir/FreeWallet-Classic/*
1919
echo "### Updating desktop database..."
2020
/usr/bin/update-desktop-database
2121
echo "### Installation Complete!"

0 commit comments

Comments
 (0)