Revert "Revert "Code formatting and method rearrangement.""
This reverts commit cc0c9c4e3e.
I'm reverting the reverting. I wanted these changes, just not
all that other -whateverthefuck- that piggybacked in.
This commit is contained in:
@@ -838,8 +838,8 @@ public class ResourceManager
|
|||||||
/**
|
/**
|
||||||
* Creates an appropriate bundle for fetching resources from files.
|
* Creates an appropriate bundle for fetching resources from files.
|
||||||
*/
|
*/
|
||||||
protected FileResourceBundle createFileResourceBundle (File source, boolean delay,
|
protected FileResourceBundle createFileResourceBundle (
|
||||||
boolean unpack)
|
File source, boolean delay, boolean unpack)
|
||||||
{
|
{
|
||||||
return new FileResourceBundle(source, delay, unpack);
|
return new FileResourceBundle(source, delay, unpack);
|
||||||
}
|
}
|
||||||
@@ -847,12 +847,24 @@ public class ResourceManager
|
|||||||
/**
|
/**
|
||||||
* Creates an appropriate bundle for fetching resources from the network.
|
* Creates an appropriate bundle for fetching resources from the network.
|
||||||
*/
|
*/
|
||||||
protected ResourceBundle createNetworkResourceBundle (String root, String path,
|
protected ResourceBundle createNetworkResourceBundle (
|
||||||
Set<String> rsrcList)
|
String root, String path, Set<String> rsrcList)
|
||||||
{
|
{
|
||||||
return new NetworkResourceBundle(root, path, rsrcList);
|
return new NetworkResourceBundle(root, path, rsrcList);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns an InputStream from this manager's classloader for the given path.
|
||||||
|
*/
|
||||||
|
protected InputStream getInputStreamFromClasspath (final String fullyQualifiedPath)
|
||||||
|
{
|
||||||
|
return AccessController.doPrivileged(new PrivilegedAction<InputStream>() {
|
||||||
|
public InputStream run () {
|
||||||
|
return _loader.getResourceAsStream(fullyQualifiedPath);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Transform the path into a locale-specific one, or return null.
|
* Transform the path into a locale-specific one, or return null.
|
||||||
*/
|
*/
|
||||||
@@ -876,18 +888,6 @@ public class ResourceManager
|
|||||||
return ImageIO.read(file);
|
return ImageIO.read(file);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Returns an InputStream from this manager's classloader for the given path.
|
|
||||||
*/
|
|
||||||
protected InputStream getInputStreamFromClasspath (final String fullyQualifiedPath)
|
|
||||||
{
|
|
||||||
return AccessController.doPrivileged(new PrivilegedAction<InputStream>() {
|
|
||||||
public InputStream run () {
|
|
||||||
return _loader.getResourceAsStream(fullyQualifiedPath);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads an image from the given input stream. Supports formats supported by {@link ImageIO}
|
* Loads an image from the given input stream. Supports formats supported by {@link ImageIO}
|
||||||
* as well as {@link FastImageIO} based on the useFastIO param.
|
* as well as {@link FastImageIO} based on the useFastIO param.
|
||||||
|
|||||||
Reference in New Issue
Block a user