Skip to content

Commit

Permalink
Added saving to settings of clip info and track info.
Browse files Browse the repository at this point in the history
  • Loading branch information
ggarra13 committed Apr 17, 2024
1 parent ec64361 commit fa97709
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
6 changes: 6 additions & 0 deletions mrv2/lib/mrvApp/mrvSettingsObject.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ namespace fs = std::filesystem;
#include <tlTimeline/Player.h>
#include <tlTimeline/Timeline.h>

#include <tlTimelineUI/IItem.h>

#include <FL/Fl.H>

#include "mrvCore/mrvOS.h"
Expand Down Expand Up @@ -70,6 +72,10 @@ namespace mrv

p.defaultValues["Timeline/Editable"] = true;
p.defaultValues["Timeline/FrameView"] = true;
p.defaultValues["Timeline/TrackInfo"] =
timelineui::ItemOptions().trackInfo;
p.defaultValues["Timeline/ClipInfo"] =
timelineui::ItemOptions().clipInfo;
p.defaultValues["Timeline/ScrollToCurrentFrame"] = true;
p.defaultValues["Timeline/StopOnScrub"] = true;
p.defaultValues["Timeline/FirstTrack"] = false;
Expand Down
4 changes: 4 additions & 0 deletions mrv2/lib/mrvFl/mrvCallbacks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1628,6 +1628,8 @@ namespace mrv
Fl_Menu_Item* item = const_cast< Fl_Menu_Item* >(m->mvalue());
auto options = ui->uiTimeline->getItemOptions();
options.trackInfo = item->checked();
auto settings = ui->app->settings();
settings->setValue("Timeline/TrackInfo", options.trackInfo);
Message msg;
msg["command"] = "setTimelineItemOptions";
msg["value"] = options;
Expand All @@ -1644,6 +1646,8 @@ namespace mrv
Fl_Menu_Item* item = const_cast< Fl_Menu_Item* >(m->mvalue());
auto options = ui->uiTimeline->getItemOptions();
options.clipInfo = item->checked();
auto settings = ui->app->settings();
settings->setValue("Timeline/ClipInfo", options.clipInfo);
Message msg;
msg["command"] = "setTimelineItemOptions";
msg["value"] = options;
Expand Down

0 comments on commit fa97709

Please sign in to comment.