source: trunk/qt/make-dialog.h @ 14241

Last change on this file since 14241 was 14241, checked in by jordan, 9 years ago

Copyedit the license's revised text: (1) remove unnecessary repitition use of the word 'license' from the top of the header and source files (2) add the standard 'we hope it's useful, but no warranty' clause to COPYING (3) make explicit that linking OpenSSL is allowed (see https://people.gnome.org/~markmc/openssl-and-the-gpl.html for background) (4) sync the Qt and GTK+ clients' license popups with COPYING's revised text

  • Property svn:keywords set to Date Rev Author Id
File size: 2.2 KB
Line 
1/*
2 * This file Copyright (C) 2009-2014 Mnemosyne LLC
3 *
4 * It may be used under the GNU GPL versions 2 or 3
5 * or any future license endorsed by Mnemosyne LLC.
6 *
7 * $Id: make-dialog.h 14241 2014-01-21 03:10:30Z jordan $
8 */
9
10#ifndef MAKE_DIALOG_H
11#define MAKE_DIALOG_H
12
13#include <QDialog>
14#include <QTimer>
15
16class QAbstractButton;
17class QPlainTextEdit;
18class QLineEdit;
19class QCheckBox;
20class QLabel;
21class QPushButton;
22class QRadioButton;
23class Session;
24class QProgressBar;
25class QDialogButtonBox;
26
27extern "C"
28{
29  struct tr_metainfo_builder;
30}
31
32class MakeDialog: public QDialog
33{
34    Q_OBJECT
35
36  private slots:
37    void onSourceChanged ();
38    void onButtonBoxClicked (QAbstractButton*);
39    void onNewButtonBoxClicked (QAbstractButton*);
40    void onNewDialogDestroyed (QObject*);
41    void onProgress ();
42
43    void onFolderClicked ();
44    void onFolderSelected (const QString&);
45    void onFolderSelected (const QStringList&);
46
47    void onFileClicked ();
48    void onFileSelected (const QString&);
49    void onFileSelected (const QStringList&);
50
51    void onDestinationClicked ();
52    void onDestinationSelected (const QString&);
53    void onDestinationSelected (const QStringList&);
54
55  private:
56    void makeTorrent ();
57    QString getSource () const;
58    void enableBuddyWhenChecked (QCheckBox *, QWidget *);
59    void enableBuddyWhenChecked (QRadioButton *, QWidget *);
60
61  private:
62    Session& mySession;
63    QString myDestination;
64    QString myTarget;
65    QString myFile;
66    QString myFolder;
67    QTimer myTimer;
68    QRadioButton * myFolderRadio;
69    QRadioButton * myFileRadio;
70    QPushButton * myDestinationButton;
71    QPushButton * myFileButton;
72    QPushButton * myFolderButton;
73    QPlainTextEdit * myTrackerEdit;
74    QCheckBox * myCommentCheck;
75    QLineEdit * myCommentEdit;
76    QCheckBox * myPrivateCheck;
77    QLabel * mySourceLabel;
78    QDialogButtonBox * myButtonBox;
79    QProgressBar * myNewProgress;
80    QLabel * myNewLabel;
81    QDialogButtonBox * myNewButtonBox;
82    QDialog * myNewDialog;
83    struct tr_metainfo_builder * myBuilder;
84
85  protected:
86    virtual void dragEnterEvent (QDragEnterEvent *);
87    virtual void dropEvent (QDropEvent *);
88
89  public:
90    MakeDialog (Session&, QWidget * parent = 0);
91    ~MakeDialog ();
92};
93
94#endif
Note: See TracBrowser for help on using the repository browser.