Пример #1
0
 public static jQuery AlertClose(this jQuery instance)
 {
     return(null);
 }
Пример #2
0
 internal static object dropdown(this jQuery query)
 {
     return(Script.Write <object>("query.dropdown();"));
 }
Пример #3
0
///<summary>
///Creates a new instance of Accordion
///</summary>
public Accordion(JsString selector, AccordionOptions options)
{
Selector = J(selector);
Selector.accordion(options);
}
Пример #4
0
 public static jQuery Alert(this jQuery instance, string operation)
 {
     return(null);
 }
Пример #5
0
///<summary>
///Creates a new instance of Slider
///</summary>
public Slider(JsString selector, SliderOptions options)
{
Selector = J(selector);
Selector.slider(options);
}
Пример #6
0
///<summary>
///Creates a new instance of Tabs
///</summary>
public Tabs(JsString selector, TabsOptions options)
{
Selector = J(selector);
Selector.tabs(options);
}
Пример #7
0
 public TextComponent(string value = null, bool preformatted = false)
 {
     RootElement = preformatted ? new jQuery("<pre>").Text(value ?? "") : new jQuery(Document.CreateTextNode(value ?? ""));
 }
Пример #8
0
///<summary>
///Creates a new instance of RemoveClass
///</summary>
public RemoveClass(JsString selector, RemoveClassOptions options)
{
Selector = J(selector);
Selector.removeClass(options);
}
Пример #9
0
 public static jQuery ScrollSpyRefresh(this jQuery instance)
 {
     return(null);
 }
Пример #10
0
 public Stage(jQuery element)
 {
     Element = element;
     jQuery.Ready(InitializeStage);
 }
Пример #11
0
 public static jQuery ScrollSpy(this jQuery instance, ScrollSpyOperation operation)
 {
     return(null);
 }
Пример #12
0
 public static jQuery ScrollSpy(this jQuery instance, ScrollSpyOptions options)
 {
     return(null);
 }
Пример #13
0
Файл: App.cs Проект: txdv/Live
        protected static void LoadExamples(bool loadDefault)
        {
            jQuery.Ajax(
                new AjaxOptions()
            {
                Url     = "https://api.github.com/gists/fc03fa0d97097d4ceabe",
                Type    = "GET",
                Cache   = false,
                Success = delegate(object data, string textStatus, jqXHR request)
                {
                    var files = data["files"];

                    // var names = Global.Keys(files);
                    var names = Global.ToDynamic().Object.keys(files);

                    // If no url hash, auto load the first example by default
                    string autoLoadUrl = (loadDefault) ? files[names[0]]["raw_url"].ToString() : string.Empty;

                    jQuery examples = jQuery.Select("#examples");

                    int count = 1;

                    foreach (string name in names)
                    {
                        string title = "#example" + (count++).ToString();

                        if (!loadDefault && App.Hash == title)
                        {
                            // Mark the example to auto load
                            autoLoadUrl = files[name]["raw_url"].ToString();
                        }

                        new jQuery("<li>")
                        .Attr("role", "presentation")
                        .Append(new AnchorElement
                        {
                            Href    = files[name]["raw_url"].ToString(),
                            Text    = App.FormatExampleFilename(files[name]["filename"].ToString()),
                            Title   = title,
                            OnClick = App.LoadExample
                        })
                        .AppendTo(examples);
                    }

                    // Auto load requested example or the first example by default
                    if (!string.IsNullOrEmpty(autoLoadUrl))
                    {
                        string hash = (loadDefault) ? "#example1" : App.Hash;

                        App.LoadFromGist(hash, autoLoadUrl);

                        jQuery example = jQuery.Select("#examples > li > a[title='" + hash + "']");
                        example.Parent().AddClass("active");

                        // Update editor title with file name
                        jQuery.Select("#filename").Html(example.Text());
                    }
                }
            }
                );
        }
Пример #14
0
 public FullCalendar(jQuery.jQuery jQuery, FullCalendar options)
 {
 }
Пример #15
0
 public Tabs(jQuery html, dynamic opts)
 {
     //dummy body
 }
Пример #16
0
///<summary>
///Creates a new instance of Hide
///</summary>
public Hide(JsString selector, HideOptions options)
{
Selector = J(selector);
Selector.hide(options);
}
Пример #17
0
 /// <summary>
 /// Renders the view contents. Accepts a jQuery selector (or jQuery object) to which the contents will be appended. Alternatively, the render method can be called without parameters in order to retrieve the View element for manual insertion/further manipulation.
 /// </summary>
 /// <param name="container"></param>
 /// <returns>(optional) the element in which the view element will be appended.</returns>
 public virtual jQuery Render(jQuery selector)
 {
     return(null);
 }
Пример #18
0
///<summary>
///Creates a new instance of AddClass
///</summary>
public AddClass(JsString selector, AddClassOptions options)
{
Selector = J(selector);
Selector.addClass(options);
}
Пример #19
0
 public virtual void activateListeners(jQuery html)
 {
 }
Пример #20
0
///<summary>
///Creates a new instance of Button
///</summary>
public Button(JsString selector, ButtonOptions options)
{
Selector = J(selector);
Selector.button(options);
}
Пример #21
0
 public ListMaker()
 {
     List = MakeList();
 }
Пример #22
0
///<summary>
///Creates a new instance of ToggleClass
///</summary>
public ToggleClass(JsString selector, ToggleClassOptions options)
{
Selector = J(selector);
Selector.toggleClass(options);
}
Пример #23
0
        private jQuery MakeList()
        {
            jQuery ul = new jQuery("<ul>").AddClass("list-group");

            return(ul);
        }
Пример #24
0
        /// <summary>
        /// Add the ui column player container
        /// </summary>
        /// <param name="playerObject"></param>
        public static void AddPlayerContainer(Player playerObject, int playerCount)
        {
            // Get main container
            var scoreboard = jQuery.Select("#" + DiceView.PlayerContainerId);

            // Max 6 item per real row
            var rowIndex = Convert.ToInt32(playerObject.Index / (DiceView.PlayerSlots / DiceView.MinColSizeLg));

            var playerRow = scoreboard.Find(string.Format("[PlayerRowAttribute={0}]", rowIndex));

            if (playerRow.Length <= 0)
            {
                playerRow = new jQuery("<div>")
                            .AddClass("row low-pad")
                            .Attr("PlayerRowAttribute", rowIndex);
                scoreboard.Append(playerRow);

                // correct row heights
                scoreboard.Find("[PlayerRowAttribute]")
                .RemoveClass("fill-height-" + rowIndex)
                .AddClass("fill-height-" + (rowIndex + 1));
            }

            // This is the column
            var playerContainer = new jQuery("<div>");

            playerContainer.Attr(DiceView.PlayerColumnAttribute, playerObject.Index)
            .AddClass("fill-height");
            // Panel with title and scoreboard
            var playerPanel = new jQuery("<div>");

            playerPanel
            .AddClass("panel panel-default low-pad")
            .Attr(DiceView.PlayerPanelAttribute, playerObject.Index)
            .Append(new jQuery("<div>").AddClass("panel-heading low-pad")
                    // Adding title
                    .Append(new jQuery("<h3>").AddClass("panel-title")
                            .Attr("id", DiceView.PlayerPanelTitleBaseId + playerObject.Index)
                            .Append(new jQuery("<span>").AddClass("player-name").Text(playerObject.Name))
                            .Append(new jQuery("<span>").AddClass("glyphicon glyphicon-edit pull-right player-icon")
                                    .On("click", null, playerObject.Index.ToString(), (Action <jQueryEvent>)Ui.ShowRename))))
            // Adding body (scoreboard)
            .Append(new jQuery("<div>").AddClass("panel-body low-pad")
                    .Append(new jQuery("<ul>").AddClass("list-group")
                            .Attr(DiceView.PlayerScoreBoardAttribute, playerObject.Index)))
            // Total in footer
            .Append(new jQuery("<div>").AddClass("panel-footer low-pad")
                    .Append(new jQuery("<h5>")
                            .AddClass("")
                            .Attr(DiceView.PlayerPanelFooterAttribute, playerObject.Index)
                            .Text("Total: 0")));
            // Adding to containers
            playerContainer.Append(playerPanel);
            playerRow.Append(playerContainer);
            // Force wrapping on a new line
            //if ((playerObject.Index + 1) % (DiceView.PlayerSlots / DiceView.MinColSizeLg) == 0)
            //{
            //    scoreboard.Append(new jQuery("<div>").AddClass("clearfix visible-lg-block"));
            //}
            // Break into logical rows on small devices
            if ((playerObject.Index + 1) % (DiceView.PlayerSlots / DiceView.MinColSizeMd) == 0)
            {
                playerRow.Append(new jQuery("<div>").AddClass("clearfix visible-md-block"));
            }
            if ((playerObject.Index + 1) % (DiceView.PlayerSlots / DiceView.MinColSizeSm) == 0)
            {
                playerRow.Append(new jQuery("<div>").AddClass("clearfix visible-sm-block"));
            }
            if ((playerObject.Index + 1) % (DiceView.PlayerSlots / DiceView.MinColSizeXs) == 0)
            {
                playerRow.Append(new jQuery("<div>").AddClass("clearfix visible-xs-block"));
            }
            // update columns classes
            Ui.SetColumnClass(playerCount);
        }
Пример #25
0
 public static jQuery Tooltip(this jQuery instance, TooltipOptions options)
 {
     return(null);
 }
Пример #26
0
 public static jQuery Alert(this jQuery instance, AlertOperation operation)
 {
     return(null);
 }
Пример #27
0
 public static jQuery Tooltip(this jQuery instance, string operation)
 {
     return(null);
 }
Пример #28
0
 internal static object tab(this jQuery query)
 {
     return(Script.Write <object>("query.tab();"));
 }
Пример #29
0
 public static jQuery Tooltip(this jQuery instance, PopupOperation operation)
 {
     return(null);
 }
Пример #30
0
 public CreateSvgRect(jQuery parent) : base(parent)
 {
 }
Пример #31
0
 public static jQuery TooltipDestroy(this jQuery instance)
 {
     return(null);
 }
Пример #32
0
///<summary>
///Creates a new instance of Droppable
///</summary>
public Droppable(JsString selector, DroppableOptions options)
{
Selector = J(selector);
Selector.droppable(options);
}
Пример #33
0
 public static jQuery TooltipShow(this jQuery instance)
 {
     return(null);
 }
Пример #34
0
///<summary>
///Creates a new instance of Progressbar
///</summary>
public Progressbar(JsString selector, ProgressbarOptions options)
{
Selector = J(selector);
Selector.progressbar(options);
}
Пример #35
0
 public static jQuery TooltipToggle(this jQuery instance)
 {
     return(null);
 }
Пример #36
0
///<summary>
///Creates a new instance of Resizable
///</summary>
public Resizable(JsString selector, ResizableOptions options)
{
Selector = J(selector);
Selector.resizable(options);
}
Пример #37
0
 public void Show()
 {
     jQuery j = new jQuery("#" + id).Modal(ModalOperation.Show);
 }
Пример #38
0
///<summary>
///Creates a new instance of Show
///</summary>
public Show(JsString selector, ShowOptions options)
{
Selector = J(selector);
Selector.show(options);
}
Пример #39
0
 public void Hide()
 {
     jQuery j = new jQuery("#" + id).Modal(ModalOperation.Hide);
 }
Пример #40
0
///<summary>
///Creates a new instance of Sortable
///</summary>
public Sortable(JsString selector, SortableOptions options)
{
Selector = J(selector);
Selector.sortable(options);
}
Пример #41
0
        public static ModalDlg Make(string titleText, string bodyText, string id)
        {
            DivElement myModal = new DivElement();

            myModal.ClassName = "modal fade";
            myModal.Id        = id;
            myModal.SetAttribute("role", "dialog");
            jQuery jq = new jQuery(myModal).On("hidden.bs.modal", OnHidden);


            DivElement modalDlg = new DivElement();

            modalDlg.ClassName = "modal-dialog-sm";
            myModal.AppendChild(modalDlg);


            DivElement modalContent = new DivElement();

            modalContent.ClassName = "modal-content";
            modalDlg.AppendChild(modalContent);

            DivElement modalHeader = new DivElement();

            modalHeader.ClassName = "modal-header";
            modalContent.AppendChild(modalHeader);

            ButtonElement button = new ButtonElement();

            button.SetAttribute("type", "button");
            button.ClassName = "close";
            button.SetAttribute("data-dismiss", "modal");
            button.InnerHTML = "&times;";
            modalHeader.AppendChild(button);

            HeadingElement title = new HeadingElement(HeadingType.H4);

            title.ClassName = "modal-title";
            title.InnerHTML = titleText;
            modalHeader.AppendChild(title);


            DivElement modalBody = new DivElement();

            modalBody.ClassName = "modal-body";
            modalContent.AppendChild(modalBody);

            ParagraphElement bodyContent = new ParagraphElement();

            bodyContent.InnerHTML = bodyText;
            modalBody.AppendChild(bodyContent);

            DivElement footer = new DivElement();

            footer.ClassName = "modal-footer";


            ButtonElement footerButton = new ButtonElement();

            footerButton.SetAttribute("type", "button");
            footerButton.ClassName = "btn btn-default";
            footerButton.SetAttribute("data-dismiss", "modal");
            footerButton.InnerHTML = "Close";

            footer.AppendChild(footerButton);
            modalContent.AppendChild(footer);

            Document.Body.AppendChild(myModal);

            ModalDlg dlg = new ModalDlg();

            dlg.TopElement  = myModal;
            dlg.Body        = modalBody;
            dlg.Title       = title;
            dlg.BodyContent = bodyContent;
            dlg.Footer      = footer;
            dlg.id          = id;
            return(dlg);
        }
Пример #42
0
///<summary>
///Creates a new instance of SwitchClass
///</summary>
public SwitchClass(JsString selector, SwitchClassOptions options)
{
Selector = J(selector);
Selector.switchClass(options);
}
Пример #43
0
 public BussyDlg()
 {
     Bussy = Make().AppendTo(Document.Body);
 }
Пример #44
0
///<summary>
///Creates a new instance of Toggle
///</summary>
public Toggle(JsString selector, ToggleOptions options)
{
Selector = J(selector);
Selector.toggle(options);
}
Пример #45
0
 private jQuery transitionViews(jQuery arrivingView, jQuery departingView, object data = null)
 {
     return(null);
 }
Пример #46
0
///<summary>
///Creates a new instance of Datepicker
///</summary>
public Datepicker(JsString selector, DatepickerOptions options)
{
Selector = J(selector);
Selector.datepicker(options);
}
Пример #47
0
 public static jQuery Append(this jQuery root, IComponent component)
 {
     return(root.Append(component.RootElement));
 }
Пример #48
0
///<summary>
///Creates a new instance of Dialog
///</summary>
public Dialog(JsString selector, DialogOptions options)
{
Selector = J(selector);
Selector.dialog(options);
}
Пример #49
0
 public static extern jQuery.Elements jQuery(string expression, jQuery.Elements context);