Click or drag to resize
MediaSelector Class
Image selection dialog.
Inheritance Hierarchy

Namespace: CMS.Controls
Assembly: CMS.Controls (in CMS.Controls.dll) Version: 9.0.0
Syntax
C#
public class MediaSelector : WebControl, 
	INamingContainer, ICallbackEventHandler, IDialogControl

The MediaSelector type exposes the following members.

Constructors
  NameDescription
Public methodMediaSelector
Constructor.
Public methodMediaSelector(String)
Constructor with default image path.
Public methodMediaSelector(String, Boolean)
Constructor with default image path.
Top
Fields
  NameDescription
Protected fieldmBtnClearPath
Clear path button.
Protected fieldmBtnSelectImage
Select image button.
Protected fieldmHidFullUrl
Hidden Full URL.
Protected fieldmHidValue
Hidden value field.
Protected fieldmLtlScript
Script literal.
Protected fieldmPnlHeader
Header panel.
Protected fieldmPnlImage
Preview image panel.
Protected fieldmPnlSelector
Selector panel.
Protected fieldmPreview
Preview control.
Protected fieldmTxtImagePath
Image path field.
Top
Properties
  NameDescription
Public propertyAutoPostback
Sets textbox autopostback value
Public propertyClearPathButton
Clear path button.
Public propertyCulture
Interface culture of the control.
Public propertyDialogConfig
Configuration of the dialog for inserting Images.
Public propertyEnabled
Enabled.
(Overrides WebControlEnabled.)
Public propertyEnableOpenInFull
Enable open in full size behavior.
Public propertyImageCssClass
CSS class of the image preview.
Public propertyImageHeight
Height of the image preview.
Public propertyImageMaxSideSize
Image max side size.
Public propertyImagePathTextBox
Image path textbox.
Public propertyImageStyle
CSS style of the image preview.
Public propertyImageWidth
Width of the image preview.
Public propertyIsLiveSite
Indicates if control is used in live site mode.
Public propertyPreviewControl
Image preview control.
Public propertySelectImageButton
Button invoking the image selection dialog.
Public propertyShowClearButton
Indicates if the Clear button should be displayed.
Public propertyShowPreview
Indicates if the image preview be displayed.
Public propertyShowTextBox
Indicates if the path textbox should be displayed.
Protected propertyTagKey
Overrides the generation of the SPAN tag with custom tag.
(Overrides WebControlTagKey.)
Public propertyUseCustomDialogConfig
Gets or sets if custom dialog configuration is used.
Public propertyValue
Selector value: URL of the media.
Top
Methods
  NameDescription
Protected methodCreateChildControls
Renders the control at run-time.
(Overrides ControlCreateChildControls.)
Protected methodCreatePreviewControl
Create preview control
Public methodGetCallbackResult
Prepares the callback result.
Protected methodGetUrlValue
Returns unresolved url for selected media.
Protected methodInitControls
Initializes controls.
Protected methodLoadDisplayValues
Returns the display text for the given selector value.
Protected methodMediaSelector_PreRender
PreRender event handler.
Protected methodOnLoad
Load event handler.
(Overrides ControlOnLoad(EventArgs).)
Protected methodPreviewControlSetup
Setup preview control
Public methodRaiseCallbackEvent
Raises the callback event.
Protected methodRender
Renders the control at design-time.
(Overrides WebControlRender(HtmlTextWriter).)
Protected methodSetUrlValue
Sets url and preview for selected media.
Top
Extension Methods
  NameDescription
Public Extension MethodAddCssClass
Adds CSS class to control. If class is already present, than adding is skipped. Class names are case sensitive.
(Defined by ControlsExtensions.)
Public Extension MethodCallHandled
Calls the method handled by the exception handler. If the call doesn't succeed, the problem is reported through parent IExceptionHandler control instead of throwing unhandled exception for the entire page. Returns true, if the call succeeded, otherwise returns false.
(Defined by ControlsExtensions.)
Public Extension MethodGetCssClasses
Returns all CSS classes of control.
(Defined by ControlsExtensions.)
Public Extension MethodGetRenderedHTML
Returns HTML which would be rendered by control to page.
(Defined by ControlsExtensions.)
Public Extension MethodGetString
Gets the string by the specified resource key
(Defined by ControlsExtensions.)
Public Extension MethodHasCssClass
Checks whether the control has given CSS class. Class names are case sensitive.
(Defined by ControlsExtensions.)
Public Extension MethodRemoveCssClass
Removes all occurrences. Class names are case sensitive.
(Defined by ControlsExtensions.)
Public Extension MethodSetCssClasses
Sets CSS classes to the control. Current classes will be overridden.
(Defined by ControlsExtensions.)
Top
See Also