mirror of
https://github.com/captbaritone/webamp.git
synced 2026-07-21 09:09:01 +00:00
parent
e89680fb48
commit
3ef93e28ab
2 changed files with 6 additions and 13 deletions
|
|
@ -132,17 +132,7 @@ class WindowManager extends React.Component {
|
|||
)
|
||||
};
|
||||
|
||||
let box;
|
||||
try {
|
||||
box = boundingBox(moving);
|
||||
} catch (err) {
|
||||
console.error(
|
||||
`Could not construct bounding box for key: ${key}. moving.length is: ${
|
||||
moving.length
|
||||
}`
|
||||
);
|
||||
throw err;
|
||||
}
|
||||
const box = boundingBox(moving);
|
||||
|
||||
const handleMouseMove = ee => {
|
||||
const proposedDiff = {
|
||||
|
|
|
|||
|
|
@ -77,13 +77,16 @@ const windows = (state = defaultWindowsState, action) => {
|
|||
}
|
||||
};
|
||||
case TOGGLE_WINDOW:
|
||||
const windowState = state.genWindows[action.windowId];
|
||||
return {
|
||||
...state,
|
||||
genWindows: {
|
||||
...state.genWindows,
|
||||
[action.windowId]: {
|
||||
...state.genWindows[action.windowId],
|
||||
open: !state.genWindows[action.windowId].open
|
||||
...windowState,
|
||||
open: !windowState.open,
|
||||
// Reset hidden state when opening window
|
||||
hidden: windowState.open ? windowState.hidden : false
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue