This needs to be done in a sandbox safe manner.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@135 ed5b42cb-e716-0410-a449-f6a68f950b19
This commit is contained in:
@@ -164,6 +164,13 @@ public class ResourceManager
|
|||||||
_rootPath = resourceRoot;
|
_rootPath = resourceRoot;
|
||||||
_loader = loader;
|
_loader = loader;
|
||||||
|
|
||||||
|
// check a system property to determine if we should unpack our bundles, but don't freak
|
||||||
|
// out if we fail to read it
|
||||||
|
try {
|
||||||
|
_unpack = Boolean.getBoolean("no_unpack_resources");
|
||||||
|
} catch (SecurityException se) {
|
||||||
|
}
|
||||||
|
|
||||||
// get our resource directory from resource_dir if possible
|
// get our resource directory from resource_dir if possible
|
||||||
initResourceDir(null);
|
initResourceDir(null);
|
||||||
}
|
}
|
||||||
@@ -638,6 +645,7 @@ public class ResourceManager
|
|||||||
try {
|
try {
|
||||||
resourceDir = System.getProperty("resource_dir");
|
resourceDir = System.getProperty("resource_dir");
|
||||||
} catch (SecurityException se) {
|
} catch (SecurityException se) {
|
||||||
|
// no problem
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -737,7 +745,7 @@ public class ResourceManager
|
|||||||
protected String _rootPath;
|
protected String _rootPath;
|
||||||
|
|
||||||
/** Whether or not to unpack our resource bundles. */
|
/** Whether or not to unpack our resource bundles. */
|
||||||
protected boolean _unpack = Boolean.getBoolean("no_unpack_resources");
|
protected boolean _unpack;
|
||||||
|
|
||||||
/** Our default resource set. */
|
/** Our default resource set. */
|
||||||
protected ResourceBundle[] _default = new ResourceBundle[0];
|
protected ResourceBundle[] _default = new ResourceBundle[0];
|
||||||
|
|||||||
Reference in New Issue
Block a user