Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个带有 uibinder 布局文件的 java 类,我想在其中引用图像并将其显示在 focusPanel 中。
在 uibinder 中使用静态图像的最佳方法是什么?为什么找不到我的图像?
src/main/java/de/myProject: > .ui.xml > .java > image.png
ui.xml:
<g:FocusPanel> <g:Image url="image.png"/> </g:FocusPanel>
结果:找不到 404 图像
您必须将此图像放在 Web 服务器上可公开访问的文件夹中。它不能在 /src 文件夹中。