diff --git a/src/gui/views/wallets/wallet/messages.rs b/src/gui/views/wallets/wallet/messages.rs index 685abf7..48654eb 100644 --- a/src/gui/views/wallets/wallet/messages.rs +++ b/src/gui/views/wallets/wallet/messages.rs @@ -487,7 +487,6 @@ impl WalletMessages { self.request_qr = false; } self.request_qr_content.ui(ui, text.clone(), cb); - ui.add_space(6.0); // Show button to close modal. ui.vertical_centered_justified(|ui| { @@ -823,7 +822,7 @@ impl WalletMessages { self.message_slate = None; } }); - } else { + } else if self.message_slate.is_none() { // Draw button to choose file. let mut parsed_text = "".to_string(); self.file_pick_button.ui(ui, cb, |text| { @@ -884,7 +883,6 @@ impl WalletMessages { // Draw QR code content. let text = self.qr_message_text.clone().unwrap(); self.qr_message_content.ui(ui, text.clone(), cb); - ui.add_space(8.0); ui.vertical_centered_justified(|ui| { View::button(ui, t!("close"), Colors::white_or_black(false), || { diff --git a/src/gui/views/wallets/wallet/txs.rs b/src/gui/views/wallets/wallet/txs.rs index 3ba8dc9..2c3146d 100644 --- a/src/gui/views/wallets/wallet/txs.rs +++ b/src/gui/views/wallets/wallet/txs.rs @@ -525,15 +525,22 @@ impl WalletTransactions { }; // Setup slate and message from transaction. - self.tx_info_response_edit = if !tx.data.confirmed && tx.can_finalize && + self.tx_info_response_edit = if !tx.data.confirmed && tx.data.tx_slate_id.is_some() && (tx.data.tx_type == TxLogEntryType::TxSent || tx.data.tx_type == TxLogEntryType::TxReceived) { - let invoice = tx.data.tx_type == TxLogEntryType::TxReceived; - let mut slate = Slate::blank(1, invoice); - slate.state = if invoice { - SlateState::Invoice1 + let mut slate = Slate::blank(1, false); + slate.state = if tx.can_finalize { + if tx.data.tx_type == TxLogEntryType::TxSent { + SlateState::Standard1 + } else { + SlateState::Invoice1 + } } else { - SlateState::Standard1 + if tx.data.tx_type == TxLogEntryType::TxReceived { + SlateState::Standard2 + } else { + SlateState::Invoice2 + } }; slate.id = tx.data.tx_slate_id.unwrap(); wallet.read_slatepack(&slate).unwrap_or("".to_string())