Add display type context menu to RationalSlider

This commit is contained in:
Thomas Wilshaw
2021-04-09 10:52:07 +01:00
parent 2cea45268f
commit 4d8233e7ac
3 changed files with 11 additions and 4 deletions
+8 -1
View File
@@ -17,6 +17,8 @@
#include "common/timecodefunctions.h"
#include "core.h"
#include "widget/menu/menu.h"
#include "widget/menu/menushared.h"
namespace olive {
@@ -189,7 +191,12 @@ void RationalSlider::changeDisplayType()
{
if (!LockDisplayType()) {
// Loop through the display types
SetDisplayType(static_cast<RationalSlider::DisplayType>(((int)(display_type_) + 1) % 4));
//SetDisplayType(static_cast<RationalSlider::DisplayType>(((int)(display_type_) + 1) % 4));
Menu m(this);
MenuShared::instance()->AddItemsForTimeRulerMenu(&m, timebase_);
MenuShared::instance()->AboutToShowTimeRulerActions();
m.exec(QCursor::pos());
ForceLabelUpdate();
}
}