QTfrontend/ui/dialog/upload_video.h
changeset 7447 01111960a48d
child 7507 3032a5739fe1
equal deleted inserted replaced
7442:9bb6abdb5675 7447:01111960a48d
       
     1 /*
       
     2  * Hedgewars, a free turn based strategy game
       
     3  * Copyright (c) 2004-2012 Andrey Korotaev <unC0Rr@gmail.com>
       
     4  *
       
     5  * This program is free software; you can redistribute it and/or modify
       
     6  * it under the terms of the GNU General Public License as published by
       
     7  * the Free Software Foundation; version 2 of the License
       
     8  *
       
     9  * This program is distributed in the hope that it will be useful,
       
    10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
       
    11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
       
    12  * GNU General Public License for more details.
       
    13  *
       
    14  * You should have received a copy of the GNU General Public License
       
    15  * along with this program; if not, write to the Free Software
       
    16  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
       
    17  */
       
    18 
       
    19 #ifndef UPLOAD_VIDEO_H
       
    20 #define UPLOAD_VIDEO_H
       
    21 
       
    22 #include <QDialog>
       
    23 
       
    24 class QLineEdit;
       
    25 class QCheckBox;
       
    26 class QPlainTextEdit;
       
    27 class QLabel;
       
    28 class QNetworkAccessManager;
       
    29 
       
    30 class HWUploadVideoDialog : public QDialog
       
    31 {
       
    32         Q_OBJECT
       
    33     public:
       
    34     HWUploadVideoDialog(QWidget* parent, const QString& filename, QNetworkAccessManager* netManager);
       
    35 
       
    36         QLineEdit* leAccount;
       
    37         QLineEdit* lePassword;
       
    38         QCheckBox* cbSave;
       
    39 
       
    40         QLineEdit* leTitle;
       
    41         QPlainTextEdit* teDescription;
       
    42 
       
    43         QPushButton* btnUpload;
       
    44 
       
    45         QLabel* labelLog;
       
    46 
       
    47         QString location;
       
    48 
       
    49     private:
       
    50         QNetworkAccessManager* netManager;
       
    51         QString filename;
       
    52 
       
    53         void log(const QString& text);
       
    54         void setEditable(bool editable);
       
    55 
       
    56     private slots:
       
    57         void upload();
       
    58         void authFinished();
       
    59         void startUpload();
       
    60 };
       
    61 
       
    62 #endif // UPLOAD_VIDEO_H