mirror of
https://github.com/captbaritone/webamp
synced 2024-11-23 16:49:41 +00:00
Add eq shade state to reducer
This commit is contained in:
parent
22eda9257c
commit
369589e460
@ -20,7 +20,8 @@ import {
|
||||
TOGGLE_REPEAT,
|
||||
TOGGLE_SHUFFLE,
|
||||
SET_EQ_ON,
|
||||
SET_EQ_OFF
|
||||
SET_EQ_OFF,
|
||||
TOGGLE_EQUALIZER_SHADE_MODE
|
||||
} from "./actionTypes";
|
||||
|
||||
export function play() {
|
||||
@ -42,7 +43,7 @@ export function stop() {
|
||||
}
|
||||
|
||||
export function seekForward(seconds) {
|
||||
return function(dispatch, getState) {
|
||||
return function (dispatch, getState) {
|
||||
const { media } = getState();
|
||||
const { timeElapsed, length } = media;
|
||||
const newTimeElapsed = timeElapsed + seconds;
|
||||
@ -222,3 +223,7 @@ export function downloadPreset() {
|
||||
downloadURI(dataURI, "entry.eqf");
|
||||
};
|
||||
}
|
||||
|
||||
export function toggleEqualizerShadeMode() {
|
||||
return { type: TOGGLE_EQUALIZER_SHADE_MODE };
|
||||
}
|
||||
|
@ -32,6 +32,7 @@ export const SET_EQ_OFF = "SET_EQ_OFF";
|
||||
export const TOGGLE_LLAMA_MODE = "TOGGLE_LLAMA_MODE";
|
||||
export const TOGGLE_REPEAT = "TOGGLE_REPEAT";
|
||||
export const TOGGLE_SHADE_MODE = "TOGGLE_SHADE_MODE";
|
||||
export const TOGGLE_EQUALIZER_SHADE_MODE = "TOGGLE_EQUALIZER_SHADE_MODE";
|
||||
export const TOGGLE_SHUFFLE = "TOGGLE_SHUFFLE";
|
||||
export const TOGGLE_TIME_MODE = "TOGGLE_TIME_MODE";
|
||||
export const TOGGLE_VISUALIZER_STYLE = "TOGGLE_VISUALIZER_STYLE";
|
||||
|
@ -26,6 +26,7 @@ import {
|
||||
TOGGLE_LLAMA_MODE,
|
||||
TOGGLE_REPEAT,
|
||||
TOGGLE_SHADE_MODE,
|
||||
TOGGLE_EQUALIZER_SHADE_MODE,
|
||||
TOGGLE_SHUFFLE,
|
||||
TOGGLE_TIME_MODE,
|
||||
TOGGLE_VISUALIZER_STYLE,
|
||||
@ -81,6 +82,7 @@ const display = (state, action) => {
|
||||
llama: false,
|
||||
closed: false,
|
||||
shade: false,
|
||||
equalizerShade: false,
|
||||
working: false,
|
||||
skinImages: {},
|
||||
skinColors: null,
|
||||
@ -93,6 +95,8 @@ const display = (state, action) => {
|
||||
return { ...state, doubled: !state.doubled };
|
||||
case TOGGLE_SHADE_MODE:
|
||||
return { ...state, shade: !state.shade };
|
||||
case TOGGLE_EQUALIZER_SHADE_MODE:
|
||||
return { ...state, equalizerShade: !state.shade };
|
||||
case TOGGLE_LLAMA_MODE:
|
||||
return { ...state, llama: !state.llama };
|
||||
case STEP_MARQUEE:
|
||||
|
Loading…
Reference in New Issue
Block a user