Switched default encoding to MP3, seems to be better supported
This commit is contained in:
@@ -23,8 +23,6 @@
|
|||||||
#include <Wt/WTemplate>
|
#include <Wt/WTemplate>
|
||||||
#include <Wt/WHBoxLayout>
|
#include <Wt/WHBoxLayout>
|
||||||
#include <Wt/WVBoxLayout>
|
#include <Wt/WVBoxLayout>
|
||||||
#include <Wt/WApplication>
|
|
||||||
#include <Wt/WEnvironment>
|
|
||||||
|
|
||||||
#include "AudioMediaPlayer.hpp"
|
#include "AudioMediaPlayer.hpp"
|
||||||
|
|
||||||
@@ -34,12 +32,8 @@ namespace Desktop {
|
|||||||
Wt::WMediaPlayer::Encoding
|
Wt::WMediaPlayer::Encoding
|
||||||
AudioMediaPlayer::getBestEncoding()
|
AudioMediaPlayer::getBestEncoding()
|
||||||
{
|
{
|
||||||
const Wt::WEnvironment& env = Wt::WApplication::instance()->environment();
|
// MP3 seems to be better supported everywhere
|
||||||
|
return Wt::WMediaPlayer::MP3;
|
||||||
if (env.agentIsIE())
|
|
||||||
return Wt::WMediaPlayer::MP3;
|
|
||||||
else
|
|
||||||
return Wt::WMediaPlayer::OGA;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
AudioMediaPlayer::AudioMediaPlayer( Wt::WMediaPlayer::Encoding encoding, Wt::WContainerWidget *parent)
|
AudioMediaPlayer::AudioMediaPlayer( Wt::WMediaPlayer::Encoding encoding, Wt::WContainerWidget *parent)
|
||||||
|
|||||||
@@ -17,8 +17,6 @@
|
|||||||
* along with LMS. If not, see <http://www.gnu.org/licenses/>.
|
* along with LMS. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <Wt/WApplication>
|
|
||||||
#include <Wt/WEnvironment>
|
|
||||||
|
|
||||||
#include "MobileAudioMediaPlayer.hpp"
|
#include "MobileAudioMediaPlayer.hpp"
|
||||||
|
|
||||||
@@ -30,12 +28,8 @@ namespace Mobile {
|
|||||||
Wt::WMediaPlayer::Encoding
|
Wt::WMediaPlayer::Encoding
|
||||||
AudioMediaPlayer::getBestEncoding()
|
AudioMediaPlayer::getBestEncoding()
|
||||||
{
|
{
|
||||||
const Wt::WEnvironment& env = Wt::WApplication::instance()->environment();
|
// MP3 seems to be better supported everywhere
|
||||||
|
return Wt::WMediaPlayer::MP3;
|
||||||
if (env.agentIsIE())
|
|
||||||
return Wt::WMediaPlayer::MP3;
|
|
||||||
else
|
|
||||||
return Wt::WMediaPlayer::OGA;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
AudioMediaPlayer::AudioMediaPlayer(Wt::WMediaPlayer::Encoding encoding, Wt::WContainerWidget *parent)
|
AudioMediaPlayer::AudioMediaPlayer(Wt::WMediaPlayer::Encoding encoding, Wt::WContainerWidget *parent)
|
||||||
|
|||||||
Reference in New Issue
Block a user