bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/settings/submenus/base/component.jsx
2017-10-10 19:08:51 -03:00

19 lines
417 B
JavaScript

import React from 'react';
export default class BaseMenu extends React.Component {
constructor(props) {
super(props);
this.handleUpdateSettings = props.handleUpdateSettings;
}
handleToggle(key) {
const obj = this.state;
obj.settings[key] = !this.state.settings[key];
this.setState(obj, () => {
this.handleUpdateSettings(this.state.settingsName, this.state.settings);
});
}
}