UI fix: Collapsed 2dMPR button to main toolbar
This commit is contained in:
parent
6a5ebb3e25
commit
c57298475a
@ -38,18 +38,13 @@ const mergeProps = (propsFromState, propsFromDispatch, ownProps) => {
|
|||||||
|
|
||||||
// TODO: Do not display certain options if the current display set
|
// TODO: Do not display certain options if the current display set
|
||||||
// cannot be displayed using these view types
|
// cannot be displayed using these view types
|
||||||
const button =
|
const mpr = () => {
|
||||||
{
|
|
||||||
label: "2D MPR",
|
|
||||||
icon: "cube",
|
|
||||||
onClick: () => {
|
|
||||||
commandsManager.runCommand("mpr2d");
|
commandsManager.runCommand("mpr2d");
|
||||||
}
|
}
|
||||||
}
|
|
||||||
;
|
;
|
||||||
|
|
||||||
return {
|
return {
|
||||||
button
|
mpr
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@ -5,7 +5,7 @@ import './PluginSwitch.css';
|
|||||||
|
|
||||||
class PluginSwitch extends Component {
|
class PluginSwitch extends Component {
|
||||||
static propTypes = {
|
static propTypes = {
|
||||||
button: PropTypes.any,
|
mpr: PropTypes.func,
|
||||||
};
|
};
|
||||||
|
|
||||||
static defaultProps = {};
|
static defaultProps = {};
|
||||||
@ -15,7 +15,7 @@ class PluginSwitch extends Component {
|
|||||||
<div className="PluginSwitch">
|
<div className="PluginSwitch">
|
||||||
<ToolbarButton label = "2D MPR"
|
<ToolbarButton label = "2D MPR"
|
||||||
icon = "cube"
|
icon = "cube"
|
||||||
onClick = {this.props.button.onClick} />
|
onClick = {this.props.mpr} />
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user