mirror of
https://github.com/EEVengers/ThunderScope.git
synced 2025-04-14 23:59:19 +00:00
skeleton code for single button handler
This commit is contained in:
parent
fe7842105f
commit
f865bff4c7
Software/waveview/src
@ -2,9 +2,9 @@ import React from 'react';
|
||||
import './../../../css/sidebar/core/singleButton.css';
|
||||
|
||||
class SingleButton extends React.Component<any, any> {
|
||||
|
||||
handleSingleClick = () => {
|
||||
alert("Single")
|
||||
|
||||
singleClickHandler = () => {
|
||||
this.props.dispatch({type: 'graph/singleMode'});
|
||||
}
|
||||
|
||||
render() {
|
||||
@ -12,7 +12,7 @@ class SingleButton extends React.Component<any, any> {
|
||||
<div className={"SingleButtonComponent"}>
|
||||
<button
|
||||
className={"SingleButton"}
|
||||
onClick={() => this.handleSingleClick()}
|
||||
onClick={() => this.singleClickHandler()}
|
||||
>
|
||||
<label
|
||||
className={"SingleButtonText"}>
|
||||
|
@ -9,6 +9,9 @@ export default function(state = GraphInitialState, action: {type: any, payload:
|
||||
...state,
|
||||
currentStatus: newStatus
|
||||
};
|
||||
case "graph/singleMode":
|
||||
// Handle what needs to happen when clicking the Single button
|
||||
return state;
|
||||
default:
|
||||
return state;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user