Skip to content

Commit

Permalink
code cleanup and more sensible defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
dvx committed Jul 8, 2020
1 parent 8f6adb7 commit 9422f04
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export const DEFAULT_SETTINGS = {
debug: false,
hardware_acceleration: true,
lofi: {
visualization: 2,
visualization: 0,
window: {
always_on_top: true,
x: 0,
Expand Down
2 changes: 1 addition & 1 deletion src/renderer/components/Lofi/About/index.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { useState } from 'react';
import React from 'react';
import TitleBar from 'frameless-titlebar'
import * as j from '../../../../../package.json'
import './style.scss';
Expand Down
4 changes: 2 additions & 2 deletions src/renderer/components/Lofi/Cover/index.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import { remote, ipcRenderer } from 'electron'
import { remote } from 'electron'
import settings from 'electron-settings';
import { MACOS } from '../../../../constants'
import * as path from 'path';
Expand Down Expand Up @@ -243,7 +243,7 @@ class Cover extends React.Component<any, any> {
// 5) Put them in the shuffled order in the playlist ID
// 6) Play that playlist ID
const playlist_id = this.state.currently_playing.context.uri.split(":").reverse()[0];
const tracks = (await this.getAllTracksFromPlaylist(playlist_id));
// const tracks = (await this.getAllTracksFromPlaylist(playlist_id));

let res = await fetch('https://api.spotify.com/v1/playlists/' + playlist_id + '/tracks', {
method: 'GET',
Expand Down
3 changes: 1 addition & 2 deletions src/renderer/components/util/WindowPortal/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

import React from 'react'
import ReactDOM from 'react-dom'
import PropTypes from 'prop-types'

/**
* The NewWindow class object.
Expand Down Expand Up @@ -66,7 +65,7 @@ class NewWindow extends React.PureComponent<any, any> {
* Create the new window when NewWindow component mount.
*/
openChild() {
const { url, title, name, features, onBlock, onOpen, center, fullscreen, size } = this.props
const { url, title, name, features, onBlock, onOpen, center } = this.props

// Prepare position of the new window to be centered against the 'parent' window or 'screen'.
if (
Expand Down

0 comments on commit 9422f04

Please sign in to comment.