Back to project page jmini3d.
The source code is released under:
Copyright 2012 Mobialia http://www.mobialia.com/ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to ...
If you think the Android project jmini3d listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package jmini3d.gwt; //from ww w . j av a 2 s. c o m import com.google.gwt.dom.client.ImageElement; import com.google.gwt.user.client.DOM; public class ResourceLoader { String resourcePath; /** * @param resourcePath Path where images are located, with the trailing slash i.e. * "img/" */ public ResourceLoader(String resourcePath) { this.resourcePath = resourcePath; } public ImageElement getImage(String image) { ImageElement img = ImageElement.as(DOM.createImg()); img.setSrc(resourcePath + image); return img; } }