Skip to content

Commit

Permalink
Merge pull request #2043 from KomodoPlatform/fix-style-and-perfectibl…
Browse files Browse the repository at this point in the history
…e-code

Fix style and perfectible code
  • Loading branch information
syl authored Nov 7, 2022
2 parents e136d06 + 3e65867 commit 5299ea6
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ Row
hoverEnabled: true
anchors.fill: parent
onClicked: {
if (orders.count == 0 || !API.app.wallet_mgr.log_status()) Qt.quit()
if (orders.count === 0 || !API.app.wallet_mgr.log_status()) Qt.quit()
else app.logout_confirm_modal.open()
}
}
Expand Down
5 changes: 3 additions & 2 deletions atomic_defi_design/Dex/Components/DexWindowHeaderControl.qml
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,9 @@ RowLayout
foregroundColor: Dex.CurrentTheme.foregroundColor
icon.source: Qaterial.Icons.windowClose

onClicked: {
if (orders.count == 0 || !API.app.wallet_mgr.log_status()) Qt.quit()
onClicked:
{
if (orders.count === 0 || !API.app.wallet_mgr.log_status()) Qt.quit()
else app.logout_confirm_modal.open()
}
}
Expand Down
3 changes: 2 additions & 1 deletion atomic_defi_design/Dex/Components/TextEditWithCopy.qml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import "../Constants"
import "../Components"
import App 1.0
import Dex.Themes 1.0 as Dex
import Dex.Components 1.0 as Dex

RowLayout
{
Expand All @@ -20,7 +21,7 @@ RowLayout

Item { Layout.fillWidth: !align_left }

DexRectangle
Dex.Rectangle
{
width: text_box_width
height: 30
Expand Down
3 changes: 3 additions & 0 deletions atomic_defi_design/Dex/Components/ZcashParamsModal.qml
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,9 @@ Dex.MultipageModal
Connections
{
target: Dex.API.app.zcash_params

// todo: can be improved.
// put it maybe in the backend ?
function onCombinedDownloadStatusChanged()
{
let combined_progress = 0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import Qaterial 1.0 as Qaterial
import "../../../Components"
import "../../../Constants"
import Dex.Themes 1.0 as Dex
import Dex.Components 1.0 as Dex
import AtomicDEX.MarketMode 1.0

Widget
Expand Down Expand Up @@ -60,7 +61,7 @@ Widget
anchors.fill: parent
anchors.centerIn: parent

DexLabel
Dex.Text
{
id: protocolTitle
Layout.preferredWidth: parent.width
Expand Down Expand Up @@ -163,7 +164,7 @@ Widget
Layout.preferredWidth: parent.width

// Show errors
DefaultText
Dex.Text
{
id: errors
visible: errors.text_value !== ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import "../../../Components"
import App 1.0
import Dex.Themes 1.0 as Dex

// todo: coding style is wrong, use camelCase.
RowLayout
{
id: control
Expand Down
2 changes: 2 additions & 0 deletions src/app/app.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,8 @@ namespace atomic_dex
!coins.contains(QString::fromStdString(coin_info.fees_ticker)))
{
auto coin_parent_info = mm2.get_coin_info(coin_info.fees_ticker);
// todo: why can it be empty when it has been found ?
// refactor coins enabling logic!!!
if (coin_parent_info.ticker != "")
{
if (!coin_parent_info.currently_enabled && !coin_parent_info.active && extra_coins.insert(coin_parent_info.ticker).second)
Expand Down

0 comments on commit 5299ea6

Please sign in to comment.