Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package tcpMessage.model;
- import javafx.beans.property.SimpleStringProperty;
- import javafx.event.ActionEvent;
- import javafx.scene.control.Button;
- import tcpMessage.controllers.TcpRequestService;
- import javax.sound.sampled.Mixer;
- /**
- * Created by Szymon on 18.07.2018.
- */
- public class TempUser {
- private String userName;
- private Button button;
- private String appOwner;
- private String roomPassword;
- private String roomName;
- public TcpRequestService requestService;
- public TempUser(String name, Button button, String appOwner, String roomName, String roomPassword) {
- this.userName = name;
- this.button = button;
- this.appOwner = appOwner;
- this.roomName = roomName;
- this.roomPassword = roomPassword;
- this.button.setText("Mute");
- this.button.setOnAction(this::handleButtonAction);
- }
- private void handleButtonAction(ActionEvent event) throws InterruptedException{
- this.requestService.sendMuteUserRequest(appOwner,roomName,userName,roomPassword );
- }
- public String getUserName() {
- return userName;
- }
- public void setUserName(String userName) {
- this.userName = userName;
- }
- public Button getButton() {
- return button;
- }
- public void setButton(Button button) {
- this.button = button;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement