The library viewer no longer uses ImGui. A filter bar with search over title, artist and album, Loved only and a file filter sits above the track list, which marks the playing track; double-clicking a track plays it. A player bar docked at the bottom shows the track, play and pause, previous and next over the visible tracks, a seek bar with buffering and volume, and advances when a track ends. Space toggles playback. The default menu bar carries File, View and Playback menus. Playback goes through a small device interface so the view is tested headlessly with a fake device.
15 lines
377 B
C++
15 lines
377 B
C++
#include "LibraryViewerApplication.hpp"
|
|
|
|
using namespace tp;
|
|
|
|
LibraryViewerApplication::LibraryViewerApplication(const std::string& libraryPath) :
|
|
mGui(mLibrary, mDevice) {
|
|
mLibrary.loadJson(libraryPath);
|
|
mLibrary.checkExisting();
|
|
mGui.rebuildTracks();
|
|
mGui.buildMenus(menuBar());
|
|
|
|
setRoot(mGui);
|
|
}
|
|
|
|
LibraryViewerApplication::~LibraryViewerApplication() { clearRoot(); }
|