digiKam
dbwindow.h
Go to the documentation of this file.
1 /* ============================================================
2  *
3  * This file is a part of digiKam project
4  * https://www.digikam.org
5  *
6  * Date : 2013-11-18
7  * Description : a tool to export images to Dropbox web service
8  *
9  * Copyright (C) 2013 by Pankaj Kumar <me at panks dot me>
10  * Copyright (C) 2013-2022 by Gilles Caulier <caulier dot gilles at gmail dot com>
11  *
12  * This program is free software; you can redistribute it
13  * and/or modify it under the terms of the GNU General
14  * Public License as published by the Free Software Foundation;
15  * either version 2, or (at your option) any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU General Public License for more details.
21  *
22  * ============================================================ */
23 
24 #ifndef DIGIKAM_DB_WINDOW_H
25 #define DIGIKAM_DB_WINDOW_H
26 
27 // Qt includes
28 
29 #include <QList>
30 #include <QUrl>
31 #include <QPair>
32 
33 // Local includes
34 
35 #include "wstooldialog.h"
36 #include "dinfointerface.h"
37 
38 class QCloseEvent;
39 class QUrl;
40 
41 using namespace Digikam;
42 
44 {
45 
46 class DBWindow : public WSToolDialog
47 {
48  Q_OBJECT
49 
50 public:
51 
52  explicit DBWindow(DInfoInterface* const iface, QWidget* const parent);
53  ~DBWindow() override;
54 
55  void reactivate();
56 
57  void setItemsList(const QList<QUrl>& urls);
58 
59 private:
60 
61  void readSettings();
62  void writeSettings();
63 
64  void uploadNextPhoto();
65 
66  void buttonStateChange(bool state);
67  void closeEvent(QCloseEvent*) override;
68 
69 private Q_SLOTS:
70 
71  void slotImageListChanged();
72  void slotUserChangeRequest();
73  void slotNewAlbumRequest();
74  void slotReloadAlbumsRequest();
75  void slotStartTransfer();
76 
77  void slotBusy(bool);
78  void slotSignalLinkingFailed();
79  void slotSignalLinkingSucceeded();
80  void slotSetUserName(const QString& msg);
81  void slotListAlbumsFailed(const QString& msg);
82  void slotListAlbumsDone(const QList<QPair<QString, QString> >& list);
83  void slotCreateFolderFailed(const QString& msg);
84  void slotCreateFolderSucceeded();
85  void slotAddPhotoFailed(const QString& msg);
86  void slotAddPhotoSucceeded();
87  void slotTransferCancel();
88 
89  void slotFinished();
90 
91 private:
92 
93  class Private;
94  Private* const d;
95 };
96 
97 } // namespace DigikamGenericDropBoxPlugin
98 
99 #endif // DIGIKAM_DB_WINDOW_H
Definition: dbwindow.h:47
Definition: dinfointerface.h:56
Definition: wstooldialog.h:43
Definition: dbitem.h:32
Definition: datefolderview.cpp:43