@@ -158,7 +158,6 @@ TransactionView::TransactionView(const PlatformStyle *platformStyle, QWidget *pa
158
158
QAction *copyTxIDAction = new QAction (tr (" Copy transaction ID" ), this );
159
159
QAction *copyTxHexAction = new QAction (tr (" Copy raw transaction" ), this );
160
160
QAction *copyTxPlainText = new QAction (tr (" Copy full transaction details" ), this );
161
- QAction *editLabelAction = new QAction (tr (" Edit label" ), this );
162
161
QAction *showDetailsAction = new QAction (tr (" Show transaction details" ), this );
163
162
164
163
contextMenu = new QMenu (this );
@@ -173,7 +172,6 @@ TransactionView::TransactionView(const PlatformStyle *platformStyle, QWidget *pa
173
172
contextMenu->addSeparator ();
174
173
contextMenu->addAction (bumpFeeAction);
175
174
contextMenu->addAction (abandonAction);
176
- contextMenu->addAction (editLabelAction);
177
175
178
176
connect (dateWidget, static_cast <void (QComboBox::*)(int )>(&QComboBox::activated), this , &TransactionView::chooseDate);
179
177
connect (typeWidget, static_cast <void (QComboBox::*)(int )>(&QComboBox::activated), this , &TransactionView::chooseType);
@@ -194,7 +192,6 @@ TransactionView::TransactionView(const PlatformStyle *platformStyle, QWidget *pa
194
192
connect (copyTxIDAction, &QAction::triggered, this , &TransactionView::copyTxID);
195
193
connect (copyTxHexAction, &QAction::triggered, this , &TransactionView::copyTxHex);
196
194
connect (copyTxPlainText, &QAction::triggered, this , &TransactionView::copyTxPlainText);
197
- connect (editLabelAction, &QAction::triggered, this , &TransactionView::editLabel);
198
195
connect (showDetailsAction, &QAction::triggered, this , &TransactionView::showDetails);
199
196
// Double-clicking on a transaction on the transaction history page shows details
200
197
connect (this , &TransactionView::doubleClicked, this , &TransactionView::showDetails);
@@ -474,52 +471,6 @@ void TransactionView::copyTxPlainText()
474
471
GUIUtil::copyEntryData (transactionView, 0 , TransactionTableModel::TxPlainTextRole);
475
472
}
476
473
477
- void TransactionView::editLabel ()
478
- {
479
- if (!transactionView->selectionModel () ||!model)
480
- return ;
481
- QModelIndexList selection = transactionView->selectionModel ()->selectedRows ();
482
- if (!selection.isEmpty ())
483
- {
484
- AddressTableModel *addressBook = model->getAddressTableModel ();
485
- if (!addressBook)
486
- return ;
487
- QString address = selection.at (0 ).data (TransactionTableModel::AddressRole).toString ();
488
- if (address.isEmpty ())
489
- {
490
- // If this transaction has no associated address, exit
491
- return ;
492
- }
493
- // Is address in address book? Address book can miss address when a transaction is
494
- // sent from outside the UI.
495
- int idx = addressBook->lookupAddress (address);
496
- if (idx != -1 )
497
- {
498
- // Edit sending / receiving address
499
- QModelIndex modelIdx = addressBook->index (idx, 0 , QModelIndex ());
500
- // Determine type of address, launch appropriate editor dialog type
501
- QString type = modelIdx.data (AddressTableModel::TypeRole).toString ();
502
-
503
- EditAddressDialog dlg (
504
- type == AddressTableModel::Receive
505
- ? EditAddressDialog::EditReceivingAddress
506
- : EditAddressDialog::EditSendingAddress, this );
507
- dlg.setModel (addressBook);
508
- dlg.loadRow (idx);
509
- dlg.exec ();
510
- }
511
- else
512
- {
513
- // Add sending address
514
- EditAddressDialog dlg (EditAddressDialog::NewSendingAddress,
515
- this );
516
- dlg.setModel (addressBook);
517
- dlg.setAddress (address);
518
- dlg.exec ();
519
- }
520
- }
521
- }
522
-
523
474
void TransactionView::showDetails ()
524
475
{
525
476
if (!transactionView->selectionModel ())
0 commit comments