Merge remote-tracking branch 'mconf/mconf-live0.7.5' into merging-to-1.0

Conflicts:
	bbb-video/build.gradle
	bbb-voice/build.gradle
	bigbluebutton-apps/build.gradle
	bigbluebutton-apps/src/main/scala/org/bigbluebutton/freeswitch/FreeswitchConferenceActor.scala
	bigbluebutton-client/branding/default/style/css/BBBDefault.css
	bigbluebutton-client/build.xml
	bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatBox.mxml
	bigbluebutton-client/src/org/bigbluebutton/modules/present/ui/views/PresentationWindow.mxml
	bigbluebutton-web/src/groovy/org/bigbluebutton/api/RecordingServiceHelperImp.groovy
	bigbluebutton-web/src/java/org/bigbluebutton/api/MeetingService.java
	bigbluebutton-web/src/java/org/bigbluebutton/api/RecordingService.java
	bigbluebutton-web/src/java/org/bigbluebutton/api/messaging/MessagingService.java
	bigbluebutton-web/src/java/org/bigbluebutton/api/messaging/RedisMessagingService.java
	deskshare/app/build.gradle
	deskshare/build.gradle
This commit is contained in:
Pedro Beschorner Marin 2016-06-20 15:34:59 +00:00
commit e47cd67903
41 changed files with 266 additions and 68 deletions

View File

@ -51,6 +51,8 @@ public class MessagingConstants {
public static final String FROM_VOICE_CONF_CHANNEL = "bigbluebutton:from-voice-conf";
public static final String FROM_VOICE_CONF_PATTERN = FROM_VOICE_CONF_CHANNEL + ":*";
public static final String FROM_VOICE_CONF_SYSTEM_CHAN = FROM_VOICE_CONF_CHANNEL + ":system";
public static final String FROM_BBB_RECORDING_CHANNEL = "bigbluebutton:from-rap";
public static final String DESTROY_MEETING_REQUEST_EVENT = "DestroyMeetingRequestEvent";
public static final String CREATE_MEETING_REQUEST_EVENT = "CreateMeetingRequestEvent";

View File

@ -139,10 +139,10 @@ public class CallAgent extends CallListenerAdapter implements CallStreamObserver
}
private void setupCallerDisplayName(String callerName, String destination) {
String fromURL = "\"" + callerName + "\" <sip:" + destination + "@" + portProvider.getHost() + ">";
String fromURL = "\"" + callerName + "\" <sip:" + destination + "@" + clientRtpIp + ">";
userProfile.username = callerName;
userProfile.fromUrl = fromURL;
userProfile.contactUrl = "sip:" + destination + "@" + sipProvider.getViaAddress();
userProfile.contactUrl = "sip:" + destination + "@" + clientRtpIp;
if (sipProvider.getPort() != SipStack.default_port) {
userProfile.contactUrl += ":" + sipProvider.getPort();
}

View File

@ -98,17 +98,7 @@ public abstract class CallListenerAdapter implements ExtendedCallListener
{
//printLog("RE-INVITE/MODIFY");
String local_session;
if (sdp!=null && sdp.length()>0)
{
SessionDescriptor remote_sdp = new SessionDescriptor(sdp);
SessionDescriptor local_sdp = new SessionDescriptor(call.getLocalSessionDescriptor());
SessionDescriptor new_sdp = new SessionDescriptor(remote_sdp.getOrigin(),remote_sdp.getSessionName(),local_sdp.getConnection(),local_sdp.getTime());
new_sdp.addMediaDescriptors(local_sdp.getMediaDescriptors());
new_sdp = SdpTools.sdpMediaProduct(new_sdp,remote_sdp.getMediaDescriptors());
new_sdp = SdpTools.sdpAttirbuteSelection(new_sdp,"rtpmap");
local_session = new_sdp.toString();
}
else local_session=call.getLocalSessionDescriptor();
local_session=call.getLocalSessionDescriptor();
// accept immediatly
call.accept(local_session);
}
@ -218,4 +208,3 @@ public abstract class CallListenerAdapter implements ExtendedCallListener
}
}

View File

@ -31,6 +31,8 @@ import org.zoolu.sip.header.*;
import org.zoolu.sip.provider.*;
import org.zoolu.tools.LogLevel;
import org.slf4j.Logger;
import org.red5.logging.Red5LoggerFactory;
/** Class InviteDialog can be used to manage invite dialogs.
* An InviteDialog can be both client or server.
@ -82,6 +84,8 @@ public class InviteDialog extends Dialog implements TransactionClientListener, I
protected static final int D_BYED=8;
protected static final int D_CLOSE=9;
private static Logger logger = Red5LoggerFactory.getLogger(InviteDialog.class, "sip");
/** Gets the dialog state */
protected String getStatus()
{ switch (status)
@ -381,6 +385,7 @@ public class InviteDialog extends Dialog implements TransactionClientListener, I
* This method should be called when the InviteDialog is in D_INVITED or D_ReINVITED state */
public void accept(String contact, String sdp)
{ printLog("inside accept(sdp)",LogLevel.MEDIUM);
logger.debug("Accepting REINVITE. Responding OK with this sdp: " + sdp);
respond(200,SipResponses.reasonOf(200),contact,sdp);
}
@ -483,6 +488,7 @@ public class InviteDialog extends Dialog implements TransactionClientListener, I
*/
public void onReceivedMessage(SipProvider sip_provider, Message msg)
{ printLog("inside onReceivedMessage(sip_provider,message)",LogLevel.MEDIUM);
logger.debug("Received this message: " + msg.toString());
if (msg.isRequest() && !(msg.isAck() || msg.isCancel()) && msg.getCSeqHeader().getSequenceNumber()<=getRemoteCSeq())
{ printLog("Request message is too late (CSeq too small): Message discarded",LogLevel.HIGH);
return;

View File

@ -41,7 +41,10 @@ config.hooks.events or= [
{ channel: "bigbluebutton:from-rap", name: "publish_started" },
{ channel: "bigbluebutton:from-rap", name: "publish_ended" },
{ channel: "bigbluebutton:from-rap", name: "post_publish_started" },
{ channel: "bigbluebutton:from-rap", name: "post_publish_ended" }
{ channel: "bigbluebutton:from-rap", name: "post_publish_ended" },
{ channel: "bigbluebutton:from-rap", name: "unpublished" },
{ channel: "bigbluebutton:from-rap", name: "published" },
{ channel: "bigbluebutton:from-rap", name: "deleted" }
]
# Retry intervals for failed attempts for perform callback calls.

View File

@ -44,10 +44,10 @@ ToolTip {
cornerRadius: 5;
borderStyle: solid;
borderThickness: 1;
paddingBottom: 3;
paddingTop: 3;
paddingLeft: 3;
paddingRight: 3;
paddingBottom: 2;
paddingTop: 2;
paddingLeft: 2;
paddingRight: 2;
}
.meetingNameLabelStyle {
@ -305,7 +305,7 @@ DataGrid {
.presentationUploadButtonStyle, .pollStartButtonStyle, .presentationBackButtonStyle, .presentationBackButtonDisabledStyle, .presentationForwardButtonStyle, .presentationForwardButtonDisabledStyle,
.presentationFitToWidthButtonStyle, .presentationFitToPageButtonStyle, .presentationDownloadButtonStyle,
.presentationFitToWidthButtonStyle, .presentationFitToPageButtonStyle, .presentationDownloadButtonStyle, .presentationDownloadButtonDisabledStyle,
.sharedNotesSaveButtonStyle, .sharedNotesNewButtonStyle, .sharedNotesFormatButtonStyle
{
textIndent: 0;
@ -325,7 +325,7 @@ DataGrid {
fontSize: 12;
}
.sharedNotesSaveButtonStyle {
.sharedNotesSaveButtonStyle, .chatSaveButtonStyle {
icon: Embed('assets/images/ic_save_16px.png');
}
@ -373,6 +373,10 @@ DataGrid {
icon: Embed('assets/images/ic_file_download_16px.png');
}
.presentationDownloadButtonDisabledStyle {
icon: Embed('assets/images/ic_file_download_grey_16px.png');
}
.presentationZoomSliderStyle{
labelOffset: 0;
thumbOffset: 3;
@ -1022,3 +1026,7 @@ EmojiGrid {
.moodSadStyle {
icon: Embed('assets/images/icon-7-sad-face.png');
}
.chatCopyButtonStyle{
icon: Embed('assets/images/ic_content_copy_black_16px.png');
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 257 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 251 B

View File

@ -278,15 +278,11 @@
<build-module src="${SRC_DIR}" target="${USERS}" />
</target>
<target name="build-sharednotes" description="Compile SharedNotes Module">
<build-module src="${SRC_DIR}" target="${SHAREDNOTES}" />
<echo message="Copying assets for SharedNotesModule" />
<copy todir="${OUTPUT_DIR}/org/bigbluebutton/modules/sharednotes/views/images/" >
<fileset dir="${BASE_DIR}/src/org/bigbluebutton/modules/sharednotes/views/images/" />
<target name="build-sharednotes" description="Compile SharedNotes Module">
<build-module src="${SRC_DIR}" target="${SHAREDNOTES}" />
<copy file="${BASE_DIR}/src/org/bigbluebutton/modules/sharednotes/util/shared_notes.js" todir="${OUTPUT_DIR}/lib/">
</copy>
<copy file="${BASE_DIR}/src/org/bigbluebutton/modules/sharednotes/util/shared_notes.js" todir="${OUTPUT_DIR}/lib/" />
</target>
</target>
<!-- just a grouping of modules to compile -->
<target name="build-main-chat-present"

View File

@ -215,6 +215,7 @@ bbb.presentation.fitToWidth.toolTip = Fit Presentation To Width
bbb.presentation.fitToPage.toolTip = Fit Presentation To Page
bbb.presentation.uploadPresBtn.toolTip = Upload Presentation
bbb.presentation.downloadPresBtn.toolTip = Download Presentations
bbb.presentation.downloadPresBtn.disabledToolTip = No presentations available for download
bbb.presentation.backBtn.toolTip = Previous slide
bbb.presentation.btnSlideNum.accessibilityName = Slide {0} of {1}
bbb.presentation.btnSlideNum.toolTip = Select a slide

View File

@ -213,6 +213,7 @@ bbb.presentation.fitToWidth.toolTip = Ajustar apresentação à largura
bbb.presentation.fitToPage.toolTip = Ajustar apresentação à página
bbb.presentation.uploadPresBtn.toolTip = Carregar apresentação
bbb.presentation.downloadPresBtn.toolTip = Baixar apresentação
bbb.presentation.downloadPresBtn.disabledToolTip = Nenhuma apresentação disponível para download
bbb.presentation.backBtn.toolTip = Slide anterior
bbb.presentation.btnSlideNum.accessibilityName = Slide {0} de {1}
bbb.presentation.btnSlideNum.toolTip = Selecionar um slide

View File

@ -9,7 +9,7 @@
<application uri="rtmp://HOST/bigbluebutton" host="http://HOST/bigbluebutton/api/enter"/>
<language userSelectionEnabled="true" />
<skinning enabled="true" url="http://HOST/client/branding/css/BBBDefault.css.swf?v=VERSION" />
<branding logo="logo.png" copyright="&#169; 2016 &lt;u&gt;&lt;a href=&quot;http://www.mconf.org&quot; target=&quot;_blank&quot;&gt;http://www.mconf.org&lt;/a&gt;&lt;/u&gt;" background="" />
<branding logo="logo.png" copyright="&#169; 2016 &lt;u&gt;&lt;a href=&quot;http://www.mconf.org&quot; target=&quot;_blank&quot;&gt;http://www.mconf.org&lt;/a&gt;&lt;/u&gt;" background="" toolbarColor="" toolbarColorAlphas="" />
<shortcutKeys showButton="true" />
<browserVersions chrome="CHROME_VERSION" firefox="FIREFOX_VERSION" flash="FLASH_VERSION" java="1.7.0_51" />
<layout showLogButton="false" defaultLayout="bbb.layout.name.defaultlayout"

View File

@ -33,6 +33,8 @@ package org.bigbluebutton.core.vo {
private var _copyright:String;
private var _logo:String;
private var _background:String;
private var _toolbarColor:String;
private var _toolbarColorAlphas:String;
public function Config(builder:ConfigBuilder) {
_version = builder.version;
@ -50,6 +52,8 @@ package org.bigbluebutton.core.vo {
_copyright = builder.copyright;
_logo = builder.logo;
_background = builder.background;
_toolbarColor = builder.toolbarColor;
_toolbarColorAlphas = builder.toolbarColorAlphas;
}
public function get version():String {
@ -108,8 +112,12 @@ package org.bigbluebutton.core.vo {
return _logo;
}
public function get background():String {
return _background;
public function get toolbarColor():String {
return _toolbarColor;
}
public function get toolbarColorAlphas():String {
return _toolbarColorAlphas;
}
}
}
}

View File

@ -33,6 +33,8 @@ package org.bigbluebutton.core.vo {
internal var copyright:String;
internal var logo:String;
internal var background:String;
internal var toolbarColor:String;
internal var toolbarColorAlphas:String;
public function ConfigBuilder(version:String, localVersion:String){
this.version = version;
@ -103,9 +105,19 @@ package org.bigbluebutton.core.vo {
this.background = background;
return this;
}
public function withToolbarColor(toolbarColor:String):ConfigBuilder {
this.toolbarColor = toolbarColor;
return this;
}
public function withToolbarColorAlphas(toolbarColorAlphas:String):ConfigBuilder {
this.toolbarColorAlphas = toolbarColorAlphas;
return this;
}
public function build():Config {
return new Config(this);
}
}
}
}

View File

@ -58,6 +58,8 @@ package org.bigbluebutton.main.model
public var copyright:String = "";
public var logo:String = "";
public var background:String = "";
public var toolbarColor:String = "";
public var toolbarColorAlphas:String = "";
private var loadedListener:Function;
private var dispatcher:Dispatcher = new Dispatcher();
@ -116,6 +118,8 @@ package org.bigbluebutton.main.model
copyright = xml.branding.@copyright;
logo = xml.branding.@logo;
background = xml.branding.@background;
toolbarColor = xml.branding.@toolbarColor;
toolbarColorAlphas = xml.branding.@toolbarColorAlphas;
}
public function getModulesXML():XMLList{
@ -149,4 +153,4 @@ package org.bigbluebutton.main.model
}
}
}
}

View File

@ -184,6 +184,8 @@ package org.bigbluebutton.main.model.modules
.withCopyright(c.copyright)
.withLogo(c.logo)
.withBackground(c.background)
.withToolbarColor(c.toolbarColor)
.withToolbarColorAlphas(c.toolbarColorAlphas)
.build()
event.config = config;
dispatcher.dispatchEvent(event);

View File

@ -357,6 +357,13 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
} else {
logo.source = e.config.logo;
}
if (e.config.toolbarColor != "") {
setStyle("backgroundColor", e.config.toolbarColor);
}
if (e.config.toolbarColorAlphas != "") {
setStyle("highlightAlphas", e.config.toolbarColorAlphas.split(","));
}
}
private function onDisconnectTest():void{

View File

@ -150,7 +150,7 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
private var chatListHeight:Number = 100;
[Bindable]
private var chatToolbarHeight:Number = 50;
private var chatToolbarHeight:Number = 80;
[Bindable] public var chatOptions:ChatOptions = new ChatOptions();
@ -791,9 +791,9 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
const paddingHeight:int = 5;
const paddingWidth:int = 5;
chatToolbar.width = chatMessagesCanvas.width - paddingWidth * 2;
chatToolbar.x = (chatMessagesCanvas.width - chatToolbar.width) / 2;
chatToolbar.y = chatMessagesCanvas.height - chatToolbar.height - paddingHeight;
chatToolbar.width = 45;
chatToolbar.x = (chatMessagesCanvas.width - chatToolbar.width) - 10;
chatToolbar.y = 10;
if(chatMessagesList.mx_internal::scroll_verticalScrollBar != null && chatMessagesList.mx_internal::scroll_verticalScrollBar.visible){
chatToolbar.width -= chatMessagesList.mx_internal::scroll_verticalScrollBar.width;
@ -826,11 +826,14 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
<mx:Label id="msgTooLongLabel" width="100%" height="100%" includeInLayout="false" visible="false"/>
</mx:VBox>
<mx:VBox verticalScrollPolicy="off" verticalAlign="middle" height="100%" >
<mx:Button label="{ResourceUtil.getInstance().getString('bbb.chat.sendBtn')}" id="sendBtn"
<mx:HBox horizontalGap="0">
<mx:Button label="{ResourceUtil.getInstance().getString('bbb.chat.sendBtn')}" id="sendBtn"
styleName="chatControlBarSendButtonStyle"
toolTip="{ResourceUtil.getInstance().getString('bbb.chat.sendBtn.toolTip')}"
click="sendMessages()"
accessibilityName="{ResourceUtil.getInstance().getString('bbb.chat.sendBtn.accessibilityName')}"/>
accessibilityName="{ResourceUtil.getInstance().getString('bbb.chat.sendBtn.accessibilityName')}"
height="100%"/>
</mx:HBox>
<mx:ColorPicker id="cmpColorPicker" showTextField="false" width="100%" visible="{chatOptions.colorPickerIsVisible}" includeInLayout="{chatOptions.colorPickerIsVisible}"
toolTip="{ResourceUtil.getInstance().getString('bbb.chat.cmpColorPicker.toolTip')}"
selectedColor="0x000000" dataProvider="{colorPickerColours}" swatchPanelStyleName="chatColorPickerStyle"/>

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<mx:HBox xmlns="flexlib.containers.*"
<mx:VBox xmlns="flexlib.containers.*"
initialize="init()"
xmlns:mx="http://www.adobe.com/2006/mxml"
xmlns:mate="http://mate.asfusion.com/"
@ -8,7 +8,8 @@
visible="{toolbarVisible}"
styleName="whiteboardToolbarStyle"
horizontalAlign="center"
hideEffect="{fadeOut}" showEffect="{fadeIn}" >
hideEffect="{fadeOut}" showEffect="{fadeIn}"
backgroundColor="{bgColor}">
<mx:Script>
<![CDATA[
@ -23,6 +24,7 @@
[Bindable] public var chatOptions:ChatOptions;
[Bindable] private var baseIndex:int;
[Bindable] private var toolbarVisible:Boolean = false;
[Bindable] private var bgColor:Number = 0xCCCCCC;
private var mousedOver:Boolean = false;
private var globalDispatcher:Dispatcher;
@ -88,18 +90,22 @@
<mx:Fade id="fadeOut" duration="200" alphaFrom="1.0" alphaTo="0.0" />
<mx:Fade id="fadeIn" duration="200" alphaFrom="0.0" alphaTo="1.0" />
<mx:Button id="saveBtn" label="{ResourceUtil.getInstance().getString('bbb.chat.saveBtn.label')}"
styleName="chatToolbarSaveButtonStyle"
<mx:Button id="saveBtn"
styleName="chatSaveButtonStyle"
width="22"
height="22"
toolTip="{ResourceUtil.getInstance().getString('bbb.chat.saveBtn.toolTip')}"
click="sendSaveEvent()"
tabIndex="{baseIndex+1}"
accessibilityName="{ResourceUtil.getInstance().getString('bbb.chat.copyBtn.accessibilityName')}"/>
<mx:Button id="copyBtn" label="{ResourceUtil.getInstance().getString('bbb.chat.copyBtn.label')}"
styleName="chatToolbarCopyButtonStyle"
<mx:Button id="copyBtn"
styleName="chatCopyButtonStyle"
width="22"
height="22"
toolTip="{ResourceUtil.getInstance().getString('bbb.chat.copyBtn.toolTip')}"
click="sendCopyEvent()"
tabIndex="{baseIndex+2}"
accessibilityName="{ResourceUtil.getInstance().getString('bbb.chat.copyBtn.accessibilityName')}"/>
</mx:HBox>
</mx:VBox>

View File

@ -60,8 +60,8 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
]]>
</mx:Script>
<mx:HBox width="100%" height="100%">
<mx:TextInput id="textInput" restrict="a-zA-Z0-9 " maxChars="32" width="100%" text="{ResourceUtil.getInstance().getString('bbb.layout.combo.customName')}"/>
<mx:HBox width="100%" height="100%" horizontalAlign="center" verticalAlign="middle">
<mx:TextInput id="textInput" maxChars="140" width="100%" text="{ResourceUtil.getInstance().getString('bbb.layout.combo.customName')}" enter="addButton_clickHandler()"/>
<mx:Button id="addButton" click="addButton_clickHandler()" enabled="{textInput.text.length > 0}" styleName="addLayoutButtonStyle" toolTip="{ResourceUtil.getInstance().getString('bbb.layout.addButton.toolTip')}"/>
</mx:HBox>
</mx:TitleWindow>

View File

@ -24,7 +24,7 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
prompt="{ResourceUtil.getInstance().getString('bbb.layout.combo.prompt')}"
height="{LayoutButton.BUTTON_SIZE}" creationComplete="init()"
change="onSelectedItemChanged(event)"
disabledColor="{getStyle('color')}" rowCount="10"
disabledColor="{getStyle('color')}" rowCount="10" width="240"
styleName="languageSelectorStyle" >
<mate:Listener type="{SwitchedLayoutEvent.SWITCHED_LAYOUT_EVENT}" method="onLayoutChanged" />

View File

@ -27,6 +27,9 @@ package org.bigbluebutton.modules.present.events
// Presentation has been removed from server.
public static const PRESENTATION_REMOVED_EVENT:String = "Presentation Removed Event";
// Presentation removed from the list of downloadable events.
public static const UPDATE_DOWNLOADABLE_FILES_EVENT:String = "Update Downloadable Files Event";
public var presentationName:String;

View File

@ -168,6 +168,8 @@ package org.bigbluebutton.modules.present.services
}
model.removePresentation(presentationID);
var updateEvent:RemovePresentationEvent = new RemovePresentationEvent(RemovePresentationEvent.UPDATE_DOWNLOADABLE_FILES_EVENT);
dispatcher.dispatchEvent(updateEvent); // this event will trigger the disabling of the download button.
}
}
}

View File

@ -15,7 +15,7 @@
}
]]>
</mx:Script>
<mx:Label id="presentationNameLabel" text="{data.name as String}" styleName="presentationNameLabelStyle" width="80%"/>
<mx:Label id="presentationNameLabel" width="{this.width-downloadBtn.width-30}" text="{data.name as String}" toolTip="{data.name as String}" styleName="presentationNameLabelStyle" truncateToFit="true"/>
<mx:Button id="downloadBtn" label="{ResourceUtil.getInstance().getString('bbb.filedownload.downloadBtn')}"
toolTip="{ResourceUtil.getInstance().getString('bbb.filedownload.downloadBtn')}"
styleName="presentationUploadShowButtonStyle"

View File

@ -61,6 +61,7 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
<mate:Listener type="{ShortcutEvent.FIT_TO_PAGE}" method="remotePage" />
<mate:Listener type="{ShortcutEvent.MINIMIZE_PRES}" method="remoteMinimize" />
<mate:Listener type="{ShortcutEvent.MAXIMIZE_PRES}" method="remoteMaximize" />
<mate:Listener type="{RemovePresentationEvent.UPDATE_DOWNLOADABLE_FILES_EVENT}" method="handleUpdateDownloadableFilesEvent" />
<mate:Listener type="{PollStartedEvent.POLL_STARTED}" method="pollStartedHandler" />
<mate:Listener type="{PollStoppedEvent.POLL_STOPPED}" method="pollStoppedHandler" />
<mate:Listener type="{PollShowResultEvent.SHOW_RESULT}" method="pollShowResultHandler" />
@ -69,6 +70,7 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
<![CDATA[
import flash.geom.Point;
import mx.collections.ArrayCollection;
import mx.controls.Menu;
import mx.events.MenuEvent;
import mx.events.ResizeEvent;
@ -100,6 +102,7 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
import org.bigbluebutton.modules.present.events.NavigationEvent;
import org.bigbluebutton.modules.present.events.PresentationChangedEvent;
import org.bigbluebutton.modules.present.events.PresenterCommands;
import org.bigbluebutton.modules.present.events.RemovePresentationEvent;
import org.bigbluebutton.modules.present.events.UploadEvent;
import org.bigbluebutton.modules.present.model.Page;
import org.bigbluebutton.modules.present.model.PresentationModel;
@ -394,6 +397,7 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
displaySlideNavigationControls(false, !!page)
}
onResetZoom();
updateDownloadBtn();
}
@ -521,7 +525,8 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
Accessibility.updateProperties();
addContextMenuItems();
updateDownloadBtnTooltip();
setPollMenuData();
}
@ -783,6 +788,36 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
setControlBarState("presenter");
}
private function handleUpdateDownloadableFilesEvent(e:RemovePresentationEvent):void {
updateDownloadBtn();
}
private function updateDownloadBtn():void {
if (downloadPres == null) {
return;
}
var isAnyPres:ArrayCollection = PresentationModel.getInstance().getDownloadablePresentations();
if (isAnyPres.length > 0) {
LOGGER.debug("Enabling dowload presentation button. There are {0} presentations available for downloading.", [isAnyPres.length]);
downloadPres.enabled = true;
downloadPres.styleName = "presentationDownloadButtonStyle";
} else {
LOGGER.debug("Disabling download presentation button. There are {0} presentations available for downloading.", [isAnyPres.length]);
downloadPres.enabled = false;
downloadPres.styleName = "presentationDownloadButtonDisabledStyle";
}
updateDownloadBtnTooltip();
}
private function updateDownloadBtnTooltip():void {
if (downloadPres == null) {
return;
}
const res:String = downloadPres.enabled? "bbb.presentation.downloadPresBtn.toolTip": "bbb.presentation.downloadPresBtn.disabledToolTip";
downloadPres.toolTip = ResourceUtil.getInstance().getString(res);
}
]]>
</mx:Script>
@ -797,10 +832,9 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
<mx:ControlBar id="presCtrlBar" name="presCtrlBar" width="100%" verticalAlign="middle" styleName="presentationWindowControlsStyle"
paddingTop="2" paddingBottom="2">
<mx:HBox id="presenterControls" width="100%" height="100%" horizontalAlign="center">
<mx:Button id="downloadPres" visible="true" height="30" styleName="presentationDownloadButtonStyle"
toolTip="{ResourceUtil.getInstance().getString('bbb.presentation.downloadPresBtn.toolTip')}"
click="onDownloadButtonClicked()"/>
<mx:Button id="uploadPres" visible="false" height="30" styleName="presentationUploadButtonStyle"
<mx:Button id="downloadPres" visible="true" height="30" width="30"
click="onDownloadButtonClicked()" creationComplete="updateDownloadBtn()"/>
<mx:Button id="uploadPres" visible="false" height="30" width="30" styleName="presentationUploadButtonStyle"
toolTip="{ResourceUtil.getInstance().getString('bbb.presentation.uploadPresBtn.toolTip')}"
click="onUploadButtonClicked()"/>
<mx:Button id="pollStartBtn" visible="false" height="30" styleName="pollStartButtonStyle"

Binary file not shown.

Before

Width:  |  Height:  |  Size: 248 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 345 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 620 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 731 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 860 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 537 B

View File

@ -52,7 +52,7 @@ dependencies {
compile 'commons-httpclient:commons-httpclient:3.1'
compile 'com.zaxxer:nuprocess:1.0.4'
compile 'org.bigbluebutton:bbb-common-message:0.0.13'
compile 'org.bigbluebutton:bbb-common-message:0.0.16'
// Logging
// Commenting out as it results in build failure (ralam - may 11, 2014)

View File

@ -99,6 +99,12 @@ public class RecordingServiceHelperImp implements RecordingServiceHelper {
xmlEventFile.write writer.toString()
}
public Recording getRecordingInfo(String id, String recordingDir, String playbackFormat) {
String path = recordingDir + File.separatorChar + playbackFormat + File.separatorChar + id;
File dir = new File(path);
return getRecordingInfo(dir);
}
public Recording getRecordingInfo(File dir) {
if (dir.isDirectory()) {
try {

View File

@ -438,17 +438,24 @@ public class MeetingService implements MessageListener {
public void setPublishRecording(List<String> idList, boolean publish) {
for (String id : idList) {
boolean success = false;
if (publish) {
recordingService.changeState(id, Recording.STATE_PUBLISHED);
success = recordingService.changeState(id, Recording.STATE_PUBLISHED);
} else {
recordingService.changeState(id, Recording.STATE_UNPUBLISHED);
success = recordingService.changeState(id, Recording.STATE_UNPUBLISHED);
}
if (success) {
messagingService.publishRecording(id, publish);
}
}
}
public void deleteRecordings(ArrayList<String> idList) {
for (String id : idList) {
recordingService.changeState(id, Recording.STATE_DELETED);
boolean success = recordingService.changeState(id, Recording.STATE_DELETED);
if (success) {
messagingService.deleteRecording(id);
}
}
}

View File

@ -291,22 +291,25 @@ public class RecordingService {
return r;
}
public void changeState(String recordingId, String state) {
public boolean changeState(String recordingId, String state) {
boolean anyResult = false;
if (state.equals(Recording.STATE_PUBLISHED)) {
// It can only be published if it is unpublished
changeState(unpublishedDir, recordingId, state);
anyResult |= changeState(unpublishedDir, recordingId, state);
} else if (state.equals(Recording.STATE_UNPUBLISHED)) {
// It can only be unpublished if it is published
changeState(publishedDir, recordingId, state);
anyResult |= changeState(publishedDir, recordingId, state);
} else if (state.equals(Recording.STATE_DELETED)) {
// It can be deleted from any state
changeState(publishedDir, recordingId, state);
changeState(unpublishedDir, recordingId, state);
anyResult |= changeState(publishedDir, recordingId, state);
anyResult |= changeState(unpublishedDir, recordingId, state);
}
return anyResult;
}
private void changeState(String path, String recordingId, String state) {
private boolean changeState(String path, String recordingId, String state) {
String[] format = getPlaybackFormats(path);
boolean anyResult = false;
for (int i = 0; i < format.length; i++) {
List<File> recordings = getDirectories(path + File.separatorChar + format[i]);
for (int f = 0; f < recordings.size(); f++) {
@ -322,7 +325,7 @@ public class RecordingService {
dest = new File(deletedDir + File.separatorChar + format[i]);
} else {
log.debug(String.format("State: %s, is not supported", state));
return;
return anyResult;
}
if (!dest.exists())
dest.mkdirs();
@ -340,10 +343,12 @@ public class RecordingService {
} else {
log.debug("Recording was not moved");
}
anyResult |= moved;
}
}
}
}
return anyResult;
}
private List<File> getAllDirectories(String state) {

View File

@ -7,6 +7,9 @@ import org.bigbluebutton.api.messaging.converters.messages.DestroyMeetingMessage
import org.bigbluebutton.api.messaging.converters.messages.EndMeetingMessage;
import org.bigbluebutton.api.messaging.converters.messages.KeepAliveMessage;
import org.bigbluebutton.api.messaging.converters.messages.RegisterUserMessage;
import org.bigbluebutton.api.messaging.converters.messages.PublishRecordingMessage;
import org.bigbluebutton.api.messaging.converters.messages.UnpublishRecordingMessage;
import org.bigbluebutton.api.messaging.converters.messages.DeleteRecordingMessage;
public class MessageToJson {
@ -68,5 +71,28 @@ public class MessageToJson {
return MessageBuilder.buildJson(header, payload);
}
public static String publishRecordingMessageToJson(PublishRecordingMessage message) {
HashMap<String, Object> payload = new HashMap<String, Object>();
payload.put(Constants.MEETING_ID, message.meetingId);
java.util.HashMap<String, Object> header = MessageBuilder.buildHeader(PublishRecordingMessage.PUBLISH_RECORDING, PublishRecordingMessage.VERSION, null);
return MessageBuilder.buildJson(header, payload);
}
public static String unpublishRecordingMessageToJson(UnpublishRecordingMessage message) {
HashMap<String, Object> payload = new HashMap<String, Object>();
payload.put(Constants.MEETING_ID, message.meetingId);
java.util.HashMap<String, Object> header = MessageBuilder.buildHeader(UnpublishRecordingMessage.UNPUBLISH_RECORDING, UnpublishRecordingMessage.VERSION, null);
return MessageBuilder.buildJson(header, payload);
}
public static String deleteRecordingMessageToJson(DeleteRecordingMessage message) {
HashMap<String, Object> payload = new HashMap<String, Object>();
payload.put(Constants.MEETING_ID, message.meetingId);
java.util.HashMap<String, Object> header = MessageBuilder.buildHeader(DeleteRecordingMessage.DELETE_RECORDING, DeleteRecordingMessage.VERSION, null);
return MessageBuilder.buildJson(header, payload);
}
}

View File

@ -34,4 +34,6 @@ public interface MessagingService {
void sendPolls(String meetingId, String title, String question, String questionType, List<String> answers);
void registerUser(String meetingID, String internalUserId, String fullname, String role, String externUserID, String authToken, String guest);
void sendKeepAlive(String system, Long timestamp);
void publishRecording(String meetingId, boolean publish);
void deleteRecording(String meetingId);
}

View File

@ -35,6 +35,9 @@ import org.bigbluebutton.api.messaging.converters.messages.DestroyMeetingMessage
import org.bigbluebutton.api.messaging.converters.messages.EndMeetingMessage;
import org.bigbluebutton.api.messaging.converters.messages.KeepAliveMessage;
import org.bigbluebutton.api.messaging.converters.messages.RegisterUserMessage;
import org.bigbluebutton.api.messaging.converters.messages.PublishRecordingMessage;
import org.bigbluebutton.api.messaging.converters.messages.UnpublishRecordingMessage;
import org.bigbluebutton.api.messaging.converters.messages.DeleteRecordingMessage;
import org.bigbluebutton.common.converters.ToJsonEncoder;
import org.bigbluebutton.common.messages.MessageHeader;
import org.bigbluebutton.common.messages.MessagingConstants;
@ -131,4 +134,30 @@ public class RedisMessagingService implements MessagingService {
storeService.removeMeeting(meetingId);
}
private void publishRecording(String meetingId) {
PublishRecordingMessage msg = new PublishRecordingMessage(meetingId);
String json = MessageToJson.publishRecordingMessageToJson(msg);
sender.send(MessagingConstants.FROM_BBB_RECORDING_CHANNEL, json);
}
private void unpublishRecording(String meetingId) {
UnpublishRecordingMessage msg = new UnpublishRecordingMessage(meetingId);
String json = MessageToJson.unpublishRecordingMessageToJson(msg);
sender.send(MessagingConstants.FROM_BBB_RECORDING_CHANNEL, json);
}
public void publishRecording(String meetingId, boolean publish) {
if (publish) {
publishRecording(meetingId);
} else {
unpublishRecording(meetingId);
}
}
public void deleteRecording(String meetingId) {
DeleteRecordingMessage msg = new DeleteRecordingMessage(meetingId);
String json = MessageToJson.deleteRecordingMessageToJson(msg);
sender.send(MessagingConstants.FROM_BBB_RECORDING_CHANNEL, json);
}
}

View File

@ -0,0 +1,12 @@
package org.bigbluebutton.api.messaging.converters.messages;
public class DeleteRecordingMessage {
public static final String DELETE_RECORDING = "deleted";
public static final String VERSION = "0.0.1";
public final String meetingId;
public DeleteRecordingMessage(String meetingId) {
this.meetingId = meetingId;
}
}

View File

@ -0,0 +1,12 @@
package org.bigbluebutton.api.messaging.converters.messages;
public class PublishRecordingMessage {
public static final String PUBLISH_RECORDING = "published";
public static final String VERSION = "0.0.1";
public final String meetingId;
public PublishRecordingMessage(String meetingId) {
this.meetingId = meetingId;
}
}

View File

@ -0,0 +1,12 @@
package org.bigbluebutton.api.messaging.converters.messages;
public class UnpublishRecordingMessage {
public static final String UNPUBLISH_RECORDING = "unpublished";
public static final String VERSION = "0.0.1";
public final String meetingId;
public UnpublishRecordingMessage(String meetingId) {
this.meetingId = meetingId;
}
}