summaryrefslogtreecommitdiffstats
path: root/src/dialog.cpp
diff options
context:
space:
mode:
authorSimon Rettberg2015-11-12 17:03:11 +0100
committerSimon Rettberg2015-11-12 17:03:11 +0100
commit1c49173c8f62d3b9e609d22a027a42376db5d3de (patch)
tree2e5559d0435aa5ff784ee58e7dbcc8524a048984 /src/dialog.cpp
parentAdd images for win2k, winxp, win8 (diff)
downloadvmchooser2-1c49173c8f62d3b9e609d22a027a42376db5d3de.tar.gz
vmchooser2-1c49173c8f62d3b9e609d22a027a42376db5d3de.tar.xz
vmchooser2-1c49173c8f62d3b9e609d22a027a42376db5d3de.zip
Start refactoring download helpers and icon management
Diffstat (limited to 'src/dialog.cpp')
-rw-r--r--src/dialog.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/dialog.cpp b/src/dialog.cpp
index 7cf8cd1..605aeb4 100644
--- a/src/dialog.cpp
+++ b/src/dialog.cpp
@@ -63,13 +63,12 @@ Dialog::Dialog(QWidget *parent)
// TODO: Implement bug report dialog :)
ui->buttonBugReport->setEnabled(false);
+ QObject::connect(SessionsIconHolder::get(), SIGNAL(iconDownloaded(const QUrl&, const QIcon&)),
+ this, SLOT(iconDownloaded(const QUrl&, const QIcon&)));
}
Dialog::~Dialog() {
delete ui;
- delete model_[0];
- delete model_[1];
- delete model_[2];
}
void Dialog::changeEvent(QEvent *e) {
@@ -600,3 +599,9 @@ void Dialog::keyPressEvent(QKeyEvent* event) {
case Qt::Key_H: this->on_helpNewsButton_clicked(); break;
}
}
+
+void Dialog::iconDownloaded(const QUrl& url, const QIcon&) {
+ qDebug() << "Icon downloaded... (" << url << ")";
+ // TODO: Check which model(s) contain an entry with this icon
+ model_[2]->updateView();
+}