[Added tooltips] [IPC constants]
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
.MountItems {
|
||||
margin-top: 10px;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
width: 100%;
|
||||
}
|
||||
@@ -1,12 +1,10 @@
|
||||
import React from 'react';
|
||||
import {Component} from 'react';
|
||||
import * as Constants from '../../constants';
|
||||
import CSSModules from 'react-css-modules';
|
||||
import styles from './MountItems.css';
|
||||
import MountItem from '../../components/MountItem/MountItem';
|
||||
import {IPC_Detect_Mounts} from "../../constants";
|
||||
import {IPC_Mount_Drive} from "../../constants";
|
||||
import {IPC_Unmount_Drive} from "../../constants";
|
||||
|
||||
const Constants = require('../../constants');
|
||||
|
||||
let ipcRenderer = null;
|
||||
if (!process.versions.hasOwnProperty('electron')) {
|
||||
@@ -50,7 +48,7 @@ class MountItems extends Component {
|
||||
|
||||
detectMounts = ()=> {
|
||||
this.props.mountsBusy(true);
|
||||
ipcRenderer.send(IPC_Detect_Mounts, {
|
||||
ipcRenderer.send(Constants.IPC_Detect_Mounts, {
|
||||
Directory: this.props.directory,
|
||||
Version: this.props.version,
|
||||
});
|
||||
@@ -78,14 +76,14 @@ class MountItems extends Component {
|
||||
this.props.mountsBusy(true);
|
||||
|
||||
if (mount) {
|
||||
ipcRenderer.send(IPC_Mount_Drive, {
|
||||
ipcRenderer.send(Constants.IPC_Mount_Drive, {
|
||||
Directory: this.props.directory,
|
||||
Location: location,
|
||||
StorageType: storageType,
|
||||
Version: this.props.version,
|
||||
});
|
||||
} else {
|
||||
ipcRenderer.send(IPC_Unmount_Drive, {
|
||||
ipcRenderer.send(Constants.IPC_Unmount_Drive, {
|
||||
Directory: this.props.directory,
|
||||
Location: location,
|
||||
PID: pid,
|
||||
|
||||
Reference in New Issue
Block a user