PIVX Core  5.6.99
P2P Digital Currency
myaddressrow.cpp
Go to the documentation of this file.
1 // Copyright (c) 2019-2021 The PIVX Core developers
2 // Distributed under the MIT software license, see the accompanying
3 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
4 
5 #include "myaddressrow.h"
6 #include "ui_myaddressrow.h"
7 
8 MyAddressRow::MyAddressRow(QWidget *parent) :
9  QWidget(parent),
10  ui(new Ui::MyAddressRow)
11 {
12  ui->setupUi(this);
13  ui->labelName->setProperty("cssClass", "text-list-title1");
14  ui->labelAddress->setProperty("cssClass", "text-list-body2");
15  ui->labelDate->setProperty("cssClass", "text-list-caption");
16 }
17 
18 void MyAddressRow::updateView(const QString& address, const QString& label, const QString& date){
19  ui->labelName->setText(label);
20  ui->labelAddress->setText(address);
21  if (date.isEmpty()){
22  ui->labelDate->setVisible(false);
23  } else {
24  ui->labelDate->setVisible(true);
25  ui->labelDate->setText(date);
26  }
27 }
28 
30  delete ui;
31 }
Ui::MyAddressRow * ui
Definition: myaddressrow.h:25
MyAddressRow(QWidget *parent=nullptr)
Definition: myaddressrow.cpp:8
void updateView(const QString &address, const QString &label, const QString &date)