Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v0.7.2 Release Candidate #2459

Merged
merged 25 commits into from
Jun 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
df186bc
extend to 8dp
smk762 Jun 13, 2024
7dc8c3b
rm leaky log
smk762 Jun 13, 2024
dd552de
fix missing rates calc
smk762 Jun 13, 2024
8f4f13a
more triggers to scroll asks to bottom in pro orderbook
smk762 Jun 13, 2024
07f0396
add settings toggle for orders display after placement
smk762 Jun 13, 2024
fba9f54
add config entry
smk762 Jun 13, 2024
a5aa4b9
increment to v0.7.2
smk762 Jun 13, 2024
70c4d1c
add VOTE2024 to default enabled coins
smk762 Jun 13, 2024
900b698
update vote info link
smk762 Jun 13, 2024
cb540f8
trailing / for url
smk762 Jun 13, 2024
26ac678
fix deprecated syntax
smk762 Jun 14, 2024
f2b86e0
fix connection triggger function syntax
smk762 Jun 14, 2024
f42cd63
use windows 2019 runner image
smk762 Jun 18, 2024
d5d378b
use gh release kdf
smk762 Jun 18, 2024
f3be2a0
Merge pull request #2458 from KomodoPlatform/use-win-2019
smk762 Jun 18, 2024
2f2755f
Merge branch 'dev' into orderbook-divergence
smk762 Jun 18, 2024
bef62b7
Merge branch 'dev' into increment-version
smk762 Jun 18, 2024
60d9111
Merge branch 'dev' into pro-static-chart
smk762 Jun 18, 2024
3272082
Merge branch 'dev' into menubar-currency-change
smk762 Jun 18, 2024
3962c34
Merge branch 'dev' into price-precision
smk762 Jun 18, 2024
a7d5afe
Merge pull request #2453 from KomodoPlatform/price-precision
smk762 Jun 21, 2024
3bd495b
Merge pull request #2454 from KomodoPlatform/menubar-currency-change
smk762 Jun 21, 2024
d92d7b7
Merge pull request #2455 from KomodoPlatform/orderbook-divergence
smk762 Jun 21, 2024
7e6cda2
Merge pull request #2456 from KomodoPlatform/pro-static-chart
smk762 Jun 21, 2024
1e6c540
Merge pull request #2457 from KomodoPlatform/increment-version
smk762 Jun 21, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Please describe what you expected to happen.
**Operating Environment(s):**
- OS: [e.g. Windows/OSX/Linux. If Linux, include distro. ]
- OS version: [e.g. 7/10/11, 10.13/10.15, 18.04/20.04 ]
- Komodo Wallet Version: [e.g. 0.7.1]
- Komodo Wallet Desktop Version: [e.g. 0.7.2]
- Build branch: [e.g. master/dev]


Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/atomicdex-desktop-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ env:
DEX_PROJECT_NAME: "komodo-wallet"
DEX_DISPLAY_NAME: "Komodo Wallet"
DEX_COMPANY: "KomodoPlatform"
DEX_VERSION: "0.7.1"
DEX_VERSION: "0.7.2"
DEX_WEBSITE: "https://atomicdex.io/"

jobs:
Expand Down Expand Up @@ -367,7 +367,7 @@ jobs:

windows-release:
name: Win Build/Release
runs-on: windows-latest
runs-on: windows-2019

steps:
- uses: actions/checkout@v2
Expand Down Expand Up @@ -445,7 +445,7 @@ jobs:

windows-debug:
name: Win Build/Debug
runs-on: windows-latest
runs-on: windows-2019

steps:
- uses: actions/checkout@v2
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/atomicdex-desktop-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ env:
DEX_PROJECT_NAME: "komodo-wallet"
DEX_DISPLAY_NAME: "Komodo Wallet"
DEX_COMPANY: "KomodoPlatform"
DEX_VERSION: "0.7.1"
DEX_VERSION: "0.7.2"
DEX_WEBSITE: "https://atomicdex.io/"
VCPKG_DEFAULT_BINARY_CACHE: ${{ github.workspace }}/b/vcpkg_cache
VCPKG_BINARY_SOURCES: clear;x-gha,readwrite
Expand Down Expand Up @@ -68,13 +68,13 @@ jobs:
host: 'mac'

- name: windows-release
os: windows-latest
os: windows-2019
qt: '5.15.2'
type: 'Release'
host: 'windows'

- name: windows-debug
os: windows-latest
os: windows-2019
qt: '5.15.2'
type: 'Debug'
host: 'windows'
Expand Down
8 changes: 4 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ include(vcpkg_prerequisites)
include(qt_prerequisites)
include(cfg_hash)

project(${DEX_PROJECT_NAME} LANGUAGES CXX VERSION 0.7.1)
project(${DEX_PROJECT_NAME} LANGUAGES CXX VERSION 0.7.2)
message(STATUS "${PROJECT_NAME} is version ${PROJECT_VERSION}")

include(cmake_default_options)
Expand Down Expand Up @@ -60,13 +60,13 @@ endif ()
##! We fetch our dependencies
if (APPLE)
FetchContent_Declare(mm2
URL https://sdk.devbuilds.komodo.earth/main/mm2_b0fd99e-mac-x86-64.zip)
URL https://github.com/KomodoPlatform/komodo-defi-framework/releases/download/v2.0.0-beta/mm2-b0fd99e84-Darwin-Release.zip)
elseif (UNIX AND NOT APPLE)
FetchContent_Declare(mm2
URL https://sdk.devbuilds.komodo.earth/main/mm2_b0fd99e-linux-x86-64.zip)
URL https://github.com/KomodoPlatform/komodo-defi-framework/releases/download/v2.0.0-beta/mm2-b0fd99e84-Linux-Release.zip)
else ()
FetchContent_Declare(mm2
URL https://sdk.devbuilds.komodo.earth/main/mm2_b0fd99e-win-x86-64.zip)
URL https://github.com/KomodoPlatform/komodo-defi-framework/releases/download/v2.0.0-beta/mm2-b0fd99e84-Win64.zip)
endif ()

#FetchContent_Declare(qmaterial URL https://github.com/KomodoPlatform/Qaterial/archive/last-clang-working-2.zip)
Expand Down
1 change: 1 addition & 0 deletions assets/config/cfg.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"notification_enabled": true,
"spamfilter_enabled": false,
"postorder_enabled": false,
"use_static_rpcpass": false,
"current_currency": "USD",
"current_fiat": "USD",
Expand Down
2 changes: 1 addition & 1 deletion atomic_defi_design/Dex/Constants/General.qml
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,7 @@ QtObject {
}
return diffPrefix(received) +
(fiat === API.app.settings_pg.current_fiat ? API.app.settings_pg.current_fiat_sign : API.app.settings_pg.current_currency_sign)
+ " " + (amount < 1E5 ? formatDouble(parseFloat(amount), precision, true) : nFormatter(parseFloat(amount), 2))
+ " " + (amount < 1E5 ? formatDouble(parseFloat(amount), precision, true) : nFormatter(parseFloat(amount), precision))
}

function formatPercent(value, show_prefix=true) {
Expand Down
49 changes: 45 additions & 4 deletions atomic_defi_design/Dex/Exchange/Trade/OrderBook/List.qml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ Item
id: _control

property bool isAsk
property bool isVertical: false
width: parent.width
height: parent.height

Expand All @@ -29,7 +28,11 @@ Item

onContentHeightChanged:
{
if (isVertical) _tm.start();
if (isAsk){
// Duplication is intended. Sometimes data takes too long to load so slowscroll is a backup.
slowscroll_timer.start();
quickscroll_timer.start()
}
}

delegate: Item
Expand All @@ -47,12 +50,50 @@ Item

Timer
{
id: _tm
interval: 2000
id: slowscroll_timer
interval: 1500
onTriggered:
{
orderbook_list.positionViewAtEnd()
}
}
Timer
{
id: quickscroll_timer
interval: 500
onTriggered:
{
orderbook_list.positionViewAtEnd()
}
}
onModelChanged: {
if (isAsk) quickscroll_timer.start()
}
}

Connections {
target: API.app.trading_pg;

function onMarketModeChanged()
{
if (isAsk)
{
quickscroll_timer.start()
}
}
function onOrderbookChanged()
{
if (isAsk)
{
quickscroll_timer.start()
}
}
function onMarketPairsChanged()
{
if (isAsk)
{
quickscroll_timer.start()
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ Widget
List
{
isAsk: true
isVertical: true
Layout.fillHeight: true
Layout.fillWidth: true
}
Expand Down
6 changes: 5 additions & 1 deletion atomic_defi_design/Dex/Exchange/Trade/ProView.qml
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,11 @@ RowLayout
General.prettifyJSON(response.result), false)

General.prevent_coin_disabling.restart()
tradingInfo.currentIndex = 1
// Show the orders tab unless settings say otherwise
if (API.app.settings_pg.postorder_enabled)
{
tradingInfo.currentIndex = 1
}
}
}
}
Expand Down
5 changes: 4 additions & 1 deletion atomic_defi_design/Dex/Exchange/Trade/SimpleView/Main.qml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@ Item
target: exchange_trade
function onOrderPlaced()
{
currentSubPage = subPages.Orders
if (API.app.settings_pg.postorder_enabled)
{
currentSubPage = subPages.Orders
}
}
}

Expand Down
26 changes: 26 additions & 0 deletions atomic_defi_design/Dex/Settings/SettingModal.qml
Original file line number Diff line number Diff line change
Expand Up @@ -482,6 +482,32 @@ Qaterial.Dialog
}
}
}

// Post-order placement toggle
RowLayout
{
width: parent.width - 30
anchors.horizontalCenter: parent.horizontalCenter
height: 50

DexLabel
{
Layout.alignment: Qt.AlignVCenter
Layout.fillWidth: true
font: DexTypo.subtitle1
text: qsTr("Show orders after placement")
}

Item { Layout.fillWidth: true }

DexSwitch
{
Layout.alignment: Qt.AlignVCenter
Component.onCompleted: checked = API.app.settings_pg.postorder_enabled
onCheckedChanged: API.app.settings_pg.postorder_enabled = checked
}
}

}
}
Item
Expand Down
5 changes: 4 additions & 1 deletion atomic_defi_design/Dex/Wallet/Main.qml
Original file line number Diff line number Diff line change
Expand Up @@ -675,7 +675,10 @@ Item
content.anchors.leftMargin: enabled ? 23 : 48
content.anchors.rightMargin: 23

onClicked: Qt.openUrlExternally("https://vote.komodoplatform.com/")
onClicked: {
let url = "https://vote.komodoplatform.com/" + api_wallet_page.ticker.toLowerCase() + "/";
Qt.openUrlExternally(url);
}

Row
{
Expand Down
2 changes: 1 addition & 1 deletion cmake/project.metadata.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ set(DEX_DISPLAY_NAME "Komodo Wallet")
set(DEX_MAINTENANCE_TOOL_NAME "Komodo Wallet Maintenance Tool")
set(DEX_COMPANY "KomodoPlatform")
set(DEX_WEBSITE "https://atomicdex.io/")
set(DEX_VERSION "0.7.1")
set(DEX_VERSION "0.7.2")
set(DEX_SUPPORT_PAGE "https://support.komodoplatform.com/support/home")
set(DEX_DISCORD "https://komodoplatform.com/discord")
set(DEX_TWITTER "https://twitter.com/AtomicDEX")
Expand Down
20 changes: 20 additions & 0 deletions src/core/atomicdex/config/app.cfg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ namespace
config_json_data["available_signs"] = config.available_currency_signs;
config_json_data["notification_enabled"] = config.notification_enabled;
config_json_data["spamfilter_enabled"] = config.spamfilter_enabled;
config_json_data["postorder_enabled"] = config.postorder_enabled;
config_json_data["static_rpcpass_enabled"] = config.static_rpcpass_enabled;

file.close();
Expand Down Expand Up @@ -85,6 +86,15 @@ namespace atomic_dex
config.spamfilter_enabled = true;
}

if (j.contains("postorder_enabled"))
{
j.at("postorder_enabled").get_to(config.postorder_enabled);
}
else
{
config.postorder_enabled = true;
}

if (j.contains("static_rpcpass_enabled"))
{
j.at("static_rpcpass_enabled").get_to(config.static_rpcpass_enabled);
Expand All @@ -105,6 +115,16 @@ namespace atomic_dex
}
}

void
change_postorder_status(cfg& config, bool is_enabled)
{
if (config.postorder_enabled != is_enabled)
{
config.postorder_enabled = is_enabled;
upgrade_cfg(config);
}
}

void
change_spamfilter_status(cfg& config, bool is_enabled)
{
Expand Down
2 changes: 2 additions & 0 deletions src/core/atomicdex/config/app.cfg.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ namespace atomic_dex
std::vector<std::string> recommended_fiat;
std::vector<std::string> possible_currencies;
bool notification_enabled;
bool postorder_enabled{false};
bool spamfilter_enabled{false};
bool static_rpcpass_enabled{false};
};
Expand All @@ -40,6 +41,7 @@ namespace atomic_dex
void change_currency(cfg& config, const std::string& new_currency);
void change_fiat(cfg& config, const std::string& new_fiat);
void change_notification_status(cfg& config, bool is_enabled);
void change_postorder_status(cfg& config, bool is_enabled);
void change_spamfilter_status(cfg& config, bool is_enabled);
void change_static_rpcpass_status(cfg& config, bool is_enabled);
[[nodiscard]] bool is_this_currency_a_fiat(const cfg& config, const std::string& currency);
Expand Down
1 change: 1 addition & 0 deletions src/core/atomicdex/constants/dex.constants.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ namespace atomic_dex
g_second_primary_dex_coin,
"BTC-segwit",
"DGB-segwit",
"VOTE2024",
};
inline const std::vector<std::string> g_faucet_coins{
"DOC",
Expand Down
2 changes: 2 additions & 0 deletions src/core/atomicdex/models/qt.portfolio.model.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,8 @@ namespace atomic_dex
bool
portfolio_model::update_activation_status()
{
// This feels a bit heavy handed. There should be a better way to do this.
// Function may be unused.
const auto& mm2_system = this->m_system_manager.get_system<mm2_service>();
const auto coins = this->m_system_manager.get_system<portfolio_page>().get_global_cfg()->get_enabled_coins();

Expand Down
14 changes: 14 additions & 0 deletions src/core/atomicdex/pages/qt.settings.page.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,20 @@ namespace atomic_dex
}
}

bool atomic_dex::settings_page::is_postorder_enabled() const
{
return m_config.postorder_enabled;
}

void settings_page::set_postorder_enabled(bool is_enabled)
{
if (m_config.postorder_enabled != is_enabled)
{
change_postorder_status(m_config, is_enabled);
emit onPostOrderEnabledChanged();
}
}

bool atomic_dex::settings_page::is_notification_enabled() const
{
return m_config.notification_enabled;
Expand Down
4 changes: 4 additions & 0 deletions src/core/atomicdex/pages/qt.settings.page.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ namespace atomic_dex
Q_PROPERTY(QString current_fiat READ get_current_fiat WRITE set_current_fiat NOTIFY onFiatChanged)
Q_PROPERTY(bool notification_enabled READ is_notification_enabled WRITE set_notification_enabled NOTIFY onNotificationEnabledChanged)
Q_PROPERTY(bool spamfilter_enabled READ is_spamfilter_enabled WRITE set_spamfilter_enabled NOTIFY onSpamFilterEnabledChanged)
Q_PROPERTY(bool postorder_enabled READ is_postorder_enabled WRITE set_postorder_enabled NOTIFY onPostOrderEnabledChanged)
Q_PROPERTY(bool static_rpcpass_enabled READ is_static_rpcpass_enabled WRITE set_static_rpcpass_enabled NOTIFY onStaticRpcPassEnabledChanged)
Q_PROPERTY(QVariant custom_token_data READ get_custom_token_data WRITE set_custom_token_data NOTIFY customTokenDataChanged)
Q_PROPERTY(bool fetching_custom_token_data_busy READ is_fetching_custom_token_data_busy WRITE set_fetching_custom_token_data_busy NOTIFY customTokenDataStatusChanged)
Expand Down Expand Up @@ -94,6 +95,8 @@ namespace atomic_dex
bool set_zhtlc_status(nlohmann::json data);
[[nodiscard]] bool is_spamfilter_enabled() const;
void set_spamfilter_enabled(bool is_enabled);
[[nodiscard]] bool is_postorder_enabled() const;
void set_postorder_enabled(bool is_enabled);
void set_current_currency(const QString& current_currency);
void set_current_fiat(const QString& current_fiat);
[[nodiscard]] bool is_fetching_custom_token_data_busy() const;
Expand Down Expand Up @@ -143,6 +146,7 @@ namespace atomic_dex
void onFiatSignChanged();
void onFiatChanged();
void onNotificationEnabledChanged();
void onPostOrderEnabledChanged();
void onSpamFilterEnabledChanged();
void onStaticRpcPassEnabledChanged();
void customTokenDataChanged();
Expand Down
2 changes: 1 addition & 1 deletion src/core/atomicdex/pages/qt.wallet.page.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -735,7 +735,7 @@ namespace atomic_dex

nlohmann::json json_data = mm2::template_request("withdraw", true);
mm2::to_json(json_data, withdraw_req);
SPDLOG_DEBUG("final json: {}", json_data.dump(4));

batch.push_back(json_data);

std::string amount_std = amount.toStdString();
Expand Down
Loading
Loading