import React, { PropTypes } from 'react' import { connect } from 'react-redux' import { bindActionCreators } from 'redux' import FontAwesome from 'react-fontawesome' import SpotifyAuthenticationFrame from '../components/SpotifyAuthenticationFrame' import ConfirmationButton from '../components/ConfirmationButton' import * as mopidyActions from '../services/mopidy/actions' import * as spotifyActions from '../services/spotify/actions' class Settings extends React.Component{ constructor(props) { super(props); this.state = { mopidy_host: this.props.mopidy.host, mopidy_port: this.props.mopidy.port }; } resetAllSettings(){ localStorage.clear(); window.location.reload(true); } setConfig(){ this.props.mopidyActions.setConfig( this.state.mopidy_host, this.state.mopidy_port ); window.location.reload(true); } render(){ return (