RadDraggable
Represents the RadDraggable control that makes elements draggable with various configuration options.
Definition
Namespace:Telerik.Web.UI
Assembly:Telerik.Web.UI.dll
Syntax:
[ToolboxBitmap(typeof(RadDraggable), "Toolbox.Icons.DragDrop.png")]
[RequiredScript(typeof(jQueryPlugins))]
[RequiredScript(typeof(Html5DragAndDrop))]
[ClientScriptResource("Telerik.Web.UI.RadDraggable", "Telerik.Web.UI.DragDropManager.Draggable.RadDraggable.js")]
public class RadDraggable : RadWebControl, IComponent, IDisposable, IParserAccessor, IUrlResolutionService, IDataBindingsAccessor, IControlBuilderAccessor, IControlDesignerAccessor, IExpressionsAccessor, IAttributeAccessor, IScriptControl, IControlResolver, IPostBackDataHandler, ISkinnableControl, IControl
Inheritance: objectControlWebControlRadWebControlRadDraggable
Implements:
Inherited Members
Constructors
public RadDraggable()
Properties
If set to true the widget will auto-scroll the container when the mouse/finger is close to the top/bottom of it.
public bool AutoScroll { get; set; }
Constrains the hint movement to either the horizontal (x) or vertical (y) axis. Can be set to either "x" or "y".
public RadDraggableAxisMode Axis { get; set; }
Defines the client events handlers.
[PersistenceMode(PersistenceMode.InnerProperty)]
public DraggableClientEvents ClientEvents { get; }
If set, the hint movement is constrained to the container boundaries.
[TypeConverter(typeof(ListConverter))]
[PersistenceMode(PersistenceMode.Attribute)]
[Bindable(true)]
public string[] ContainerSelectors { get; set; }
The values of the property should be a valid jQuery selectors. E.g. class name or Id of html element.
The CssClass property will now be used instead of the former Skin and will be modified in AddAttributesToRender()
protected override string CssClassFormatString { get; }
Overrides:
If set, specifies the offset of the hint relative to the mouse cursor/finger. By default, the hint is initially positioned on top of the draggable source offset. The option accepts an object with two keys: top and left.
public object CursorOffset { get; set; }
The options that will be used for the popup initialization. For more details about the available options refer to Popup documentation.
[PersistenceMode(PersistenceMode.InnerProperty)]
public DraggableCursorOffsetSettings CursorOffsetSettings { get; }
The required distance that the mouse should travel in order to initiate a drag.
public double Distance { get; set; }
Gets or sets the selectors used to get the elements within the Draggable that will be draggable.
[TypeConverter(typeof(ListConverter))]
[PersistenceMode(PersistenceMode.Attribute)]
[Bindable(true)]
public string[] FilterSelectors { get; set; }
The values of the property should be a valid jQuery selectors. E.g. class name or Id of html element.
Used to group sets of draggable and drop targets. A draggable with the same group value as a drop target will be accepted by the drop target.
public string Group { get; set; }
Provides a way for customization of the drag indicator. If a function is supplied, it receives one argument - the draggable element's jQuery object.
public string Hint { get; set; }
Suitable for touch oriented user interface, in order to avoid collision with the touch scrolling gesture. When set to true, the widget will be activated after the user taps and holds the finger on the element for a short amount of time.The draggable will also be activated by pressing, holding and lifting the finger without any movement. Dragging it afterwards will initiate the drag immediately. The activated mode can be canceled by calling cancelHold.
public bool HoldToDrag { get; set; }
Gets or sets the selectors used to get the elements within the Draggable that will not trigger a drag.
[TypeConverter(typeof(ListConverter))]
[PersistenceMode(PersistenceMode.Attribute)]
[Bindable(true)]
public string[] IgnoreSelectors { get; set; }
The values of the property should be a valid jQuery selectors. E.g. class name or Id of html element.
protected override HtmlTextWriterTag TagKey { get; }
Overrides:
Gets or sets the selectors used to get the elements that will become Draggables.
[TypeConverter(typeof(ListConverter))]
[PersistenceMode(PersistenceMode.Attribute)]
[Bindable(true)]
public string[] TargetSelectors { get; set; }
The values of the property should be a valid jQuery selectors. E.g. class name or Id of html element.
Methods
protected override void DescribeClientEvents(IScriptDescriptor descriptor)
Overrides:
protected override void DescribeComponent(IScriptDescriptor descriptor)
Overrides: