Skip to content

Commit

Permalink
With total hackhish review
Browse files Browse the repository at this point in the history
  • Loading branch information
b0l0k committed May 24, 2024
1 parent 41a1ee7 commit c578550
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app_stax.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"apiLevel": "15",
"binary": "target/stax/release/app.hex",
"dataSize": 24064,
"dataSize": 24576,
"derivationPath": {
"curves": [
"secp256k1"
Expand Down
22 changes: 20 additions & 2 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@


use ledger_secure_sdk_sys::buttons::ButtonEvent;
use ledger_device_sdk::io;
use ledger_device_sdk::{io, nbgl};
use ledger_device_sdk::io::{ApduHeader, Reply, StatusWords};
use ledger_device_sdk::{ecc, nvm, NVMData};
use ledger_device_sdk::io::Event::{Command};
Expand All @@ -32,6 +32,7 @@ use core::mem::MaybeUninit;
use include_gif::include_gif;
#[cfg(any(target_os = "stax", target_os = "flex"))]
use ledger_device_sdk::nbgl::{NbglGlyph, NbglHomeAndSettings};
use ledger_device_sdk::nbgl::{Field, NbglReview};
#[cfg(not(any(target_os = "stax", target_os = "flex")))]
use ledger_device_sdk::ui::bitmaps::{CERTIFICATE, DASHBOARD_X, Glyph};

Expand Down Expand Up @@ -401,7 +402,24 @@ fn validate( message:&[&str],

cancel: &[&str]) -> bool
{
true
let my_fields = [
Field {
name: "Amount",
value: "111 CRAB",
},
Field {
name: "Destination",
value: "0x1234567890ABCDEF1234567890ABCDEF12345678",
},
Field {
name: "Memo",
value: "This is a test transaction.",
},
];

NbglReview::<32,1024>::new()
.titles(confirm.first().unwrap_or(&""), "subtitle", message.first().unwrap_or(&"") )
.show(&[])
}


Expand Down

0 comments on commit c578550

Please sign in to comment.