Files
SubMusic/source/View/SubMusicMenuPlayback.mc
memen45 abc95254a3 added 'More...' to playback configuration to open sync menu
fixed hanging sync (feedback required)
fixed error on error string creation
2020-12-09 16:39:47 +01:00

42 lines
1020 B
MonkeyC

using Toybox.WatchUi;
using SubMusic.Menu;
module SubMusic {
module Menu {
class Playback {
var title = Rez.Strings.confPlayback_Title;
enum {
SELECT_PLAYLIST,
OPEN_SYNC,
}
var items = {
SELECT_PLAYLIST => {
LABEL => Rez.Strings.confPlayback_SelectPlaylist_label,
SUBLABEL => null,
METHOD => method(:onSelectPlaylist),
},
OPEN_SYNC => {
LABEL => Rez.Strings.confPlayback_OpenSync_label,
SUBLABEL => null,
METHOD => method(:onOpenSync),
},
};
function onSelectPlaylist() {
WatchUi.pushView(new SubMusicConfigurePlaybackPlaylistView(), null, WatchUi.SLIDE_IMMEDIATE);
}
function onOpenSync() {
// pass false to indicate we are coming from another sync flow than normal
WatchUi.pushView(new SubMusic.Menu.SyncView(false), new SubMusic.Menu.Delegate(), WatchUi.SLIDE_IMMEDIATE);
}
}
class PlaybackView extends MenuView {
function initialize() {
MenuView.initialize(new Playback());
}
}
}
}