various: encapsulate all code in the olive namespace to avoid name collisions

Large-scale code cleanup. Also adds a license to the top of all files that were
missing it.
This commit is contained in:
itsmattkc
2020-04-06 15:29:53 +10:00
parent 82b6ddccc8
commit 1aa87cbda6
519 changed files with 7939 additions and 158 deletions
+24
View File
@@ -1,5 +1,27 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#include "audiomonitor.h"
OLIVE_NAMESPACE_ENTER
AudioMonitorPanel::AudioMonitorPanel(QWidget *parent) :
PanelWidget(parent)
{
@@ -17,3 +39,5 @@ void AudioMonitorPanel::Retranslate()
{
SetTitle(tr("Audio Monitor"));
}
OLIVE_NAMESPACE_EXIT
+24
View File
@@ -1,9 +1,31 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#ifndef AUDIOMONITORPANEL_H
#define AUDIOMONITORPANEL_H
#include "widget/audiomonitor/audiomonitor.h"
#include "widget/panel/panel.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief PanelWidget wrapper around an AudioMonitor
*/
@@ -19,4 +41,6 @@ private:
};
OLIVE_NAMESPACE_EXIT
#endif // AUDIOMONITORPANEL_H
+24
View File
@@ -1,5 +1,27 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#include "curve.h"
OLIVE_NAMESPACE_ENTER
CurvePanel::CurvePanel(QWidget *parent) :
TimeBasedPanel(parent)
{
@@ -41,3 +63,5 @@ void CurvePanel::Retranslate()
SetTitle(tr("Curve Editor"));
}
OLIVE_NAMESPACE_EXIT
+24
View File
@@ -1,9 +1,31 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#ifndef CURVEPANEL_H
#define CURVEPANEL_H
#include "panel/timebased/timebased.h"
#include "widget/curvewidget/curvewidget.h"
OLIVE_NAMESPACE_ENTER
class CurvePanel : public TimeBasedPanel
{
Q_OBJECT
@@ -24,4 +46,6 @@ protected:
};
OLIVE_NAMESPACE_EXIT
#endif // CURVEPANEL_H
@@ -22,6 +22,8 @@
#include "widget/viewer/footageviewer.h"
OLIVE_NAMESPACE_ENTER
FootageViewerPanel::FootageViewerPanel(QWidget *parent) :
ViewerPanelBase(parent)
{
@@ -57,3 +59,5 @@ void FootageViewerPanel::Retranslate()
SetTitle(tr("Footage Viewer"));
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -26,6 +26,8 @@
#include "panel/viewer/viewerbase.h"
#include "panel/project/footagemanagementpanel.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief Dockable wrapper around a ViewerWidget
*/
@@ -43,4 +45,6 @@ protected:
};
OLIVE_NAMESPACE_EXIT
#endif // FOOTAGE_VIEWER_PANEL_H
+4
View File
@@ -20,6 +20,8 @@
#include "node.h"
OLIVE_NAMESPACE_ENTER
NodePanel::NodePanel(QWidget *parent) :
PanelWidget(parent)
{
@@ -88,3 +90,5 @@ void NodePanel::Retranslate()
{
SetTitle(tr("Node Editor"));
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -24,6 +24,8 @@
#include "widget/nodeview/nodeview.h"
#include "widget/panel/panel.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief A PanelWidget wrapper around a NodeView
*/
@@ -62,4 +64,6 @@ private:
};
OLIVE_NAMESPACE_EXIT
#endif // NODEPANEL_H
+4
View File
@@ -22,6 +22,8 @@
#include "config/config.h"
OLIVE_NAMESPACE_ENTER
PanelManager* PanelManager::instance_ = nullptr;
PanelManager::PanelManager(QObject *parent) :
@@ -147,3 +149,5 @@ void PanelManager::SetPanelsLocked(bool locked)
locked_ = locked;
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -26,6 +26,8 @@
#include "widget/panel/panel.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief The PanelFocusManager class
*
@@ -209,4 +211,6 @@ QList<T*> PanelManager::GetPanelsOfType()
return panels;
}
OLIVE_NAMESPACE_EXIT
#endif // PANELFOCUSMANAGER_H
+4
View File
@@ -20,6 +20,8 @@
#include "param.h"
OLIVE_NAMESPACE_ENTER
ParamPanel::ParamPanel(QWidget* parent) :
TimeBasedPanel(parent)
{
@@ -55,3 +57,5 @@ void ParamPanel::Retranslate()
SetSubtitle(tr("(multiple)"));
}
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -24,6 +24,8 @@
#include "panel/timebased/timebased.h"
#include "widget/nodeparamview/nodeparamview.h"
OLIVE_NAMESPACE_ENTER
class ParamPanel : public TimeBasedPanel
{
Q_OBJECT
@@ -43,4 +45,6 @@ protected:
};
OLIVE_NAMESPACE_EXIT
#endif // PARAM_H
@@ -1,5 +1,27 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#include "pixelsamplerpanel.h"
OLIVE_NAMESPACE_ENTER
PixelSamplerPanel::PixelSamplerPanel(QWidget *parent) :
PanelWidget(parent)
{
@@ -21,3 +43,5 @@ void PixelSamplerPanel::Retranslate()
{
SetTitle(tr("Pixel Sampler"));
}
OLIVE_NAMESPACE_EXIT
@@ -1,9 +1,31 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#ifndef PIXELSAMPLERPANEL_H
#define PIXELSAMPLERPANEL_H
#include "widget/panel/panel.h"
#include "widget/viewer/pixelsamplerwidget.h"
OLIVE_NAMESPACE_ENTER
class PixelSamplerPanel : public PanelWidget
{
Q_OBJECT
@@ -20,4 +42,6 @@ private:
};
OLIVE_NAMESPACE_EXIT
#endif // PIXELSAMPLERPANEL_H
@@ -1,3 +1,23 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#ifndef FOOTAGEMANAGEMENTPANEL_H
#define FOOTAGEMANAGEMENTPANEL_H
@@ -5,9 +25,13 @@
#include "project/item/footage/footage.h"
OLIVE_NAMESPACE_ENTER
class FootageManagementPanel {
public:
virtual QList<Footage*> GetSelectedFootage() = 0;
};
OLIVE_NAMESPACE_EXIT
#endif // FOOTAGEMANAGEMENTPANEL_H
+4
View File
@@ -32,6 +32,8 @@
#include "widget/projecttoolbar/projecttoolbar.h"
#include "window/mainwindow/mainwindow.h"
OLIVE_NAMESPACE_ENTER
ProjectPanel::ProjectPanel(QWidget *parent) :
PanelWidget(parent)
{
@@ -197,3 +199,5 @@ QList<Footage *> ProjectPanel::GetSelectedFootage()
return footage;
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -26,6 +26,8 @@
#include "widget/panel/panel.h"
#include "widget/projectexplorer/projectexplorer.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief A PanelWidget wrapper around a ProjectExplorer and a ProjectToolbar
*/
@@ -74,4 +76,6 @@ private slots:
};
OLIVE_NAMESPACE_EXIT
#endif // PROJECT_PANEL_H
@@ -1,5 +1,27 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#include "sequenceviewer.h"
OLIVE_NAMESPACE_ENTER
SequenceViewerPanel::SequenceViewerPanel(QWidget *parent) :
ViewerPanel(parent)
{
@@ -16,3 +38,5 @@ void SequenceViewerPanel::Retranslate()
SetTitle(tr("Sequence Viewer"));
}
OLIVE_NAMESPACE_EXIT
+24
View File
@@ -1,8 +1,30 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#ifndef SEQUENCEVIEWERPANEL_H
#define SEQUENCEVIEWERPANEL_H
#include "panel/viewer/viewer.h"
OLIVE_NAMESPACE_ENTER
class SequenceViewerPanel : public ViewerPanel
{
public:
@@ -13,4 +35,6 @@ protected:
};
OLIVE_NAMESPACE_EXIT
#endif // SEQUENCEVIEWERPANEL_H
+4
View File
@@ -22,6 +22,8 @@
#include "task/taskmanager.h"
OLIVE_NAMESPACE_ENTER
TaskManagerPanel::TaskManagerPanel(QWidget* parent) :
PanelWidget(parent)
{
@@ -45,3 +47,5 @@ void TaskManagerPanel::Retranslate()
{
SetTitle(tr("Task Manager"));
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -24,6 +24,8 @@
#include "widget/taskview/taskview.h"
#include "widget/panel/panel.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief A PanelWidget wrapper around a TaskView widget
*/
@@ -39,4 +41,6 @@ private:
TaskView* view_;
};
OLIVE_NAMESPACE_EXIT
#endif // TASKMANAGER_H
+24
View File
@@ -1,5 +1,27 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#include "timebased.h"
OLIVE_NAMESPACE_ENTER
TimeBasedPanel::TimeBasedPanel(QWidget *parent) :
PanelWidget(parent),
widget_(nullptr)
@@ -164,3 +186,5 @@ void TimeBasedPanel::SetMarker()
{
GetTimeBasedWidget()->SetMarker();
}
OLIVE_NAMESPACE_EXIT
+24
View File
@@ -1,9 +1,31 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#ifndef TIMEBASEDPANEL_H
#define TIMEBASEDPANEL_H
#include "widget/panel/panel.h"
#include "widget/timebased/timebased.h"
OLIVE_NAMESPACE_ENTER
class TimeBasedPanel : public PanelWidget
{
Q_OBJECT
@@ -86,4 +108,6 @@ private:
};
OLIVE_NAMESPACE_EXIT
#endif // TIMEBASEDPANEL_H
+4
View File
@@ -23,6 +23,8 @@
#include "panel/panelmanager.h"
#include "panel/project/footagemanagementpanel.h"
OLIVE_NAMESPACE_ENTER
TimelinePanel::TimelinePanel(QWidget *parent) :
TimeBasedPanel(parent)
{
@@ -156,3 +158,5 @@ void TimelinePanel::Retranslate()
SetTitle(tr("Timeline"));
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -24,6 +24,8 @@
#include "panel/timebased/timebased.h"
#include "widget/timelinewidget/timelinewidget.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief Panel container for a TimelineWidget
*/
@@ -83,4 +85,6 @@ signals:
};
OLIVE_NAMESPACE_EXIT
#endif // TIMELINE_PANEL_H
+4
View File
@@ -23,6 +23,8 @@
#include "core.h"
#include "widget/toolbar/toolbar.h"
OLIVE_NAMESPACE_ENTER
ToolPanel::ToolPanel(QWidget *parent) :
PanelWidget(parent)
{
@@ -51,3 +53,5 @@ void ToolPanel::Retranslate()
{
SetTitle(tr("Tools"));
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -23,6 +23,8 @@
#include "widget/panel/panel.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief A PanelWidget wrapper around a Toolbar
*/
@@ -37,4 +39,6 @@ private:
};
OLIVE_NAMESPACE_EXIT
#endif // TOOL_PANEL_H
+4
View File
@@ -20,6 +20,8 @@
#include "viewer.h"
OLIVE_NAMESPACE_ENTER
ViewerPanel::ViewerPanel(QWidget *parent) :
ViewerPanelBase(parent)
{
@@ -39,3 +41,5 @@ void ViewerPanel::Retranslate()
SetTitle(tr("Viewer"));
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -25,6 +25,8 @@
#include "viewerbase.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief Dockable wrapper around a ViewerWidget
*/
@@ -38,4 +40,6 @@ protected:
};
OLIVE_NAMESPACE_EXIT
#endif // VIEWER_PANEL_H
+24
View File
@@ -1,5 +1,27 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#include "viewerbase.h"
OLIVE_NAMESPACE_ENTER
ViewerPanelBase::ViewerPanelBase(QWidget *parent) :
TimeBasedPanel(parent)
{
@@ -58,3 +80,5 @@ void ViewerPanelBase::SetFullScreen(QScreen *screen)
{
static_cast<ViewerWidget*>(GetTimeBasedWidget())->SetFullScreen(screen);
}
OLIVE_NAMESPACE_EXIT
+24
View File
@@ -1,3 +1,23 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#ifndef VIEWERPANELBASE_H
#define VIEWERPANELBASE_H
@@ -5,6 +25,8 @@
#include "panel/timebased/timebased.h"
#include "widget/viewer/viewer.h"
OLIVE_NAMESPACE_ENTER
class ViewerPanelBase : public TimeBasedPanel
{
Q_OBJECT
@@ -34,4 +56,6 @@ public:
};
OLIVE_NAMESPACE_EXIT
#endif // VIEWERPANELBASE_H