You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

69 lines
1.3 KiB

#ifndef MAIN_H
#define MAIN_H
#include <QtNetwork/QNetworkAccessManager>
#include <QAbstractListModel>
#include <QMainWindow>
#include <QMutex>
#include <libethereum/Common.h>
namespace Ui {
class Main;
}
namespace eth {
class Client;
}
class Main : public QMainWindow
{
Q_OBJECT
public:
explicit Main(QWidget *parent = 0);
~Main();
private slots:
void on_connect_triggered();
void on_mine_triggered();
void on_send_clicked();
void on_create_triggered();
void on_net_triggered();
void on_verbosity_sliderMoved();
void on_ourAccounts_doubleClicked();
void on_accounts_doubleClicked();
void on_destination_textChanged();
void on_data_textChanged();
void on_idealPeers_valueChanged();
void on_value_valueChanged() { updateFee(); }
void on_valueUnits_currentIndexChanged() { updateFee(); }
void on_log_doubleClicked();
void on_about_triggered();
void on_quit_triggered() { close(); }
void refresh();
private:
void updateFee();
void readSettings();
void writeSettings();
eth::u256 fee() const;
eth::u256 total() const;
eth::u256 value() const;
Ui::Main *ui;
eth::Client* m_client;
QByteArray m_peers;
QMutex m_guiLock;
QTimer* m_refresh;
QStringList m_servers;
QVector<eth::KeyPair> m_myKeys;
QStringList m_data;
QNetworkAccessManager m_webCtrl;
};
#endif // MAIN_H