removing web.flyingsaucer module as the code is incompatible with trunk and the provided functionality already replaced by another modules.
authorMarek Fukala <mfukala@netbeans.org>
Tue, 04 Sep 2012 08:54:43 +0200
changeset 1787112cde13be2b3
parent 17870 367d3813e6b7
child 17872 402425992715
removing web.flyingsaucer module as the code is incompatible with trunk and the provided functionality already replaced by another modules.
.hgmail
web.flyingsaucer/build.xml
web.flyingsaucer/manifest.mf
web.flyingsaucer/nbproject/project.properties
web.flyingsaucer/nbproject/project.xml
web.flyingsaucer/src/org/netbeans/modules/web/flyingsaucer/Bundle.properties
web.flyingsaucer/src/org/netbeans/modules/web/flyingsaucer/CssPreviewPanel.form
web.flyingsaucer/src/org/netbeans/modules/web/flyingsaucer/CssPreviewPanel.java
web.flyingsaucer/src/org/netbeans/modules/web/flyingsaucer/flyingsaucers.xml
     1.1 --- a/.hgmail	Fri Aug 31 16:31:24 2012 +0200
     1.2 +++ b/.hgmail	Tue Sep 04 08:54:43 2012 +0200
     1.3 @@ -9,7 +9,7 @@
     1.4  commits@ide.netbeans.org=bluej-suite/*,featureentries/*
     1.5  commits@installer.netbeans.org=jnlpmodules/*,ssinstaller/*
     1.6  commits@java.netbeans.org=javax.jmi.reflect/*,api.mdr/*,mdr/*,javax.jmi.model/*,jmiutils/*,jdkblacklist/*
     1.7 -commits@javaee.netbeans.org=j2ee.adventure/*,j2ee.blueprints/*,web.flyingsaucer/*
     1.8 +commits@javaee.netbeans.org=j2ee.adventure/*,j2ee.blueprints/*,
     1.9  commits@mobility.netbeans.org=mobility.plugins.blackberry/*,mobility.plugins.javase/*
    1.10  commits@obsolete.netbeans.org=accelerators/*,corba/*,jndi/*,languages.*/*,*fortress*/*,metrics/*,rmi*/*,vcs.advanced/*,vcs.profiles.clearcase/*,vcs.profiles.cvsprofiles/*,vcs.profiles.perforce/*,vcs.profiles.pvcs/*,vcs.profiles.starteam/*,vcs.profiles.subversion/*,vcs.profiles.teamware/*,vcs.profiles.vss/*
    1.11  commits@obsolete.netbeans.org=themebuilder/*
     2.1 --- a/web.flyingsaucer/build.xml	Fri Aug 31 16:31:24 2012 +0200
     2.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.3 @@ -1,48 +0,0 @@
     2.4 -<?xml version="1.0" encoding="UTF-8"?>
     2.5 -<!--
     2.6 -DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
     2.7 -
     2.8 -Copyright 1997-2010 Oracle and/or its affiliates. All rights reserved.
     2.9 -
    2.10 -Oracle and Java are registered trademarks of Oracle and/or its affiliates.
    2.11 -Other names may be trademarks of their respective owners.
    2.12 -
    2.13 -
    2.14 -The contents of this file are subject to the terms of either the GNU
    2.15 -General Public License Version 2 only ("GPL") or the Common
    2.16 -Development and Distribution License("CDDL") (collectively, the
    2.17 -"License"). You may not use this file except in compliance with the
    2.18 -License. You can obtain a copy of the License at
    2.19 -http://www.netbeans.org/cddl-gplv2.html
    2.20 -or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the
    2.21 -specific language governing permissions and limitations under the
    2.22 -License.  When distributing the software, include this License Header
    2.23 -Notice in each file and include the License file at
    2.24 -nbbuild/licenses/CDDL-GPL-2-CP.  Oracle designates this
    2.25 -particular file as subject to the "Classpath" exception as provided
    2.26 -by Oracle in the GPL Version 2 section of the License file that
    2.27 -accompanied this code. If applicable, add the following below the
    2.28 -License Header, with the fields enclosed by brackets [] replaced by
    2.29 -your own identifying information:
    2.30 -"Portions Copyrighted [year] [name of copyright owner]"
    2.31 -
    2.32 -Contributor(s):
    2.33 -
    2.34 -The Original Software is NetBeans. The Initial Developer of the Original
    2.35 -Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
    2.36 -Microsystems, Inc. All Rights Reserved.
    2.37 -
    2.38 -If you wish your version of this file to be governed by only the CDDL
    2.39 -or only the GPL Version 2, indicate your decision by adding
    2.40 -"[Contributor] elects to include this software in this distribution
    2.41 -under the [CDDL or GPL Version 2] license." If you do not indicate a
    2.42 -single choice of license, a recipient has the option to distribute
    2.43 -your version of this file under either the CDDL, the GPL Version 2 or
    2.44 -to extend the choice of license to its licensees as provided above.
    2.45 -However, if you add GPL Version 2 code and therefore, elected the GPL
    2.46 -Version 2 license, then the option applies only if the new code is
    2.47 -made subject to such option by the copyright holder.
    2.48 --->
    2.49 -<project name="contrib/web.flyingsaucer" default="netbeans" basedir=".">
    2.50 -    <import file="../../nbbuild/templates/projectized.xml"/>
    2.51 -</project>
     3.1 --- a/web.flyingsaucer/manifest.mf	Fri Aug 31 16:31:24 2012 +0200
     3.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     3.3 @@ -1,6 +0,0 @@
     3.4 -Manifest-Version: 1.0
     3.5 -OpenIDE-Module: org.netbeans.modules.web.flyingsaucer/1
     3.6 -OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/web/flyingsaucer/Bundle.properties
     3.7 -OpenIDE-Module-Implementation-Version: 1
     3.8 -AutoUpdate-Show-In-Client: true
     3.9 -
     4.1 --- a/web.flyingsaucer/nbproject/project.properties	Fri Aug 31 16:31:24 2012 +0200
     4.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.3 @@ -1,56 +0,0 @@
     4.4 -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
     4.5 -#
     4.6 -# Copyright 1997-2010 Oracle and/or its affiliates. All rights reserved.
     4.7 -#
     4.8 -# Oracle and Java are registered trademarks of Oracle and/or its affiliates.
     4.9 -# Other names may be trademarks of their respective owners.
    4.10 -#
    4.11 -# The contents of this file are subject to the terms of either the GNU
    4.12 -# General Public License Version 2 only ("GPL") or the Common
    4.13 -# Development and Distribution License("CDDL") (collectively, the
    4.14 -# "License"). You may not use this file except in compliance with the
    4.15 -# License. You can obtain a copy of the License at
    4.16 -# http://www.netbeans.org/cddl-gplv2.html
    4.17 -# or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the
    4.18 -# specific language governing permissions and limitations under the
    4.19 -# License.  When distributing the software, include this License Header
    4.20 -# Notice in each file and include the License file at
    4.21 -# nbbuild/licenses/CDDL-GPL-2-CP.  Oracle designates this
    4.22 -# particular file as subject to the "Classpath" exception as provided
    4.23 -# by Oracle in the GPL Version 2 section of the License file that
    4.24 -# accompanied this code. If applicable, add the following below the
    4.25 -# License Header, with the fields enclosed by brackets [] replaced by
    4.26 -# your own identifying information:
    4.27 -# "Portions Copyrighted [year] [name of copyright owner]"
    4.28 -#
    4.29 -# Contributor(s):
    4.30 -#
    4.31 -# The Original Software is NetBeans. The Initial Developer of the Original
    4.32 -# Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
    4.33 -# Microsystems, Inc. All Rights Reserved.
    4.34 -#
    4.35 -# If you wish your version of this file to be governed by only the CDDL
    4.36 -# or only the GPL Version 2, indicate your decision by adding
    4.37 -# "[Contributor] elects to include this software in this distribution
    4.38 -# under the [CDDL or GPL Version 2] license." If you do not indicate a
    4.39 -# single choice of license, a recipient has the option to distribute
    4.40 -# your version of this file under either the CDDL, the GPL Version 2 or
    4.41 -# to extend the choice of license to its licensees as provided above.
    4.42 -# However, if you add GPL Version 2 code and therefore, elected the GPL
    4.43 -# Version 2 license, then the option applies only if the new code is
    4.44 -# made subject to such option by the copyright holder.
    4.45 -
    4.46 -javac.compilerargs=-Xlint -Xlint:-serial
    4.47 -javac.source=1.5
    4.48 -nbm.needs.restart=true
    4.49 -release.external/core-rendererR8final.jar=modules/ext/core-renderer.jar
    4.50 -
    4.51 -# Fatal error: class com.lowagie.text.DocumentException not found
    4.52 -# Warning: class com.lowagie.text.DocumentException not found. Please, add required jar or directory to the classpath.
    4.53 -sigtest.gen.fail.on.error=false
    4.54 -spec.version.base=1.13.0
    4.55 -
    4.56 -license.file=external/flying-saucer-R8final-license.txt
    4.57 -#TODO fix the homepage!
    4.58 -nbm.homepage=http://web.netbeans.org
    4.59 -nbm.module.author=Marek Fukala
     5.1 --- a/web.flyingsaucer/nbproject/project.xml	Fri Aug 31 16:31:24 2012 +0200
     5.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     5.3 @@ -1,101 +0,0 @@
     5.4 -<?xml version="1.0" encoding="UTF-8"?>
     5.5 -<!--
     5.6 -DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
     5.7 -
     5.8 -Copyright 1997-2010 Oracle and/or its affiliates. All rights reserved.
     5.9 -
    5.10 -Oracle and Java are registered trademarks of Oracle and/or its affiliates.
    5.11 -Other names may be trademarks of their respective owners.
    5.12 -
    5.13 -
    5.14 -The contents of this file are subject to the terms of either the GNU
    5.15 -General Public License Version 2 only ("GPL") or the Common
    5.16 -Development and Distribution License("CDDL") (collectively, the
    5.17 -"License"). You may not use this file except in compliance with the
    5.18 -License. You can obtain a copy of the License at
    5.19 -http://www.netbeans.org/cddl-gplv2.html
    5.20 -or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the
    5.21 -specific language governing permissions and limitations under the
    5.22 -License.  When distributing the software, include this License Header
    5.23 -Notice in each file and include the License file at
    5.24 -nbbuild/licenses/CDDL-GPL-2-CP.  Oracle designates this
    5.25 -particular file as subject to the "Classpath" exception as provided
    5.26 -by Oracle in the GPL Version 2 section of the License file that
    5.27 -accompanied this code. If applicable, add the following below the
    5.28 -License Header, with the fields enclosed by brackets [] replaced by
    5.29 -your own identifying information:
    5.30 -"Portions Copyrighted [year] [name of copyright owner]"
    5.31 -
    5.32 -Contributor(s):
    5.33 -
    5.34 -The Original Software is NetBeans. The Initial Developer of the Original
    5.35 -Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
    5.36 -Microsystems, Inc. All Rights Reserved.
    5.37 -
    5.38 -If you wish your version of this file to be governed by only the CDDL
    5.39 -or only the GPL Version 2, indicate your decision by adding
    5.40 -"[Contributor] elects to include this software in this distribution
    5.41 -under the [CDDL or GPL Version 2] license." If you do not indicate a
    5.42 -single choice of license, a recipient has the option to distribute
    5.43 -your version of this file under either the CDDL, the GPL Version 2 or
    5.44 -to extend the choice of license to its licensees as provided above.
    5.45 -However, if you add GPL Version 2 code and therefore, elected the GPL
    5.46 -Version 2 license, then the option applies only if the new code is
    5.47 -made subject to such option by the copyright holder.
    5.48 --->
    5.49 -<project xmlns="http://www.netbeans.org/ns/project/1">
    5.50 -    <type>org.netbeans.modules.apisupport.project</type>
    5.51 -    <configuration>
    5.52 -        <data xmlns="http://www.netbeans.org/ns/nb-module-project/2">
    5.53 -            <code-name-base>org.netbeans.modules.web.flyingsaucer</code-name-base>
    5.54 -            <module-dependencies>
    5.55 -                <dependency>
    5.56 -                    <code-name-base>org.netbeans.modules.css.visual</code-name-base>
    5.57 -                    <build-prerequisite/>
    5.58 -                    <compile-dependency/>
    5.59 -                    <run-dependency>
    5.60 -                        <release-version>1</release-version>
    5.61 -                        <specification-version>2.15</specification-version>
    5.62 -                    </run-dependency>
    5.63 -                </dependency>
    5.64 -                <dependency>
    5.65 -                    <code-name-base>org.netbeans.modules.web.common</code-name-base>
    5.66 -                    <build-prerequisite/>
    5.67 -                    <compile-dependency/>
    5.68 -                    <run-dependency>
    5.69 -                        <specification-version>1.14</specification-version>
    5.70 -                    </run-dependency>
    5.71 -                </dependency>
    5.72 -                <dependency>
    5.73 -                    <code-name-base>org.openide.filesystems</code-name-base>
    5.74 -                    <build-prerequisite/>
    5.75 -                    <compile-dependency/>
    5.76 -                    <run-dependency>
    5.77 -                        <specification-version>7.44</specification-version>
    5.78 -                    </run-dependency>
    5.79 -                </dependency>
    5.80 -                <dependency>
    5.81 -                    <code-name-base>org.openide.util</code-name-base>
    5.82 -                    <build-prerequisite/>
    5.83 -                    <compile-dependency/>
    5.84 -                    <run-dependency>
    5.85 -                        <specification-version>8.11</specification-version>
    5.86 -                    </run-dependency>
    5.87 -                </dependency>
    5.88 -                <dependency>
    5.89 -                    <code-name-base>org.openide.util.lookup</code-name-base>
    5.90 -                    <build-prerequisite/>
    5.91 -                    <compile-dependency/>
    5.92 -                    <run-dependency>
    5.93 -                        <specification-version>8.5</specification-version>
    5.94 -                    </run-dependency>
    5.95 -                </dependency>
    5.96 -            </module-dependencies>
    5.97 -            <public-packages/>
    5.98 -            <class-path-extension>
    5.99 -                <runtime-relative-path>ext/core-renderer.jar</runtime-relative-path>
   5.100 -                <binary-origin>external/core-rendererR8final.jar</binary-origin>
   5.101 -            </class-path-extension>
   5.102 -        </data>
   5.103 -    </configuration>
   5.104 -</project>
     6.1 --- a/web.flyingsaucer/src/org/netbeans/modules/web/flyingsaucer/Bundle.properties	Fri Aug 31 16:31:24 2012 +0200
     6.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     6.3 @@ -1,51 +0,0 @@
     6.4 -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
     6.5 -#
     6.6 -# Copyright 1997-2010 Oracle and/or its affiliates. All rights reserved.
     6.7 -#
     6.8 -# Oracle and Java are registered trademarks of Oracle and/or its affiliates.
     6.9 -# Other names may be trademarks of their respective owners.
    6.10 -#
    6.11 -# The contents of this file are subject to the terms of either the GNU
    6.12 -# General Public License Version 2 only ("GPL") or the Common
    6.13 -# Development and Distribution License("CDDL") (collectively, the
    6.14 -# "License"). You may not use this file except in compliance with the
    6.15 -# License. You can obtain a copy of the License at
    6.16 -# http://www.netbeans.org/cddl-gplv2.html
    6.17 -# or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the
    6.18 -# specific language governing permissions and limitations under the
    6.19 -# License.  When distributing the software, include this License Header
    6.20 -# Notice in each file and include the License file at
    6.21 -# nbbuild/licenses/CDDL-GPL-2-CP.  Oracle designates this
    6.22 -# particular file as subject to the "Classpath" exception as provided
    6.23 -# by Oracle in the GPL Version 2 section of the License file that
    6.24 -# accompanied this code. If applicable, add the following below the
    6.25 -# License Header, with the fields enclosed by brackets [] replaced by
    6.26 -# your own identifying information:
    6.27 -# "Portions Copyrighted [year] [name of copyright owner]"
    6.28 -#
    6.29 -# Contributor(s):
    6.30 -#
    6.31 -# The Original Software is NetBeans. The Initial Developer of the Original
    6.32 -# Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
    6.33 -# Microsystems, Inc. All Rights Reserved.
    6.34 -#
    6.35 -# If you wish your version of this file to be governed by only the CDDL
    6.36 -# or only the GPL Version 2, indicate your decision by adding
    6.37 -# "[Contributor] elects to include this software in this distribution
    6.38 -# under the [CDDL or GPL Version 2] license." If you do not indicate a
    6.39 -# single choice of license, a recipient has the option to distribute
    6.40 -# your version of this file under either the CDDL, the GPL Version 2 or
    6.41 -# to extend the choice of license to its licensees as provided above.
    6.42 -# However, if you add GPL Version 2 code and therefore, elected the GPL
    6.43 -# Version 2 license, then the option applies only if the new code is
    6.44 -# made subject to such option by the copyright holder.
    6.45 -
    6.46 -# module descritpion
    6.47 -OpenIDE-Module-Name=CSS Preview by Flying Saucer Renderer
    6.48 -OpenIDE-Module-Display-Category=Web
    6.49 -OpenIDE-Module-Short-Description=Previews CSS documents using the Flying Saucer XHTML rendered
    6.50 -OpenIDE-Module-Long-Description=\
    6.51 -    Previews CSS documents using the Flying Saucer XHTML rendered
    6.52 -
    6.53 -# library display name
    6.54 -flyingsaucer=Flying Saucer
     7.1 --- a/web.flyingsaucer/src/org/netbeans/modules/web/flyingsaucer/CssPreviewPanel.form	Fri Aug 31 16:31:24 2012 +0200
     7.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     7.3 @@ -1,29 +0,0 @@
     7.4 -<?xml version="1.1" encoding="UTF-8" ?>
     7.5 -
     7.6 -<Form version="1.4" maxVersion="1.4" type="org.netbeans.modules.form.forminfo.JPanelFormInfo">
     7.7 -  <AuxValues>
     7.8 -    <AuxValue name="FormSettings_autoResourcing" type="java.lang.Integer" value="1"/>
     7.9 -    <AuxValue name="FormSettings_autoSetComponentName" type="java.lang.Boolean" value="false"/>
    7.10 -    <AuxValue name="FormSettings_generateFQN" type="java.lang.Boolean" value="true"/>
    7.11 -    <AuxValue name="FormSettings_generateMnemonicsCode" type="java.lang.Boolean" value="false"/>
    7.12 -    <AuxValue name="FormSettings_i18nAutoMode" type="java.lang.Boolean" value="true"/>
    7.13 -    <AuxValue name="FormSettings_layoutCodeTarget" type="java.lang.Integer" value="2"/>
    7.14 -    <AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
    7.15 -    <AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
    7.16 -    <AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
    7.17 -    <AuxValue name="designerSize" type="java.awt.Dimension" value="-84,-19,0,5,115,114,0,18,106,97,118,97,46,97,119,116,46,68,105,109,101,110,115,105,111,110,65,-114,-39,-41,-84,95,68,20,2,0,2,73,0,6,104,101,105,103,104,116,73,0,5,119,105,100,116,104,120,112,0,0,1,16,0,0,1,-112"/>
    7.18 -  </AuxValues>
    7.19 -
    7.20 -  <Layout class="org.netbeans.modules.form.compat2.layouts.DesignBorderLayout"/>
    7.21 -  <SubComponents>
    7.22 -    <Container class="javax.swing.JScrollPane" name="jScrollPane1">
    7.23 -      <Constraints>
    7.24 -        <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignBorderLayout" value="org.netbeans.modules.form.compat2.layouts.DesignBorderLayout$BorderConstraintsDescription">
    7.25 -          <BorderConstraints direction="Center"/>
    7.26 -        </Constraint>
    7.27 -      </Constraints>
    7.28 -
    7.29 -      <Layout class="org.netbeans.modules.form.compat2.layouts.support.JScrollPaneSupportLayout"/>
    7.30 -    </Container>
    7.31 -  </SubComponents>
    7.32 -</Form>
     8.1 --- a/web.flyingsaucer/src/org/netbeans/modules/web/flyingsaucer/CssPreviewPanel.java	Fri Aug 31 16:31:24 2012 +0200
     8.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     8.3 @@ -1,396 +0,0 @@
     8.4 -/*
     8.5 - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
     8.6 - *
     8.7 - * Copyright 1997-2010 Oracle and/or its affiliates. All rights reserved.
     8.8 - *
     8.9 - * Oracle and Java are registered trademarks of Oracle and/or its affiliates.
    8.10 - * Other names may be trademarks of their respective owners.
    8.11 - *
    8.12 - * The contents of this file are subject to the terms of either the GNU
    8.13 - * General Public License Version 2 only ("GPL") or the Common
    8.14 - * Development and Distribution License("CDDL") (collectively, the
    8.15 - * "License"). You may not use this file except in compliance with the
    8.16 - * License. You can obtain a copy of the License at
    8.17 - * http://www.netbeans.org/cddl-gplv2.html
    8.18 - * or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the
    8.19 - * specific language governing permissions and limitations under the
    8.20 - * License.  When distributing the software, include this License Header
    8.21 - * Notice in each file and include the License file at
    8.22 - * nbbuild/licenses/CDDL-GPL-2-CP.  Oracle designates this
    8.23 - * particular file as subject to the "Classpath" exception as provided
    8.24 - * by Oracle in the GPL Version 2 section of the License file that
    8.25 - * accompanied this code. If applicable, add the following below the
    8.26 - * License Header, with the fields enclosed by brackets [] replaced by
    8.27 - * your own identifying information:
    8.28 - * "Portions Copyrighted [year] [name of copyright owner]"
    8.29 - *
    8.30 - * Contributor(s):
    8.31 - *
    8.32 - * The Original Software is NetBeans. The Initial Developer of the Original
    8.33 - * Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
    8.34 - * Microsystems, Inc. All Rights Reserved.
    8.35 - *
    8.36 - * If you wish your version of this file to be governed by only the CDDL
    8.37 - * or only the GPL Version 2, indicate your decision by adding
    8.38 - * "[Contributor] elects to include this software in this distribution
    8.39 - * under the [CDDL or GPL Version 2] license." If you do not indicate a
    8.40 - * single choice of license, a recipient has the option to distribute
    8.41 - * your version of this file under either the CDDL, the GPL Version 2 or
    8.42 - * to extend the choice of license to its licensees as provided above.
    8.43 - * However, if you add GPL Version 2 code and therefore, elected the GPL
    8.44 - * Version 2 license, then the option applies only if the new code is
    8.45 - * made subject to such option by the copyright holder.
    8.46 - */
    8.47 -package org.netbeans.modules.web.flyingsaucer;
    8.48 -
    8.49 -import java.beans.PropertyChangeListener;
    8.50 -import java.util.Collection;
    8.51 -import java.util.LinkedList;
    8.52 -import org.netbeans.modules.css.visual.api.CssPreviewComponent;
    8.53 -import java.awt.Graphics;
    8.54 -import java.io.StringReader;
    8.55 -import java.net.MalformedURLException;
    8.56 -import java.net.URISyntaxException;
    8.57 -import java.net.URL;
    8.58 -import java.util.concurrent.FutureTask;
    8.59 -import java.util.logging.Level;
    8.60 -import java.util.logging.Logger;
    8.61 -import javax.swing.JComponent;
    8.62 -import javax.swing.SwingUtilities;
    8.63 -import org.netbeans.modules.css.visual.api.CssPreviewComponentFactory;
    8.64 -import org.netbeans.modules.css.visual.api.CssPreviewComponentListener;
    8.65 -import org.netbeans.modules.web.common.api.WebUtils;
    8.66 -import org.openide.filesystems.FileObject;
    8.67 -import org.openide.filesystems.URLMapper;
    8.68 -import org.openide.util.RequestProcessor;
    8.69 -import org.openide.util.lookup.ServiceProvider;
    8.70 -import org.w3c.dom.Document;
    8.71 -import org.xhtmlrenderer.extend.FSImage;
    8.72 -import org.xhtmlrenderer.extend.UserAgentCallback;
    8.73 -import org.xhtmlrenderer.resource.ImageResource;
    8.74 -import org.xhtmlrenderer.resource.XMLResource;
    8.75 -import org.xhtmlrenderer.simple.XHTMLPanel;
    8.76 -import org.xhtmlrenderer.simple.extend.XhtmlNamespaceHandler;
    8.77 -import org.xhtmlrenderer.swing.NaiveUserAgent;
    8.78 -import org.xhtmlrenderer.util.XRLog;
    8.79 -import org.xhtmlrenderer.util.XRLogger;
    8.80 -import org.xml.sax.InputSource;
    8.81 - 
    8.82 -/**
    8.83 - * JPanel wrapping XHTMLPanel, the Flying Saucer's rendering area.
    8.84 - * The class also suppresses exceptions falling from the renderer
    8.85 - * so they are just logged, not displayed to user as exceptions.
    8.86 - *
    8.87 - * @author  Marek Fukala
    8.88 - */
    8.89 -public class CssPreviewPanel extends javax.swing.JPanel implements CssPreviewComponent {
    8.90 -
    8.91 -    private static final String EMPTY_DOCUMENT_CONTENT = "<html><head><title>empty document</title></head><body></body></html>"; //NOI18N
    8.92 -    private static final Logger LOGGER = Logger.getLogger(CssPreviewPanel.class.getName());
    8.93 -    private static final boolean LOG_FINE = LOGGER.isLoggable(Level.FINE);
    8.94 -    private XRLogger FS_HANDLER = new FlyingSaucerLoggersHandler();
    8.95 -    private PatchedXHTMLPanel xhtmlPanel;
    8.96 -    private Runnable panelCreatedTask;
    8.97 -    private final Collection<CssPreviewComponentListener> listeners = new LinkedList<CssPreviewComponentListener>();
    8.98 -
    8.99 -    /** Creates new form CssPreviewPanel2 */
   8.100 -    public CssPreviewPanel() {
   8.101 -        initComponents();
   8.102 -        //run the xhtml panel creation in a non-AWT thread
   8.103 -        RequestProcessor.getDefault().execute(new FutureTask<XHTMLPanel>(new Runnable() {
   8.104 -
   8.105 -            @Override
   8.106 -            public void run() {
   8.107 -                //create outside of AWT
   8.108 -                final PatchedXHTMLPanel panel = new PatchedXHTMLPanel(new PreviewUserAgent());
   8.109 -                //set own XRLogger, all FS logged events will go to our impl.
   8.110 -                XRLog.setLoggerImpl(FS_HANDLER);
   8.111 -                try {
   8.112 -                    //call the setDocument(...) on the freshly created panel so all the resources
   8.113 -                    //loading is done now and not later in EDT
   8.114 -                    InputSource inputSource = new InputSource(new StringReader(EMPTY_DOCUMENT_CONTENT));
   8.115 -                    panel.setDocument(inputSource, null);
   8.116 -                } catch (Exception ex) {
   8.117 -                    //no-op
   8.118 -                }
   8.119 -                //and set the panel to this component in AWT
   8.120 -                SwingUtilities.invokeLater(new Runnable() {
   8.121 -
   8.122 -                    @Override
   8.123 -                    public void run() {
   8.124 -                        setXhtmlPanel(panel);
   8.125 -                    }
   8.126 -                });
   8.127 -            }
   8.128 -        }, null));
   8.129 -
   8.130 -    }
   8.131 -
   8.132 -    private synchronized void setXhtmlPanel(PatchedXHTMLPanel panel) {
   8.133 -        assert SwingUtilities.isEventDispatchThread();
   8.134 -        this.xhtmlPanel = panel;
   8.135 -        jScrollPane1.setViewportView(panel);
   8.136 -        //set the content if some was already requested
   8.137 -        if (panelCreatedTask != null) {
   8.138 -            panelCreatedTask.run();
   8.139 -            //release the only once used runnable
   8.140 -            panelCreatedTask = null;
   8.141 -        }
   8.142 -    }
   8.143 -
   8.144 -    @Override
   8.145 -    public synchronized void setDocument(final InputSource is, final String url) throws Exception {
   8.146 -        if (xhtmlPanel == null) {
   8.147 -            //early attempt to set a document content, the xhtml panel initialization
   8.148 -            //is still running
   8.149 -            panelCreatedTask = new Runnable() {
   8.150 -
   8.151 -                @Override
   8.152 -                public void run() {
   8.153 -                    //call it in non-AWT thread, it may take some time
   8.154 -                    RequestProcessor.getDefault().post(new Runnable() {
   8.155 -
   8.156 -                        @Override
   8.157 -                        public void run() {
   8.158 -                            try {
   8.159 -                                doSetDocument(is, url);
   8.160 -                                //repaing the panel in AWT then
   8.161 -                                SwingUtilities.invokeLater(new Runnable() {
   8.162 -
   8.163 -                                    @Override
   8.164 -                                    public void run() {
   8.165 -                                        xhtmlPanel.revalidate();
   8.166 -                                        xhtmlPanel.repaint();
   8.167 -                                    }
   8.168 -                                    
   8.169 -                                });
   8.170 -                            } catch (Exception ex) {
   8.171 -                                LOGGER.log(Level.INFO, "Error setting the document to be previewed!", ex); //NOI18N
   8.172 -                            }
   8.173 -                        }
   8.174 -                    });
   8.175 -                }
   8.176 -
   8.177 -            };
   8.178 -        } else {
   8.179 -            //and set the document to he renderer
   8.180 -            doSetDocument(is, url);
   8.181 -        }
   8.182 -    }
   8.183 -
   8.184 -    private void doSetDocument(InputSource inputSource, String url) throws Exception {
   8.185 -        xhtmlPanel.setDocument(inputSource, url);
   8.186 -    }
   8.187 -
   8.188 -    @Override
   8.189 -    public JComponent getComponent() {
   8.190 -        return this;
   8.191 -    }
   8.192 -
   8.193 -    @Override
   8.194 -    public void dispose() {
   8.195 -        // nothing to dispose here
   8.196 -    }
   8.197 -
   8.198 -    /** This method is called from within the constructor to
   8.199 -     * initialize the form.
   8.200 -     * WARNING: Do NOT modify this code. The content of this method is
   8.201 -     * always regenerated by the Form Editor.
   8.202 -     */
   8.203 -    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
   8.204 -    private void initComponents() {
   8.205 -
   8.206 -        jScrollPane1 = new javax.swing.JScrollPane();
   8.207 -
   8.208 -        setLayout(new java.awt.BorderLayout());
   8.209 -        add(jScrollPane1, java.awt.BorderLayout.CENTER);
   8.210 -    }// </editor-fold>//GEN-END:initComponents
   8.211 -    // Variables declaration - do not modify//GEN-BEGIN:variables
   8.212 -    private javax.swing.JScrollPane jScrollPane1;
   8.213 -    // End of variables declaration//GEN-END:variables
   8.214 -
   8.215 -    @Override
   8.216 -    public void addListener(CssPreviewComponentListener listener) {
   8.217 -        synchronized (listeners) {
   8.218 -            listeners.add(listener);
   8.219 -        }
   8.220 -    }
   8.221 -
   8.222 -    @Override
   8.223 -    public void removeListener(CssPreviewComponentListener listener) {
   8.224 -        synchronized (listeners) {
   8.225 -            listeners.remove(listener);
   8.226 -        }
   8.227 -    }
   8.228 -
   8.229 -    private void fireErrorEvent(String msg) {
   8.230 -        synchronized (listeners) {
   8.231 -            for(CssPreviewComponentListener l : listeners) {
   8.232 -                l.error(msg);
   8.233 -            }
   8.234 -        }
   8.235 -    }
   8.236 -
   8.237 -    // End of variables declaration
   8.238 -
   8.239 -    @ServiceProvider(service=CssPreviewComponentFactory.class, position=100)
   8.240 -    public static class Factory implements CssPreviewComponentFactory {
   8.241 -
   8.242 -        @Override
   8.243 -        public CssPreviewComponent createCssPreviewComponent() {
   8.244 -            return new CssPreviewPanel();
   8.245 -        }
   8.246 -
   8.247 -        @Override
   8.248 -        public void addPropertyChangeListener(PropertyChangeListener l) {
   8.249 -            //no-op
   8.250 -        }
   8.251 -
   8.252 -        @Override
   8.253 -        public void removePropertyChangeListener(PropertyChangeListener l) {
   8.254 -            //no-op
   8.255 -        }
   8.256 -
   8.257 -    }
   8.258 -
   8.259 -    //delegating flying saucer handler
   8.260 -    //modifies the log record priorities!
   8.261 -    private class FlyingSaucerLoggersHandler implements XRLogger {
   8.262 -
   8.263 -        private void publish(Level level, String msg, Throwable exc) {
   8.264 -            //log the important messages with INFO level and show them in the status bar
   8.265 -            if(level.intValue() >= Level.WARNING.intValue()) {
   8.266 -                //log the exception message to output
   8.267 -                LOGGER.log(Level.INFO, msg, exc);
   8.268 -                //...and to the status bar
   8.269 -                fireErrorEvent(msg);
   8.270 -            } else {
   8.271 -                //lower priority
   8.272 -                if(LOG_FINE) {
   8.273 -                    LOGGER.log(Level.FINE, msg, exc);
   8.274 -                }
   8.275 -            }
   8.276 -        }
   8.277 -
   8.278 -        @Override
   8.279 -        public void log(String logger, Level level, String msg) {
   8.280 -            log(logger, level, msg, null);
   8.281 -        }
   8.282 -
   8.283 -        @Override
   8.284 -        public void log(String logger, Level level, String msg, Throwable thrwbl) {
   8.285 -            publish(level, logger+msg, thrwbl);
   8.286 -        }
   8.287 -
   8.288 -        @Override
   8.289 -        public void setLevel(String string, Level level) {
   8.290 -            //no-op
   8.291 -        }
   8.292 -        
   8.293 -    }
   8.294 -
   8.295 -    //workaround for FlyingSaucer bug (reported as netbeans issue #117499 (NullPointerException for unreachable url))
   8.296 -    private class PatchedXHTMLPanel extends XHTMLPanel {
   8.297 -
   8.298 -        /**
   8.299 -         * Instantiates a panel with a custom {@link org.xhtmlrenderer.extend.UserAgentCallback}
   8.300 -         * implementation.
   8.301 -         *
   8.302 -         * @param uac The custom UserAgentCallback implementation.
   8.303 -         */
   8.304 -        public PatchedXHTMLPanel(UserAgentCallback uac) {
   8.305 -            super(uac);
   8.306 -        }
   8.307 -
   8.308 -        public void setDocument(InputSource inputSource, String url) {
   8.309 -            Document dom = XMLResource.load(inputSource).getDocument();
   8.310 -            setDocument(dom, url, new XhtmlNamespaceHandler());
   8.311 -        }
   8.312 -
   8.313 -        @Override
   8.314 -        public void paintComponent(Graphics g) {
   8.315 -            try {
   8.316 -                super.paintComponent(g);
   8.317 -            } catch (Throwable e) {
   8.318 -                if (LOG_FINE) {
   8.319 -                    LOGGER.log(Level.FINE, "It seems there is a bug in FlyinSaucer XHTML renderer.", e); //NOI18N
   8.320 -                }
   8.321 -                fireErrorEvent(e.getLocalizedMessage());
   8.322 -            }
   8.323 -        }
   8.324 -    }
   8.325 -
   8.326 -    //workaround for specifying Base URL
   8.327 -    private static class PreviewUserAgent extends NaiveUserAgent {
   8.328 -
   8.329 -        //issue #191644 - 'endless image drawing' workround
   8.330 -        @Override
   8.331 -        public ImageResource getImageResource(String uri) {
   8.332 -            ImageResource is = super.getImageResource(uri);
   8.333 -            if(is != null) {
   8.334 -                //if the image to be returned by the ImageResource has width or height == 0
   8.335 -                //we cannot pass it to the AbstractOutputDevice since it would cause the
   8.336 -                //AbstractOutputDevice.paintTiles(...) to run endlessly
   8.337 -                FSImage fsimg = is.getImage();
   8.338 -                if(fsimg.getHeight() == 0 || fsimg.getWidth() == 0) {
   8.339 -                    return new ImageResource(null);
   8.340 -                }
   8.341 -            }
   8.342 -
   8.343 -            return is;
   8.344 -        }
   8.345 -
   8.346 -        @Override
   8.347 -        public String resolveURI(String uri) {
   8.348 -            if (uri == null) {
   8.349 -                return null;
   8.350 -            }
   8.351 -
   8.352 -            try {
   8.353 -                //the FS tries to resolve the absolute link by simply adding it to the
   8.354 -                //current relative base so the uri given here looks like:
   8.355 -                //
   8.356 -                //file:/Users/marekfukala/NetBeansProjects/CssTesting/web/resources//duke2.png
   8.357 -                //
   8.358 -                //We can try to identify the doubleslash here and resolve the rest of the URI
   8.359 -                //by relativizing it to the web root (base of the absolute links).
   8.360 -                //This solution however seems to be little hacky to me and can stop
   8.361 -                //working if FS changes the (undefined) semantic.
   8.362 -                int doubleSlashIndex = uri.lastIndexOf("//"); //NOI18N
   8.363 -                if(doubleSlashIndex != -1) {
   8.364 -                    //get the link path w/o the base, KEEP one slash as the link prefix
   8.365 -                    //so we can simply use WebUtils.resolve()
   8.366 -                    String absoluteLink = uri.substring(doubleSlashIndex + 1); //+1 => just one slash goes away
   8.367 -                    // Absolute path now we will look to the webRoot of the project
   8.368 -                    URL url = new URL(getBaseURL());
   8.369 -
   8.370 -                    //fix for Bug 188259 - java.net.URISyntaxException: Illegal character in path at index 20: file:/C:/Users/Bryan Field/Projects/SurfNSecure.com-Applied-Thermal-DocumentNotes/web/,.css (edit)
   8.371 -                    //the FileBasedURLMapper.getFileObjects() logs URISyntaxException instead of passing it out,
   8.372 -                    //if happens during its call to url.getURI();
   8.373 -                    url.toURI(); //lets catch the exception here
   8.374 -
   8.375 -                    FileObject edited = URLMapper.findFileObject(url);
   8.376 -                    if (edited != null) {
   8.377 -                        FileObject target = WebUtils.resolve(edited, absoluteLink);
   8.378 -                        if (target != null) {
   8.379 -                            URL targetURL = URLMapper.findURL(target, URLMapper.INTERNAL);
   8.380 -                            if (targetURL != null) {
   8.381 -                                return targetURL.toExternalForm();
   8.382 -                            }
   8.383 -                        }
   8.384 -                    }
   8.385 -                }
   8.386 -
   8.387 -            } catch (URISyntaxException ex) {
   8.388 -                LOGGER.log(Level.INFO, null, ex); //NOI18N
   8.389 -            } catch (MalformedURLException ex) {
   8.390 -                LOGGER.log(Level.INFO, null, ex); //NOI18N
   8.391 -            } catch (IllegalArgumentException ex) {
   8.392 -                //Bug 198411 - Corrupted URI from CssPreviewPanel: URI has an authority component 
   8.393 -                LOGGER.log(Level.INFO, null, ex); //NOI18N
   8.394 -            }
   8.395 -            // falling back to FlyingSaucer implementation
   8.396 -            return super.resolveURI(uri);
   8.397 -        }
   8.398 -    }
   8.399 -}
     9.1 --- a/web.flyingsaucer/src/org/netbeans/modules/web/flyingsaucer/flyingsaucers.xml	Fri Aug 31 16:31:24 2012 +0200
     9.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     9.3 @@ -1,56 +0,0 @@
     9.4 -<?xml version="1.0" encoding="UTF-8"?>
     9.5 -
     9.6 -<!--
     9.7 -DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
     9.8 -
     9.9 -Copyright 1997-2010 Oracle and/or its affiliates. All rights reserved.
    9.10 -
    9.11 -Oracle and Java are registered trademarks of Oracle and/or its affiliates.
    9.12 -Other names may be trademarks of their respective owners.
    9.13 -
    9.14 -
    9.15 -The contents of this file are subject to the terms of either the GNU
    9.16 -General Public License Version 2 only ("GPL") or the Common
    9.17 -Development and Distribution License("CDDL") (collectively, the
    9.18 -"License"). You may not use this file except in compliance with the
    9.19 -License. You can obtain a copy of the License at
    9.20 -http://www.netbeans.org/cddl-gplv2.html
    9.21 -or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the
    9.22 -specific language governing permissions and limitations under the
    9.23 -License.  When distributing the software, include this License Header
    9.24 -Notice in each file and include the License file at
    9.25 -nbbuild/licenses/CDDL-GPL-2-CP.  Oracle designates this
    9.26 -particular file as subject to the "Classpath" exception as provided
    9.27 -by Oracle in the GPL Version 2 section of the License file that
    9.28 -accompanied this code. If applicable, add the following below the
    9.29 -License Header, with the fields enclosed by brackets [] replaced by
    9.30 -your own identifying information:
    9.31 -"Portions Copyrighted [year] [name of copyright owner]"
    9.32 -
    9.33 -Contributor(s):
    9.34 -
    9.35 -The Original Software is NetBeans. The Initial Developer of the Original
    9.36 -Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
    9.37 -Microsystems, Inc. All Rights Reserved.
    9.38 -
    9.39 -If you wish your version of this file to be governed by only the CDDL
    9.40 -or only the GPL Version 2, indicate your decision by adding
    9.41 -"[Contributor] elects to include this software in this distribution
    9.42 -under the [CDDL or GPL Version 2] license." If you do not indicate a
    9.43 -single choice of license, a recipient has the option to distribute
    9.44 -your version of this file under either the CDDL, the GPL Version 2 or
    9.45 -to extend the choice of license to its licensees as provided above.
    9.46 -However, if you add GPL Version 2 code and therefore, elected the GPL
    9.47 -Version 2 license, then the option applies only if the new code is
    9.48 -made subject to such option by the copyright holder.
    9.49 --->
    9.50 -<!DOCTYPE library PUBLIC "-//NetBeans//DTD Library Declaration 1.0//EN" "http://www.netbeans.org/dtds/library-declaration-1_0.dtd">
    9.51 -<library version="1.0">
    9.52 -    <name>flyingsaucer</name>
    9.53 -    <type>j2se</type>
    9.54 -    <localizing-bundle>org/netbeans/modules/web/flyingsaucer/Bundle</localizing-bundle>
    9.55 -    <volume>
    9.56 -        <type>classpath</type>
    9.57 -        <resource>jar:nbinst://org.netbeans.modules.web.flyingsaucer/modules/ext/core-renderer.jar!/</resource>
    9.58 -    </volume>
    9.59 -</library>