using System.Web;
using CMS.CMSHelper;
using CMS.GlobalHelper;
using CMS.PortalControls;
using CMS.PortalEngine;
using CMS.SettingsProvider;
public partial class CMSWebParts_Media_QuickTime : CMSAbstractWebPart
{
#region "Public properties"
///
/// Gets or sets the value that indicates whether video is automatically activated.
///
public bool AutoActivation
{
get
{
return ValidationHelper.GetBoolean(GetValue("AutoActivation"), false);
}
set
{
SetValue("AutoActivation", value);
}
}
///
/// Gets or sets the URL of video to be displayed.
///
public string VideoURL
{
get
{
return ValidationHelper.GetString(GetValue("VideoURL"), "");
}
set
{
SetValue("VideoURL", value);
}
}
///
/// Gets or sets the width of video.
///
public int Width
{
get
{
return ValidationHelper.GetInteger(GetValue("Width"), 400);
}
set
{
SetValue("Width", value);
}
}
///
/// Gets or sets the height of video.
///
public int Height
{
get
{
return ValidationHelper.GetInteger(GetValue("Height"), 300);
}
set
{
SetValue("Height", value);
}
}
///
/// Gets or sets the value that indicates whether the video is automatically started.
///
public bool Autostart
{
get
{
return ValidationHelper.GetBoolean(GetValue("Autostart"), false);
}
set
{
SetValue("Autostart", value);
}
}
///
/// Gets or sets the value that indicates whether video controller is displayed.
///
public bool ShowControls
{
get
{
return ValidationHelper.GetBoolean(GetValue("ShowControls"), true);
}
set
{
SetValue("ShowControls", value);
}
}
///
/// Gets or sets the value that indicates whether video after the end is automatically started again.
///
public bool Loop
{
get
{
return ValidationHelper.GetBoolean(GetValue("Loop"), false);
}
set
{
SetValue("Loop", value);
}
}
#endregion
#region "Methods"
///
/// Content loaded event handler.
///
public override void OnContentLoaded()
{
base.OnContentLoaded();
SetupControl();
}
///
/// Reloads data.
///
public override void ReloadData()
{
base.ReloadData();
SetupControl();
}
///
/// Initializes the control properties.
///
protected void SetupControl()
{
if (StopProcessing)
{
// Do nothing
}
else
{
if (CMSContext.ViewMode == ViewModeEnum.Design)
{
ltlPlaceholder.Text = "