Skip to content
Permalink
Browse files
Automatic merge of jdk:master into master
  • Loading branch information
duke committed Mar 24, 2021
2 parents f06813e + 37f494c commit 1273fcfe4bb6166c7688d674d0705deb204d57e1
Showing 1 changed file with 6 additions and 6 deletions.
@@ -185,10 +185,10 @@ private static DataFlavor createConstant(String mt, String prn) {
/*
* private initializer
*/
private static DataFlavor initHtmlDataFlavor(String htmlFlavorType) {
private static DataFlavor initHtml(String htmlFlavorType) {
try {
return new DataFlavor ("text/html; class=java.lang.String;document=" +
htmlFlavorType + ";charset=Unicode");
return new DataFlavor("text/html; class=java.lang.String;document="
+ htmlFlavorType + ";charset=Unicode");
} catch (Exception e) {
return null;
}
@@ -292,7 +292,7 @@ private static DataFlavor initHtmlDataFlavor(String htmlFlavorType) {
*
* @since 1.8
*/
public static DataFlavor selectionHtmlFlavor = initHtmlDataFlavor("selection");
public static final DataFlavor selectionHtmlFlavor = initHtml("selection");

/**
* Represents a piece of an HTML markup. If possible, the markup received
@@ -306,7 +306,7 @@ private static DataFlavor initHtmlDataFlavor(String htmlFlavorType) {
*
* @since 1.8
*/
public static DataFlavor fragmentHtmlFlavor = initHtmlDataFlavor("fragment");
public static final DataFlavor fragmentHtmlFlavor = initHtml("fragment");

/**
* Represents a piece of an HTML markup. If possible, the markup received
@@ -320,7 +320,7 @@ private static DataFlavor initHtmlDataFlavor(String htmlFlavorType) {
*
* @since 1.8
*/
public static DataFlavor allHtmlFlavor = initHtmlDataFlavor("all");
public static final DataFlavor allHtmlFlavor = initHtml("all");

/**
* Constructs a new {@code DataFlavor}. This constructor is provided only

0 comments on commit 1273fcf

Please sign in to comment.