Just Wonder
5 years ago
8 changed files with 227 additions and 245 deletions
@ -0,0 +1,74 @@
@@ -0,0 +1,74 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?> |
||||
<ui version="4.0"> |
||||
<class>KevaDetailDialog</class> |
||||
<widget class="QDialog" name="KevaDetailDialog"> |
||||
<property name="geometry"> |
||||
<rect> |
||||
<x>0</x> |
||||
<y>0</y> |
||||
<width>800</width> |
||||
<height>400</height> |
||||
</rect> |
||||
</property> |
||||
<property name="windowTitle"> |
||||
<string notr="true">Value</string> |
||||
</property> |
||||
<layout class="QVBoxLayout" name="verticalLayout"> |
||||
<item> |
||||
<widget class="QTextEdit" name="detailText"> |
||||
<property name="toolTip"> |
||||
<string>This pane shows the value associated with a give key</string> |
||||
</property> |
||||
<property name="readOnly"> |
||||
<bool>true</bool> |
||||
</property> |
||||
</widget> |
||||
</item> |
||||
<item> |
||||
<widget class="QDialogButtonBox" name="buttonBox"> |
||||
<property name="orientation"> |
||||
<enum>Qt::Horizontal</enum> |
||||
</property> |
||||
<property name="standardButtons"> |
||||
<set>QDialogButtonBox::Close</set> |
||||
</property> |
||||
</widget> |
||||
</item> |
||||
</layout> |
||||
</widget> |
||||
<resources/> |
||||
<connections> |
||||
<connection> |
||||
<sender>buttonBox</sender> |
||||
<signal>accepted()</signal> |
||||
<receiver>KevaDetailDialog</receiver> |
||||
<slot>accept()</slot> |
||||
<hints> |
||||
<hint type="sourcelabel"> |
||||
<x>20</x> |
||||
<y>20</y> |
||||
</hint> |
||||
<hint type="destinationlabel"> |
||||
<x>20</x> |
||||
<y>20</y> |
||||
</hint> |
||||
</hints> |
||||
</connection> |
||||
<connection> |
||||
<sender>buttonBox</sender> |
||||
<signal>rejected()</signal> |
||||
<receiver>KevaDetailDialog</receiver> |
||||
<slot>reject()</slot> |
||||
<hints> |
||||
<hint type="sourcelabel"> |
||||
<x>20</x> |
||||
<y>20</y> |
||||
</hint> |
||||
<hint type="destinationlabel"> |
||||
<x>20</x> |
||||
<y>20</y> |
||||
</hint> |
||||
</hints> |
||||
</connection> |
||||
</connections> |
||||
</ui> |
@ -0,0 +1,27 @@
@@ -0,0 +1,27 @@
|
||||
// Copyright (c) 2011-2017 The Bitcoin Core developers
|
||||
// Distributed under the MIT software license, see the accompanying
|
||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
#include <qt/kevadetaildialog.h> |
||||
#include <qt/forms/ui_kevadetaildialog.h> |
||||
|
||||
#include <qt/kevatablemodel.h> |
||||
|
||||
#include <QModelIndex> |
||||
|
||||
KevaDetailDialog::KevaDetailDialog(const QModelIndex &idx, QWidget *parent) : |
||||
QDialog(parent), |
||||
ui(new Ui::KevaDetailDialog) |
||||
{ |
||||
ui->setupUi(this); |
||||
QModelIndex keyIdx = idx.sibling(idx.row(), KevaTableModel::Key); |
||||
QModelIndex valueIdx = idx.sibling(idx.row(), KevaTableModel::Value); |
||||
setWindowTitle(tr("Value for %1").arg(keyIdx.data(Qt::DisplayRole).toString())); |
||||
QString desc = valueIdx.data(Qt::DisplayRole).toString(); |
||||
ui->detailText->setHtml(desc); |
||||
} |
||||
|
||||
KevaDetailDialog::~KevaDetailDialog() |
||||
{ |
||||
delete ui; |
||||
} |
@ -0,0 +1,34 @@
@@ -0,0 +1,34 @@
|
||||
// Copyright (c) 2011-2014 The Bitcoin Core developers
|
||||
// Distributed under the MIT software license, see the accompanying
|
||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
#ifndef BITCOIN_QT_KEVADETAILDIALOG_H |
||||
#define BITCOIN_QT_KEVADETAILDIALOG_H |
||||
|
||||
#include <QObject> |
||||
#include <QString> |
||||
|
||||
#include <QDialog> |
||||
|
||||
namespace Ui { |
||||
class KevaDetailDialog; |
||||
} |
||||
|
||||
QT_BEGIN_NAMESPACE |
||||
class QModelIndex; |
||||
QT_END_NAMESPACE |
||||
|
||||
/** Dialog showing transaction details. */ |
||||
class KevaDetailDialog : public QDialog |
||||
{ |
||||
Q_OBJECT |
||||
|
||||
public: |
||||
explicit KevaDetailDialog(const QModelIndex &idx, QWidget *parent = 0); |
||||
~KevaDetailDialog(); |
||||
|
||||
private: |
||||
Ui::KevaDetailDialog *ui; |
||||
}; |
||||
|
||||
#endif // BITCOIN_QT_KEVADETAILDIALOG_H
|
Loading…
Reference in new issue