-
Notifications
You must be signed in to change notification settings - Fork 0
/
SekvojRackMainMenuView.h
74 lines (64 loc) · 1.78 KB
/
SekvojRackMainMenuView.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
/*
* SekvojRackMainMenuView.h
*
* Created on: Jul 25, 2014
* Author: bastl
*/
#ifndef SEKVOJRACKMAINMENUVIEW_H_
#define SEKVOJRACKMAINMENUVIEW_H_
#include <IView.h>
#include "sekvojHW.h"
#include <Player.h>
#include <IStepMemory.h>
#include <RadioButtons.h>
#include <PlayerSettings.h>
#include <BastlMetronome.h>
#include <StepRecorder.h>
#include "InstrumentBar.h"
#include <IButtonMap.h>
#include <Switches.h>
#include <StepSynchronizer.h>
#include <ITapper.h>
#include <SekvojRackSDPreset.h>
#include <SekvojModulePool.h>
class SekvojRackMainMenuView : public IView {
public:
SekvojRackMainMenuView();
void init(void (*playerStatusChangedCallback)());
void update();
bool isPlaying();
private:
enum UIStatus{INIT, INIT_FROM_PATTERN, ACTIVE, RECORDING, PATTERN, PATTERN_FROM_ACTIVE, FUNCTION_FROM_PATTERN, FUNCTION, FUNCTION_FROM_RECORD};
Switches activePlayRecordSwitch_;
IView * currentView_;
unsigned char currentViewIndex_;
unsigned char currentBarIndex_;
bool functionButtonDown_;
bool patternButtonMomentary_;
bool functionInActive_;
bool activeButtonDown_;
bool patternButtonDown_;
bool jumpButtonDown_;
UIStatus currentStatus_;
unsigned char selectedInstrument_;
bool isPlaying_;
void (*playerStatusChangedCallback_)();
void updateInInit();
void updateInJumpInit();
void updateInActive();
void updateInRecording();
void updateInPattern();
void updateInFunction();
void createSetStepView(bool fromPattern);
void destroyInitView();
void createFunctionView(UIStatus viewSourceDefinition);
void createRecordView();
void createPatternView(UIStatus viewSourceDefinition);
void createActiveView();
void clearAllDiods();
void clearBottomPartDiods();
};
inline bool SekvojRackMainMenuView::isPlaying() {
return isPlaying_;
}
#endif /* SEKVOJRACKMAINMENUVIEW_H_ */