On Monday, March 4, 2013 10:45:35 AM UTC+1, Harold wrote:
>
> Hi Thomas,
>
> Thanks for you answer.
>
> Following your suggestion ( new Image(myImageResource) ), there is no 
> more security error :)
>
> All my textures are loaded but are almost empties. According to 
> WebGLInspector all textures have size 1x1 with a transparent pixel.
> It looks like that the HTMLImageElement obtained via image.getElement() is 
> not properly filled now.
>
> An idea about that ?
>

The image then is probably a "clipped image" using a sprited image: the 
image itself is a 1×1px transparent gif (clear.cache.gif, served from the 
same origin as the app) and the image is set as its background, with 
background-position and clip to only show the portion of the sprited image 
that corresponds to the original image. That makes me think we should add a 
isComplete() or isSprited() to ImageResource to "optimize" the way we 
create Image widgets out of ImageResources (which I happen to have already 
proposed in issue 
7403<https://code.google.com/p/google-web-toolkit/issues/detail?id=7403>
).

Anyway, that explains why the security error has vanished.
So in the mean time, revert to "new Image(myImageResource.getSafeUri())" 
(no need to use asString(), there's an overload taking a SafeUri argument), 
but then I bet you'll have the security error back…

>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to