[vlc-commits] qt: overload streamingDialog to parse through QUrl list
Fatih Uzunoglu
git at videolan.org
Tue Aug 18 17:15:08 CEST 2020
vlc | branch: master | Fatih Uzunoglu <fuzun54 at outlook.com> | Wed Jul 15 20:29:27 2020 +0300| [bdf758d99dd9cd444d732737df851957ae2bca7d] | committer: Pierre Lamot
qt: overload streamingDialog to parse through QUrl list
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=bdf758d99dd9cd444d732737df851957ae2bca7d
---
modules/gui/qt/dialogs/dialogs_provider.cpp | 14 ++++++++++++++
modules/gui/qt/dialogs/dialogs_provider.hpp | 1 +
2 files changed, 15 insertions(+)
diff --git a/modules/gui/qt/dialogs/dialogs_provider.cpp b/modules/gui/qt/dialogs/dialogs_provider.cpp
index 5b022a0944..72a96946d3 100644
--- a/modules/gui/qt/dialogs/dialogs_provider.cpp
+++ b/modules/gui/qt/dialogs/dialogs_provider.cpp
@@ -734,6 +734,20 @@ void DialogsProvider::streamingDialog( QWidget *parent,
}
}
+void DialogsProvider::streamingDialog(const QList<QUrl> &urls, bool b_stream )
+{
+ if(urls.isEmpty())
+ return;
+
+ QStringList _urls;
+ std::transform(urls.begin(),
+ urls.end(),
+ std::back_inserter(_urls),
+ [](const QUrl& url){ return url.toString(); });
+
+ streamingDialog(nullptr, _urls, b_stream);
+}
+
void DialogsProvider::openAndStreamingDialogs()
{
OpenDialog::getInstance( p_intf->p_sys->p_mi, p_intf, false, OPEN_AND_STREAM )
diff --git a/modules/gui/qt/dialogs/dialogs_provider.hpp b/modules/gui/qt/dialogs/dialogs_provider.hpp
index 4cd94cd9a0..a588fd939a 100644
--- a/modules/gui/qt/dialogs/dialogs_provider.hpp
+++ b/modules/gui/qt/dialogs/dialogs_provider.hpp
@@ -164,6 +164,7 @@ public slots:
void streamingDialog( QWidget *parent, const QStringList& mrls, bool b_stream = true,
QStringList options = QStringList("") );
+ void streamingDialog( const QList<QUrl>& urls, bool b_stream = true );
void openAndStreamingDialogs();
void openAndTranscodingDialogs();
More information about the vlc-commits
mailing list