Remove whitespaces

This commit is contained in:
Jonas Kvinge
2018-10-02 00:38:52 +02:00
parent 2883ef840e
commit db035351be
88 changed files with 414 additions and 411 deletions

View File

@@ -79,7 +79,7 @@ public:
virtual qint64 position_nanosec() const = 0;
virtual qint64 length_nanosec() const = 0;
virtual const Scope &scope(int chunk_length) { return scope_; }
// Sets new values for the beginning and end markers of the currently playing song.
@@ -106,7 +106,7 @@ public slots:
protected:
void EmitAboutToEnd();
public:
// Simple accessors
@@ -200,7 +200,7 @@ protected:
private:
bool about_to_end_emitted_;
Q_DISABLE_COPY(Base);
};
struct SimpleMetaBundle {

View File

@@ -37,12 +37,12 @@ class EngineDevice : public QObject {
~EngineDevice();
void Init();
QList<DeviceFinder*> device_finders_;
private:
QString output_;
};
#endif // ENGINEDEVICE_H

View File

@@ -45,7 +45,7 @@ QString EngineName(Engine::EngineType enginetype) {
default: return QString("None");
}
}
QString EngineDescription(Engine::EngineType enginetype) {
switch (enginetype) {
case Engine::Xine: return QString("Xine");
@@ -54,7 +54,7 @@ QString EngineDescription(Engine::EngineType enginetype) {
case Engine::VLC: return QString("VLC");
case Engine::None:
default: return QString("None");
}
}

View File

@@ -26,7 +26,7 @@
#include <QString>
namespace Engine {
enum EngineType {
None,
GStreamer,

View File

@@ -127,7 +127,7 @@ GstEngine::~GstEngine() {
}
bool GstEngine::Init() {
SetEnvironment();
initialising_ = QtConcurrent::run(this, &GstEngine::InitialiseGStreamer);

View File

@@ -398,7 +398,7 @@ bool GstEnginePipeline::InitFromUrl(const QByteArray &media_url, const QUrl orig
}
GstEnginePipeline::~GstEnginePipeline() {
if (pipeline_) {
gst_bus_set_sync_handler(gst_pipeline_get_bus(GST_PIPELINE(pipeline_)), nullptr, nullptr, nullptr);
g_source_remove(bus_cb_id_);
@@ -517,7 +517,7 @@ void GstEnginePipeline::StreamStartMessageReceived() {
}
void GstEnginePipeline::TaskEnterCallback(GstTask *, GThread *, gpointer) {
// Bump the priority of the thread only on OS X
#ifdef Q_OS_MACOS
@@ -527,7 +527,7 @@ void GstEnginePipeline::TaskEnterCallback(GstTask *, GThread *, gpointer) {
param.sched_priority = 99;
pthread_setschedparam(pthread_self(), SCHED_RR, &param);
#endif
}
void GstEnginePipeline::ElementMessageReceived(GstMessage *msg) {
@@ -834,7 +834,7 @@ GstPadProbeReturn GstEnginePipeline::EventHandoffCallback(GstPad*, GstPadProbeIn
void GstEnginePipeline::AboutToFinishCallback(GstPlayBin *bin, gpointer self) {
GstEnginePipeline* instance = reinterpret_cast<GstEnginePipeline*>(self);
if (instance->has_next_valid_url() && !instance->next_uri_set_) {
// Set the next uri. When the current song ends it will be played automatically and a STREAM_START message is send to the bus.
// When the next uri is not playable an error message is send when the pipeline goes to PLAY (or PAUSE) state or immediately if it is currently in PLAY state.
@@ -911,7 +911,7 @@ QFuture<GstStateChangeReturn> GstEnginePipeline::SetState(GstState state) {
}
bool GstEnginePipeline::Seek(qint64 nanosec) {
if (ignore_next_seek_) {
ignore_next_seek_ = false;
return true;
@@ -937,14 +937,14 @@ bool GstEnginePipeline::Seek(qint64 nanosec) {
}
void GstEnginePipeline::SetEqualizerEnabled(bool enabled) {
eq_enabled_ = enabled;
UpdateEqualizer();
}
void GstEnginePipeline::SetEqualizerParams(int preamp, const QList<int>& band_gains) {
eq_preamp_ = preamp;
eq_band_gains_ = band_gains;
UpdateEqualizer();
@@ -952,14 +952,14 @@ void GstEnginePipeline::SetEqualizerParams(int preamp, const QList<int>& band_ga
}
void GstEnginePipeline::SetStereoBalance(float value) {
stereo_balance_ = value;
UpdateStereoBalance();
}
void GstEnginePipeline::UpdateEqualizer() {
if (!equalizer_ || !equalizer_preamp_) return;
// Update band gains

View File

@@ -208,7 +208,7 @@ signals:
bool buffering_;
bool mono_playback_;
// These get called when there is a new audio buffer available
QList<GstBufferConsumer*> buffer_consumers_;
QMutex buffer_consumers_mutex_;

View File

@@ -43,7 +43,7 @@ class PhononEngine : public Engine::Base {
~PhononEngine();
bool Init();
OutputDetailsList GetOutputsList() const;
bool CanDecode(const QUrl &url);
@@ -62,7 +62,7 @@ class PhononEngine : public Engine::Base {
qint64 position_nanosec() const;
qint64 length_nanosec() const;
QString DefaultOutput() { return ""; }
bool ValidOutput(const QString &output);
bool CustomDeviceSupport(const QString &output);

View File

@@ -49,7 +49,7 @@ VLCEngine::VLCEngine(TaskManager *task_manager)
}
VLCEngine::~VLCEngine() {
libvlc_media_player_stop(player_);
libvlc_media_player_release(player_);
libvlc_release(instance_);
@@ -275,7 +275,7 @@ uint VLCEngine::length() const {
}
bool VLCEngine::CanDecode(const QUrl &url) {
// TODO
return true;
}
@@ -291,7 +291,7 @@ void VLCEngine::AttachCallback(libvlc_event_manager_t *em, libvlc_event_type_t t
}
void VLCEngine::StateChangedCallback(const libvlc_event_t *e, void *data) {
VLCEngine *engine = reinterpret_cast<VLCEngine*>(data);
switch (e->type) {

View File

@@ -138,10 +138,10 @@ class XineEngine : public Engine::Base {
void Cleanup();
bool EnsureStream();
void SetDevice();
uint length() const;
uint position() const;
bool MetaDataForUrl(const QUrl &url, Engine::SimpleMetaBundle &b);
bool GetAudioCDContents(const QString &device, QList<QUrl> &urls);
bool FlushBuffer();