[vlc-devel] commit: Revert "Fixed open network panel." (Jean-Baptiste Kempf )
Laurent Aimar
fenrir at via.ecp.fr
Mon Jul 7 19:02:11 CEST 2008
On Mon, Jul 07, 2008, git version control wrote:
> - typedef QPair<QString,QString> QPairString;
> - QMap<int, QPairString> protocols;
> -#define P(value,name,dsc) do { protocols[value] = QPairString( QString(dsc), QString(name) );} while(0)
> - P( NO_PROTO, "", "" );
> - P( UDPM_PROTO, "udp", "UDP/RTP (multicast)" );
> - P( HTTP_PROTO, "http", "HTTP" );
> - P( HTTPS_PROTO, "https", "HTTPS" );
> - P( MMS_PROTO, "mms", "MMS" );
> - P( FTP_PROTO, "ftp", "FTP" );
> - P( RTSP_PROTO, "rtsp", "RTSP" );
> - P( UDP_PROTO, "udp", "UDP/RTP (unicast)" );
> - P( RTMP_PROTO, "rtmp", "RTMP" );
> -#undef P
> - foreach( QPairString e, protocols ) /* Sorted by key, exactly what we need */
> - ui.protocolCombo->addItem( e.first, QVariant(e.second.isEmpty() ) );
> + ui.protocolCombo->addItem( "" );
> + ui.protocolCombo->addItem("HTTP", QVariant("http"));
> + ui.protocolCombo->addItem("HTTPS", QVariant("https"));
> + ui.protocolCombo->addItem("FTP", QVariant("ftp"));
> + ui.protocolCombo->addItem("MMS", QVariant("mms"));
> + 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"));
> }
There was a reason behing it, it allows to change the order in *_PROTO without
having to change this function and thus to prevent future errors.
At least could you reorder it to match *_PROTO order ? (mms and ftp are to be
swapped).
--
fenrir
More information about the vlc-devel
mailing list