fix(changelog): fix modal peers display

This commit is contained in:
Alexey Kasyanchuk 2018-03-05 06:51:29 +03:00
parent 008a9bd0cc
commit c40799816b
2 changed files with 9 additions and 4 deletions

View File

@ -7,6 +7,7 @@ import injectTapEventPlugin from 'react-tap-event-plugin';
import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider';
const { ipcRenderer, remote } = require('electron');
const currentWindow = remote.getCurrentWindow()
//var io = require("socket.io-client");
//window.torrentSocket = io(document.location.protocol + '//' + document.location.hostname + (process.env.NODE_ENV === 'production' ? '/' : ':8095/'));
@ -110,9 +111,13 @@ class App extends Component {
<MuiThemeProvider>
<div>
<PagesPie />
<div className='fs0-85 pad0-75' style={{position: 'fixed', bottom: 0, left: 0, color: window.peers > 0 ? 'green' : 'grey'}}>
rats peers: {window.peers} {window.peers > 0 ? ' (p2p rats search enabled)' : ' (p2p rats search not available at this moment)'}
</div>
{
!currentWindow.isModal()
&&
<div className='fs0-85 pad0-75' style={{position: 'fixed', bottom: 0, left: 0, color: window.peers > 0 ? 'green' : 'grey'}}>
rats peers: {window.peers} {window.peers > 0 ? ' (p2p rats search enabled)' : ' (p2p rats search not available at this moment)'}
</div>
}
</div>
</MuiThemeProvider>
);

View File

@ -20,7 +20,7 @@ export const aboutMenuTemplate = {
slashes: true
}))
win.webContents.on('did-finish-load', () => {
win.send('url', '/changelog')
setTimeout(() => win.send('url', '/changelog'), 0)
});
const handleRedirect = (e, url) => {