bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/actions-bar/container.jsx

32 lines
831 B
React
Raw Normal View History

2016-04-29 03:02:51 +08:00
import React, { Component, PropTypes } from 'react';
import { createContainer } from 'meteor/react-meteor-data';
import ActionsBar from './component';
import Service from './service';
import { joinListenOnly } from '/imports/api/phone';
2017-03-14 00:05:54 +08:00
import { exitAudio } from '/imports/api/phone';
2016-04-29 03:02:51 +08:00
class ActionsBarContainer extends Component {
2016-04-29 03:02:51 +08:00
constructor(props) {
super(props);
}
render() {
const handleJoinListenOnly = () => joinListenOnly();
2017-03-14 00:05:54 +08:00
const handleExitAudio = () => exitAudio();
2016-04-29 03:02:51 +08:00
return (
<ActionsBar
2017-03-15 06:34:57 +08:00
handleJoinListenOnly={handleJoinListenOnly}
2017-03-14 00:05:54 +08:00
handleExitAudio={handleExitAudio}
{...this.props}>
2017-03-15 06:34:57 +08:00
{this.props.children}
</ActionsBar>
2016-04-29 03:02:51 +08:00
);
}
}
export default createContainer(() => {
let data = Service.isUserPresenter();
2016-06-28 02:24:37 +08:00
return data;
}, ActionsBarContainer);