Merge remote branch 'origin/add-pointer-record' into add-more-whiteboard-features
This commit is contained in:
commit
459d486309
@ -32,4 +32,5 @@ public interface IPresentationRoomListener {
|
|||||||
public void resizeAndMoveSlide(Double xOffset, Double yOffset, Double widthRatio, Double heightRatio);
|
public void resizeAndMoveSlide(Double xOffset, Double yOffset, Double widthRatio, Double heightRatio);
|
||||||
public void removePresentation(String name);
|
public void removePresentation(String name);
|
||||||
public void sharePresentation(String presentationName, Boolean share);
|
public void sharePresentation(String presentationName, Boolean share);
|
||||||
|
public void sendCursorUpdate(Double xPercent, Double yPercent);
|
||||||
}
|
}
|
||||||
|
@ -118,6 +118,15 @@ public class PresentationApplication {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void sendCursorUpdate(String room, Double xPercent, Double yPercent) {
|
||||||
|
if (roomsManager.hasRoom(room)){
|
||||||
|
log.debug("Request to update cursor[" + xPercent + "," + yPercent + "]");
|
||||||
|
roomsManager.sendCursorUpdate(room, xPercent, yPercent);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
log.warn("resizeAndMoveSlide on a non-existant room " + room);
|
||||||
|
}
|
||||||
|
|
||||||
public void resizeAndMoveSlide(String room, Double xOffset, Double yOffset, Double widthRatio, Double heightRatio) {
|
public void resizeAndMoveSlide(String room, Double xOffset, Double yOffset, Double widthRatio, Double heightRatio) {
|
||||||
if (roomsManager.hasRoom(room)){
|
if (roomsManager.hasRoom(room)){
|
||||||
log.debug("Request to resize and move slide[" + xOffset + "," + yOffset + "," + widthRatio + "," + heightRatio + "]");
|
log.debug("Request to resize and move slide[" + xOffset + "," + yOffset + "," + widthRatio + "," + heightRatio + "]");
|
||||||
@ -150,4 +159,6 @@ public class PresentationApplication {
|
|||||||
roomsManager = r;
|
roomsManager = r;
|
||||||
log.debug("Done setting room manager");
|
log.debug("Done setting room manager");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -139,6 +139,15 @@ public class PresentationEventSender implements IPresentationRoomListener {
|
|||||||
list.add(share);
|
list.add(share);
|
||||||
so.sendMessage("sharePresentationCallback", list);
|
so.sendMessage("sharePresentationCallback", list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void sendCursorUpdate(Double xPercent, Double yPercent) {
|
||||||
|
log.debug("calling updateCursorCallback[" + xPercent + "," + yPercent + "]");
|
||||||
|
ArrayList list=new ArrayList();
|
||||||
|
list.add(xPercent);
|
||||||
|
list.add(yPercent);
|
||||||
|
so.sendMessage("updateCursorCallback", list);
|
||||||
|
}
|
||||||
|
|
||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
@Override
|
@Override
|
||||||
@ -151,4 +160,6 @@ public class PresentationEventSender implements IPresentationRoomListener {
|
|||||||
list.add(heightRatio);
|
list.add(heightRatio);
|
||||||
so.sendMessage("moveCallback", list);
|
so.sendMessage("moveCallback", list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -47,6 +47,11 @@ public class PresentationRoom {
|
|||||||
Double yOffset = 0D;
|
Double yOffset = 0D;
|
||||||
Double widthRatio = 0D;
|
Double widthRatio = 0D;
|
||||||
Double heightRatio = 0D;
|
Double heightRatio = 0D;
|
||||||
|
|
||||||
|
/* cursor location */
|
||||||
|
Double xPercent = 0D;
|
||||||
|
Double yPercent = 0D;
|
||||||
|
|
||||||
ArrayList<String> presentationNames = new ArrayList<String>();
|
ArrayList<String> presentationNames = new ArrayList<String>();
|
||||||
|
|
||||||
public PresentationRoom(String name) {
|
public PresentationRoom(String name) {
|
||||||
@ -93,6 +98,18 @@ public class PresentationRoom {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void sendCursorUpdate(Double xPercent, Double yPercent) {
|
||||||
|
this.xPercent = xPercent;
|
||||||
|
this.yPercent = yPercent;
|
||||||
|
|
||||||
|
for (Iterator iter = listeners.values().iterator(); iter.hasNext();) {
|
||||||
|
log.debug("calling on listener");
|
||||||
|
IPresentationRoomListener listener = (IPresentationRoomListener) iter.next();
|
||||||
|
log.debug("calling sendCursorUpdate on listener " + listener.getName());
|
||||||
|
listener.sendCursorUpdate(xPercent,yPercent);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public void resizeAndMoveSlide(Double xOffset, Double yOffset, Double widthRatio, Double heightRatio) {
|
public void resizeAndMoveSlide(Double xOffset, Double yOffset, Double widthRatio, Double heightRatio) {
|
||||||
this.xOffset = xOffset;
|
this.xOffset = xOffset;
|
||||||
this.yOffset = yOffset;
|
this.yOffset = yOffset;
|
||||||
@ -192,4 +209,6 @@ public class PresentationRoom {
|
|||||||
public Double getHeightRatio() {
|
public Double getHeightRatio() {
|
||||||
return heightRatio;
|
return heightRatio;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -121,6 +121,16 @@ public class PresentationRoomsManager {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void sendCursorUpdate(String room, Double xPercent, Double yPercent) {
|
||||||
|
PresentationRoom r = getRoom(room);
|
||||||
|
if (r != null){
|
||||||
|
log.debug("Request to update cursor[" + xPercent + "," + yPercent + "]");
|
||||||
|
r.sendCursorUpdate(xPercent, yPercent);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
log.warn("resizeAndMoveSlide on a non-existant room " + room);
|
||||||
|
}
|
||||||
|
|
||||||
public void resizeAndMoveSlide(String room, Double xOffset, Double yOffset, Double widthRatio, Double heightRatio) {
|
public void resizeAndMoveSlide(String room, Double xOffset, Double yOffset, Double widthRatio, Double heightRatio) {
|
||||||
PresentationRoom r = getRoom(room);
|
PresentationRoom r = getRoom(room);
|
||||||
if (r != null){
|
if (r != null){
|
||||||
@ -186,4 +196,5 @@ public class PresentationRoomsManager {
|
|||||||
log.warn("Removing presentation from a non-existing room " + room);
|
log.warn("Removing presentation from a non-existing room " + room);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -100,6 +100,12 @@ public class PresentationService {
|
|||||||
presentationApplication.sharePresentation(scope.getName(), presentationName, share);
|
presentationApplication.sharePresentation(scope.getName(), presentationName, share);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void sendCursorUpdate(Double xPercent,Double yPercent) {
|
||||||
|
log.debug("Request update cursor[" + xPercent + "," + yPercent + "]" );
|
||||||
|
IScope scope = Red5.getConnectionLocal().getScope();
|
||||||
|
presentationApplication.sendCursorUpdate(scope.getName(), xPercent, yPercent);
|
||||||
|
}
|
||||||
|
|
||||||
public void resizeAndMoveSlide(Double xOffset,Double yOffset,Double widthRatio,Double heightRatio) {
|
public void resizeAndMoveSlide(Double xOffset,Double yOffset,Double widthRatio,Double heightRatio) {
|
||||||
log.debug("Request to resize and move slide[" + xOffset + "," + yOffset + "," + widthRatio + "," + heightRatio);
|
log.debug("Request to resize and move slide[" + xOffset + "," + yOffset + "," + widthRatio + "," + heightRatio);
|
||||||
IScope scope = Red5.getConnectionLocal().getScope();
|
IScope scope = Red5.getConnectionLocal().getScope();
|
||||||
|
@ -0,0 +1,18 @@
|
|||||||
|
package org.bigbluebutton.conference.service.recorder.presentation;
|
||||||
|
|
||||||
|
public class CursorUpdateRecordEvent extends AbstractPresentationRecordEvent{
|
||||||
|
|
||||||
|
public CursorUpdateRecordEvent() {
|
||||||
|
super();
|
||||||
|
setEvent("CursorMoveEvent");
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setXPercent(double percent) {
|
||||||
|
eventMap.put("xOffset", Double.toString(percent));
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setYPercent(double percent) {
|
||||||
|
eventMap.put("yOffset", Double.toString(percent));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -113,4 +113,17 @@ public class PresentationEventRecorder implements IPresentationRoomListener {
|
|||||||
recorder.record(session, event);
|
recorder.record(session, event);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void sendCursorUpdate(Double xPercent, Double yPercent) {
|
||||||
|
log.debug("RECORD module:presentation event:CursorMoveEvent");
|
||||||
|
|
||||||
|
CursorUpdateRecordEvent event = new CursorUpdateRecordEvent();
|
||||||
|
event.setMeetingId(session);
|
||||||
|
event.setTimestamp(System.currentTimeMillis());
|
||||||
|
event.setXPercent(xPercent.doubleValue());
|
||||||
|
event.setYPercent(yPercent.doubleValue());
|
||||||
|
|
||||||
|
recorder.record(session, event);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user