Cleanup for merge.

This commit is contained in:
Thomas Wilshaw
2021-04-14 12:48:44 +01:00
parent da275efdf2
commit 139adbdb31
8 changed files with 9 additions and 10 deletions
+1
View File
@@ -41,6 +41,7 @@ public:
rational GetTime();
// Get the timebase of this panels widget
const rational& timebase();
ViewerOutput *GetConnectedViewer() const
+1 -1
View File
@@ -163,7 +163,7 @@ void MenuShared::AddItemsForClipEditMenu(Menu *m)
void MenuShared::AddItemsForTimeRulerMenu(Menu *m, const rational& timebase)
{
// If a menu is already created (such as the view menu) we need to remove the instance
// of dropfram or non-dropframe timecode that is already there to avoid double displays
// of dropframe or non-dropframe timecode that is already there to avoid double displays
if (m->actions().contains(view_timecode_view_dropframe_item_)) {
m->removeAction(view_timecode_view_dropframe_item_);
@@ -133,7 +133,6 @@ NodeParamView::NodeParamView(QWidget *parent) :
&QApplication::focusChanged,
this,
&NodeParamView::FocusChanged);
}
void NodeParamView::SelectNodes(const QVector<Node *> &nodes)
@@ -85,6 +85,7 @@ public:
int GetElementY(NodeInput c) const;
// Set the timebase of any timebased widgets contained here
void SetTimebase(const rational& timebase);
signals:
@@ -169,6 +170,7 @@ public:
void SetTime(const rational& time);
// Set the timebase of the NodeParamViewItemBody
void SetTimebase(const rational& timebase);
Node* GetNode() const;
@@ -49,6 +49,7 @@ public:
return widgets_;
}
// Set the timebase of certain Timebased widgets
void SetTimebase(const rational& timebase);
signals:
+1 -2
View File
@@ -1,6 +1,6 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2020 Olive Team
Copyright (C) 2021 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
@@ -127,7 +127,6 @@ QString RationalSlider::ValueToString(const QVariant &v)
case kTimestamp:
return QString::number(Timecode::time_to_timestamp(time, timebase_));
case kRational:
// Might we want to call reduce() on r here?
return v.value<rational>().toString();
case kFloat:
{
+2 -5
View File
@@ -1,6 +1,6 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2020 Olive Team
Copyright (C) 2021 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
@@ -27,10 +27,8 @@ namespace olive {
/**
* @brief A olive::rational based slider
*
* A slider that can display rationals as either timecode, a timestamp (frames), a rational (a/b)
* A slider that can display rationals as either timecode (drop or non-drop), a timestamp (frames),
* or a float (seconds).
*
* Control clikcing the slider (see sliderlabel.h) changes thedisplay type
*/
class RationalSlider : public SliderBase
{
@@ -42,7 +40,6 @@ public:
enum DisplayType {
kTimecode,
kTimestamp,
kRational,
kFloat
};
+1 -1
View File
@@ -57,7 +57,7 @@ void SliderLabel::mousePressEvent(QMouseEvent *e)
if (e->button() == Qt::LeftButton) {
if (e->modifiers() & Qt::AltModifier) {
emit RequestReset();
} else {
} else {
emit LabelPressed();
}
}