[HtmlUnit] SVN: [14351] trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[HtmlUnit] SVN: [14351] trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit

rbri
Revision: 14351
          http://sourceforge.net/p/htmlunit/code/14351
Author:   rbri
Date:     2017-05-04 11:11:38 +0000 (Thu, 04 May 2017)
Log Message:
-----------
FF52

Modified Paths:
--------------
    trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/BrowserVersionFeatures.java
    trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/html/HtmlImage.java

Modified: trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/BrowserVersionFeatures.java
===================================================================
--- trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/BrowserVersionFeatures.java 2017-05-04 10:19:19 UTC (rev 14350)
+++ trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/BrowserVersionFeatures.java 2017-05-04 11:11:38 UTC (rev 14351)
@@ -392,6 +392,10 @@
     @BrowserFeature({IE, CHROME})
     HTMLIMAGE_BLANK_SRC_AS_EMPTY,
 
+    /** Empty src attribute sets display to false. */
+    @BrowserFeature(FF52)
+    HTMLIMAGE_EMPTY_SRC_DISPLAY_FALSE,
+
     /** Is document.cretaeElement('image') an HTMLElement. */
     @BrowserFeature(FF)
     HTMLIMAGE_HTMLELEMENT,

Modified: trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/html/HtmlImage.java
===================================================================
--- trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/html/HtmlImage.java 2017-05-04 10:19:19 UTC (rev 14350)
+++ trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/html/HtmlImage.java 2017-05-04 11:11:38 UTC (rev 14351)
@@ -15,6 +15,7 @@
 package com.gargoylesoftware.htmlunit.html;
 
 import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.HTMLIMAGE_BLANK_SRC_AS_EMPTY;
+import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.HTMLIMAGE_EMPTY_SRC_DISPLAY_FALSE;
 import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.HTMLIMAGE_HTMLELEMENT;
 import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.HTMLIMAGE_HTMLUNKNOWNELEMENT;
 import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.HTMLIMAGE_INVISIBLE_NO_SRC;
@@ -661,7 +662,8 @@
         final String src = getSrcAttribute();
         if (hasFeature(HTMLIMAGE_INVISIBLE_NO_SRC)
                 && (ATTRIBUTE_NOT_DEFINED == src
-                    || (hasFeature(HTMLIMAGE_BLANK_SRC_AS_EMPTY) && StringUtils.isBlank(src)))) {
+                    || (hasFeature(HTMLIMAGE_BLANK_SRC_AS_EMPTY) && StringUtils.isBlank(src))
+                    || (hasFeature(HTMLIMAGE_EMPTY_SRC_DISPLAY_FALSE) && StringUtils.isEmpty(src)))) {
             return false;
         }
         return super.isDisplayed();


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
HtmlUnit-develop mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/htmlunit-develop