[vlc-devel] commit: Add RTMP option on the panel. (Jean-Baptiste Kempf )

git version control git at videolan.org
Wed Jun 25 03:36:53 CEST 2008


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Tue Jun 24 18:37:42 2008 -0700| [a10edeec0fbf5a5f6e3dabd03ca3af6e428fe08f]

Add RTMP option on the panel.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=a10edeec0fbf5a5f6e3dabd03ca3af6e428fe08f
---

 modules/gui/qt4/components/open_panels.cpp |   12 ++++++++++--
 modules/gui/qt4/components/open_panels.hpp |    3 ++-
 2 files changed, 12 insertions(+), 3 deletions(-)

diff --git a/modules/gui/qt4/components/open_panels.cpp b/modules/gui/qt4/components/open_panels.cpp
index 79e2a5d..5f8ec12 100644
--- a/modules/gui/qt4/components/open_panels.cpp
+++ b/modules/gui/qt4/components/open_panels.cpp
@@ -425,6 +425,7 @@ NetOpenPanel::NetOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
     ui.protocolCombo->addItem("RTSP", QVariant("rtsp"));
     ui.protocolCombo->addItem("UDP/RTP (unicast)", QVariant("udp"));
     ui.protocolCombo->addItem("UDP/RTP (multicast)", QVariant("udp"));
+    ui.protocolCombo->addItem("RTMP", QVariant("rtmp"));
 }
 
 NetOpenPanel::~NetOpenPanel()
@@ -438,10 +439,12 @@ void NetOpenPanel::updateProtocol( int idx_proto ) {
     QString addr = ui.addressText->text();
     QString proto = ui.protocolCombo->itemData( idx_proto ).toString();
 
-    ui.timeShift->setEnabled( idx_proto >= UDP_PROTO );
+    ui.timeShift->setEnabled( idx_proto == UDP_PROTO ||
+                              idx_proto == UDPM_PROTO );
     ui.ipv6->setEnabled( idx_proto == UDP_PROTO );
     ui.addressText->setEnabled( idx_proto != UDP_PROTO );
-    ui.portSpin->setEnabled( idx_proto >= UDP_PROTO );
+    ui.portSpin->setEnabled( idx_proto == UDP_PROTO ||
+                             idx_proto == UDPM_PROTO );
 
     if( idx_proto == NO_PROTO ) return;
 
@@ -514,6 +517,11 @@ void NetOpenPanel::updateMRL() {
             else mrl += addr;
             mrl += QString(":%1").arg( ui.portSpin->value() );
             emit methodChanged("udp-caching");
+        case RTMP_PROTO:
+            mrl = "rtmp://" + addr;
+            emit methodChanged("rtmp-caching");
+            break;
+
         }
     }
 
diff --git a/modules/gui/qt4/components/open_panels.hpp b/modules/gui/qt4/components/open_panels.hpp
index d79105c..e8348ca 100644
--- a/modules/gui/qt4/components/open_panels.hpp
+++ b/modules/gui/qt4/components/open_panels.hpp
@@ -57,7 +57,8 @@ enum
     FTP_PROTO,
     RTSP_PROTO,
     UDP_PROTO,
-    UDPM_PROTO
+    UDPM_PROTO,
+    RTMP_PROTO
 };
 
 




More information about the vlc-devel mailing list