> idont want to use GQuery because it generates heavy javascript.
Indeed, GQuery produces extra javascript code when you use the CSS
class (and only if you use it) due to the static initializer of this
class. We are aware of this problem. An issue exists to track it and
should be resolved soon :
ht
Thanks Thomas.
it works like a charm now.
Thanks
Deepak
On Wed, Nov 23, 2011 at 1:14 AM, Thomas Broyer wrote:
> In CSS, you use background-image: url(...);, so you should do the same in
> GWT: setBackgroundImage("url(" + x + ")").
>
> But in this case I'd rather use a CssResource.
>
> Oh, and
In CSS, you use background-image: url(...);, so you should do the same in
GWT: setBackgroundImage("url(" + x + ")").
But in this case I'd rather use a CssResource.
Oh, and you should add an @ImageOptions(repeatStyle=Vertical) (or Both,
depending on the width of your element) or you'll see other
Tried this also. But still image is not displayed.
If i use GQuery and does this one
$("#topbar").css(CSS.BACKGROUND_IMAGE.with(UriValue.url(HomePageClientBundle.INSTANCE.topbar2().getSafeUri().asString(;
then image gets displayed.
But using gwt
Document.get().getElementById("topbar").getS
Should be ImageResource yes, and I also think the setBackgroundImage(...)
method accepts a String, not an ImageResource.
In the 2.4 release you should use
...setBackgroundImage(clientbundle.topbar2().getSafeUri().asString());
cause in 2.4 the getUrl() in the ImageResource is deprecated.
--
Yo
Sorry.Writing mistake.
It is ImageResource only.
On Wed, Nov 23, 2011 at 12:34 AM, darkflame wrote:
> ImageSource?
> Isnt it supposed to be ImageResource?
>
>
> On Nov 22, 7:37 pm, Deepak Singh wrote:
> > Hi,
> >
> > GWT 2.4
> >
> > html contains one div as written below
> >
> > > style="backg
ImageSource?
Isnt it supposed to be ImageResource?
On Nov 22, 7:37 pm, Deepak Singh wrote:
> Hi,
>
> GWT 2.4
>
> html contains one div as written below
>
> style="background-image:url(images/top-bar-2.png);background-repeat:
> repeat-y;">
>
> Now i need to replace this image through clientbundl
Hi,
GWT 2.4
html contains one div as written below
Now i need to replace this image through clientbundle. So MyClientBundle as
follows
@source("images/top-bar-2.png")
ImageSource topbar2();
i change my html like this
and in java code i set
Document.get().getElementById("topbar").getStyle(