use of org.bigbluebutton.red5.client.messaging.BroadcastClientMessage in project bigbluebutton by bigbluebutton.
the class PresentationClientMessageSender method processPresentationCursorUpdate.
private void processPresentationCursorUpdate(String json) {
PresentationCursorUpdateMessage msg = PresentationCursorUpdateMessage.fromJson(json);
if (msg != null) {
Map<String, Object> args = new HashMap<String, Object>();
args.put("meetingID", msg.meetingId);
args.put("xPercent", msg.xPercent);
args.put("yPercent", msg.yPercent);
Map<String, Object> message = new HashMap<String, Object>();
Gson gson = new Gson();
message.put("msg", gson.toJson(args));
BroadcastClientMessage m = new BroadcastClientMessage(msg.meetingId, "PresentationCursorUpdateCommand", message);
service.sendMessage(m);
}
}
use of org.bigbluebutton.red5.client.messaging.BroadcastClientMessage in project bigbluebutton by bigbluebutton.
the class PresentationClientMessageSender method processPresentationPageGeneratedReply.
private void processPresentationPageGeneratedReply(String json) {
PresentationPageGeneratedReplyMessage msg = PresentationPageGeneratedReplyMessage.fromJson(json);
if (msg != null) {
Map<String, Object> args = new HashMap<String, Object>();
args.put("presentationID", msg.presentationId);
args.put("meetingID", msg.meetingId);
args.put("code", msg.code);
args.put("messageKey", msg.messageKey);
args.put("presentationName", msg.presentationName);
args.put("pagesCompleted", msg.pagesCompleted);
args.put("numberOfPages", msg.numPages);
Map<String, Object> message = new HashMap<String, Object>();
Gson gson = new Gson();
message.put("msg", gson.toJson(args));
BroadcastClientMessage m = new BroadcastClientMessage(msg.meetingId, "generatedSlideUpdateMessageCallback", message);
service.sendMessage(m);
}
}
use of org.bigbluebutton.red5.client.messaging.BroadcastClientMessage in project bigbluebutton by bigbluebutton.
the class PresentationClientMessageSender method processPresentationPageResized.
private void processPresentationPageResized(String json) {
PresentationPageResizedMessage msg = PresentationPageResizedMessage.fromJson(json);
if (msg != null) {
Map<String, Object> args = new HashMap<String, Object>();
args.put("id", msg.page.get("id"));
args.put("num", msg.page.get("num"));
args.put("current", msg.page.get("current"));
args.put("swfUri", msg.page.get("swf_uri"));
args.put("txtUri", msg.page.get("txt_uri"));
args.put("svgUri", msg.page.get("svg_uri"));
args.put("thumbUri", msg.page.get("thumb_uri"));
args.put("xOffset", msg.page.get("x_offset"));
args.put("yOffset", msg.page.get("y_offset"));
args.put("widthRatio", msg.page.get("width_ratio"));
args.put("heightRatio", msg.page.get("height_ratio"));
Map<String, Object> message = new HashMap<String, Object>();
Gson gson = new Gson();
message.put("msg", gson.toJson(args));
BroadcastClientMessage m = new BroadcastClientMessage(msg.meetingId, "moveCallback", message);
service.sendMessage(m);
}
}
use of org.bigbluebutton.red5.client.messaging.BroadcastClientMessage in project bigbluebutton by bigbluebutton.
the class PresentationClientMessageSender method processGoToSlideMessage.
private void processGoToSlideMessage(String json) {
GoToSlideReplyMessage msg = GoToSlideReplyMessage.fromJson(json);
if (msg != null) {
Map<String, Object> args = new HashMap<String, Object>();
args.put("id", msg.page.get(Constants.ID));
args.put("widthRatio", msg.page.get(Constants.WIDTH_RATIO));
args.put("yOffset", msg.page.get(Constants.Y_OFFSET));
args.put("xOffset", msg.page.get(Constants.X_OFFSET));
args.put("num", msg.page.get("num"));
args.put("heightRatio", msg.page.get(Constants.HEIGHT_RATIO));
args.put("svgUri", msg.page.get("svg_uri"));
args.put("thumbUri", msg.page.get("thumb_uri"));
args.put(Constants.CURRENT, msg.page.get(Constants.CURRENT));
args.put("txtUri", msg.page.get("txt_uri"));
args.put("swfUri", msg.page.get("swf_uri"));
Map<String, Object> message = new HashMap<String, Object>();
Gson gson = new Gson();
message.put("msg", gson.toJson(args));
BroadcastClientMessage m = new BroadcastClientMessage(msg.meetingId, "goToSlideCallback", message);
service.sendMessage(m);
}
}
use of org.bigbluebutton.red5.client.messaging.BroadcastClientMessage in project bigbluebutton by bigbluebutton.
the class PresentationClientMessageSender method processPresentationSharedMessage.
private void processPresentationSharedMessage(String json) {
PresentationSharedMessage msg = PresentationSharedMessage.fromJson(json);
if (msg != null) {
Map<String, Object> presentation = new HashMap<String, Object>();
presentation.put("id", msg.presentation.get("id"));
presentation.put("name", msg.presentation.get("name"));
presentation.put("current", msg.presentation.get("current"));
presentation.put("pages", msg.presentation.get("pages"));
Map<String, Object> args = new HashMap<String, Object>();
args.put("presentation", presentation);
Map<String, Object> message = new HashMap<String, Object>();
Gson gson = new Gson();
message.put("msg", gson.toJson(args));
BroadcastClientMessage m = new BroadcastClientMessage(msg.meetingId, "sharePresentationCallback", message);
service.sendMessage(m);
}
}
Aggregations