[HtmlUnit] SVN: [14352] 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: [14352] trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit

rbri
Revision: 14352
          http://sourceforge.net/p/htmlunit/code/14352
Author:   rbri
Date:     2017-05-04 11:19:20 +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/javascript/host/Window.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 11:11:38 UTC (rev 14351)
+++ trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/BrowserVersionFeatures.java 2017-05-04 11:19:20 UTC (rev 14352)
@@ -1332,6 +1332,10 @@
     @BrowserFeature(IE)
     JS_WINDOW_FRAME_BY_ID_RETURNS_WINDOW,
 
+    /** <code>window.mozPaintCount</code> returns 0 instead of 8. */
+    @BrowserFeature(FF45)
+    JS_WINDOW_MOZ_PAINT_COUNT_ZERO,
+
     /**
      * Difference of window.outer/inner height is 63.
      */

Modified: trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/Window.java
===================================================================
--- trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/Window.java 2017-05-04 11:11:38 UTC (rev 14351)
+++ trunk/htmlunit/src/main/java/com/gargoylesoftware/htmlunit/javascript/host/Window.java 2017-05-04 11:19:20 UTC (rev 14352)
@@ -18,6 +18,7 @@
 import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_FORMFIELDS_ACCESSIBLE_BY_NAME;
 import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_FRAMES_ACCESSIBLE_BY_ID;
 import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_FRAME_BY_ID_RETURNS_WINDOW;
+import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_MOZ_PAINT_COUNT_ZERO;
 import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_SELECTION_NULL_IF_INVISIBLE;
 import static com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_TOP_WRITABLE;
 import static com.gargoylesoftware.htmlunit.javascript.configuration.SupportedBrowser.CHROME;
@@ -267,6 +268,7 @@
      */
     @JsxFunction
     public void alert(final Object message) {
+// System.out.println(message);
         // use Object as parameter and perform String conversion by ourself
         // this allows to place breakpoint here and "see" the message object and its properties
         final String stringMessage = Context.toString(message);
@@ -1783,7 +1785,10 @@
      */
     @JsxGetter(FF)
     public int getMozPaintCount() {
-        return 0;
+        if (getBrowserVersion().hasFeature(JS_WINDOW_MOZ_PAINT_COUNT_ZERO)) {
+            return 0;
+        }
+        return 8;
     }
 
     /** Definition of special cases for the smart DomHtmlAttributeChangeListenerImpl */


------------------------------------------------------------------------------
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