diff options
-rw-r--r-- | TODO | 6 | ||||
-rw-r--r-- | aboutdialog.cpp | 15 | ||||
-rw-r--r-- | aboutdialog.h | 13 | ||||
-rw-r--r-- | aboutdialog.ui | 162 | ||||
-rw-r--r-- | addressbookdialog.cpp | 20 | ||||
-rw-r--r-- | addressbookdialog.h | 6 | ||||
-rw-r--r-- | addressbookdialog.ui | 139 | ||||
-rw-r--r-- | bitcoin.pro | 11 | ||||
-rw-r--r-- | bitcoin.qrc | 3 | ||||
-rw-r--r-- | bitcoingui.cpp | 2 | ||||
-rw-r--r-- | res/icons/address-book.png | bin | 656 -> 1211 bytes | |||
-rw-r--r-- | res/icons/send.png | bin | 938 -> 1485 bytes | |||
-rw-r--r-- | res/images/about.png | bin | 0 -> 3488 bytes | |||
-rw-r--r-- | sendcoinsdialog.cpp | 23 | ||||
-rw-r--r-- | sendcoinsdialog.h | 6 | ||||
-rw-r--r-- | sendcoinsdialog.ui | 80 |
16 files changed, 375 insertions, 111 deletions
@@ -54,3 +54,9 @@ AboutDialog - Toolbar icon - 'notify' on incoming transaction + +- AddressTableModel + - Name / Label + - Address + - Delete / Copy to clipboard based on tab + diff --git a/aboutdialog.cpp b/aboutdialog.cpp index 90d74e69a4..3d7a3f98af 100644 --- a/aboutdialog.cpp +++ b/aboutdialog.cpp @@ -1,6 +1,19 @@ #include "aboutdialog.h" +#include "ui_aboutdialog.h" AboutDialog::AboutDialog(QWidget *parent) : - QDialog(parent) + QDialog(parent), + ui(new Ui::AboutDialog) { + ui->setupUi(this); +} + +AboutDialog::~AboutDialog() +{ + delete ui; +} + +void AboutDialog::on_buttonBox_accepted() +{ + close(); } diff --git a/aboutdialog.h b/aboutdialog.h index 1372121099..827cc741c3 100644 --- a/aboutdialog.h +++ b/aboutdialog.h @@ -3,16 +3,23 @@ #include <QDialog> +namespace Ui { + class AboutDialog; +} + class AboutDialog : public QDialog { Q_OBJECT + public: explicit AboutDialog(QWidget *parent = 0); + ~AboutDialog(); -signals: - -public slots: +private: + Ui::AboutDialog *ui; +private slots: + void on_buttonBox_accepted(); }; #endif // ABOUTDIALOG_H diff --git a/aboutdialog.ui b/aboutdialog.ui new file mode 100644 index 0000000000..2cc178fb98 --- /dev/null +++ b/aboutdialog.ui @@ -0,0 +1,162 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ui version="4.0"> + <class>AboutDialog</class> + <widget class="QDialog" name="AboutDialog"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>593</width> + <height>319</height> + </rect> + </property> + <property name="windowTitle"> + <string>About Bitcoin</string> + </property> + <layout class="QHBoxLayout" name="horizontalLayout_2"> + <item> + <widget class="QLabel" name="label_4"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Ignored"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string/> + </property> + <property name="pixmap"> + <pixmap resource="bitcoin.qrc">:/images/about</pixmap> + </property> + </widget> + </item> + <item> + <layout class="QVBoxLayout" name="verticalLayout_2"> + <item> + <spacer name="verticalSpacer_2"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + <item> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <widget class="QLabel" name="label"> + <property name="text"> + <string><b>Bitcoin</b> version</string> + </property> + </widget> + </item> + <item> + <widget class="QLabel" name="label_3"> + <property name="text"> + <string>0.3.666-beta</string> + </property> + <property name="textFormat"> + <enum>Qt::RichText</enum> + </property> + </widget> + </item> + <item> + <spacer name="horizontalSpacer"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + </layout> + </item> + <item> + <widget class="QLabel" name="label_2"> + <property name="text"> + <string>Copyright (c) 2009-2011 Bitcoin Developers + +This is experimental software. + +Distributed under the MIT/X11 software license, see the accompanying file license.txt or http://www.opensource.org/licenses/mit-license.php. + +This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit (http://www.openssl.org/) and cryptographic software written by Eric Young (eay@cryptsoft.com) and UPnP software written by Thomas Bernard.</string> + </property> + <property name="wordWrap"> + <bool>true</bool> + </property> + </widget> + </item> + <item> + <spacer name="verticalSpacer"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QDialogButtonBox" name="buttonBox"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="standardButtons"> + <set>QDialogButtonBox::Ok</set> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </widget> + <resources> + <include location="bitcoin.qrc"/> + </resources> + <connections> + <connection> + <sender>buttonBox</sender> + <signal>accepted()</signal> + <receiver>AboutDialog</receiver> + <slot>accept()</slot> + <hints> + <hint type="sourcelabel"> + <x>248</x> + <y>254</y> + </hint> + <hint type="destinationlabel"> + <x>157</x> + <y>274</y> + </hint> + </hints> + </connection> + <connection> + <sender>buttonBox</sender> + <signal>rejected()</signal> + <receiver>AboutDialog</receiver> + <slot>reject()</slot> + <hints> + <hint type="sourcelabel"> + <x>316</x> + <y>260</y> + </hint> + <hint type="destinationlabel"> + <x>286</x> + <y>274</y> + </hint> + </hints> + </connection> + </connections> +</ui> diff --git a/addressbookdialog.cpp b/addressbookdialog.cpp index ca74159d2f..e1ce1feefc 100644 --- a/addressbookdialog.cpp +++ b/addressbookdialog.cpp @@ -15,5 +15,25 @@ AddressBookDialog::~AddressBookDialog() void AddressBookDialog::setTab(int tab) { + ui->tabWidget->setCurrentIndex(tab); +} + +void AddressBookDialog::on_OKButton_clicked() +{ + accept(); +} + +void AddressBookDialog::on_copyToClipboard_clicked() +{ + +} + +void AddressBookDialog::on_editButton_clicked() +{ + +} + +void AddressBookDialog::on_newAddressButton_clicked() +{ } diff --git a/addressbookdialog.h b/addressbookdialog.h index a51c02a794..e287019d9b 100644 --- a/addressbookdialog.h +++ b/addressbookdialog.h @@ -23,6 +23,12 @@ public: void setTab(int tab); private: Ui::AddressBookDialog *ui; + +private slots: + void on_newAddressButton_clicked(); + void on_editButton_clicked(); + void on_copyToClipboard_clicked(); + void on_OKButton_clicked(); }; #endif // ADDRESSBOOKDIALOG_H diff --git a/addressbookdialog.ui b/addressbookdialog.ui index e646b08ef2..530322ee00 100644 --- a/addressbookdialog.ui +++ b/addressbookdialog.ui @@ -6,72 +6,101 @@ <rect> <x>0</x> <y>0</y> - <width>400</width> - <height>300</height> + <width>591</width> + <height>347</height> </rect> </property> <property name="windowTitle"> - <string>Dialog</string> + <string>Address Book</string> </property> <layout class="QVBoxLayout" name="verticalLayout"> <item> - <spacer name="verticalSpacer"> - <property name="orientation"> - <enum>Qt::Vertical</enum> + <widget class="QTabWidget" name="tabWidget"> + <property name="currentIndex"> + <number>1</number> </property> - <property name="sizeHint" stdset="0"> - <size> - <width>20</width> - <height>40</height> - </size> - </property> - </spacer> + <widget class="QWidget" name="tab"> + <attribute name="title"> + <string>Sending</string> + </attribute> + <layout class="QVBoxLayout" name="verticalLayout_2"> + <item> + <widget class="QTableView" name="tableView"/> + </item> + </layout> + </widget> + <widget class="QWidget" name="tab_2"> + <attribute name="title"> + <string>Receiving</string> + </attribute> + <layout class="QVBoxLayout" name="verticalLayout_3"> + <item> + <widget class="QLabel" name="label"> + <property name="text"> + <string>These are your Bitcoin addresses for receiving payments. You may want to give a different one to each sender so you can keep track of who is paying you. The highlighted address is displayed in the main window.</string> + </property> + <property name="textFormat"> + <enum>Qt::AutoText</enum> + </property> + <property name="wordWrap"> + <bool>true</bool> + </property> + </widget> + </item> + <item> + <widget class="QTableView" name="tableView_2"/> + </item> + </layout> + </widget> + </widget> </item> <item> - <widget class="QDialogButtonBox" name="buttonBox"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="standardButtons"> - <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set> - </property> - </widget> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <spacer name="horizontalSpacer"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QPushButton" name="copyToClipboard"> + <property name="text"> + <string>Copy to Clipboard</string> + </property> + </widget> + </item> + <item> + <widget class="QPushButton" name="editButton"> + <property name="text"> + <string>Edit...</string> + </property> + </widget> + </item> + <item> + <widget class="QPushButton" name="newAddressButton"> + <property name="text"> + <string>New Address...</string> + </property> + </widget> + </item> + <item> + <widget class="QPushButton" name="OKButton"> + <property name="text"> + <string>OK</string> + </property> + </widget> + </item> + </layout> </item> </layout> </widget> <resources/> - <connections> - <connection> - <sender>buttonBox</sender> - <signal>accepted()</signal> - <receiver>AddressBookDialog</receiver> - <slot>accept()</slot> - <hints> - <hint type="sourcelabel"> - <x>248</x> - <y>254</y> - </hint> - <hint type="destinationlabel"> - <x>157</x> - <y>274</y> - </hint> - </hints> - </connection> - <connection> - <sender>buttonBox</sender> - <signal>rejected()</signal> - <receiver>AddressBookDialog</receiver> - <slot>reject()</slot> - <hints> - <hint type="sourcelabel"> - <x>316</x> - <y>260</y> - </hint> - <hint type="destinationlabel"> - <x>286</x> - <y>274</y> - </hint> - </hints> - </connection> - </connections> + <connections/> </ui> diff --git a/bitcoin.pro b/bitcoin.pro index 4e9bfda32e..7bcf3afded 100644 --- a/bitcoin.pro +++ b/bitcoin.pro @@ -10,24 +10,25 @@ INCLUDEPATH += . # Input HEADERS += bitcoingui.h \ transactiontablemodel.h \ - aboutdialog.h \ addresstablemodel.h \ optionsdialog.h \ mainoptionspage.h \ sendcoinsdialog.h \ - addressbookdialog.h + addressbookdialog.h \ + aboutdialog.h SOURCES += bitcoin.cpp bitcoingui.cpp \ transactiontablemodel.cpp \ - aboutdialog.cpp \ addresstablemodel.cpp \ optionsdialog.cpp \ mainoptionspage.cpp \ sendcoinsdialog.cpp \ - addressbookdialog.cpp + addressbookdialog.cpp \ + aboutdialog.cpp RESOURCES += \ bitcoin.qrc FORMS += \ sendcoinsdialog.ui \ - addressbookdialog.ui + addressbookdialog.ui \ + aboutdialog.ui diff --git a/bitcoin.qrc b/bitcoin.qrc index ebce276c8d..0d91bbcd40 100644 --- a/bitcoin.qrc +++ b/bitcoin.qrc @@ -5,4 +5,7 @@ <file alias="quit">res/icons/quit.png</file> <file alias="send">res/icons/send.png</file> </qresource> + <qresource prefix="/images"> + <file alias="about">res/images/about.png</file> + </qresource> </RCC> diff --git a/bitcoingui.cpp b/bitcoingui.cpp index 4083afbf8b..c78bb3c5ac 100644 --- a/bitcoingui.cpp +++ b/bitcoingui.cpp @@ -41,7 +41,7 @@ BitcoinGUI::BitcoinGUI(QWidget *parent): QAction *quit = new QAction(QIcon(":/icons/quit"), tr("&Quit"), this); QAction *sendcoins = new QAction(QIcon(":/icons/send"), tr("&Send coins"), this); - QAction *addressbook = new QAction(QIcon(":/icons/address-book"), tr("&Address book"), this); + QAction *addressbook = new QAction(QIcon(":/icons/address-book"), tr("&Address Book"), this); QAction *about = new QAction(QIcon(":/icons/bitcoin"), tr("&About"), this); QAction *receiving_addresses = new QAction(QIcon(":/icons/receiving-addresses"), tr("Your &Receiving Addresses..."), this); QAction *options = new QAction(QIcon(":/icons/options"), tr("&Options..."), this); diff --git a/res/icons/address-book.png b/res/icons/address-book.png Binary files differindex 621ca40245..abfb3c3a51 100644 --- a/res/icons/address-book.png +++ b/res/icons/address-book.png diff --git a/res/icons/send.png b/res/icons/send.png Binary files differindex 51067a192b..0ba5359d7b 100644 --- a/res/icons/send.png +++ b/res/icons/send.png diff --git a/res/images/about.png b/res/images/about.png Binary files differnew file mode 100644 index 0000000000..c9ab9511ef --- /dev/null +++ b/res/images/about.png diff --git a/sendcoinsdialog.cpp b/sendcoinsdialog.cpp index 283039f2b3..1eaa35884b 100644 --- a/sendcoinsdialog.cpp +++ b/sendcoinsdialog.cpp @@ -1,6 +1,8 @@ #include "sendcoinsdialog.h" #include "ui_sendcoinsdialog.h" +#include "addressbookdialog.h" + SendCoinsDialog::SendCoinsDialog(QWidget *parent) : QDialog(parent), ui(new Ui::SendCoinsDialog) @@ -12,3 +14,24 @@ SendCoinsDialog::~SendCoinsDialog() { delete ui; } + +void SendCoinsDialog::on_sendButton_clicked() +{ + accept(); +} + +void SendCoinsDialog::on_cancelButton_clicked() +{ + reject(); +} + +void SendCoinsDialog::on_pasteButton_clicked() +{ + +} + +void SendCoinsDialog::on_addressBookButton_clicked() +{ + AddressBookDialog dlg; + dlg.exec(); +} diff --git a/sendcoinsdialog.h b/sendcoinsdialog.h index 82fae9cfac..e3ffd1d33d 100644 --- a/sendcoinsdialog.h +++ b/sendcoinsdialog.h @@ -17,6 +17,12 @@ public: private: Ui::SendCoinsDialog *ui; + +private slots: + void on_addressBookButton_clicked(); + void on_pasteButton_clicked(); + void on_cancelButton_clicked(); + void on_sendButton_clicked(); }; #endif // SENDCOINSDIALOG_H diff --git a/sendcoinsdialog.ui b/sendcoinsdialog.ui index 56ec6d3d23..b1adbc5159 100644 --- a/sendcoinsdialog.ui +++ b/sendcoinsdialog.ui @@ -7,11 +7,11 @@ <x>0</x> <y>0</y> <width>736</width> - <height>129</height> + <height>140</height> </rect> </property> <property name="windowTitle"> - <string>Dialog</string> + <string>Send Coins</string> </property> <layout class="QVBoxLayout" name="verticalLayout"> <item> @@ -56,14 +56,14 @@ </widget> </item> <item row="3" column="2"> - <widget class="QPushButton" name="pushButton"> + <widget class="QPushButton" name="pasteButton"> <property name="text"> <string>&Paste</string> </property> </widget> </item> <item row="3" column="3"> - <widget class="QPushButton" name="pushButton_2"> + <widget class="QPushButton" name="addressBookButton"> <property name="text"> <string>Address &Book...</string> </property> @@ -97,50 +97,38 @@ </spacer> </item> <item> - <widget class="QDialogButtonBox" name="buttonBox"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="standardButtons"> - <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set> - </property> - </widget> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <spacer name="horizontalSpacer"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QPushButton" name="sendButton"> + <property name="text"> + <string>&Send</string> + </property> + </widget> + </item> + <item> + <widget class="QPushButton" name="cancelButton"> + <property name="text"> + <string>Cancel</string> + </property> + </widget> + </item> + </layout> </item> </layout> </widget> <resources/> - <connections> - <connection> - <sender>buttonBox</sender> - <signal>accepted()</signal> - <receiver>SendCoinsDialog</receiver> - <slot>accept()</slot> - <hints> - <hint type="sourcelabel"> - <x>248</x> - <y>254</y> - </hint> - <hint type="destinationlabel"> - <x>157</x> - <y>274</y> - </hint> - </hints> - </connection> - <connection> - <sender>buttonBox</sender> - <signal>rejected()</signal> - <receiver>SendCoinsDialog</receiver> - <slot>reject()</slot> - <hints> - <hint type="sourcelabel"> - <x>316</x> - <y>260</y> - </hint> - <hint type="destinationlabel"> - <x>286</x> - <y>274</y> - </hint> - </hints> - </connection> - </connections> + <connections/> </ui> |