Skip to content

Commit

Permalink
fixed: #26
Browse files Browse the repository at this point in the history
  • Loading branch information
ganeshrvel committed Jul 14, 2019
1 parent 84bc158 commit 0a407d3
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
10 changes: 10 additions & 0 deletions app/containers/HomePage/components/ToolbarAreaPane.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ import { pathUp } from '../../../utils/paths';
import { toggleSettings } from '../../Settings/actions';
import { toggleWindowSizeOnDoubleClick } from '../../../utils/titlebarDoubleClick';
import ToolbarBody from './ToolbarBody';
import { openExternalUrl } from '../../../utils/url';
import { APP_GITHUB_URL } from '../../../constants/meta';

class ToolbarAreaPane extends PureComponent {
constructor(props) {
Expand Down Expand Up @@ -139,6 +141,10 @@ class ToolbarAreaPane extends PureComponent {
actionCreateToggleSettings(true);
};

_handleOpenGitHubRepo = () => {
openExternalUrl(APP_GITHUB_URL);
};

_handleToolbarAction = itemType => {
const {
currentBrowsePath,
Expand Down Expand Up @@ -179,6 +185,10 @@ class ToolbarAreaPane extends PureComponent {
this._handleToggleSettings(true);
break;

case 'gitHub':
this._handleOpenGitHubRepo();
break;

default:
break;
}
Expand Down
6 changes: 6 additions & 0 deletions app/containers/HomePage/reducers.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,12 @@ export const initialState = {
label: 'Settings',
imgSrc: 'Toolbar/settings.svg',
invert: false
},
gitHub: {
enabled: true,
label: 'GitHub',
imgSrc: 'Toolbar/github.svg',
invert: false
}
},
[DEVICES_TYPE_CONST.mtp]: {
Expand Down
1 change: 1 addition & 0 deletions app/public/images/Toolbar/github.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 0a407d3

Please sign in to comment.