From: <asa...@us...> - 2017-05-05 10:04:59
|
Revision: 14373 http://sourceforge.net/p/htmlunit/code/14373 Author: asashour Date: 2017-05-05 10:04:56 +0000 (Fri, 05 May 2017) Log Message: ----------- Fix build Modified Paths: -------------- trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/Element.java trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/Attr.java trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/DocumentType.java trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/Node.java trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/svg/SVGElement.java trunk/htmlunit/src/test/java/com/gargoylesoftware/htmlunit/javascript/host/html/HTMLDocumentTest.java Modified: trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/Element.java =================================================================== --- trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/Element.java 2017-05-05 08:47:11 UTC (rev 14372) +++ trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/Element.java 2017-05-05 10:04:56 UTC (rev 14373) @@ -1258,30 +1258,30 @@ public void scrollIntoViewIfNeeded() { /* do nothing at the moment */ } /** - * Returns the namespace prefix. - * @return the namespace prefix + * {@inheritDoc} */ - @JsxGetter + @Override + @JsxGetter({CHROME, FF}) public Object getPrefix() { - return getDomNodeOrDie().getPrefix(); + return super.getPrefix(); } /** - * Returns the local name of this element. - * @return the local name of this element + * {@inheritDoc} */ - @JsxGetter + @Override + @JsxGetter({CHROME, FF}) public Object getLocalName() { - return getDomNodeOrDie().getLocalName(); + return super.getLocalName(); } /** - * Returns the URI that identifies an XML namespace. - * @return the URI that identifies an XML namespace + * {@inheritDoc} */ - @JsxGetter + @Override + @JsxGetter({CHROME, FF}) public Object getNamespaceURI() { - return getDomNodeOrDie().getNamespaceURI(); + return super.getNamespaceURI(); } } Modified: trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/Attr.java =================================================================== --- trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/Attr.java 2017-05-05 08:47:11 UTC (rev 14372) +++ trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/Attr.java 2017-05-05 10:04:56 UTC (rev 14373) @@ -175,30 +175,30 @@ } /** - * Returns the namespace prefix. - * @return the namespace prefix + * {@inheritDoc} */ + @Override @JsxGetter public Object getPrefix() { - return getDomNodeOrDie().getPrefix(); + return super.getPrefix(); } /** - * Returns the local name of this attribute. - * @return the local name of this attribute + * {@inheritDoc} */ + @Override @JsxGetter public Object getLocalName() { - return getDomNodeOrDie().getLocalName(); + return super.getLocalName(); } /** - * Returns the URI that identifies an XML namespace. - * @return the URI that identifies an XML namespace + * {@inheritDoc} */ + @Override @JsxGetter public Object getNamespaceURI() { - return getDomNodeOrDie().getNamespaceURI(); + return super.getNamespaceURI(); } } Modified: trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/DocumentType.java =================================================================== --- trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/DocumentType.java 2017-05-05 08:47:11 UTC (rev 14372) +++ trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/DocumentType.java 2017-05-05 10:04:56 UTC (rev 14373) @@ -137,9 +137,10 @@ * Returns the namespace prefix. * @return the namespace prefix */ - @JsxGetter({FF45, IE}) + @Override + @JsxGetter(FF45) public Object getPrefix() { - return getDomNodeOrDie().getPrefix(); + return super.getPrefix(); } /** @@ -146,9 +147,10 @@ * Returns the local name of this element. * @return the local name of this element */ - @JsxGetter({FF45, IE}) + @Override + @JsxGetter(FF45) public Object getLocalName() { - return getDomNodeOrDie().getLocalName(); + return super.getLocalName(); } /** @@ -155,9 +157,10 @@ * Returns the URI that identifies an XML namespace. * @return the URI that identifies an XML namespace */ - @JsxGetter({FF45, IE}) + @Override + @JsxGetter(IE) public Object getNamespaceURI() { - return getDomNodeOrDie().getNamespaceURI(); + return super.getNamespaceURI(); } } Modified: trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/Node.java =================================================================== --- trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/Node.java 2017-05-05 08:47:11 UTC (rev 14372) +++ trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/dom/Node.java 2017-05-05 10:04:56 UTC (rev 14373) @@ -713,4 +713,31 @@ return getDomNodeOrDie().hasAttributes(); } + /** + * Returns the namespace prefix. + * @return the namespace prefix + */ + @JsxGetter(IE) + public Object getPrefix() { + return getDomNodeOrDie().getPrefix(); + } + + /** + * Returns the local name of this attribute. + * @return the local name of this attribute + */ + @JsxGetter(IE) + public Object getLocalName() { + return getDomNodeOrDie().getLocalName(); + } + + /** + * Returns the URI that identifies an XML namespace. + * @return the URI that identifies an XML namespace + */ + @JsxGetter(IE) + public Object getNamespaceURI() { + return getDomNodeOrDie().getNamespaceURI(); + } + } Modified: trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/svg/SVGElement.java =================================================================== --- trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/svg/SVGElement.java 2017-05-05 08:47:11 UTC (rev 14372) +++ trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/svg/SVGElement.java 2017-05-05 10:04:56 UTC (rev 14373) @@ -17,6 +17,7 @@ import static com.gargoylesoftware.htmlunit.javascript.configuration.SupportedBrowser.CHROME; import static com.gargoylesoftware.htmlunit.javascript.configuration.SupportedBrowser.EDGE; import static com.gargoylesoftware.htmlunit.javascript.configuration.SupportedBrowser.FF; +import static com.gargoylesoftware.htmlunit.javascript.configuration.SupportedBrowser.IE; import com.gargoylesoftware.htmlunit.javascript.configuration.JsxClass; import com.gargoylesoftware.htmlunit.javascript.configuration.JsxConstructor; @@ -72,4 +73,21 @@ super.setStyle(style); } + /** + * {@inheritDoc} + */ + @Override + @JsxGetter(IE) + public String getId() { + return super.getId(); + } + + /** + * {@inheritDoc} + */ + @Override + @JsxSetter(IE) + public void setId(final String newId) { + super.setId(newId); + } } Modified: trunk/htmlunit/src/test/java/com/gargoylesoftware/htmlunit/javascript/host/html/HTMLDocumentTest.java =================================================================== --- trunk/htmlunit/src/test/java/com/gargoylesoftware/htmlunit/javascript/host/html/HTMLDocumentTest.java 2017-05-05 08:47:11 UTC (rev 14372) +++ trunk/htmlunit/src/test/java/com/gargoylesoftware/htmlunit/javascript/host/html/HTMLDocumentTest.java 2017-05-05 10:04:56 UTC (rev 14373) @@ -2541,7 +2541,8 @@ * @throws Exception if the test fails */ @Test - @Alerts("1") + @Alerts(DEFAULT = "1", + IE = "undefined") public void childElementCount() throws Exception { final String html = "" + "<html><head>\n" |