mirror of
https://github.com/captbaritone/webamp.git
synced 2026-07-25 02:57:30 +00:00
Clean up skin stuff and some odds and ends
This commit is contained in:
parent
2ee295ec72
commit
d4182bc862
6 changed files with 4 additions and 82 deletions
|
|
@ -5,7 +5,6 @@ import React from "react";
|
|||
import ReactDOM from "react-dom";
|
||||
import createMiddleware from "raven-for-redux";
|
||||
import isButterchurnSupported from "butterchurn/lib/isSupported.min";
|
||||
import base from "../../skins/base-2.91-png.wsz";
|
||||
import { WINDOWS } from "../../js/constants";
|
||||
import * as Selectors from "../../js/selectors";
|
||||
|
||||
|
|
@ -115,7 +114,6 @@ Raven.context(async () => {
|
|||
let __initialWindowLayout = null;
|
||||
if (isButterchurnSupported()) {
|
||||
const startWithMilkdropHidden =
|
||||
library ||
|
||||
document.body.clientWidth < MIN_MILKDROP_WIDTH ||
|
||||
skinUrl != null ||
|
||||
screenshot;
|
||||
|
|
|
|||
|
|
@ -73,7 +73,6 @@ export const LOAD_SERIALIZED_STATE = "LOAD_SERIALIZED_STATE";
|
|||
export const RESET_WINDOW_SIZES = "RESET_WINDOW_SIZES";
|
||||
export const BROWSER_WINDOW_SIZE_CHANGED = "BROWSER_WINDOW_SIZE_CHANGED";
|
||||
export const LOAD_DEFAULT_SKIN = "LOAD_DEFAULT_SKIN";
|
||||
export const ENABLE_MEDIA_LIBRARY = "ENABLE_MEDIA_LIBRARY";
|
||||
export const ENABLE_MILKDROP = "ENABLE_MILKDROP";
|
||||
export const SET_MILKDROP_DESKTOP = "SET_MILKDROP_DESKTOP";
|
||||
export const SET_VISUALIZER_STYLE = "SET_VISUALIZER_STYLE";
|
||||
|
|
|
|||
|
|
@ -135,71 +135,6 @@ function cssRulesFromProps(props) {
|
|||
}
|
||||
}
|
||||
|
||||
// TODO: Find a way to make this declarative.
|
||||
cssRules.push(
|
||||
`#webamp-media-library {
|
||||
background-color: ${props.skinGenExColors.windowBackground};
|
||||
color: ${props.skinGenExColors.windowText};
|
||||
}`
|
||||
);
|
||||
cssRules.push(
|
||||
`#webamp-media-library input {
|
||||
caret-color: ${props.skinGenExColors.windowText};
|
||||
}`
|
||||
);
|
||||
cssRules.push(
|
||||
`#webamp-media-library .webamp-media-library-item {
|
||||
color: ${props.skinGenExColors.itemForeground};
|
||||
background-color: ${props.skinGenExColors.itemBackground};
|
||||
border-right: 1px solid ${props.skinGenExColors.divider};
|
||||
border-bottom: 1px solid ${props.skinGenExColors.divider};
|
||||
}`
|
||||
);
|
||||
cssRules.push(
|
||||
`#webamp-media-library .library-button-center {
|
||||
color: ${props.skinGenExColors.buttonText};
|
||||
}`
|
||||
);
|
||||
cssRules.push(
|
||||
`#webamp-media-library .webamp-media-library-vertical-divider {
|
||||
}`
|
||||
);
|
||||
cssRules.push(
|
||||
`#webamp-media-library .webamp-media-library-vertical-divider-line,
|
||||
#webamp-media-library .webamp-media-library-horizontal-divider-line
|
||||
{
|
||||
background-color: ${props.skinGenExColors.divider};
|
||||
}`
|
||||
);
|
||||
cssRules.push(
|
||||
`#webamp-media-library .webamp-media-library-table {
|
||||
color: ${props.skinGenExColors.itemForeground};
|
||||
background-color: ${props.skinGenExColors.itemBackground};
|
||||
}`
|
||||
);
|
||||
|
||||
cssRules.push(
|
||||
`#webamp-media-library .webamp-media-library-table .library-table-heading {
|
||||
background-color: ${props.skinGenExColors.listHeaderFramePressed};
|
||||
}`
|
||||
);
|
||||
|
||||
cssRules.push(
|
||||
`#webamp-media-library .webamp-media-library-table .library-table-heading > div {
|
||||
color: ${props.skinGenExColors.listHeaderText};
|
||||
background-color: ${props.skinGenExColors.listHeaderBackground};
|
||||
border-top: 1px solid ${props.skinGenExColors.listHeaderFrameTopAndLeft};
|
||||
border-left: 1px solid ${props.skinGenExColors.listHeaderFrameTopAndLeft};
|
||||
border-bottom: 1px solid ${props.skinGenExColors.listHeaderFrameBottomAndRight};
|
||||
border-right: 1px solid ${props.skinGenExColors.listHeaderFrameBottomAndRight};
|
||||
}`
|
||||
);
|
||||
cssRules.push(
|
||||
`#webamp-media-library .webamp-media-library-table .library-table-row.selected {
|
||||
background-color: ${props.skinGenExColors.playlistSelection};
|
||||
color: ${props.skinGenExColors.listHeaderText};
|
||||
}`
|
||||
);
|
||||
return cssRules;
|
||||
}
|
||||
|
||||
|
|
@ -233,5 +168,4 @@ export default connect(state => ({
|
|||
skinCursors: state.display.skinCursors,
|
||||
skinRegion: state.display.skinRegion,
|
||||
skinGenLetterWidths: state.display.skinGenLetterWidths,
|
||||
skinGenExColors: state.display.skinGenExColors,
|
||||
}))(Skin);
|
||||
|
|
|
|||
|
|
@ -483,10 +483,6 @@ export const getSkinPlaylistStyle = (state: AppState): PlaylistStyle => {
|
|||
return state.display.skinPlaylistStyle || defaultPlaylistStyle;
|
||||
};
|
||||
|
||||
export const getSkinGenExColors = (state: AppState) => {
|
||||
return state.display.skinGenExColors;
|
||||
};
|
||||
|
||||
export const getVisualizerStyle = (state: AppState): string => {
|
||||
const milkdrop = state.windows.genWindows[WINDOWS.MILKDROP];
|
||||
if (milkdrop != null && milkdrop.open) {
|
||||
|
|
|
|||
|
|
@ -318,15 +318,6 @@ export const imageSelectors: Selectors = {
|
|||
GEN_MIDDLE_RIGHT: [".gen-window .gen-middle-right"],
|
||||
GEN_MIDDLE_RIGHT_BOTTOM: [".gen-window .gen-middle-right-bottom"],
|
||||
GEN_CLOSE_SELECTED: [".gen-window .gen-close:active"],
|
||||
GENEX_BUTTON_BACKGROUND_LEFT_UNPRESSED: [
|
||||
"#webamp-media-library .library-button-left",
|
||||
],
|
||||
GENEX_BUTTON_BACKGROUND_CENTER_UNPRESSED: [
|
||||
"#webamp-media-library .library-button-center",
|
||||
],
|
||||
GENEX_BUTTON_BACKGROUND_RIGHT_UNPRESSED: [
|
||||
"#webamp-media-library .library-button-right",
|
||||
],
|
||||
};
|
||||
|
||||
Object.keys(FONT_LOOKUP).forEach(character => {
|
||||
|
|
|
|||
|
|
@ -738,6 +738,9 @@ const sprites: SpriteMap = {
|
|||
{ name: "GEN_MIDDLE_RIGHT_BOTTOM", x: 170, y: 42, width: 8, height: 24 },
|
||||
{ name: "GEN_CLOSE_SELECTED", x: 148, y: 42, width: 9, height: 9 },
|
||||
],
|
||||
/*
|
||||
|
||||
We don't currently support the Media Library, so there are disabled
|
||||
GENEX: [
|
||||
{
|
||||
name: "GENEX_BUTTON_BACKGROUND_LEFT_UNPRESSED",
|
||||
|
|
@ -816,6 +819,7 @@ const sprites: SpriteMap = {
|
|||
width: 28,
|
||||
},
|
||||
],
|
||||
*/
|
||||
};
|
||||
|
||||
export default sprites;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue