[gwt-contrib] Re: Removes unnecessary constructor param for JsniMethodBody.
JNode used to have a JProgram program field, forcing the entire AST to be completely interconnected. At some point while taking a step towards decoupling things, we removed the field and 99% of the constructor args, but it looks like we missed one. On Fri, Feb 26, 2010 at 6:58 PM, cromwell...@google.com wrote: On 2010/02/26 23:16:27, scottb wrote: Small compiler review. LGTM, was this parameter ever used for anything? http://gwt-code-reviews.appspot.com/153811 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: ScrollTable as a FastTreeItem doesn't show up
On 2010/02/24 18:29:56, jlabanca wrote: Looks good. But is there any reason not to just look at the offset-size only? Not that it makes a huge difference, but it sounds like it could be a little simpler. http://gwt-code-reviews.appspot.com/152801 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: ScrollTable as a FastTreeItem doesn't show up
On 2010/03/01 15:25:14, jgw wrote: On 2010/02/24 18:29:56, jlabanca wrote: Looks good. But is there any reason not to just look at the offset-size only? Not that it makes a huge difference, but it sounds like it could be a little simpler. (to be clear, if you're convinced that's necessary, please go ahead and commit) http://gwt-code-reviews.appspot.com/152801 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: ScrollTable as a FastTreeItem doesn't show up
Two reasons: 1. We used to look at the clientSize, and I'm worried about the implications about switching to the offsetSize exclusively. It shouldn't take any more JavaScript time to look at both. 2. It is technically possible for the clientSize to change without the offset size changing. I think that changing the padding and/or borders could have this effect. Thanks, John LaBanca jlaba...@google.com On Mon, Mar 1, 2010 at 10:25 AM, j...@google.com wrote: On 2010/03/01 15:25:14, jgw wrote: On 2010/02/24 18:29:56, jlabanca wrote: Looks good. But is there any reason not to just look at the offset-size only? Not that it makes a huge difference, but it sounds like it could be a little simpler. (to be clear, if you're convinced that's necessary, please go ahead and commit) http://gwt-code-reviews.appspot.com/152801 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Issue 1700: ImageSrcIE6 throws native NPE exception
http://gwt-code-reviews.appspot.com/150807/diff/1/11 File user/src/com/google/gwt/dom/client/DOMImplIE6.java (right): http://gwt-code-reviews.appspot.com/150807/diff/1/11#newcode130 Line 130: }-*/; We now have this method in all of LayoutImplIE6, ClippedImageImplIE6, and DOMImplIE6. Could we just hoist it out into a deprecated public class in the .dom.client package so we can share it? I'd prefer to deprecate it with a notice that it might go away at any time and without warning, as soon as we come up with a better solution (i.e. Bob's soft perms stuff). http://gwt-code-reviews.appspot.com/150807 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] FocusImplStandard.focusHandler causes clinits
Reviewers: jlabanca, scottb, Description: Uploaded on behalf of scottb. FocusImplStandard.focusHandler is causing FocusImpl to need a clinit, which has trickle-down consequences. Fix: Lazily initialize focusHandler. Please review this at http://gwt-code-reviews.appspot.com/154808 Affected files: user/src/com/google/gwt/user/client/ui/impl/FocusImplStandard.java Index: user/src/com/google/gwt/user/client/ui/impl/FocusImplStandard.java --- user/src/com/google/gwt/user/client/ui/impl/FocusImplStandard.java (revision 7390) +++ user/src/com/google/gwt/user/client/ui/impl/FocusImplStandard.java (working copy) @@ -25,14 +25,12 @@ import com.google.gwt.user.client.Element; */ public class FocusImplStandard extends FocusImpl { - /* - * Use isolated method calls to create all of the handlers to avoid creating - * memory leaks via handler-closures-element. + /** + * Single focusHandler shared by all focusable. */ - JavaScriptObject focusHandler = createFocusHandler(); + static JavaScriptObject focusHandler; - @Override - public native Element createFocusable() /*-{ + private static native Element createFocusable0(JavaScriptObject focusHandler) /*-{ // Divs are focusable in all browsers, but only IE supports the accessKey // property on divs. We use the infamous 'hidden input' trick to add an // accessKey to the focusable div. Note that the input is only used to @@ -44,31 +42,38 @@ public class FocusImplStandard extends FocusImpl { var input = $doc.createElement('input'); input.type = 'text'; input.tabIndex = -1; -input.style.opacity = 0; -input.style.height = '1px'; -input.style.width = '1px'; -input.style.zIndex = -1; -input.style.overflow = 'hidden'; -input.style.position = 'absolute'; +var style = input.style; +style.opacity = 0; +style.height = '1px'; +style.width = '1px'; +style.zIndex = -1; +style.overflow = 'hidden'; +style.position = 'absolute'; // Note that we're using isolated lambda methods as the event listeners // to avoid creating a memory leaks. (Lambdas here would create cycles // involving the div and input). This also allows us to share a single // set of handlers among every focusable item. -input.addEventListener( - 'focus', - th...@com.google.gwt.user.client.ui.impl.focusimplstandard::focusHandler, - false); +input.addEventListener('focus', focusHandler, false); div.appendChild(input); return div; }-*/; @Override + public Element createFocusable() { +return createFocusable0(getFocusHandler()); + } + + @Override public native void setAccessKey(Element elem, char key) /*-{ elem.firstChild.accessKey = String.fromCharCode(key); }-*/; + /** + * Use an isolated method call to create the handler to avoid creating memory + * leaks via handler-closures-element. + */ private native JavaScriptObject createFocusHandler() /*-{ return function(evt) { // This function is called directly as an event handler, so 'this' is @@ -83,4 +88,8 @@ public class FocusImplStandard extends FocusImpl { } }; }-*/; + + private JavaScriptObject getFocusHandler() { +return focusHandler != null ? focusHandler : (focusHandler = createFocusHandler()); + } } -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: FocusImplStandard.focusHandler causes clinits
Sounds good on both counts. Would you might committing for me? :) http://gwt-code-reviews.appspot.com/154808 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: FocusImplStandard.focusHandler causes clinits
I'll commit it tomorrow. http://gwt-code-reviews.appspot.com/154808 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Fix to keep FocusWidget's setElement() implementation from clobbering
Reviewers: Dan Rice, Description: Fix to keep FocusWidget's setElement() implementation from clobbering tabindex when it's already set. This comes up in practice when calling, e.g., TextBox.wrap() on a static element that already had a perfectly good tabindex. Please review this at http://gwt-code-reviews.appspot.com/153815 Affected files: M user/src/com/google/gwt/user/client/ui/FocusWidget.java M user/test/com/google/gwt/user/client/ui/TextBoxTest.java Index: user/src/com/google/gwt/user/client/ui/FocusWidget.java === --- user/src/com/google/gwt/user/client/ui/FocusWidget.java (revision 7630) +++ user/src/com/google/gwt/user/client/ui/FocusWidget.java (working copy) @@ -272,7 +272,8 @@ // any calls made to FocusWidget.setTabIndex(int) by user code, because // FocusWidget.setTabIndex(int) cannot be called until setElement(elem) // has been called. -setTabIndex(0); - } - +if (-1 == getTabIndex()) { + setTabIndex(0); +} + } } Index: user/test/com/google/gwt/user/client/ui/TextBoxTest.java === --- user/test/com/google/gwt/user/client/ui/TextBoxTest.java(revision 7630) +++ user/test/com/google/gwt/user/client/ui/TextBoxTest.java(working copy) @@ -14,6 +14,9 @@ * the License. */ package com.google.gwt.user.client.ui; + +import com.google.gwt.dom.client.DivElement; +import com.google.gwt.dom.client.Document; /** * Testing TextBox. @@ -32,7 +35,7 @@ // As our setText does not honor max length, no way to text it in the wild // here. } - + public void testMinLength() { TextBox b = createTextBoxBase(); b.setVisibleLength(5); @@ -44,4 +47,14 @@ // Now check visible length. assertEquals(5, b.getVisibleLength()); } + + public void testNoNukeTabIndex() { +Document doc = Document.get(); +DivElement div = doc.createDivElement(); +div.setInnerHTML(input type='text' id='tb' tabindex='1'/input); +doc.getBody().appendChild(div); + +TextBox tb = TextBox.wrap(doc.getElementById(tb)); +assertEquals(1, tb.getTabIndex()); + } } -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] meta tag applying to just one module?
The meta tag system is a general system for a host page to influence a loaded GWT module. One aspect I don't understand, however: is there an existing way to have it apply to just one module, if multiple GWT modules are loaded on the same page? The reason this comes up is that I would like to make the magic base URL be settable by the host page for people who have inlined the selection script into the host page. For such people, the built-in magic can do the wrong thing. The first idea that was suggested was to use a meta tag. However, wouldn't t hat by default apply to all GWT apps loaded on the page? It might be that one app comes from one server and the other from a different one. If there is no other idea around, then perhaps we could bake the module into the name parameter, like this: meta name=com.google.gwt.sample.mail.Mail::baseUrl content= http://static-content.service.com/mail; If no :: is present, then the setting applies to every module. Lex -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Fix for issue 4595: In TabLayoutPanel, inserting a tab before the currently
Reviewers: Dan Rice, Description: Fix for issue 4595: In TabLayoutPanel, inserting a tab before the currently selected tab causes problems due to not incrementing selectedIndex. Please review this at http://gwt-code-reviews.appspot.com/153816 Affected files: M user/src/com/google/gwt/user/client/ui/TabLayoutPanel.java M user/test/com/google/gwt/user/client/ui/TabLayoutPanelTest.java Index: user/src/com/google/gwt/user/client/ui/TabLayoutPanel.java === --- user/src/com/google/gwt/user/client/ui/TabLayoutPanel.java (revision 7630) +++ user/src/com/google/gwt/user/client/ui/TabLayoutPanel.java (working copy) @@ -474,6 +474,10 @@ if (selectedIndex == -1) { selectTab(0); +} else if (selectedIndex = beforeIndex) { + // If we inserted before the currently selected tab, its index has just + // increased. + selectedIndex++; } } Index: user/test/com/google/gwt/user/client/ui/TabLayoutPanelTest.java === --- user/test/com/google/gwt/user/client/ui/TabLayoutPanelTest.java (revision 7630) +++ user/test/com/google/gwt/user/client/ui/TabLayoutPanelTest.java (working copy) @@ -59,6 +59,14 @@ HasWidgetsTester.testAll(new TabLayoutPanel(1, Unit.EM), new Adder(), true); } + public void testInsertBeforeSelected() { +TabLayoutPanel p = new TabLayoutPanel(2, Unit.EM); +p.add(new Label(foo), foo); +p.selectTab(0); +p.insert(new Label(bar), bar, 0); +assertEquals(1, p.getSelectedIndex()); + } + public void testInsertMultipleTimes() { TabLayoutPanel p = new TabLayoutPanel(2, Unit.EM); -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Fix for issue 4595: In TabLayoutPanel, inserting a tab before the currently
LGTM http://gwt-code-reviews.appspot.com/153816 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Fix to keep FocusWidget's setElement() implementation from clobbering
LGTM http://gwt-code-reviews.appspot.com/153815 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Fix for issue 4595: In TabLayoutPanel, inserting a tab before the currently
On 2010/03/01 18:48:48, Dan Rice wrote: LGTM Committed at r7633. http://gwt-code-reviews.appspot.com/153816 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
Re: [gwt-contrib] meta tag applying to just one module?
Avoiding the larger issue of meta tags applying globally, I'd think for this case there should be a more direct way to do it. What I mean is, you have to load the *.cache.html files from *somewhere*. So (from the inlined selection script), you have to do something roughly equivalent to: iframe.src = baseUrl + strongHash + .cache.html It seems like... whatever process is used to inline the selection script in the first place, has to be able to specify the base URL, at least relative to the host page base url. Am I understanding this right? On Mon, Mar 1, 2010 at 12:38 PM, Lex Spoon sp...@google.com wrote: The meta tag system is a general system for a host page to influence a loaded GWT module. One aspect I don't understand, however: is there an existing way to have it apply to just one module, if multiple GWT modules are loaded on the same page? The reason this comes up is that I would like to make the magic base URL be settable by the host page for people who have inlined the selection script into the host page. For such people, the built-in magic can do the wrong thing. The first idea that was suggested was to use a meta tag. However, wouldn't t hat by default apply to all GWT apps loaded on the page? It might be that one app comes from one server and the other from a different one. If there is no other idea around, then perhaps we could bake the module into the name parameter, like this: meta name=com.google.gwt.sample.mail.Mail::baseUrl content= http://static-content.service.com/mail; If no :: is present, then the setting applies to every module. Lex -- http://groups.google.com/group/Google-Web-Toolkit-Contributors -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Fix to keep FocusWidget's setElement() implementation from clobbering
On 2010/03/01 20:46:35, Dan Rice wrote: LGTM Committed at r7635. http://gwt-code-reviews.appspot.com/153815 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Fix to keep FocusWidget's setElement() implementation from clobbering
On 2010/03/01 21:25:56, jgw wrote: On 2010/03/01 20:46:35, Dan Rice wrote: LGTM Committed at r7635. Rolling back. This is causing unexpected failures on Firefox. http://gwt-code-reviews.appspot.com/153815 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] [google-web-toolkit] r7635 committed - Fix to keep FocusWidget's setElement() implementation from clobbering...
Revision: 7635 Author: j...@google.com Date: Mon Mar 1 09:49:01 2010 Log: Fix to keep FocusWidget's setElement() implementation from clobbering tabindex when it's already set. This comes up in practice when calling, e.g., TextBox.wrap() on a static element that already had a perfectly good tabindex. Review at http://gwt-code-reviews.appspot.com/153815 http://code.google.com/p/google-web-toolkit/source/detail?r=7635 Modified: /trunk/user/src/com/google/gwt/user/client/ui/FocusWidget.java /trunk/user/test/com/google/gwt/user/client/ui/TextBoxTest.java === --- /trunk/user/src/com/google/gwt/user/client/ui/FocusWidget.java Fri Mar 20 11:33:42 2009 +++ /trunk/user/src/com/google/gwt/user/client/ui/FocusWidget.java Mon Mar 1 09:49:01 2010 @@ -272,7 +272,8 @@ // any calls made to FocusWidget.setTabIndex(int) by user code, because // FocusWidget.setTabIndex(int) cannot be called until setElement(elem) // has been called. -setTabIndex(0); - } - -} +if (-1 == getTabIndex()) { + setTabIndex(0); +} + } +} === --- /trunk/user/test/com/google/gwt/user/client/ui/TextBoxTest.java Fri Apr 4 09:22:37 2008 +++ /trunk/user/test/com/google/gwt/user/client/ui/TextBoxTest.java Mon Mar 1 09:49:01 2010 @@ -15,6 +15,9 @@ */ package com.google.gwt.user.client.ui; +import com.google.gwt.dom.client.DivElement; +import com.google.gwt.dom.client.Document; + /** * Testing TextBox. */ @@ -32,7 +35,7 @@ // As our setText does not honor max length, no way to text it in the wild // here. } - + public void testMinLength() { TextBox b = createTextBoxBase(); b.setVisibleLength(5); @@ -44,4 +47,14 @@ // Now check visible length. assertEquals(5, b.getVisibleLength()); } -} + + public void testNoNukeTabIndex() { +Document doc = Document.get(); +DivElement div = doc.createDivElement(); +div.setInnerHTML(input type='text' id='tb' tabindex='1'/input); +doc.getBody().appendChild(div); + +TextBox tb = TextBox.wrap(doc.getElementById(tb)); +assertEquals(1, tb.getTabIndex()); + } +} -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Comment on ValueStoreAndRequestFactory in google-web-toolkit
Comment by jon.nermut: This looks promising. Mirrors some of my ideas at http://groups.google.com/group/google-web-toolkit-contributors/browse_thread/thread/ebeb2a9ddc3cfd52/7534d2c15d49e40d I like the emphasis on DRY A couple of points: 1. One big DRY problem - repeating all the fields in the view class as @UiField despite them never being used in the class. You should be able to declare fields in the UiBinder without having to repeat in the view if all they do is bind to a model property. 2. This leads to needing a way of expressing a data bind in UiBinder, which means UiBinder needs to know about the data binder. There are two approaches I can think of - ui:bind='expression' or value='{expression}' . The second might be the best as I think you should be able to bind other properties beside value - eg visible or styleName are the prime use cases. 3. Need a proper expression language in UiBinder to express binds. The current {method.method} binding in UiBinder could be extended, but needs a lot of work as its very simplistic currently 4. Please support weakly typed models. Particularly the use cases of the model being a Map, a JSONObject or an XML Node. Suggest building this into the expression language similar to JSF EL notation eg foo.bar['x'] and foo.bar.x both translate to foo.bar.get(x) if bar implements Map For more information: http://code.google.com/p/google-web-toolkit/wiki/ValueStoreAndRequestFactory -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] [google-web-toolkit] r7636 committed - Better cast optimization where only one concrete type exists....
Revision: 7636 Author: sco...@google.com Date: Mon Mar 1 09:59:34 2010 Log: Better cast optimization where only one concrete type exists. http://gwt-code-reviews.appspot.com/154807/show Review by: cromwellian http://code.google.com/p/google-web-toolkit/source/detail?r=7636 Modified: /trunk/dev/core/src/com/google/gwt/dev/jjs/impl/TypeTightener.java === --- /trunk/dev/core/src/com/google/gwt/dev/jjs/impl/TypeTightener.java Wed Dec 9 09:10:40 2009 +++ /trunk/dev/core/src/com/google/gwt/dev/jjs/impl/TypeTightener.java Mon Mar 1 09:59:34 2010 @@ -387,8 +387,14 @@ return; } - JReferenceType toType = (JReferenceType) x.getCastType(); - JReferenceType fromType = (JReferenceType) argType; + JReferenceType toType = getSingleConcreteType(x.getCastType()); + if (toType == null) { +toType = (JReferenceType) x.getCastType(); + } + JReferenceType fromType = getSingleConcreteType(argType); + if (fromType == null) { +fromType = (JReferenceType) argType; + } boolean triviallyTrue = false; boolean triviallyFalse = false; @@ -465,8 +471,14 @@ return; } - JReferenceType toType = x.getTestType(); - JReferenceType fromType = (JReferenceType) argType; + JReferenceType toType = getSingleConcreteType(x.getTestType()); + if (toType == null) { +toType = x.getTestType(); + } + JReferenceType fromType = getSingleConcreteType(argType); + if (fromType == null) { +fromType = (JReferenceType) argType; + } boolean triviallyTrue = false; boolean triviallyFalse = false; -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] [google-web-toolkit] r7637 committed - JsNew's constructor target expression should be immutable....
Revision: 7637 Author: sco...@google.com Date: Mon Mar 1 10:24:16 2010 Log: JsNew's constructor target expression should be immutable. http://gwt-code-reviews.appspot.com/154806/show Review by: cromwellian http://code.google.com/p/google-web-toolkit/source/detail?r=7637 Modified: /trunk/dev/core/src/com/google/gwt/dev/jjs/impl/GenerateJavaScriptAST.java /trunk/dev/core/src/com/google/gwt/dev/js/JsHoister.java /trunk/dev/core/src/com/google/gwt/dev/js/JsParser.java /trunk/dev/core/src/com/google/gwt/dev/js/ast/JsNew.java === --- /trunk/dev/core/src/com/google/gwt/dev/jjs/impl/GenerateJavaScriptAST.java Mon Mar 1 09:03:44 2010 +++ /trunk/dev/core/src/com/google/gwt/dev/jjs/impl/GenerateJavaScriptAST.java Mon Mar 1 10:24:16 2010 @@ -1102,9 +1102,8 @@ @Override public void endVisit(JNewInstance x, Context ctx) { - JsNew newOp = new JsNew(x.getSourceInfo()); JsNameRef nameRef = names.get(x.getClassType()).makeRef(x.getSourceInfo()); - newOp.setConstructorExpression(nameRef); + JsNew newOp = new JsNew(x.getSourceInfo(), nameRef); push(newOp); } @@ -1600,10 +1599,9 @@ lhs.setQualifier(seedFuncName.makeRef(sourceInfo)); JsExpression rhs; if (x.getSuperClass() != null) { - JsNew newExpr = new JsNew(sourceInfo); JsNameRef superPrototypeRef = names.get(x.getSuperClass()).makeRef( sourceInfo); - newExpr.setConstructorExpression(superPrototypeRef); + JsNew newExpr = new JsNew(sourceInfo, superPrototypeRef); rhs = newExpr; } else { rhs = new JsObjectLiteral(sourceInfo); === --- /trunk/dev/core/src/com/google/gwt/dev/js/JsHoister.java Mon Oct 26 14:02:26 2009 +++ /trunk/dev/core/src/com/google/gwt/dev/js/JsHoister.java Mon Mar 1 10:24:16 2010 @@ -39,6 +39,7 @@ import com.google.gwt.dev.js.ast.JsThisRef; import com.google.gwt.dev.js.ast.JsVisitor; +import java.util.ArrayList; import java.util.List; import java.util.Stack; @@ -151,14 +152,13 @@ @Override public void endVisit(JsNew x, JsContextJsExpression ctx) { - JsNew toReturn = new JsNew(x.getSourceInfo()); - - ListJsExpression arguments = toReturn.getArguments(); int size = x.getArguments().size(); + ListJsExpression arguments = new ArrayListJsExpression(size); while (size-- 0) { arguments.add(0, stack.pop()); } - toReturn.setConstructorExpression(stack.pop()); + JsNew toReturn = new JsNew(x.getSourceInfo(), stack.pop()); + toReturn.getArguments().addAll(arguments); stack.push(toReturn); } === --- /trunk/dev/core/src/com/google/gwt/dev/js/JsParser.java Thu Aug 13 12:43:26 2009 +++ /trunk/dev/core/src/com/google/gwt/dev/js/JsParser.java Mon Mar 1 10:24:16 2010 @@ -807,14 +807,12 @@ } private JsNew mapNew(Node newNode) throws JsParserException { - -JsNew newExpr = new JsNew(makeSourceInfo(newNode)); - // Map the constructor expression, which is often just the name of // some lambda. // Node fromCtorExpr = newNode.getFirstChild(); -newExpr.setConstructorExpression(mapExpression(fromCtorExpr)); +JsNew newExpr = new JsNew(makeSourceInfo(newNode), +mapExpression(fromCtorExpr)); // Iterate over and map the arguments. // === --- /trunk/dev/core/src/com/google/gwt/dev/js/ast/JsNew.java Fri Sep 26 08:20:00 2008 +++ /trunk/dev/core/src/com/google/gwt/dev/js/ast/JsNew.java Mon Mar 1 10:24:16 2010 @@ -29,8 +29,9 @@ private JsExpression ctorExpr; - public JsNew(SourceInfo sourceInfo) { + public JsNew(SourceInfo sourceInfo, JsExpression ctorExpr) { super(sourceInfo); +this.ctorExpr = ctorExpr; } public ListJsExpression getArguments() { @@ -57,10 +58,6 @@ public boolean isDefinitelyNull() { return false; } - - public void setConstructorExpression(JsExpression ctorExpr) { -this.ctorExpr = ctorExpr; - } public void traverse(JsVisitor v, JsContextJsExpression ctx) { if (v.visit(this, ctx)) { -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Remove unused JClassSeed.
LGTM. http://gwt-code-reviews.appspot.com/153810 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
Re: [gwt-contrib] Re: Better cast optimization where only one concrete type exists - in what scope, actually?
The context is during the compiler optimization loop, so this affects types that are actually reachable from your application. As the compile proceeds, this list shrinks down as we do more and more optimization elimintation. What this patch does is effectively rewrite certain cast operations from an abstract type to a concrete type, if we have determined that there's only one possible concrete subclass. For example, if CFoo is the only type in your program that implements the IFoo interface, then: (IFoo) someValue is equivalent to writing: (CFoo) someValue It's more useful to express this in terms of the more derived type, because you 'gain' local information by reason of global information. On Mon, Mar 1, 2010 at 5:47 PM, Bart Guijt bgu...@gmail.com wrote: Scott/Ray, I like what you guys are squeezing out of the compiler! Just glancing over the sources doesn't give me a clear answer: This particular patch, is it *only* checking for types which are actually used in GWT client code? (e.g., what types are put in JTypeOracle?) Bart Revision: 7636 Author: sco...@google.com Date: Mon Mar 1 09:59:34 2010 Log: Better cast optimization where only one concrete type exists. http://gwt-code-reviews.appspot.com/154807/show Review by: cromwellian http://code.google.com/p/google-web-toolkit/source/detail?r=7636 Modified: /trunk/dev/core/src/com/google/gwt/dev/jjs/impl/TypeTightener.java -- http://groups.google.com/group/Google-Web-Toolkit-Contributors -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Allowing support to field references inside html elements and GWT widgets.
LGTM Thanks, Hermes! Just one JavaDoc nit below. http://gwt-code-reviews.appspot.com/153813/diff/1/4 File user/src/com/google/gwt/uibinder/elementparsers/UiTextInterpreter.java (right): http://gwt-code-reviews.appspot.com/153813/diff/1/4#newcode23 Line 23: * Interprets i18n tags like: blt;ui:text from={myMsg.message} /gt;/b. These are not i18n specific. They're any field reference that produces a string. http://gwt-code-reviews.appspot.com/153813 -- http://groups.google.com/group/Google-Web-Toolkit-Contributors