use hardcoded namespace

The macro defined namespaces confused the hell out of lupdate and more or less broke translations permanently. Looks like the only way we can do it is to have a hardcoded namespace, which goes against my instinct, but honestly how likely is it that we'll change the namespace anyway (I guess forks might want to do it, but that's their problem ;) )
This commit is contained in:
itsmattkc
2020-11-17 20:24:42 +11:00
parent d241090a9f
commit 75d4cd899b
626 changed files with 1971 additions and 1972 deletions
+2 -2
View File
@@ -24,7 +24,7 @@
#include "config/config.h" #include "config/config.h"
OLIVE_NAMESPACE_ENTER namespace olive {
AudioManager* AudioManager::instance_ = nullptr; AudioManager* AudioManager::instance_ = nullptr;
@@ -268,4 +268,4 @@ void AudioManager::InputDevicesRefreshed()
emit InputListReady(); emit InputListReady();
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -32,7 +32,7 @@
#include "render/audioparams.h" #include "render/audioparams.h"
#include "render/audioplaybackcache.h" #include "render/audioplaybackcache.h"
OLIVE_NAMESPACE_ENTER namespace olive {
/** /**
* @brief Audio input and output management class * @brief Audio input and output management class
@@ -124,6 +124,6 @@ private slots:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // AUDIOMANAGER_H #endif // AUDIOMANAGER_H
+2 -2
View File
@@ -24,7 +24,7 @@
#include "config/config.h" #include "config/config.h"
OLIVE_NAMESPACE_ENTER namespace olive {
const int AudioVisualWaveform::kSumSampleRate = 200; const int AudioVisualWaveform::kSumSampleRate = 200;
@@ -330,4 +330,4 @@ void AudioVisualWaveform::ExpandMinMax(AudioVisualWaveform::SamplePerChannel &su
} }
} }
OLIVE_NAMESPACE_EXIT }
+3 -3
View File
@@ -27,7 +27,7 @@
#include "codec/samplebuffer.h" #include "codec/samplebuffer.h"
OLIVE_NAMESPACE_ENTER namespace olive {
/** /**
* @brief A buffer of data used to store a visual representation of audio * @brief A buffer of data used to store a visual representation of audio
@@ -108,8 +108,8 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
Q_DECLARE_METATYPE(OLIVE_NAMESPACE::AudioVisualWaveform) Q_DECLARE_METATYPE(olive::AudioVisualWaveform)
#endif // SUMSAMPLES_H #endif // SUMSAMPLES_H
+2 -2
View File
@@ -22,7 +22,7 @@
#include "audiomanager.h" #include "audiomanager.h"
OLIVE_NAMESPACE_ENTER namespace olive {
AudioOutputDeviceProxy::AudioOutputDeviceProxy(QObject *parent) : AudioOutputDeviceProxy::AudioOutputDeviceProxy(QObject *parent) :
QIODevice(parent), QIODevice(parent),
@@ -137,4 +137,4 @@ qint64 AudioOutputDeviceProxy::ReverseAwareRead(char *data, qint64 maxlen)
return read_count; return read_count;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -26,7 +26,7 @@
#include "common/define.h" #include "common/define.h"
#include "tempoprocessor.h" #include "tempoprocessor.h"
OLIVE_NAMESPACE_ENTER namespace olive {
/** /**
* @brief QIODevice wrapper that can adjust speed/reverse an audio file * @brief QIODevice wrapper that can adjust speed/reverse an audio file
@@ -61,6 +61,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // AUDIOOUTPUTDEVICEPROXY_H #endif // AUDIOOUTPUTDEVICEPROXY_H
+2 -2
View File
@@ -25,7 +25,7 @@
#include <QFile> #include <QFile>
OLIVE_NAMESPACE_ENTER namespace olive {
AudioOutputManager::AudioOutputManager(QObject *parent) : AudioOutputManager::AudioOutputManager(QObject *parent) :
QObject(parent), QObject(parent),
@@ -151,4 +151,4 @@ void AudioOutputManager::OutputStateChanged(QAudio::State state)
qDebug() << state << output_->error(); qDebug() << state << output_->error();
} }
OLIVE_NAMESPACE_EXIT }
+3 -3
View File
@@ -30,7 +30,7 @@
#include "outputdeviceproxy.h" #include "outputdeviceproxy.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class AudioOutputManager : public QObject class AudioOutputManager : public QObject
{ {
@@ -59,7 +59,7 @@ public slots:
void ResetToPushMode(); void ResetToPushMode();
// Queued // Queued
void SetParameters(OLIVE_NAMESPACE::AudioParams params); void SetParameters(olive::AudioParams params);
// Queued // Queued
void Close(); void Close();
@@ -84,6 +84,6 @@ private slots:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // AUDIOHYBRIDDEVICE_H #endif // AUDIOHYBRIDDEVICE_H
+2 -2
View File
@@ -30,7 +30,7 @@ extern "C" {
#include "common/ffmpegutils.h" #include "common/ffmpegutils.h"
OLIVE_NAMESPACE_ENTER namespace olive {
TempoProcessor::TempoProcessor() : TempoProcessor::TempoProcessor() :
filter_graph_(nullptr), filter_graph_(nullptr),
@@ -274,4 +274,4 @@ AVFilterContext *TempoProcessor::CreateTempoFilter(AVFilterGraph* graph, AVFilte
return nullptr; return nullptr;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -35,7 +35,7 @@ extern "C" {
#include "render/audioparams.h" #include "render/audioparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class TempoProcessor class TempoProcessor
{ {
@@ -78,6 +78,6 @@ private:
bool flushed_; bool flushed_;
}; };
OLIVE_NAMESPACE_EXIT }
#endif // TEMPOPROCESSOR_H #endif // TEMPOPROCESSOR_H
+2 -2
View File
@@ -20,11 +20,11 @@
#include "cliexportmanager.h" #include "cliexportmanager.h"
OLIVE_NAMESPACE_ENTER namespace olive {
CLIExportManager::CLIExportManager() CLIExportManager::CLIExportManager()
{ {
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -23,7 +23,7 @@
#include "task/export/export.h" #include "task/export/export.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class CLIExportManager : public QObject class CLIExportManager : public QObject
{ {
@@ -31,6 +31,6 @@ public:
CLIExportManager(); CLIExportManager();
}; };
OLIVE_NAMESPACE_EXIT }
#endif // CLIEXPORTMANAGER_H #endif // CLIEXPORTMANAGER_H
+2 -2
View File
@@ -22,7 +22,7 @@
#include <iostream> #include <iostream>
OLIVE_NAMESPACE_ENTER namespace olive {
CLIProgressDialog::CLIProgressDialog(const QString& title, QObject *parent) : CLIProgressDialog::CLIProgressDialog(const QString& title, QObject *parent) :
QObject(parent), QObject(parent),
@@ -103,4 +103,4 @@ void CLIProgressDialog::SetProgress(double p)
} }
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -26,7 +26,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class CLIProgressDialog : public QObject class CLIProgressDialog : public QObject
{ {
@@ -47,6 +47,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // CLIPROGRESSDIALOG_H #endif // CLIPROGRESSDIALOG_H
+2 -2
View File
@@ -20,7 +20,7 @@
#include "clitaskdialog.h" #include "clitaskdialog.h"
OLIVE_NAMESPACE_ENTER namespace olive {
CLITaskDialog::CLITaskDialog(Task *task, QObject* parent) : CLITaskDialog::CLITaskDialog(Task *task, QObject* parent) :
CLIProgressDialog(task->GetTitle(), parent), CLIProgressDialog(task->GetTitle(), parent),
@@ -34,4 +34,4 @@ bool CLITaskDialog::Run()
return task_->Start(); return task_->Start();
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -24,7 +24,7 @@
#include "cli/cliprogress/cliprogressdialog.h" #include "cli/cliprogress/cliprogressdialog.h"
#include "task/task.h" #include "task/task.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class CLITaskDialog : public CLIProgressDialog class CLITaskDialog : public CLIProgressDialog
{ {
@@ -39,6 +39,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // CLITASKDIALOG_H #endif // CLITASKDIALOG_H
+2 -2
View File
@@ -37,7 +37,7 @@
#include "task/taskmanager.h" #include "task/taskmanager.h"
#include "project/project.h" #include "project/project.h"
OLIVE_NAMESPACE_ENTER namespace olive {
QMutex Decoder::currently_conforming_mutex_; QMutex Decoder::currently_conforming_mutex_;
QWaitCondition Decoder::currently_conforming_wait_cond_; QWaitCondition Decoder::currently_conforming_wait_cond_;
@@ -377,4 +377,4 @@ SampleBufferPtr Decoder::RetrieveAudioFromConform(const QString &conform_filenam
return nullptr; return nullptr;
} }
OLIVE_NAMESPACE_EXIT }
+3 -3
View File
@@ -36,7 +36,7 @@ extern "C" {
#include "common/rational.h" #include "common/rational.h"
#include "project/item/footage/footage.h" #include "project/item/footage/footage.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class Decoder; class Decoder;
using DecoderPtr = std::shared_ptr<Decoder>; using DecoderPtr = std::shared_ptr<Decoder>;
@@ -248,8 +248,8 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
Q_DECLARE_METATYPE(OLIVE_NAMESPACE::Decoder::RetrieveState) Q_DECLARE_METATYPE(olive::Decoder::RetrieveState)
#endif // DECODER_H #endif // DECODER_H
+2 -2
View File
@@ -24,7 +24,7 @@
#include "ffmpeg/ffmpegencoder.h" #include "ffmpeg/ffmpegencoder.h"
OLIVE_NAMESPACE_ENTER namespace olive {
Encoder::Encoder(const EncodingParams &params) : Encoder::Encoder(const EncodingParams &params) :
params_(params) params_(params)
@@ -236,4 +236,4 @@ Encoder* Encoder::CreateFromID(const QString &id, const EncodingParams& params)
return new FFmpegEncoder(params); return new FFmpegEncoder(params);
} }
OLIVE_NAMESPACE_EXIT }
+5 -5
View File
@@ -32,7 +32,7 @@
#include "render/audioparams.h" #include "render/audioparams.h"
#include "render/videoparams.h" #include "render/videoparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class Encoder; class Encoder;
using EncoderPtr = std::shared_ptr<Encoder>; using EncoderPtr = std::shared_ptr<Encoder>;
@@ -114,10 +114,10 @@ public:
virtual bool Open() = 0; virtual bool Open() = 0;
virtual bool WriteFrame(OLIVE_NAMESPACE::FramePtr frame, OLIVE_NAMESPACE::rational time) = 0; virtual bool WriteFrame(olive::FramePtr frame, olive::rational time) = 0;
virtual void WriteAudio(OLIVE_NAMESPACE::AudioParams pcm_info, virtual void WriteAudio(olive::AudioParams pcm_info,
QIODevice *file) = 0; QIODevice *file) = 0;
void WriteAudio(OLIVE_NAMESPACE::AudioParams pcm_info, void WriteAudio(olive::AudioParams pcm_info,
const QString& pcm_filename); const QString& pcm_filename);
virtual void Close() = 0; virtual void Close() = 0;
@@ -132,6 +132,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // ENCODER_H #endif // ENCODER_H
+2 -2
View File
@@ -25,7 +25,7 @@ extern "C" {
#include <libavutil/pixdesc.h> #include <libavutil/pixdesc.h>
} }
OLIVE_NAMESPACE_ENTER namespace olive {
QString ExportCodec::GetCodecName(ExportCodec::Codec c) QString ExportCodec::GetCodecName(ExportCodec::Codec c)
{ {
@@ -125,4 +125,4 @@ QStringList ExportCodec::GetPixelFormatsForCodec(ExportCodec::Codec c)
return pix_fmts; return pix_fmts;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -26,7 +26,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class ExportCodec : public QObject class ExportCodec : public QObject
{ {
@@ -57,6 +57,6 @@ public:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // EXPORTCODEC_H #endif // EXPORTCODEC_H
+2 -2
View File
@@ -20,7 +20,7 @@
#include "exportformat.h" #include "exportformat.h"
OLIVE_NAMESPACE_ENTER namespace olive {
QString ExportFormat::GetName(olive::ExportFormat::Format f) QString ExportFormat::GetName(olive::ExportFormat::Format f)
{ {
@@ -135,4 +135,4 @@ QList<ExportCodec::Codec> ExportFormat::GetAudioCodecs(ExportFormat::Format f)
return {}; return {};
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -27,7 +27,7 @@
#include "common/define.h" #include "common/define.h"
#include "exportcodec.h" #include "exportcodec.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class ExportFormat : public QObject class ExportFormat : public QObject
{ {
@@ -53,6 +53,6 @@ public:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // EXPORTFORMAT_H #endif // EXPORTFORMAT_H
+2 -2
View File
@@ -30,7 +30,7 @@ extern "C" {
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class AVFrameWrapper { class AVFrameWrapper {
public: public:
@@ -55,6 +55,6 @@ private:
using AVFramePtr = std::shared_ptr<AVFrameWrapper>; using AVFramePtr = std::shared_ptr<AVFrameWrapper>;
OLIVE_NAMESPACE_EXIT }
#endif // AVFRAMEPTR_H #endif // AVFRAMEPTR_H
+2 -2
View File
@@ -45,7 +45,7 @@ extern "C" {
#include "render/framehashcache.h" #include "render/framehashcache.h"
#include "render/diskmanager.h" #include "render/diskmanager.h"
OLIVE_NAMESPACE_ENTER namespace olive {
FFmpegDecoder::FFmpegDecoder() : FFmpegDecoder::FFmpegDecoder() :
scale_ctx_(nullptr), scale_ctx_(nullptr),
@@ -1085,4 +1085,4 @@ void FFmpegDecoder::Instance::Seek(int64_t timestamp)
av_seek_frame(fmt_ctx_, avstream_->index, timestamp, AVSEEK_FLAG_BACKWARD); av_seek_frame(fmt_ctx_, avstream_->index, timestamp, AVSEEK_FLAG_BACKWARD);
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -38,7 +38,7 @@ extern "C" {
#include "ffmpegframepool.h" #include "ffmpegframepool.h"
#include "project/item/footage/videostream.h" #include "project/item/footage/videostream.h"
OLIVE_NAMESPACE_ENTER namespace olive {
/** /**
* @brief A Decoder derivative that wraps FFmpeg functions as on Olive decoder * @brief A Decoder derivative that wraps FFmpeg functions as on Olive decoder
@@ -162,6 +162,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // FFMPEGDECODER_H #endif // FFMPEGDECODER_H
+2 -2
View File
@@ -28,7 +28,7 @@ extern "C" {
#include "common/ffmpegutils.h" #include "common/ffmpegutils.h"
OLIVE_NAMESPACE_ENTER namespace olive {
FFmpegEncoder::FFmpegEncoder(const EncodingParams &params) : FFmpegEncoder::FFmpegEncoder(const EncodingParams &params) :
Encoder(params), Encoder(params),
@@ -634,4 +634,4 @@ void FFmpegEncoder::Error(const QString &s)
Close(); Close();
} }
OLIVE_NAMESPACE_EXIT }
+4 -4
View File
@@ -30,7 +30,7 @@ extern "C" {
#include "codec/encoder.h" #include "codec/encoder.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class FFmpegEncoder : public Encoder class FFmpegEncoder : public Encoder
{ {
@@ -40,9 +40,9 @@ public:
virtual bool Open() override; virtual bool Open() override;
virtual bool WriteFrame(OLIVE_NAMESPACE::FramePtr frame, OLIVE_NAMESPACE::rational time) override; virtual bool WriteFrame(olive::FramePtr frame, olive::rational time) override;
virtual void WriteAudio(OLIVE_NAMESPACE::AudioParams pcm_info, virtual void WriteAudio(olive::AudioParams pcm_info,
QIODevice *file) override; QIODevice *file) override;
virtual void Close() override; virtual void Close() override;
@@ -97,6 +97,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // FFMPEGENCODER_H #endif // FFMPEGENCODER_H
+2 -2
View File
@@ -22,7 +22,7 @@
#include "codec/frame.h" #include "codec/frame.h"
OLIVE_NAMESPACE_ENTER namespace olive {
FFmpegFramePool::FFmpegFramePool(int element_count) : FFmpegFramePool::FFmpegFramePool(int element_count) :
MemoryPool(element_count), MemoryPool(element_count),
@@ -48,4 +48,4 @@ size_t FFmpegFramePool::GetElementSize()
return Frame::generate_linesize_bytes(width_, format_, channel_count_) * height_; return Frame::generate_linesize_bytes(width_, format_, channel_count_) * height_;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -24,7 +24,7 @@
#include "common/memorypool.h" #include "common/memorypool.h"
#include "render/videoparams.h" #include "render/videoparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class FFmpegFramePool : public MemoryPool<uint8_t> class FFmpegFramePool : public MemoryPool<uint8_t>
{ {
@@ -57,6 +57,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // FFMPEGFRAMEPOOL_H #endif // FFMPEGFRAMEPOOL_H
+2 -2
View File
@@ -27,7 +27,7 @@
#include "common/oiioutils.h" #include "common/oiioutils.h"
OLIVE_NAMESPACE_ENTER namespace olive {
Frame::Frame() : Frame::Frame() :
timestamp_(0) timestamp_(0)
@@ -129,4 +129,4 @@ FramePtr Frame::convert(VideoParams::Format format) const
} }
} }
OLIVE_NAMESPACE_EXIT }
+3 -3
View File
@@ -28,7 +28,7 @@
#include "render/color.h" #include "render/color.h"
#include "render/videoparams.h" #include "render/videoparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class Frame; class Frame;
using FramePtr = std::shared_ptr<Frame>; using FramePtr = std::shared_ptr<Frame>;
@@ -163,8 +163,8 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
Q_DECLARE_METATYPE(OLIVE_NAMESPACE::FramePtr) Q_DECLARE_METATYPE(olive::FramePtr)
#endif // FRAME_H #endif // FRAME_H
+2 -2
View File
@@ -31,7 +31,7 @@
#include "config/config.h" #include "config/config.h"
#include "core.h" #include "core.h"
OLIVE_NAMESPACE_ENTER namespace olive {
QStringList OIIODecoder::supported_formats_; QStringList OIIODecoder::supported_formats_;
@@ -261,4 +261,4 @@ void OIIODecoder::CloseImageHandle()
} }
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -26,7 +26,7 @@
#include "codec/decoder.h" #include "codec/decoder.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class OIIODecoder : public Decoder class OIIODecoder : public Decoder
{ {
@@ -72,6 +72,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // OIIODECODER_H #endif // OIIODECODER_H
+2 -2
View File
@@ -20,7 +20,7 @@
#include "samplebuffer.h" #include "samplebuffer.h"
OLIVE_NAMESPACE_ENTER namespace olive {
SampleBuffer::SampleBuffer() : SampleBuffer::SampleBuffer() :
sample_count_per_channel_(0), sample_count_per_channel_(0),
@@ -310,4 +310,4 @@ void SampleBuffer::destroy_sample_buffer(float ***data, int nb_channels)
} }
} }
OLIVE_NAMESPACE_EXIT }
+3 -3
View File
@@ -25,7 +25,7 @@
#include "render/audioparams.h" #include "render/audioparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class SampleBuffer; class SampleBuffer;
using SampleBufferPtr = std::shared_ptr<SampleBuffer>; using SampleBufferPtr = std::shared_ptr<SampleBuffer>;
@@ -94,8 +94,8 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
Q_DECLARE_METATYPE(OLIVE_NAMESPACE::SampleBufferPtr) Q_DECLARE_METATYPE(olive::SampleBufferPtr)
#endif // SAMPLEBUFFER_H #endif // SAMPLEBUFFER_H
+2 -2
View File
@@ -27,7 +27,7 @@ extern "C" {
#include <QDataStream> #include <QDataStream>
#include <QtMath> #include <QtMath>
OLIVE_NAMESPACE_ENTER namespace olive {
WaveInput::WaveInput(const QString &f) : WaveInput::WaveInput(const QString &f) :
file_(f) file_(f)
@@ -239,4 +239,4 @@ qint64 WaveInput::calculate_max_read() const
return data_size_ - (file_.pos() - data_position_ ); return data_size_ - (file_.pos() - data_position_ );
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -25,7 +25,7 @@
#include "render/audioparams.h" #include "render/audioparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class WaveInput class WaveInput
{ {
@@ -70,6 +70,6 @@ private:
quint32 data_size_; quint32 data_size_;
}; };
OLIVE_NAMESPACE_EXIT }
#endif // WAVEINPUT_H #endif // WAVEINPUT_H
+2 -2
View File
@@ -22,7 +22,7 @@
#include "render/audioparams.h" #include "render/audioparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
const int16_t kWAVIntegerFormat = 1; const int16_t kWAVIntegerFormat = 1;
const int16_t kWAVFloatFormat = 3; const int16_t kWAVFloatFormat = 3;
@@ -177,4 +177,4 @@ void WaveOutput::write_int(QFile *file, T integer)
file->write(bytes); file->write(bytes);
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -26,7 +26,7 @@
#include "render/audioparams.h" #include "render/audioparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class WaveOutput class WaveOutput
{ {
@@ -63,6 +63,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // WAVEAUDIO_H #endif // WAVEAUDIO_H
+2 -2
View File
@@ -23,7 +23,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class AutoScroll { class AutoScroll {
public: public:
@@ -34,6 +34,6 @@ public:
}; };
}; };
OLIVE_NAMESPACE_EXIT }
#endif // AUTOSCROLL_H #endif // AUTOSCROLL_H
+2 -2
View File
@@ -22,7 +22,7 @@
#include <QtMath> #include <QtMath>
OLIVE_NAMESPACE_ENTER namespace olive {
double Bezier::QuadraticXtoT(double x, double a, double b, double c) double Bezier::QuadraticXtoT(double x, double a, double b, double c)
{ {
@@ -63,4 +63,4 @@ double Bezier::CubicTtoY(double a, double b, double c, double d, double t)
return qPow(1.0 - t, 3)*a + 3*qPow(1.0 - t, 2)*t*b + 3*(1.0 - t)*qPow(t, 2)*c + qPow(t, 3)*d; return qPow(1.0 - t, 3)*a + 3*qPow(1.0 - t, 2)*t*b + 3*(1.0 - t)*qPow(t, 2)*c + qPow(t, 3)*d;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -23,7 +23,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class Bezier class Bezier
{ {
@@ -37,6 +37,6 @@ public:
static double CubicTtoY(double a, double b, double c, double d, double t); static double CubicTtoY(double a, double b, double c, double d, double t);
}; };
OLIVE_NAMESPACE_EXIT }
#endif // BEZIER_H #endif // BEZIER_H
+2 -2
View File
@@ -25,7 +25,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class CancelableObject { class CancelableObject {
public: public:
@@ -53,6 +53,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // CANCELABLEOBJECT_H #endif // CANCELABLEOBJECT_H
+2 -2
View File
@@ -40,7 +40,7 @@ crashpad::CrashpadClient *client;
QString GenerateReportPath() QString GenerateReportPath()
{ {
return QDir(OLIVE_NAMESPACE::FileFunctions::GetTempFilePath()).filePath(QStringLiteral("reports")); return QDir(olive::FileFunctions::GetTempFilePath()).filePath(QStringLiteral("reports"));
} }
base::FilePath GenerateReportPathForCrashpad() base::FilePath GenerateReportPathForCrashpad()
@@ -90,7 +90,7 @@ bool InitializeCrashpad()
base::FilePath reports_dir = GenerateReportPathForCrashpad(); base::FilePath reports_dir = GenerateReportPathForCrashpad();
base::FilePath metrics_dir(QSTRING_TO_BASE_STRING(QDir(OLIVE_NAMESPACE::FileFunctions::GetTempFilePath()).filePath(QStringLiteral("metrics")))); base::FilePath metrics_dir(QSTRING_TO_BASE_STRING(QDir(olive::FileFunctions::GetTempFilePath()).filePath(QStringLiteral("metrics"))));
// Metadata that will be posted to the server with the crash report map // Metadata that will be posted to the server with the crash report map
std::map<std::string, std::string> annotations; std::map<std::string, std::string> annotations;
+2 -2
View File
@@ -20,7 +20,7 @@
#include "debug.h" #include "debug.h"
OLIVE_NAMESPACE_ENTER namespace olive {
void DebugHandler(QtMsgType type, const QMessageLogContext &context, const QString &msg) void DebugHandler(QtMsgType type, const QMessageLogContext &context, const QString &msg)
{ {
@@ -54,4 +54,4 @@ void DebugHandler(QtMsgType type, const QMessageLogContext &context, const QStri
#endif #endif
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -25,10 +25,10 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
void DebugHandler(QtMsgType type, const QMessageLogContext &context, const QString &msg); void DebugHandler(QtMsgType type, const QMessageLogContext &context, const QString &msg);
OLIVE_NAMESPACE_EXIT }
#endif // DEBUG_H #endif // DEBUG_H
+5 -11
View File
@@ -21,13 +21,7 @@
#ifndef OLIVECOMMONDEFINE_H #ifndef OLIVECOMMONDEFINE_H
#define OLIVECOMMONDEFINE_H #define OLIVECOMMONDEFINE_H
#define OLIVE_NAMESPACE olive namespace olive {
#define OLIVE_NAMESPACE_ENTER namespace OLIVE_NAMESPACE {
#define OLIVE_NAMESPACE_EXIT }
OLIVE_NAMESPACE_ENTER
/// The minimum size an icon in ProjectExplorer can be /// The minimum size an icon in ProjectExplorer can be
const int kProjectIconSizeMinimum = 16; const int kProjectIconSizeMinimum = 16;
@@ -40,14 +34,14 @@ const int kProjectIconSizeDefault = 64;
const int kBytesInGigabyte = 1073741824; const int kBytesInGigabyte = 1073741824;
OLIVE_NAMESPACE_EXIT }
#define MACRO_NAME_AS_STR(s) #s #define MACRO_NAME_AS_STR(s) #s
#define MACRO_VAL_AS_STR(s) MACRO_NAME_AS_STR(s) #define MACRO_VAL_AS_STR(s) MACRO_NAME_AS_STR(s)
#define OLIVE_NS_CONST_ARG(x, y) QArgument<const OLIVE_NAMESPACE::x>("const " MACRO_VAL_AS_STR(OLIVE_NAMESPACE) "::" #x, y) #define OLIVE_NS_CONST_ARG(x, y) QArgument<const olive::x>("const " MACRO_VAL_AS_STR(olive) "::" #x, y)
#define OLIVE_NS_ARG(x, y) QArgument<OLIVE_NAMESPACE::x>(MACRO_VAL_AS_STR(OLIVE_NAMESPACE) "::" #x, y) #define OLIVE_NS_ARG(x, y) QArgument<olive::x>(MACRO_VAL_AS_STR(olive) "::" #x, y)
#define OLIVE_NS_RETURN_ARG(x, y) QReturnArgument<OLIVE_NAMESPACE::x>(MACRO_VAL_AS_STR(OLIVE_NAMESPACE) "::" #x, y) #define OLIVE_NS_RETURN_ARG(x, y) QReturnArgument<olive::x>(MACRO_VAL_AS_STR(olive) "::" #x, y)
/** /**
* Copy/move deleters. Similar to Q_DISABLE_COPY_MOVE, et al. but those functions are not present in Qt < 5.13 so we * Copy/move deleters. Similar to Q_DISABLE_COPY_MOVE, et al. but those functions are not present in Qt < 5.13 so we
+2 -2
View File
@@ -20,7 +20,7 @@
#include "common/ffmpegutils.h" #include "common/ffmpegutils.h"
OLIVE_NAMESPACE_ENTER namespace olive {
AVPixelFormat FFmpegUtils::GetCompatiblePixelFormat(const AVPixelFormat &pix_fmt) AVPixelFormat FFmpegUtils::GetCompatiblePixelFormat(const AVPixelFormat &pix_fmt)
{ {
@@ -138,4 +138,4 @@ VideoParams::Format FFmpegUtils::GetCompatiblePixelFormat(const VideoParams::For
return VideoParams::kFormatInvalid; return VideoParams::kFormatInvalid;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -28,7 +28,7 @@ extern "C" {
#include "render/audioparams.h" #include "render/audioparams.h"
#include "render/videoparams.h" #include "render/videoparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class FFmpegUtils { class FFmpegUtils {
public: public:
@@ -58,6 +58,6 @@ public:
static AVSampleFormat GetFFmpegSampleFormat(const AudioParams::Format &smp_fmt); static AVSampleFormat GetFFmpegSampleFormat(const AudioParams::Format &smp_fmt);
}; };
OLIVE_NAMESPACE_EXIT }
#endif // FFMPEGABSTRACTION_H #endif // FFMPEGABSTRACTION_H
+2 -2
View File
@@ -29,7 +29,7 @@
#include "config/config.h" #include "config/config.h"
OLIVE_NAMESPACE_ENTER namespace olive {
QString FileFunctions::GetUniqueFileIdentifier(const QString &filename) QString FileFunctions::GetUniqueFileIdentifier(const QString &filename)
{ {
@@ -240,4 +240,4 @@ bool FileFunctions::RenameFileAllowOverwrite(const QString &from, const QString
return true; return true;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -25,7 +25,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
/** /**
* @brief A collection of static file and directory functions * @brief A collection of static file and directory functions
@@ -88,6 +88,6 @@ public:
OLIVE_NAMESPACE_EXIT }
#endif // FILEFUNCTIONS_H #endif // FILEFUNCTIONS_H
+2 -2
View File
@@ -20,7 +20,7 @@
#include "flipmodifiers.h" #include "flipmodifiers.h"
OLIVE_NAMESPACE_ENTER namespace olive {
Qt::KeyboardModifiers FlipControlAndShiftModifiers(Qt::KeyboardModifiers e) { Qt::KeyboardModifiers FlipControlAndShiftModifiers(Qt::KeyboardModifiers e) {
if (e & Qt::ControlModifier & Qt::ShiftModifier) { if (e & Qt::ControlModifier & Qt::ShiftModifier) {
@@ -38,4 +38,4 @@ Qt::KeyboardModifiers FlipControlAndShiftModifiers(Qt::KeyboardModifiers e) {
return e; return e;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -25,10 +25,10 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
Qt::KeyboardModifiers FlipControlAndShiftModifiers(Qt::KeyboardModifiers e); Qt::KeyboardModifiers FlipControlAndShiftModifiers(Qt::KeyboardModifiers e);
OLIVE_NAMESPACE_EXIT }
#endif // FLIPMODIFIERS_H #endif // FLIPMODIFIERS_H
+2 -2
View File
@@ -1,6 +1,6 @@
#include "memorypool.h" #include "memorypool.h"
OLIVE_NAMESPACE_ENTER namespace olive {
size_t memory_pool_consumption = 0; size_t memory_pool_consumption = 0;
QMutex memory_pool_consumption_lock; QMutex memory_pool_consumption_lock;
@@ -11,4 +11,4 @@ bool MemoryPoolLimitReached()
return (memory_pool_consumption >= 2147483648); return (memory_pool_consumption >= 2147483648);
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -30,7 +30,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
extern size_t memory_pool_consumption; extern size_t memory_pool_consumption;
extern QMutex memory_pool_consumption_lock; extern QMutex memory_pool_consumption_lock;
@@ -397,6 +397,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // MEMORYPOOL_H #endif // MEMORYPOOL_H
+2 -2
View File
@@ -20,7 +20,7 @@
#include "ocioutils.h" #include "ocioutils.h"
OLIVE_NAMESPACE_ENTER namespace olive {
OCIO::BitDepth OCIOUtils::GetOCIOBitDepthFromPixelFormat(VideoParams::Format format) OCIO::BitDepth OCIOUtils::GetOCIOBitDepthFromPixelFormat(VideoParams::Format format)
{ {
@@ -44,4 +44,4 @@ OCIO::BitDepth OCIOUtils::GetOCIOBitDepthFromPixelFormat(VideoParams::Format for
return OCIO::BIT_DEPTH_UNKNOWN; return OCIO::BIT_DEPTH_UNKNOWN;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -26,7 +26,7 @@ namespace OCIO = OpenColorIO_v2_0dev;
#include "render/videoparams.h" #include "render/videoparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class OCIOUtils class OCIOUtils
{ {
@@ -34,6 +34,6 @@ public:
static OCIO::BitDepth GetOCIOBitDepthFromPixelFormat(VideoParams::Format format); static OCIO::BitDepth GetOCIOBitDepthFromPixelFormat(VideoParams::Format format);
}; };
OLIVE_NAMESPACE_EXIT }
#endif // OCIOUTILS_H #endif // OCIOUTILS_H
+2 -2
View File
@@ -20,7 +20,7 @@
#include "oiioutils.h" #include "oiioutils.h"
OLIVE_NAMESPACE_ENTER namespace olive {
void OIIOUtils::FrameToBuffer(const Frame* frame, OIIO::ImageBuf *buf) void OIIOUtils::FrameToBuffer(const Frame* frame, OIIO::ImageBuf *buf)
{ {
@@ -117,4 +117,4 @@ VideoParams::Format OIIOUtils::GetFormatFromOIIOBasetype(OIIO::TypeDesc::BASETYP
return VideoParams::kFormatInvalid; return VideoParams::kFormatInvalid;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -27,7 +27,7 @@
#include "codec/frame.h" #include "codec/frame.h"
#include "render/videoparams.h" #include "render/videoparams.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class OIIOUtils { class OIIOUtils {
public: public:
@@ -60,6 +60,6 @@ public:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // OIIOUTILS_H #endif // OIIOUTILS_H
+2 -2
View File
@@ -25,7 +25,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
uint32_t ceil_to_power_of_2(uint32_t v) uint32_t ceil_to_power_of_2(uint32_t v)
{ {
@@ -51,6 +51,6 @@ uint32_t floor_to_power_of_2(uint32_t x)
return x - (x >> 1); return x - (x >> 1);
} }
OLIVE_NAMESPACE_EXIT }
#endif // POWER_H #endif // POWER_H
+2 -2
View File
@@ -20,7 +20,7 @@
#include "qtutils.h" #include "qtutils.h"
OLIVE_NAMESPACE_ENTER namespace olive {
int QtUtils::QFontMetricsWidth(QFontMetrics fm, const QString& s) { int QtUtils::QFontMetricsWidth(QFontMetrics fm, const QString& s) {
#if QT_VERSION < QT_VERSION_CHECK(5, 11, 0) #if QT_VERSION < QT_VERSION_CHECK(5, 11, 0)
@@ -38,4 +38,4 @@ QFrame *QtUtils::CreateHorizontalLine()
return horizontal_line; return horizontal_line;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -32,7 +32,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class QtUtils { class QtUtils {
public: public:
@@ -49,6 +49,6 @@ public:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // QTVERSIONABSTRACTION_H #endif // QTVERSIONABSTRACTION_H
+2 -2
View File
@@ -23,7 +23,7 @@
#include <QCoreApplication> #include <QCoreApplication>
#include <QMessageBox> #include <QMessageBox>
OLIVE_NAMESPACE_ENTER namespace olive {
double GetFloatRatioFromUser(QWidget* parent, double GetFloatRatioFromUser(QWidget* parent,
const QString& title, const QString& title,
@@ -88,4 +88,4 @@ double GetFloatRatioFromUser(QWidget* parent,
} }
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -25,12 +25,12 @@
#include "common/rational.h" #include "common/rational.h"
OLIVE_NAMESPACE_ENTER namespace olive {
double GetFloatRatioFromUser(QWidget* parent, double GetFloatRatioFromUser(QWidget* parent,
const QString& title, const QString& title,
bool* ok_in); bool* ok_in);
OLIVE_NAMESPACE_EXIT }
#endif // RATIODIALOG_H #endif // RATIODIALOG_H
+3 -3
View File
@@ -3,7 +3,7 @@
#include "rational.h" #include "rational.h"
OLIVE_NAMESPACE_ENTER namespace olive {
rational rational::fromDouble(const double &flt) rational rational::fromDouble(const double &flt)
{ {
@@ -391,9 +391,9 @@ uint qHash(const rational &r, uint seed)
return ::qHash(r.toDouble(), seed); return ::qHash(r.toDouble(), seed);
} }
OLIVE_NAMESPACE_EXIT }
QDebug operator<<(QDebug debug, const OLIVE_NAMESPACE::rational &r) QDebug operator<<(QDebug debug, const olive::rational &r)
{ {
return debug.space() << r.toDouble(); return debug.space() << r.toDouble();
/* /*
+4 -4
View File
@@ -20,7 +20,7 @@ extern "C" {
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
typedef int64_t intType; typedef int64_t intType;
/* /*
@@ -140,10 +140,10 @@ private:
uint qHash(const rational& r, uint seed); uint qHash(const rational& r, uint seed);
OLIVE_NAMESPACE_EXIT }
QDebug operator<<(QDebug debug, const OLIVE_NAMESPACE::rational& r); QDebug operator<<(QDebug debug, const olive::rational& r);
Q_DECLARE_METATYPE(OLIVE_NAMESPACE::rational) Q_DECLARE_METATYPE(olive::rational)
#endif // RATIONAL_H #endif // RATIONAL_H
+2 -2
View File
@@ -20,7 +20,7 @@
#include "threadedobject.h" #include "threadedobject.h"
OLIVE_NAMESPACE_ENTER namespace olive {
void ThreadedObject::LockDeletes() void ThreadedObject::LockDeletes()
{ {
@@ -54,4 +54,4 @@ bool ThreadedObject::TryLockMutex(int timeout)
return threadobj_main_lock_.tryLock(timeout); return threadobj_main_lock_.tryLock(timeout);
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -25,7 +25,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class ThreadedObject class ThreadedObject
{ {
@@ -45,6 +45,6 @@ private:
QAtomicInt threadobj_delete_lock_; QAtomicInt threadobj_delete_lock_;
}; };
OLIVE_NAMESPACE_EXIT }
#endif // THREADEDOBJECT_H #endif // THREADEDOBJECT_H
+2 -2
View File
@@ -24,7 +24,7 @@
#include "config/config.h" #include "config/config.h"
OLIVE_NAMESPACE_ENTER namespace olive {
QString padded(int64_t arg, int padding) { QString padded(int64_t arg, int padding) {
return QStringLiteral("%1").arg(arg, padding, 10, QChar('0')); return QStringLiteral("%1").arg(arg, padding, 10, QChar('0'));
@@ -289,4 +289,4 @@ int64_t Timecode::rescale_timestamp_ceil(const int64_t &ts, const rational &sour
return qCeil(static_cast<double>(ts) * source.toDouble() / dest.toDouble()); return qCeil(static_cast<double>(ts) * source.toDouble() / dest.toDouble());
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -25,7 +25,7 @@
#include "common/rational.h" #include "common/rational.h"
OLIVE_NAMESPACE_ENTER namespace olive {
/** /**
* @brief Functions for converting times/timecodes/timestamps * @brief Functions for converting times/timecodes/timestamps
@@ -72,6 +72,6 @@ public:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // TIMECODEFUNCTIONS_H #endif // TIMECODEFUNCTIONS_H
+3 -3
View File
@@ -23,7 +23,7 @@
#include <QtMath> #include <QtMath>
#include <utility> #include <utility>
OLIVE_NAMESPACE_ENTER namespace olive {
TimeRange::TimeRange(const rational &in, const rational &out) : TimeRange::TimeRange(const rational &in, const rational &out) :
in_(in), in_(in),
@@ -296,9 +296,9 @@ uint qHash(const TimeRange &r, uint seed)
return qHash(r.in(), seed) ^ qHash(r.out(), seed); return qHash(r.in(), seed) ^ qHash(r.out(), seed);
} }
OLIVE_NAMESPACE_EXIT }
QDebug operator<<(QDebug debug, const OLIVE_NAMESPACE::TimeRange &r) QDebug operator<<(QDebug debug, const olive::TimeRange &r)
{ {
debug.nospace() << r.in().toDouble() << " - " << r.out().toDouble(); debug.nospace() << r.in().toDouble() << " - " << r.out().toDouble();
return debug.space(); return debug.space();
+5 -5
View File
@@ -23,7 +23,7 @@
#include "rational.h" #include "rational.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class TimeRange { class TimeRange {
public: public:
@@ -139,11 +139,11 @@ private:
uint qHash(const TimeRange& r, uint seed); uint qHash(const TimeRange& r, uint seed);
OLIVE_NAMESPACE_EXIT }
QDebug operator<<(QDebug debug, const OLIVE_NAMESPACE::TimeRange& r); QDebug operator<<(QDebug debug, const olive::TimeRange& r);
QDebug operator<<(QDebug debug, const OLIVE_NAMESPACE::TimeRangeList& r); QDebug operator<<(QDebug debug, const olive::TimeRangeList& r);
Q_DECLARE_METATYPE(OLIVE_NAMESPACE::TimeRange) Q_DECLARE_METATYPE(olive::TimeRange)
#endif // TIMERANGE_H #endif // TIMERANGE_H
+2 -2
View File
@@ -5,12 +5,12 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
inline QString ToHex(quint64 t) { inline QString ToHex(quint64 t) {
return QStringLiteral("%1").arg(t, 0, 16); return QStringLiteral("%1").arg(t, 0, 16);
} }
OLIVE_NAMESPACE_EXIT }
#endif // TOHEX_H #endif // TOHEX_H
+2 -2
View File
@@ -24,7 +24,7 @@
#include "node/factory.h" #include "node/factory.h"
#include "widget/nodeview/nodeviewundo.h" #include "widget/nodeview/nodeviewundo.h"
OLIVE_NAMESPACE_ENTER namespace olive {
void XMLConnectNodes(const XMLNodeData &xml_node_data, QUndoCommand *command) void XMLConnectNodes(const XMLNodeData &xml_node_data, QUndoCommand *command)
{ {
@@ -64,4 +64,4 @@ void XMLLinkBlocks(const XMLNodeData &xml_node_data)
} }
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -26,7 +26,7 @@
#include "project/item/footage/stream.h" #include "project/item/footage/stream.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class Block; class Block;
class Node; class Node;
@@ -71,6 +71,6 @@ bool XMLReadNextStartElement(QXmlStreamReader* reader);
void XMLLinkBlocks(const XMLNodeData& xml_node_data); void XMLLinkBlocks(const XMLNodeData& xml_node_data);
OLIVE_NAMESPACE_EXIT }
#endif // XMLREADLOOP_H #endif // XMLREADLOOP_H
+2 -2
View File
@@ -34,7 +34,7 @@
#include "ui/style/style.h" #include "ui/style/style.h"
#include "window/mainwindow/mainwindow.h" #include "window/mainwindow/mainwindow.h"
OLIVE_NAMESPACE_ENTER namespace olive {
Config Config::current_config_; Config Config::current_config_;
@@ -268,4 +268,4 @@ NodeParam::DataType Config::GetConfigEntryType(const QString &key) const
return config_map_[key].type; return config_map_[key].type;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -28,7 +28,7 @@
#include "common/timecodefunctions.h" #include "common/timecodefunctions.h"
#include "node/param.h" #include "node/param.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class Config { class Config {
public: public:
@@ -63,6 +63,6 @@ private:
static QString GetConfigFilePath(); static QString GetConfigFilePath();
}; };
OLIVE_NAMESPACE_EXIT }
#endif // CONFIG_H #endif // CONFIG_H
+12 -12
View File
@@ -68,7 +68,7 @@
#include "widget/viewer/viewer.h" #include "widget/viewer/viewer.h"
#include "window/mainwindow/mainwindow.h" #include "window/mainwindow/mainwindow.h"
OLIVE_NAMESPACE_ENTER namespace olive {
Core* Core::instance_ = nullptr; Core* Core::instance_ = nullptr;
const uint Core::kProjectVersion = 201003; const uint Core::kProjectVersion = 201003;
@@ -103,17 +103,17 @@ void Core::DeclareTypesForQt()
qRegisterMetaType<AudioParams>(); qRegisterMetaType<AudioParams>();
qRegisterMetaType<NodeKeyframe::Type>(); qRegisterMetaType<NodeKeyframe::Type>();
qRegisterMetaType<Decoder::RetrieveState>(); qRegisterMetaType<Decoder::RetrieveState>();
qRegisterMetaType<OLIVE_NAMESPACE::TimeRange>(); qRegisterMetaType<olive::TimeRange>();
qRegisterMetaType<Color>(); qRegisterMetaType<Color>();
qRegisterMetaType<OLIVE_NAMESPACE::ProjectPtr>(); qRegisterMetaType<olive::ProjectPtr>();
qRegisterMetaType<OLIVE_NAMESPACE::AudioVisualWaveform>(); qRegisterMetaType<olive::AudioVisualWaveform>();
qRegisterMetaType<OLIVE_NAMESPACE::SampleJob>(); qRegisterMetaType<olive::SampleJob>();
qRegisterMetaType<OLIVE_NAMESPACE::ShaderJob>(); qRegisterMetaType<olive::ShaderJob>();
qRegisterMetaType<OLIVE_NAMESPACE::GenerateJob>(); qRegisterMetaType<olive::GenerateJob>();
qRegisterMetaType<OLIVE_NAMESPACE::VideoParams>(); qRegisterMetaType<olive::VideoParams>();
qRegisterMetaType<OLIVE_NAMESPACE::VideoParams::Interlacing>(); qRegisterMetaType<olive::VideoParams::Interlacing>();
qRegisterMetaType<OLIVE_NAMESPACE::MainWindowLayoutInfo>(); qRegisterMetaType<olive::MainWindowLayoutInfo>();
qRegisterMetaType<OLIVE_NAMESPACE::RenderTicketPtr>(); qRegisterMetaType<olive::RenderTicketPtr>();
} }
void Core::Start() void Core::Start()
@@ -1375,4 +1375,4 @@ Core::CoreParams::CoreParams() :
{ {
} }
OLIVE_NAMESPACE_EXIT }
+3 -3
View File
@@ -36,7 +36,7 @@
#include "tool/tool.h" #include "tool/tool.h"
#include "undo/undostack.h" #include "undo/undostack.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class MainWindow; class MainWindow;
@@ -563,7 +563,7 @@ private slots:
/** /**
* @brief Adds a project to the "open projects" list * @brief Adds a project to the "open projects" list
*/ */
void AddOpenProject(OLIVE_NAMESPACE::ProjectPtr p); void AddOpenProject(olive::ProjectPtr p);
void AddOpenProjectFromTask(Task* task); void AddOpenProjectFromTask(Task* task);
@@ -584,6 +584,6 @@ private slots:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // CORE_H #endif // CORE_H
+2 -2
View File
@@ -25,7 +25,7 @@
#include <QLabel> #include <QLabel>
#include <QVBoxLayout> #include <QVBoxLayout>
OLIVE_NAMESPACE_ENTER namespace olive {
AboutDialog::AboutDialog(QWidget *parent) : AboutDialog::AboutDialog(QWidget *parent) :
QDialog(parent) QDialog(parent)
@@ -67,4 +67,4 @@ AboutDialog::AboutDialog(QWidget *parent) :
connect(buttons, &QDialogButtonBox::accepted, this, &QDialog::accept); connect(buttons, &QDialogButtonBox::accepted, this, &QDialog::accept);
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -25,7 +25,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
/** /**
* @brief The AboutDialog class * @brief The AboutDialog class
@@ -49,6 +49,6 @@ public:
explicit AboutDialog(QWidget *parent = nullptr); explicit AboutDialog(QWidget *parent = nullptr);
}; };
OLIVE_NAMESPACE_EXIT }
#endif // ABOUTDIALOG_H #endif // ABOUTDIALOG_H
+2 -2
View File
@@ -25,7 +25,7 @@
#include <QMenuBar> #include <QMenuBar>
#include <QLabel> #include <QLabel>
OLIVE_NAMESPACE_ENTER namespace olive {
ActionSearch::ActionSearch(QWidget *parent) : ActionSearch::ActionSearch(QWidget *parent) :
QDialog(parent), QDialog(parent),
@@ -254,4 +254,4 @@ void ActionSearchList::mouseDoubleClickEvent(QMouseEvent *) {
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -29,7 +29,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class ActionSearchList; class ActionSearchList;
@@ -182,6 +182,6 @@ signals:
void moveSelectionDown(); void moveSelectionDown();
}; };
OLIVE_NAMESPACE_EXIT }
#endif // ACTIONSEARCH_H #endif // ACTIONSEARCH_H
+2 -2
View File
@@ -26,7 +26,7 @@
#include "common/qtutils.h" #include "common/qtutils.h"
OLIVE_NAMESPACE_ENTER namespace olive {
ColorDialog::ColorDialog(ColorManager* color_manager, const ManagedColor& start, QWidget *parent) : ColorDialog::ColorDialog(ColorManager* color_manager, const ManagedColor& start, QWidget *parent) :
QDialog(parent), QDialog(parent),
@@ -160,4 +160,4 @@ void ColorDialog::ColorSpaceChanged(const QString &input, const ColorTransform &
color_values_widget_->SetColorProcessor(input_to_ref_processor_, ref_to_display, nullptr, ref_to_input); color_values_widget_->SetColorProcessor(input_to_ref_processor_, ref_to_display, nullptr, ref_to_input);
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -31,7 +31,7 @@
#include "widget/colorwheel/colorvalueswidget.h" #include "widget/colorwheel/colorvalueswidget.h"
#include "widget/colorwheel/colorwheelwidget.h" #include "widget/colorwheel/colorwheelwidget.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class ColorDialog : public QDialog class ColorDialog : public QDialog
{ {
@@ -87,6 +87,6 @@ private slots:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // COLORDIALOG_H #endif // COLORDIALOG_H
+2 -2
View File
@@ -36,7 +36,7 @@
#include "common/crashpadutils.h" #include "common/crashpadutils.h"
OLIVE_NAMESPACE_ENTER namespace olive {
CrashHandlerDialog::CrashHandlerDialog(const char *report_dir, const char* crash_time) CrashHandlerDialog::CrashHandlerDialog(const char *report_dir, const char* crash_time)
{ {
@@ -208,4 +208,4 @@ void CrashHandlerDialog::SendErrorReport()
manager->post(request, multipart); manager->post(request, multipart);
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -30,7 +30,7 @@
#include "common/define.h" #include "common/define.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class CrashHandlerDialog : public QDialog class CrashHandlerDialog : public QDialog
{ {
@@ -72,6 +72,6 @@ private slots:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // CRASHHANDLERDIALOG_H #endif // CRASHHANDLERDIALOG_H
+1 -1
View File
@@ -30,7 +30,7 @@ int main(int argc, char *argv[])
QApplication a(argc, argv); QApplication a(argc, argv);
OLIVE_NAMESPACE::CrashHandlerDialog chd(argv[1], argv[2]); olive::CrashHandlerDialog chd(argv[1], argv[2]);
chd.open(); chd.open();
return a.exec(); return a.exec();
+2 -2
View File
@@ -27,7 +27,7 @@
#include "config/config.h" #include "config/config.h"
OLIVE_NAMESPACE_ENTER namespace olive {
DiskCacheDialog::DiskCacheDialog(DiskCacheFolder *folder, QWidget* parent) : DiskCacheDialog::DiskCacheDialog(DiskCacheFolder *folder, QWidget* parent) :
QDialog(parent), QDialog(parent),
@@ -104,4 +104,4 @@ void DiskCacheDialog::ClearDiskCache()
} }
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -28,7 +28,7 @@
#include "render/diskmanager.h" #include "render/diskmanager.h"
#include "widget/slider/floatslider.h" #include "widget/slider/floatslider.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class DiskCacheDialog : public QDialog class DiskCacheDialog : public QDialog
{ {
@@ -53,6 +53,6 @@ private slots:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // DISKCACHEDIALOG_H #endif // DISKCACHEDIALOG_H
+2 -2
View File
@@ -20,11 +20,11 @@
#include "codecsection.h" #include "codecsection.h"
OLIVE_NAMESPACE_ENTER namespace olive {
CodecSection::CodecSection(QWidget *parent) : CodecSection::CodecSection(QWidget *parent) :
QWidget(parent) QWidget(parent)
{ {
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -25,7 +25,7 @@
#include "codec/encoder.h" #include "codec/encoder.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class CodecSection : public QWidget class CodecSection : public QWidget
{ {
@@ -37,6 +37,6 @@ public:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // CODECSECTION_H #endif // CODECSECTION_H
+2 -2
View File
@@ -28,7 +28,7 @@
#include "common/qtutils.h" #include "common/qtutils.h"
#include "widget/slider/integerslider.h" #include "widget/slider/integerslider.h"
OLIVE_NAMESPACE_ENTER namespace olive {
H264Section::H264Section(QWidget *parent) : H264Section::H264Section(QWidget *parent) :
CodecSection(parent) CodecSection(parent)
@@ -208,4 +208,4 @@ int64_t H264FileSizeSection::GetFileSize() const
return qRound64(file_size_->GetValue() * 1024.0 * 1024.0 * 8.0); return qRound64(file_size_->GetValue() * 1024.0 * 1024.0 * 8.0);
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -27,7 +27,7 @@
#include "codecsection.h" #include "codecsection.h"
#include "widget/slider/floatslider.h" #include "widget/slider/floatslider.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class H264CRFSection : public QWidget class H264CRFSection : public QWidget
{ {
@@ -112,6 +112,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // H264SECTION_H #endif // H264SECTION_H
+2 -2
View File
@@ -23,7 +23,7 @@
#include <QGridLayout> #include <QGridLayout>
#include <QLabel> #include <QLabel>
OLIVE_NAMESPACE_ENTER namespace olive {
ImageSection::ImageSection(QWidget* parent) : ImageSection::ImageSection(QWidget* parent) :
CodecSection(parent) CodecSection(parent)
@@ -44,4 +44,4 @@ QCheckBox *ImageSection::image_sequence_checkbox() const
return image_sequence_checkbox_; return image_sequence_checkbox_;
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -25,7 +25,7 @@
#include "codecsection.h" #include "codecsection.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class ImageSection : public CodecSection class ImageSection : public CodecSection
{ {
@@ -40,6 +40,6 @@ private:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // IMAGESECTION_H #endif // IMAGESECTION_H
+2 -2
View File
@@ -37,7 +37,7 @@
#include "project/project.h" #include "project/project.h"
#include "ui/icons/icons.h" #include "ui/icons/icons.h"
OLIVE_NAMESPACE_ENTER namespace olive {
ExportDialog::ExportDialog(ViewerOutput *viewer_node, TimelinePoints *points, QWidget *parent) : ExportDialog::ExportDialog(ViewerOutput *viewer_node, TimelinePoints *points, QWidget *parent) :
QDialog(parent), QDialog(parent),
@@ -507,4 +507,4 @@ void ExportDialog::UpdateViewerDimensions()
preview_viewer_->SetMatrix(transform); preview_viewer_->SetMatrix(transform);
} }
OLIVE_NAMESPACE_EXIT }
+2 -2
View File
@@ -34,7 +34,7 @@
#include "task/export/export.h" #include "task/export/export.h"
#include "widget/viewer/viewer.h" #include "widget/viewer/viewer.h"
OLIVE_NAMESPACE_ENTER namespace olive {
class ExportDialog : public QDialog class ExportDialog : public QDialog
{ {
@@ -95,6 +95,6 @@ private slots:
}; };
OLIVE_NAMESPACE_EXIT }
#endif // EXPORTDIALOG_H #endif // EXPORTDIALOG_H

Some files were not shown because too many files have changed in this diff Show More