internal string InternalGetExplicitRuleSelector() { // X:\jsc.svn\examples\javascript\CSS\Test\CSSSelectorReuse\CSSSelectorReuse\Application.cs // page.Header.setAttribute("style-id", "45"); //IStyleSheet.Default[CSSMediaTypes.print][ // //"#" + page.Header.id // "[style-id='45']" IHTMLElement that = this; if (that == null) { throw new InvalidOperationException(); } // there can be only one body it seems. if (this.localName.ToLower() == "html") { return(this.localName); } if (this.localName.ToLower() == "body") { return(this.localName); } #region style-id var x = (string)that.getAttribute("style-id"); if (string.IsNullOrEmpty(x)) { // https://sites.google.com/a/jsc-solutions.net/backlog/knowledge-base/2014/201401/20140125/speed // localName: "div" //x = this.tagName + __style_id; // localName: "div" // tagName: "DIV" // className: "" // lassList: DOMTokenList // are we building an Expression<> here? //x = this.localName + "." + this.classList.FirstOrDefault() + "[" + __style_id + "]"; x = "" + __style_id; this.setAttribute("style-id", x); // 95ms css.style { selectorText = [style-id="table.__ContentTable[2]"] > tbody > tr > td } __style_id++; } #endregion #region selectorText var selectorText = this.localName; // looks like cookie api access. lets talk to only the primary class thp var className = this.classList.FirstOrDefault(); if (className != null) { // do we need to do css escape? selectorText += "." + className; } selectorText += "[style-id='" + x + "']"; #endregion return(selectorText); }
static IHTMLObject InternalConstructor() { return((IHTMLObject)IHTMLElement.InternalConstructor(HTMLElementEnum.@object)); }
static IHTMLFieldset InternalConstructor() { return((IHTMLFieldset)IHTMLElement.InternalConstructor(HTMLElementEnum.fieldset)); }
internal static IHTMLUnorderedList InternalConstructor() { return((IHTMLUnorderedList)IHTMLElement.InternalConstructor(HTMLElementEnum.ul)); }
static IHTMLAudio InternalConstructor() { return((IHTMLAudio)IHTMLElement.InternalConstructor(HTMLElementEnum.audio)); }
internal static IHTMLLabel InternalConstructor() { return((IHTMLLabel)IHTMLElement.InternalConstructor(HTMLElementEnum.label)); }
public IHTMLLabel(string e, IHTMLElement f) { }
public static IEnumerable <IHTMLScript> ScriptElements(this IHTMLElement i) { return(i.querySelectorAll(IHTMLElement.HTMLElementEnum.script).Select(k => (IHTMLScript)k)); }
static IHTMLLegend InternalConstructor() { return((IHTMLLegend)IHTMLElement.InternalConstructor(HTMLElementEnum.legend)); }