]> git.sesse.net Git - vlc/blobdiff - modules/gui/qt4/dialogs/sout.hpp
Drop trailing semicolons
[vlc] / modules / gui / qt4 / dialogs / sout.hpp
index 9cc9255be7d365c4ad2652ba325ef9a0cf395c23..85c1284ca30df23e1bdd2d45bf83bc143347852b 100644 (file)
@@ -21,8 +21,8 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
-#ifndef _SOUT_DIALOG_H_
-#define _SOUT_DIALOG_H_
+#ifndef QVLC_SOUT_DIALOG_H_
+#define QVLC_SOUT_DIALOG_H_ 1
 
 #ifdef HAVE_CONFIG_H
 # include "config.h"
@@ -34,6 +34,7 @@
 #include "util/qvlcframe.hpp"
 
 class QPushButton;
+class QToolButton;
 class QCheckBox;
 class QGridLayout;
 class QTextEdit;
@@ -41,7 +42,7 @@ class QTextEdit;
 class SoutMrl
 {
 public:
-    SoutMrl( const QString head = "")
+    SoutMrl( const QString& head = "")
     {
         mrl = head;
         b_first = true;
@@ -53,7 +54,7 @@ public:
         return mrl;
     }
 
-    void begin( QString module )
+    void begin( const QString& module )
     {
         if( !b_first )
             mrl += ":";
@@ -67,7 +68,7 @@ public:
         if( b_has_bracket )
             mrl += "}";
     }
-    void option( const QString option, const QString value = "" )
+    void option( const QString& option, const QString& value = "" )
     {
         if( !b_has_bracket )
             mrl += "{";
@@ -82,21 +83,21 @@ public:
             char *psz = config_StringEscape( qtu(value) );
             if( psz )
             {
-                mrl += "=\"" + qfu( psz ) + "\"";
+                mrl += "=" + qfu( psz );
                 free( psz );
             }
         }
     }
-    void option( const QString name, const int i_value, const int i_precision = 10 )
+    void option( const QString& name, const int i_value, const int i_precision = 10 )
     {
         option( name, QString::number( i_value, i_precision ) );
     }
-    void option( const QString name, const double f_value )
+    void option( const QString& name, const double f_value )
     {
         option( name, QString::number( f_value ) );
     }
 
-    void option( const QString name, const QString base, const int i_value, const int i_precision = 10 )
+    void option( const QString& name, const QString& base, const int i_value, const int i_precision = 10 )
     {
         option( name, base + ":" + QString::number( i_value, i_precision ) );
     }
@@ -110,31 +111,19 @@ private:
 
 class SoutDialog : public QVLCDialog
 {
-    Q_OBJECT;
+    Q_OBJECT
 public:
-    static SoutDialog* getInstance( QWidget *parent, intf_thread_t *p_intf,
-                                    QString mrl = "" )
-    {
-        if( !instance )
-            instance = new SoutDialog( parent, p_intf, mrl );
-        else
-        {
-            /* Recenter the dialog on the parent */
-            instance->setParent( parent, Qt::Dialog );
-        }
-        return instance;
-    }
-
+    SoutDialog( QWidget* parent, intf_thread_t *, const QString& mrl = "");
     virtual ~SoutDialog(){}
 
     QString getMrl(){ return mrl; }
 
 private:
     Ui::Sout ui;
-    static SoutDialog *instance;
-    SoutDialog( QWidget* parent, intf_thread_t *, QString mrl );
-    QPushButton *okButton;
+
     QString mrl;
+    QPushButton *okButton;
+    QToolButton *closeTabButton;
 
 public slots:
     void updateMRL();
@@ -142,12 +131,11 @@ public slots:
 private slots:
     void ok();
     void cancel();
-    void setOptions();
-    void fileBrowse();
-    void setRawOptions( bool );
-    void changeUDPandRTPmess( bool );
-    void RTPtoggled( bool );
     void next();
+    void prev();
+    void closeTab();
+    void tabChanged( int );
+    void addDest();
 };
 
 #endif