From 4a77524b059c12165e20b38de6c0d4ed08e56419 Mon Sep 17 00:00:00 2001 From: robotbrain Date: Sun, 23 Feb 2014 16:14:24 -0500 Subject: Initial stuff. It doesnt work. --- gui/dialogs/ScreenshotDialog.cpp | 28 ++++++++++++ gui/dialogs/ScreenshotDialog.h | 29 +++++++++++++ gui/dialogs/ScreenshotDialog.ui | 93 ++++++++++++++++++++++++++++++++++++++++ 3 files changed, 150 insertions(+) create mode 100644 gui/dialogs/ScreenshotDialog.cpp create mode 100644 gui/dialogs/ScreenshotDialog.h create mode 100644 gui/dialogs/ScreenshotDialog.ui (limited to 'gui/dialogs') diff --git a/gui/dialogs/ScreenshotDialog.cpp b/gui/dialogs/ScreenshotDialog.cpp new file mode 100644 index 00000000..662c9e84 --- /dev/null +++ b/gui/dialogs/ScreenshotDialog.cpp @@ -0,0 +1,28 @@ +#include "ScreenshotDialog.h" +#include "ui_ScreenshotDialog.h" +#include "QModelIndex" + +ScreenshotDialog::ScreenshotDialog(ScreenshotList *list, QWidget *parent) : + QDialog(parent), + ui(new Ui::ScreenshotDialog), + m_list(list) +{ + ui->setupUi(this); + ui->listView->setModel(m_list); +} + +ScreenshotDialog::~ScreenshotDialog() +{ + delete ui; +} + +QList ScreenshotDialog::selected() +{ + QList list; + QList first = m_list->screenshots(); + for (QModelIndex index : ui->listView->selectionModel()->selectedIndexes()) + { + list.append(first.at(index.row())); + } + return list; +} diff --git a/gui/dialogs/ScreenshotDialog.h b/gui/dialogs/ScreenshotDialog.h new file mode 100644 index 00000000..d3f629e7 --- /dev/null +++ b/gui/dialogs/ScreenshotDialog.h @@ -0,0 +1,29 @@ +#pragma once + +#include +#include "logic/lists/ScreenshotList.h" + +class BaseInstance; + +namespace Ui +{ +class ScreenshotDialog; +} + +class ScreenshotDialog : public QDialog +{ + Q_OBJECT + +public: + explicit ScreenshotDialog(ScreenshotList *list, QWidget *parent = 0); + ~ScreenshotDialog(); + + QList selected(); + +private +slots: + +private: + Ui::ScreenshotDialog *ui; + ScreenshotList *m_list; +}; diff --git a/gui/dialogs/ScreenshotDialog.ui b/gui/dialogs/ScreenshotDialog.ui new file mode 100644 index 00000000..c912dffe --- /dev/null +++ b/gui/dialogs/ScreenshotDialog.ui @@ -0,0 +1,93 @@ + + + ScreenshotDialog + + + + 0 + 0 + 470 + 300 + + + + Dialog + + + + + 10 + 260 + 441 + 31 + + + + QDialogButtonBox::Cancel|QDialogButtonBox::Ok + + + + + + 10 + 10 + 439 + 241 + + + + QAbstractItemView::MultiSelection + + + + 480 + 360 + + + + QListView::LeftToRight + + + true + + + QListView::ListMode + + + + + + + buttonBox + accepted() + ScreenshotDialog + accept() + + + 248 + 254 + + + 157 + 274 + + + + + buttonBox + rejected() + ScreenshotDialog + reject() + + + 316 + 260 + + + 286 + 274 + + + + + -- cgit From 5e33da258c3b5159dba854eb4792d0852a1ca363 Mon Sep 17 00:00:00 2001 From: robotbrain Date: Sun, 23 Feb 2014 19:45:59 -0500 Subject: Close to finished. Need to fix the upload part. Viewing works (in grayscale) --- gui/dialogs/ScreenshotDialog.cpp | 2 +- gui/dialogs/ScreenshotDialog.ui | 21 +++++++++++++++------ 2 files changed, 16 insertions(+), 7 deletions(-) (limited to 'gui/dialogs') diff --git a/gui/dialogs/ScreenshotDialog.cpp b/gui/dialogs/ScreenshotDialog.cpp index 662c9e84..8900f15b 100644 --- a/gui/dialogs/ScreenshotDialog.cpp +++ b/gui/dialogs/ScreenshotDialog.cpp @@ -20,7 +20,7 @@ QList ScreenshotDialog::selected() { QList list; QList first = m_list->screenshots(); - for (QModelIndex index : ui->listView->selectionModel()->selectedIndexes()) + for (QModelIndex index : ui->listView->selectionModel()->selectedRows()) { list.append(first.at(index.row())); } diff --git a/gui/dialogs/ScreenshotDialog.ui b/gui/dialogs/ScreenshotDialog.ui index c912dffe..af73e5ec 100644 --- a/gui/dialogs/ScreenshotDialog.ui +++ b/gui/dialogs/ScreenshotDialog.ui @@ -11,7 +11,11 @@ - Dialog + Screenshots + + + + :/icons/multimc/scalable/apps/multimc.svg:/icons/multimc/scalable/apps/multimc.svg @@ -36,12 +40,15 @@ - QAbstractItemView::MultiSelection + QAbstractItemView::ExtendedSelection + + + QAbstractItemView::SelectItems - 480 - 360 + 120 + 90 @@ -51,11 +58,13 @@ true - QListView::ListMode + QListView::IconMode - + + + buttonBox -- cgit From 226c1bdae5ec615381965b6731f6496dffa3299e Mon Sep 17 00:00:00 2001 From: Jan Dalheimer Date: Mon, 24 Feb 2014 09:34:21 +0100 Subject: Screenshot fixes, move some code around, fix some stuff --- gui/dialogs/ScreenshotDialog.cpp | 42 ++++++++++++++++++++++++++++++++++++++-- gui/dialogs/ScreenshotDialog.h | 11 ++++++++++- gui/dialogs/ScreenshotDialog.ui | 16 --------------- 3 files changed, 50 insertions(+), 19 deletions(-) (limited to 'gui/dialogs') diff --git a/gui/dialogs/ScreenshotDialog.cpp b/gui/dialogs/ScreenshotDialog.cpp index 8900f15b..02764fa3 100644 --- a/gui/dialogs/ScreenshotDialog.cpp +++ b/gui/dialogs/ScreenshotDialog.cpp @@ -1,6 +1,13 @@ #include "ScreenshotDialog.h" #include "ui_ScreenshotDialog.h" -#include "QModelIndex" + +#include +#include + +#include "ProgressDialog.h" +#include "CustomMessageBox.h" +#include "logic/net/NetJob.h" +#include "logic/net/ScreenshotUploader.h" ScreenshotDialog::ScreenshotDialog(ScreenshotList *list, QWidget *parent) : QDialog(parent), @@ -16,7 +23,12 @@ ScreenshotDialog::~ScreenshotDialog() delete ui; } -QList ScreenshotDialog::selected() +QList ScreenshotDialog::uploaded() const +{ + return m_uploaded; +} + +QList ScreenshotDialog::selected() const { QList list; QList first = m_list->screenshots(); @@ -26,3 +38,29 @@ QList ScreenshotDialog::selected() } return list; } + +void ScreenshotDialog::on_buttonBox_accepted() +{ + QList screenshots = selected(); + if (screenshots.isEmpty()) + { + done(NothingDone); + return; + } + NetJob *job = new NetJob("Screenshot Upload"); + for (ScreenShot *shot : screenshots) + { + qDebug() << shot->file; + job->addNetAction(ScreenShotUpload::make(shot)); + } + ProgressDialog prog(this); + prog.exec(job); + connect(job, &NetJob::failed, [this] + { + CustomMessageBox::selectable(this, tr("Failed to upload screenshots!"), + tr("Unknown error"), QMessageBox::Warning)->exec(); + reject(); + }); + m_uploaded = screenshots; + connect(job, &NetJob::succeeded, this, &ScreenshotDialog::accept); +} diff --git a/gui/dialogs/ScreenshotDialog.h b/gui/dialogs/ScreenshotDialog.h index d3f629e7..1ca27bdd 100644 --- a/gui/dialogs/ScreenshotDialog.h +++ b/gui/dialogs/ScreenshotDialog.h @@ -18,12 +18,21 @@ public: explicit ScreenshotDialog(ScreenshotList *list, QWidget *parent = 0); ~ScreenshotDialog(); - QList selected(); + enum + { + NothingDone = 0x42 + }; + + QList uploaded() const; private slots: + void on_buttonBox_accepted(); private: Ui::ScreenshotDialog *ui; ScreenshotList *m_list; + QList m_uploaded; + + QList selected() const; }; diff --git a/gui/dialogs/ScreenshotDialog.ui b/gui/dialogs/ScreenshotDialog.ui index af73e5ec..7eeab859 100644 --- a/gui/dialogs/ScreenshotDialog.ui +++ b/gui/dialogs/ScreenshotDialog.ui @@ -66,22 +66,6 @@ - - buttonBox - accepted() - ScreenshotDialog - accept() - - - 248 - 254 - - - 157 - 274 - - - buttonBox rejected() -- cgit From a8811a27f78698f1ab2acad47e90f3b16274e221 Mon Sep 17 00:00:00 2001 From: Jan Dalheimer Date: Mon, 24 Feb 2014 10:34:51 +0100 Subject: Working screenshot upload --- gui/dialogs/ScreenshotDialog.cpp | 15 +++--- gui/dialogs/ScreenshotDialog.h | 2 +- gui/dialogs/ScreenshotDialog.ui | 114 ++++++++++++++++++++++----------------- 3 files changed, 73 insertions(+), 58 deletions(-) (limited to 'gui/dialogs') diff --git a/gui/dialogs/ScreenshotDialog.cpp b/gui/dialogs/ScreenshotDialog.cpp index 02764fa3..33e93162 100644 --- a/gui/dialogs/ScreenshotDialog.cpp +++ b/gui/dialogs/ScreenshotDialog.cpp @@ -39,7 +39,7 @@ QList ScreenshotDialog::selected() const return list; } -void ScreenshotDialog::on_buttonBox_accepted() +void ScreenshotDialog::on_uploadBtn_clicked() { QList screenshots = selected(); if (screenshots.isEmpty()) @@ -50,17 +50,18 @@ void ScreenshotDialog::on_buttonBox_accepted() NetJob *job = new NetJob("Screenshot Upload"); for (ScreenShot *shot : screenshots) { - qDebug() << shot->file; job->addNetAction(ScreenShotUpload::make(shot)); } + m_uploaded = screenshots; ProgressDialog prog(this); - prog.exec(job); - connect(job, &NetJob::failed, [this] + if (prog.exec(job) == QDialog::Accepted) + { + accept(); + } + else { CustomMessageBox::selectable(this, tr("Failed to upload screenshots!"), tr("Unknown error"), QMessageBox::Warning)->exec(); reject(); - }); - m_uploaded = screenshots; - connect(job, &NetJob::succeeded, this, &ScreenshotDialog::accept); + } } diff --git a/gui/dialogs/ScreenshotDialog.h b/gui/dialogs/ScreenshotDialog.h index 1ca27bdd..104814f1 100644 --- a/gui/dialogs/ScreenshotDialog.h +++ b/gui/dialogs/ScreenshotDialog.h @@ -27,7 +27,7 @@ public: private slots: - void on_buttonBox_accepted(); + void on_uploadBtn_clicked(); private: Ui::ScreenshotDialog *ui; diff --git a/gui/dialogs/ScreenshotDialog.ui b/gui/dialogs/ScreenshotDialog.ui index 7eeab859..9e4bd6f0 100644 --- a/gui/dialogs/ScreenshotDialog.ui +++ b/gui/dialogs/ScreenshotDialog.ui @@ -17,68 +17,82 @@ :/icons/multimc/scalable/apps/multimc.svg:/icons/multimc/scalable/apps/multimc.svg - - - - 10 - 260 - 441 - 31 - - - - QDialogButtonBox::Cancel|QDialogButtonBox::Ok - - - - - - 10 - 10 - 439 - 241 - - - - QAbstractItemView::ExtendedSelection - - - QAbstractItemView::SelectItems - - - - 120 - 90 - - - - QListView::LeftToRight - - - true - - - QListView::IconMode - - + + + + + QAbstractItemView::ExtendedSelection + + + QAbstractItemView::SelectItems + + + + 120 + 90 + + + + QListView::LeftToRight + + + true + + + QListView::IconMode + + + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + Close + + + + + + + Upload + + + + + + - buttonBox - rejected() + closeBtn + clicked() ScreenshotDialog reject() - 316 - 260 + 315 + 272 - 286 - 274 + 271 + 258 -- cgit From da33fa4090b4510267d06b3fd3ec439ff563b80e Mon Sep 17 00:00:00 2001 From: Jan Dalheimer Date: Mon, 24 Feb 2014 11:30:27 +0100 Subject: Imgur album creation --- gui/dialogs/CustomMessageBox.cpp | 1 + gui/dialogs/ScreenshotDialog.cpp | 38 ++++++++++++++++++++++---------------- gui/dialogs/ScreenshotDialog.h | 5 +++-- 3 files changed, 26 insertions(+), 18 deletions(-) (limited to 'gui/dialogs') diff --git a/gui/dialogs/CustomMessageBox.cpp b/gui/dialogs/CustomMessageBox.cpp index 1d2ab58a..4013db60 100644 --- a/gui/dialogs/CustomMessageBox.cpp +++ b/gui/dialogs/CustomMessageBox.cpp @@ -28,6 +28,7 @@ QMessageBox *selectable(QWidget *parent, const QString &title, const QString &te messageBox->setDefaultButton(defaultButton); messageBox->setTextInteractionFlags(Qt::TextSelectableByMouse); messageBox->setIcon(icon); + messageBox->setTextInteractionFlags(Qt::TextBrowserInteraction); return messageBox; } diff --git a/gui/dialogs/ScreenshotDialog.cpp b/gui/dialogs/ScreenshotDialog.cpp index 33e93162..3b4af5e5 100644 --- a/gui/dialogs/ScreenshotDialog.cpp +++ b/gui/dialogs/ScreenshotDialog.cpp @@ -7,12 +7,12 @@ #include "ProgressDialog.h" #include "CustomMessageBox.h" #include "logic/net/NetJob.h" -#include "logic/net/ScreenshotUploader.h" +#include "logic/net/ImgurUpload.h" +#include "logic/net/ImgurAlbumCreation.h" +#include "logic/tasks/SequentialTask.h" -ScreenshotDialog::ScreenshotDialog(ScreenshotList *list, QWidget *parent) : - QDialog(parent), - ui(new Ui::ScreenshotDialog), - m_list(list) +ScreenshotDialog::ScreenshotDialog(ScreenshotList *list, QWidget *parent) + : QDialog(parent), ui(new Ui::ScreenshotDialog), m_list(list) { ui->setupUi(this); ui->listView->setModel(m_list); @@ -23,15 +23,17 @@ ScreenshotDialog::~ScreenshotDialog() delete ui; } -QList ScreenshotDialog::uploaded() const +QString ScreenshotDialog::message() const { - return m_uploaded; + return tr("Visit album
Delete hash: %2 (save " + "this if you want to be able to edit/delete the album)") + .arg(m_imgurAlbum->id(), m_imgurAlbum->deleteHash()); } -QList ScreenshotDialog::selected() const +QList ScreenshotDialog::selected() const { - QList list; - QList first = m_list->screenshots(); + QList list; + QList first = m_list->screenshots(); for (QModelIndex index : ui->listView->selectionModel()->selectedRows()) { list.append(first.at(index.row())); @@ -41,20 +43,24 @@ QList ScreenshotDialog::selected() const void ScreenshotDialog::on_uploadBtn_clicked() { - QList screenshots = selected(); - if (screenshots.isEmpty()) + m_uploaded = selected(); + if (m_uploaded.isEmpty()) { done(NothingDone); return; } + SequentialTask *task = new SequentialTask(this); NetJob *job = new NetJob("Screenshot Upload"); - for (ScreenShot *shot : screenshots) + for (ScreenShot *shot : m_uploaded) { - job->addNetAction(ScreenShotUpload::make(shot)); + job->addNetAction(ImgurUpload::make(shot)); } - m_uploaded = screenshots; + NetJob *albumTask = new NetJob("Imgur Album Creation"); + albumTask->addNetAction(m_imgurAlbum = ImgurAlbumCreation::make(m_uploaded)); + task->addTask(std::shared_ptr(job)); + task->addTask(std::shared_ptr(albumTask)); ProgressDialog prog(this); - if (prog.exec(job) == QDialog::Accepted) + if (prog.exec(task) == QDialog::Accepted) { accept(); } diff --git a/gui/dialogs/ScreenshotDialog.h b/gui/dialogs/ScreenshotDialog.h index 104814f1..ac1494d6 100644 --- a/gui/dialogs/ScreenshotDialog.h +++ b/gui/dialogs/ScreenshotDialog.h @@ -3,7 +3,7 @@ #include #include "logic/lists/ScreenshotList.h" -class BaseInstance; +class ImgurAlbumCreation; namespace Ui { @@ -23,7 +23,7 @@ public: NothingDone = 0x42 }; - QList uploaded() const; + QString message() const; private slots: @@ -33,6 +33,7 @@ private: Ui::ScreenshotDialog *ui; ScreenshotList *m_list; QList m_uploaded; + std::shared_ptr m_imgurAlbum; QList selected() const; }; -- cgit From 55e21737dd7d30c1922615c575384b41cc77985f Mon Sep 17 00:00:00 2001 From: robotbrain Date: Mon, 24 Feb 2014 17:40:05 -0500 Subject: Deleting screenshots. Needs fixing. --- gui/dialogs/ScreenshotDialog.cpp | 7 ++++++- gui/dialogs/ScreenshotDialog.h | 5 +++-- gui/dialogs/ScreenshotDialog.ui | 9 ++++++++- 3 files changed, 17 insertions(+), 4 deletions(-) (limited to 'gui/dialogs') diff --git a/gui/dialogs/ScreenshotDialog.cpp b/gui/dialogs/ScreenshotDialog.cpp index 3b4af5e5..c62e1d52 100644 --- a/gui/dialogs/ScreenshotDialog.cpp +++ b/gui/dialogs/ScreenshotDialog.cpp @@ -2,7 +2,7 @@ #include "ui_ScreenshotDialog.h" #include -#include +#include #include "ProgressDialog.h" #include "CustomMessageBox.h" @@ -71,3 +71,8 @@ void ScreenshotDialog::on_uploadBtn_clicked() reject(); } } + +void ScreenshotDialog::on_deleteBtn_clicked() +{ + m_list->deleteSelected(this); +} diff --git a/gui/dialogs/ScreenshotDialog.h b/gui/dialogs/ScreenshotDialog.h index ac1494d6..a406d1fe 100644 --- a/gui/dialogs/ScreenshotDialog.h +++ b/gui/dialogs/ScreenshotDialog.h @@ -24,16 +24,17 @@ public: }; QString message() const; + QList selected() const; private slots: void on_uploadBtn_clicked(); + void on_deleteBtn_clicked(); + private: Ui::ScreenshotDialog *ui; ScreenshotList *m_list; QList m_uploaded; std::shared_ptr m_imgurAlbum; - - QList selected() const; }; diff --git a/gui/dialogs/ScreenshotDialog.ui b/gui/dialogs/ScreenshotDialog.ui index 9e4bd6f0..4e42a548 100644 --- a/gui/dialogs/ScreenshotDialog.ui +++ b/gui/dialogs/ScreenshotDialog.ui @@ -11,7 +11,7 @@ - Screenshots + Screenshot Manager @@ -72,6 +72,13 @@ + + + + Delete + + + -- cgit From b1cddb4600db2aa54c9d274466b393fc1e03eba9 Mon Sep 17 00:00:00 2001 From: robotbrain Date: Mon, 24 Feb 2014 17:49:18 -0500 Subject: Fix memory leak in system --- gui/dialogs/ScreenshotDialog.cpp | 6 +++--- gui/dialogs/ScreenshotDialog.h | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'gui/dialogs') diff --git a/gui/dialogs/ScreenshotDialog.cpp b/gui/dialogs/ScreenshotDialog.cpp index c62e1d52..76f87283 100644 --- a/gui/dialogs/ScreenshotDialog.cpp +++ b/gui/dialogs/ScreenshotDialog.cpp @@ -32,8 +32,8 @@ QString ScreenshotDialog::message() const QList ScreenshotDialog::selected() const { - QList list; - QList first = m_list->screenshots(); + QList> list; + QList> first = m_list->screenshots(); for (QModelIndex index : ui->listView->selectionModel()->selectedRows()) { list.append(first.at(index.row())); @@ -51,7 +51,7 @@ void ScreenshotDialog::on_uploadBtn_clicked() } SequentialTask *task = new SequentialTask(this); NetJob *job = new NetJob("Screenshot Upload"); - for (ScreenShot *shot : m_uploaded) + for (std::shared_ptr shot : m_uploaded) { job->addNetAction(ImgurUpload::make(shot)); } diff --git a/gui/dialogs/ScreenshotDialog.h b/gui/dialogs/ScreenshotDialog.h index a406d1fe..ac95b4f0 100644 --- a/gui/dialogs/ScreenshotDialog.h +++ b/gui/dialogs/ScreenshotDialog.h @@ -24,7 +24,7 @@ public: }; QString message() const; - QList selected() const; + QList> selected() const; private slots: @@ -35,6 +35,6 @@ slots: private: Ui::ScreenshotDialog *ui; ScreenshotList *m_list; - QList m_uploaded; + QList> m_uploaded; std::shared_ptr m_imgurAlbum; }; -- cgit From cb5cfe724208beb7d506868fc4e50d9f13e28a53 Mon Sep 17 00:00:00 2001 From: Petr Mrázek Date: Tue, 25 Feb 2014 00:51:24 +0100 Subject: Reorganize all the screenshot files --- gui/dialogs/ScreenshotDialog.cpp | 16 ++++++++-------- gui/dialogs/ScreenshotDialog.h | 6 +++--- 2 files changed, 11 insertions(+), 11 deletions(-) (limited to 'gui/dialogs') diff --git a/gui/dialogs/ScreenshotDialog.cpp b/gui/dialogs/ScreenshotDialog.cpp index 76f87283..a88c8dfd 100644 --- a/gui/dialogs/ScreenshotDialog.cpp +++ b/gui/dialogs/ScreenshotDialog.cpp @@ -7,8 +7,8 @@ #include "ProgressDialog.h" #include "CustomMessageBox.h" #include "logic/net/NetJob.h" -#include "logic/net/ImgurUpload.h" -#include "logic/net/ImgurAlbumCreation.h" +#include "logic/screenshots/ImgurUpload.h" +#include "logic/screenshots/ImgurAlbumCreation.h" #include "logic/tasks/SequentialTask.h" ScreenshotDialog::ScreenshotDialog(ScreenshotList *list, QWidget *parent) @@ -30,10 +30,10 @@ QString ScreenshotDialog::message() const .arg(m_imgurAlbum->id(), m_imgurAlbum->deleteHash()); } -QList ScreenshotDialog::selected() const +QList ScreenshotDialog::selected() const { - QList> list; - QList> first = m_list->screenshots(); + QList list; + QList first = m_list->screenshots(); for (QModelIndex index : ui->listView->selectionModel()->selectedRows()) { list.append(first.at(index.row())); @@ -51,14 +51,14 @@ void ScreenshotDialog::on_uploadBtn_clicked() } SequentialTask *task = new SequentialTask(this); NetJob *job = new NetJob("Screenshot Upload"); - for (std::shared_ptr shot : m_uploaded) + for (auto shot : m_uploaded) { job->addNetAction(ImgurUpload::make(shot)); } NetJob *albumTask = new NetJob("Imgur Album Creation"); albumTask->addNetAction(m_imgurAlbum = ImgurAlbumCreation::make(m_uploaded)); - task->addTask(std::shared_ptr(job)); - task->addTask(std::shared_ptr(albumTask)); + task->addTask(NetJobPtr(job)); + task->addTask(NetJobPtr(albumTask)); ProgressDialog prog(this); if (prog.exec(task) == QDialog::Accepted) { diff --git a/gui/dialogs/ScreenshotDialog.h b/gui/dialogs/ScreenshotDialog.h index ac95b4f0..29dd6765 100644 --- a/gui/dialogs/ScreenshotDialog.h +++ b/gui/dialogs/ScreenshotDialog.h @@ -1,7 +1,7 @@ #pragma once #include -#include "logic/lists/ScreenshotList.h" +#include "logic/screenshots/ScreenshotList.h" class ImgurAlbumCreation; @@ -24,7 +24,7 @@ public: }; QString message() const; - QList> selected() const; + QList selected() const; private slots: @@ -35,6 +35,6 @@ slots: private: Ui::ScreenshotDialog *ui; ScreenshotList *m_list; - QList> m_uploaded; + QList m_uploaded; std::shared_ptr m_imgurAlbum; }; -- cgit From 9d4e840a6e1a7169a2863fa1ff1812f8fe19e615 Mon Sep 17 00:00:00 2001 From: Petr Mrázek Date: Tue, 25 Feb 2014 01:21:46 +0100 Subject: Screenshots: Optimize image loading and memory use, fix list and button layout. --- gui/dialogs/ScreenshotDialog.ui | 31 +++++++++++++++++-------------- 1 file changed, 17 insertions(+), 14 deletions(-) (limited to 'gui/dialogs') diff --git a/gui/dialogs/ScreenshotDialog.ui b/gui/dialogs/ScreenshotDialog.ui index 4e42a548..eb3dafba 100644 --- a/gui/dialogs/ScreenshotDialog.ui +++ b/gui/dialogs/ScreenshotDialog.ui @@ -38,6 +38,9 @@ true + + QListView::Adjust + QListView::IconMode @@ -45,6 +48,20 @@ + + + + Upload + + + + + + + Delete + + + @@ -65,20 +82,6 @@ - - - - Upload - - - - - - - Delete - - - -- cgit