Re: Creating CSS Animations dynamically?

2015-01-03 Thread Thomas Wrobel
perfect.
I wasn't aware you could do it just like that. That works fine. (at least
on FF and Chrome).

Also saves me from having all those ugly vendor extensions.


~~~
Thomas & Bertines online review show:
http://randomreviewshow.com/index.html
Try it! You might even feel ambivalent about it :)

On 3 January 2015 at 22:13, Jens  wrote:

> Have you tried using transitions instead of animations?
>
> So you add
>
> transition:transform ease-in-out 1s;
> transform:translate(0px, 0px);
>
> as CSS class to the element you want to translate and then dynamically add
> a style attribute to that element which contains
> transform:translate(targetX, targetY);
>
> -- J.
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Google Web Toolkit" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/google-web-toolkit/5h6FeUdIh88/unsubscribe
> .
> To unsubscribe from this group and all its topics, send an email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> Visit this group at http://groups.google.com/group/google-web-toolkit.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Re: Revisiting Support for GWT Designer

2015-01-03 Thread Vassilis Virvilis
For me GWT brings sanity in an insane platform.

By sanity I mean mostly static typing. Javascript, css and html are
extremely fragile in typos and therefore refactorings. Since I am not that
smart to figure out the correct interfaces with the first (or even the
second) pass the refactoring is the only thing that is sure that will
happen. So when I am changing method signatures, or lass hierarchies it is
a very good thing that the compiler (or the IDE) will tell me that you
can't do that because you have 26 internal clients of that method. With
pure javascript I would have the options of grep or just don't touch the
code anymore.

The same goes with css. I am willing to pay the price (almost any price
actually) in order to know from the compiler where each css class
definition is used - never mind the obfuscation (think namespacing) - never
mind the the variable substitution that pure CSS lacks, are extremely nice
features.

The same goes for HTML. UIBinder is the killer feature not the GWT designer
- you can't really program without knowing the platform. At some point you
will need to understand it. The only question is if you are going to have
tools to help you do that or you are going to have everything in your mind
for ever (in case you need to revisit code 3 months later)  playing the
role of a compiler or static type checker.

Therefore GWT has great value for me. It would be nice if GWT was the
equivalent of Qt for the web but it isn't.

If you just accept the insane fact that the javascript is the new assembly
and the resistance is futile you may come into terms with the ugly truth.

  Vassilis

On Sat, Jan 3, 2015 at 8:58 PM, Jens  wrote:

> A bit off topic, but:  The real value of GWT for me has been the ability
>> to write browser apps without HTML, CSS, JavaScript, and Java (you know,
>> spaghetti) - being able to use Java only.  As you start adding HTML and CSS
>> to GWT apps  (the UI part), I question the whole value of GWT.
>>
>
> The value of GWT is its tooling support because it can reuse tooling from
> the Java world. That is literally the only reason that really counts.
>
> GWT is a leaky abstraction and will always be. If you refuse to learn more
> about the platform you are programming apps for (the web and its
> technologies) then you are limiting yourself. Good luck writing a smooth
> mobile website/app with custom UI and corporate identity theme without
> knowing HTML/CSS and browser reflows.
>
> But yes that is off topic.
>
> -- J.
>
> --
> 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 google-web-toolkit+unsubscr...@googlegroups.com.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> Visit this group at http://groups.google.com/group/google-web-toolkit.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Vassilis Virvilis

-- 
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 google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Re: Creating CSS Animations dynamically?

2015-01-03 Thread Jens
Have you tried using transitions instead of animations?

So you add 

transition:transform ease-in-out 1s;
transform:translate(0px, 0px);

as CSS class to the element you want to translate and then dynamically add 
a style attribute to that element which contains 
transform:translate(targetX, targetY);

-- J.

-- 
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 google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Re: Performance impact of Focus panel with no handlers?

2015-01-03 Thread darkflame
Thanks for the info.
I removed them it was pointless having them as I don't need access keys for 
those elements. I think I got a slight performance boast, but I changed a 
few things at once so hard to tell definitively.
Still, similar page is probably always good.

On Tuesday, December 30, 2014 5:41:02 PM UTC+1, Jens wrote:
>
> Ah, thanks. Good to know.
>> What about all those little hidden >
>
> Hm yeah well that carries some overhead if you don't need access key 
> support for your focus panels. But if you need access key support then it 
> is kind of a requirement in most browsers as you normally can not assign an 
> access key to a div element.
>
> In HTML5 the accesskey property is allowed on any element not just a, 
> button, various inputs. But I don't know how well browsers already support 
> that. But in the future that input hack might go away for HTML5 compliant 
> browsers.
>
> -- J.
>

-- 
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 google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Creating CSS Animations dynamically?

2015-01-03 Thread darkflame
I have an engine I was making that requires scrolling a large scene amount.
I have had this working with gwt for awhile, but recently spotted I can 
scroll it much smoother by CSS. I guess the browser is more optimised then 
my code for this, and as a side-effect I can easily play with ease-in 
ease-out stuff.

However, the method I used to do this was to add a new style tag to the 
page and put the css defining the animation keyframes within it


createdStyleTag = DOM.createElement("style"); 
RootPanel.getBodyElement().appendChild(createdStyleTag);

Then to set the animation

for (String vendor : vendors) {
 newstyle=newstyle+"@-"+vendor+"-keyframes "+name+" \n {\n"+
"from { transform: translate(0px,0px); } \n"+
 "to{ transform: translate("+enddifx+"px,"+enddify+"px); } \n"+
 "} \n";

}

Where vendors is a list of vendors (-webkit-  -moz, etc)
Then it was simply a matter of applying a class that set the animation and 
duration. Worked great on chrome making my app *much* smoother. yay.

Then I read this
https://bugzilla.mozilla.org/show_bug.cgi?id=830056

Despite Firefox supporting CSS animations it seems they dont support them 
inline. So this sort of on-the-fly defining and running doesnt work.


I wondered if anyone had any alternative methods?

Essentially I am just panning a large absolute panel (with a lot on it) 
within another one, and am hoping to move it between two runtime set 
locations in the smoothest possible way.


-- 
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 google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Re: Revisiting Support for GWT Designer

2015-01-03 Thread Jens

>
> A bit off topic, but:  The real value of GWT for me has been the ability 
> to write browser apps without HTML, CSS, JavaScript, and Java (you know, 
> spaghetti) - being able to use Java only.  As you start adding HTML and CSS 
> to GWT apps  (the UI part), I question the whole value of GWT.
>

The value of GWT is its tooling support because it can reuse tooling from 
the Java world. That is literally the only reason that really counts. 

GWT is a leaky abstraction and will always be. If you refuse to learn more 
about the platform you are programming apps for (the web and its 
technologies) then you are limiting yourself. Good luck writing a smooth 
mobile website/app with custom UI and corporate identity theme without 
knowing HTML/CSS and browser reflows.

But yes that is off topic.

-- J.

-- 
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 google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Re: GWT 2.7 manifest support

2015-01-03 Thread marian lux

>
> Is this really a problem with the manifest update mechanism? Maybe a 
> problem on file system (I use Ubuntu 14.04)?
>
Seems not be a problem with Ubuntu file system. Tested it to build / deploy 
/ run (in Tomcat) the project on OS X 10.10. Still the same issue.


-- 
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 google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Re: Revisiting Support for GWT Designer

2015-01-03 Thread Blake McBride
A bit off topic, but:  The real value of GWT for me has been the ability to
write browser apps without HTML, CSS, JavaScript, and Java (you know,
spaghetti) - being able to use Java only.  As you start adding HTML and CSS
to GWT apps  (the UI part), I question the whole value of GWT.  In that
case, what is the difference between using GWT with HTML/CSS vs. something
like Angular.js?

I think the big payoff with GWT is the one language and magic integration
between front and back ends.  This is big.  Being able to add HTML/CSS on
one-off, special cases is cool too.  Pushing towards more HTML/CSS is
totally missing the point.  For those of us not "pretty well with HTML +
CSS in general", the appeal of GWT could be lost.

GWT Designer was extremely nice, again, for those of us not "pretty well
with HTML + CSS in general".

Blake



On Fri, Jan 2, 2015 at 7:12 PM, Jens  wrote:

> Probably the wrong forum since GWT Designer was never managed by the GWT
> team itself at Google. Making it a community project on Github is probably
> the best bet to keep it alive.
>
> Generally I think UI designers can make code unreadable if you don't go
> the extra mile and give all elements a name, otherwise your variables often
> end up button1, button2, button3 in code. You also have to switch often
> between mouse to place components and keyboard to further adjust
> properties. Maybe GWT designer is better at these points but personally I
> always had the feeling I wasn't really slower without a UI designer.
>
> In GWT you mostly use a HTMLPanel as root with normal HTML inside and with
> some other widgets here and there. So an alternative to GWT designer would
> be to just use any HTML editor (or even the browser itself, like Chrome
> workspaces) to create the HTML + CSS part of your UI. Then you copy it into
> your UiBinder file, making the root element a HTMLPanel and replace input
> elements and such with their corresponding GWT widget. Sure you still need
> to write the Java part of your UiBinder file but at least you can create
> the UI design mostly visual in your HTML editing tool of choice.
>
> Personally I never used GWT designer and I am not feeling slow at writing
> UI layouts directly in UiBinder. On the other hand I am pretty well with
> HTML + CSS in general so it might be different if I would not have that
> knowledge.
>
> Maybe you just give raw UiBinder or any other HTML authoring tool a try.
>
> -- J.
>
> --
> 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 google-web-toolkit+unsubscr...@googlegroups.com.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> Visit this group at http://groups.google.com/group/google-web-toolkit.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


how to correctly remove element in gwt (both `DOM.isOrHasChild` & `DOM.removeChild` were deprecated)?

2015-01-03 Thread Patrick Tucker
The code is open source, you can just look at what the 2 functions do and use 
it instead.  I'm pretty sure they both are just 1 liners.  Also, last I looked 
the deprecation java doc indicates what should be used instead.  They generally 
are really good about doing that.

If memory serves me right you will just call removeChild(element) on your body 
element.  I don't recall what the other is.

As a side note, you should save your returned elements to a variable to reduce 
calls to the DOM.

-- 
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 google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.