changeset 5868:cc2acc7f4a50

RT-33113: Printing: HtmlEditor does not print anything Reviewed-by: kcr
author prr
date Mon, 02 Dec 2013 14:12:26 -0800
parents 446894e7355b
children 7032137bf627
files modules/graphics/src/main/java/com/sun/javafx/sg/prism/NGNode.java
diffstat 1 files changed, 6 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/modules/graphics/src/main/java/com/sun/javafx/sg/prism/NGNode.java	Mon Dec 02 11:31:48 2013 -0800
+++ b/modules/graphics/src/main/java/com/sun/javafx/sg/prism/NGNode.java	Mon Dec 02 14:12:26 2013 -0800
@@ -2375,7 +2375,12 @@
      **************************************************************************/
 
     static FilterContext getFilterContext(Graphics g) {
-        return PrFilterContext.getInstance(g.getAssociatedScreen());
+        Screen s = g.getAssociatedScreen();
+        if (s == null) {
+            return PrFilterContext.getPrinterContext(g.getResourceFactory());
+        } else {
+            return PrFilterContext.getInstance(s);
+        }
     }
 
     /**