Re: Android (1.5) Browser displays empty page
On 18 Aug., 01:07, Thomas Broyer t.bro...@gmail.com wrote: A quick Google search led me tohttp://stackoverflow.com/questions/468993 Unfortunately this reveals nothing at all. No output related to any JS errors, etc. In the meantime I found, that accessing the same GWT application using an iPhone shows the same behaviour: blank page. Michael --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to Google-Web-Toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~--~~~~--~~--~--~---
Re: GALGWT, Eclipse 3.5 / Galileo, and GWT 1.7 -- how to add this or any other GWT library to projects?
Thanks Philip! I'll give this a try -- it worked fine in hosted mode I assume. On Tue, Aug 18, 2009 at 3:31 AM, philipmac philipmacmena...@gmail.comwrote: Hey, so I've been mucking about with this for say... a couple of hours. And, ehh, I never actually used Eclipse until tonight, and I'm a Perl coder. So, ahem, take what I say with this in mind... but, I just right click on my project, go to Properties, into the Java Build Path, Add External Jars, and stick in the external jar file into the project. Although, for some magical reason of which I am unaware of, you have to use the noredist gears jar. Give it a try. On Aug 17, 7:03 pm, Julian julian.har...@gmail.com wrote: Hi all, firstly the GWT / AppEngine plugin for Eclipse is sensational. To be able to deploy to production so easily is amazing. However a basic question -- how do you add other GWT libraries? I wanted to extend the template given by making a geolocation API call in gwt-gears I'm struggling to figure out where to add gwt-gears.jar. 1. I added it to my project's lib folder along with the other jars that were included in the default project but they are not presented through the GUI as available to add. 2. Adding them as 'external jars' solves the IDE syntax checking issues but then unsurprisingly crashes in hosted mode. I'm missing something basic I'm sure about how to add GWT libraries -- anyone have any suggestions? thanks! (This is for GALGWT, Eclipse 3.5 / Galileo, and GWT 1.7) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: SmartGWT 1.2 Tile Sort Filtering Example Question Fuzzy Search / (Maybe Bug)?
Jan,Please post SmartGWT specific questions on the SmartGWT forum : http://forums.smartclient.com/forumdisplay.php?f=14 Thanks, Sanjiv On Mon, Aug 17, 2009 at 7:00 PM, Jan weitz@googlemail.com wrote: Hi everybody, I am just new to GWT and experiencing a little bit with SmartGWT, implementing and trying to change the Tile Sort Filtering Example from the Showcase http://www.smartclient.com/smartgwt/showcase/#featured_tile_filtering I am trying to implement the above example with a fuzzy search but without the extra SearchItems, which causes the FuzzySearch to fail and draw back on an EQUALS search. Everything works fine with the example, but here comes my 'error' / 'bug' : Here is an excerpt from the code from the showcase example: code final DynamicForm filterForm = new DynamicForm(); filterForm.setIsGroup(true); filterForm.setGroupTitle(Search); filterForm.setNumCols(6); filterForm.setDataSource(AnimalXmlDS.getInstance()); filterForm.setAutoFocus(false); TextItem commonNameItem = new TextItem(commonName); SliderItem lifeSpanItem = new SliderItem(lifeSpan); lifeSpanItem.setTitle(Max Life Span); lifeSpanItem.setMinValue(1); lifeSpanItem.setMaxValue(60); lifeSpanItem.setDefaultValue(60); lifeSpanItem.setHeight(50); lifeSpanItem.setOperator(OperatorId.LESS_THAN); SelectItem statusItem = new SelectItem(status); statusItem.setOperator(OperatorId.EQUALS); statusItem.setAllowEmptyValue(true); filterForm.setFields(commonNameItem, lifeSpanItem, statusItem); filterForm.addItemChangedHandler(new ItemChangedHandler() { public void onItemChanged(ItemChangedEvent event) { tileGrid.fetchData(filterForm.getValuesAsCriteria()); } }); /code Three search items are created and fit together in the filterForm. Using the form and entering just a part of a Common Name, will break down the results with each letter I type. Now comes the bad part: I do not want the lifeSpanItem and statusItem any more. So I change code filterForm.setFields(commonNameItem, lifeSpanItem, statusItem); /code to code filterForm.setFields(commonNameItem); /code Now, trying to enter just a part of a Common Name will not break down my results with each letter I type, but instead the behaviour is like commonNameItem.setOperator(OperatorId.EQUALS) So what I am saying is that the search works fine for searchItems greater than just one TextField. My workaround therefore was to create a HiddenItem as follows: code HiddenItem tagsItem = new HiddenItem(tags); tagsItem.setOperator(OperatorId.EQUALS); filterForm.setFields(commonNameItem, tagsItem); /code Now I think that this can't be right. Now am I missing something? Do I have to use .setOperator on commonNameItem, if only commonNameItem is present? If yes: Which OperatorId should I choose? Thank you very much for your help, Greets, Jan --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Servlet is not getting called in my GWT application.Why?
Hi all, I want to use Flash with Servlets within my GWT application/ project. In my application/project,When a GWTButton is clicked,I am calling a flash[.fla/.swf] application which is placed in public folder within my project. It works fine upto this point[Hence, Flash contents are visible]. Here,my flash application contains images. From flash,I am calling Java servlets placed in com/project/server/servlet folder within my GWT project to store/retreive data between Flash database respectively and this is what the servlets do. I have deployed servlets in Tomcat server. When I execute the application and click on GWTButton, flash contents appears fine. When I click on the contents of Flash file,a servlet should be called.But, the servlet is not getting called. Instead, it shows an error in a diaog box which belongs to Flash as: [B]Error #2044: Unhandled ioError:. text=Error #2032: Stream Error. URL: http://localhost/webapps/ROOT/servlet/xmlServlet?viewid=2 at DynaAccess_fla::MainTimeline/createXML() at DynaAccess_fla::MainTimeline/onChecked()[/B] Note: These are the details of my application: Servlets are deployed in /Tomcat6.0/ROOT folder Servlets source code is present incom/project/server/ servlet folder web.xml is placed at \Tomcat 6.0\webapps\ROOT\WEB-INF folder In web.xml file, I have placed url-pattern for my servlets as: ...bla ...bla servlet servlet-nameXmlServlet/servlet-name servlet-classcom.project.server.servlet.XmlServlet/servlet- class /servlet servlet-mapping servlet-nameXmlServlet/servlet-name url-pattern/servlet/xmlServlet/url-pattern /servlet-mapping ...bla ...bla In flash application, I have mentioned a servlet-url as [B]http:// localhost/servlet/xmlServlet[B]. But, it displays the same error which is mentioned above[viz., Error# 2044...]. Why I am unable to call the servlet? Please can anyone reply me with a solution or atleast cause for this problem... Thanks in advance.. Waiting for your replies... Srihari.Ch --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
TabPanel mouseover
I have a TabPanel where some specific styling of the tab headers are needed. One style for the selected tab header, and another when the mouse is over a tab header that is not selected. All this work fine ... except that sometimes when changing tabs the mouseOver style is not removed. When adding tabs to the TabPanel I use the add(Widget w, Widget tabWidget) method, where tabWidget is a custom version of Label: --- public class TabHeaderWidget extends Label { public TabHeaderWidget(String s) { super(s); // enable mouseOver/mouseOut events on the label sinkEvents(Event.ONMOUSEOVER|Event.ONMOUSEOUT); } @Override public void onBrowserEvent(Event event) { if (getParent().getStyleName().indexOf(gwt-TabBarItem- selected) == -1) { // only do mouseover effect if the tab is NOT selected. switch (event.getTypeInt()) { case Event.ONMOUSEOVER: mouseOver(); break; case Event.ONMOUSEOUT: mouseOut(); break; } } else { // This was an early attempt to solve the problem :-/ mouseOut(); } } private void mouseOver() { // add style for text color addStyleName(tabhover); } private void mouseOut() { // remove style for text color removeStyleName(tabhover); } } --- Any ideas as to why this should not _always_ work? (btw, i'm using gwt1.5.2) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Servlet is not getting called in my GWT application.Why?
Hi, Srihari.Ch schrieb: Instead, it shows an error in a diaog box which belongs to Flash as: [B]Error #2044: Unhandled ioError:. text=Error #2032: Stream Error. URL: http://localhost/webapps/ROOT/servlet/xmlServlet?viewid=2 [...] servlet-mapping servlet-nameXmlServlet/servlet-name url-pattern/servlet/xmlServlet/url-pattern /servlet-mapping ...bla ...bla After checking Google, the error-code is returned e.g. if the URL being specified can't be found. Check out your request- log and see if the request the flash is performing lead to a 404-response (or something else than a 200). Personally I think it will be a 404 because your URL above does not fit the mapping you've defined. Regards, Lothar --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: SmartGWT 1.2 Tile Sort Filtering Example Question Fuzzy Search / (Maybe Bug)?
Sanjiv, I thought of doing it. But I also thought I won't make me any friends crossposting. Greets, Jan On Aug 18, 2009, at 9:32 AM, Sanjiv Jivan wrote: Jan, Please post SmartGWT specific questions on the SmartGWT forum : http://forums.smartclient.com/forumdisplay.php?f=14 Thanks, Sanjiv On Mon, Aug 17, 2009 at 7:00 PM, Jan weitz@googlemail.com wrote: Hi everybody, I am just new to GWT and experiencing a little bit with SmartGWT, implementing and trying to change the Tile Sort Filtering Example from the Showcase http://www.smartclient.com/smartgwt/showcase/#featured_tile_filtering I am trying to implement the above example with a fuzzy search but without the extra SearchItems, which causes the FuzzySearch to fail and draw back on an EQUALS search. Everything works fine with the example, but here comes my 'error' / 'bug' : Here is an excerpt from the code from the showcase example: code final DynamicForm filterForm = new DynamicForm(); filterForm.setIsGroup(true); filterForm.setGroupTitle(Search); filterForm.setNumCols(6); filterForm.setDataSource(AnimalXmlDS.getInstance()); filterForm.setAutoFocus(false); TextItem commonNameItem = new TextItem(commonName); SliderItem lifeSpanItem = new SliderItem(lifeSpan); lifeSpanItem.setTitle(Max Life Span); lifeSpanItem.setMinValue(1); lifeSpanItem.setMaxValue(60); lifeSpanItem.setDefaultValue(60); lifeSpanItem.setHeight(50); lifeSpanItem.setOperator(OperatorId.LESS_THAN); SelectItem statusItem = new SelectItem(status); statusItem.setOperator(OperatorId.EQUALS); statusItem.setAllowEmptyValue(true); filterForm.setFields(commonNameItem, lifeSpanItem, statusItem); filterForm.addItemChangedHandler(new ItemChangedHandler() { public void onItemChanged(ItemChangedEvent event) { tileGrid.fetchData(filterForm.getValuesAsCriteria()); } }); /code Three search items are created and fit together in the filterForm. Using the form and entering just a part of a Common Name, will break down the results with each letter I type. Now comes the bad part: I do not want the lifeSpanItem and statusItem any more. So I change code filterForm.setFields(commonNameItem, lifeSpanItem, statusItem); /code to code filterForm.setFields(commonNameItem); /code Now, trying to enter just a part of a Common Name will not break down my results with each letter I type, but instead the behaviour is like commonNameItem.setOperator(OperatorId.EQUALS) So what I am saying is that the search works fine for searchItems greater than just one TextField. My workaround therefore was to create a HiddenItem as follows: code HiddenItem tagsItem = new HiddenItem(tags); tagsItem.setOperator(OperatorId.EQUALS); filterForm.setFields(commonNameItem, tagsItem); /code Now I think that this can't be right. Now am I missing something? Do I have to use .setOperator on commonNameItem, if only commonNameItem is present? If yes: Which OperatorId should I choose? Thank you very much for your help, Greets, Jan --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Servlet is not getting called in my GWT application.Why?
Hi Lothar Kimmeringer, After checking Google, the error-code is returned e.g. if the URL being specified can't be found. Check out your request- log and see if the request the flash is performing lead to a 404-response (or something else than a 200). Personally I think it will be a 404 because your URL above does not fit the mapping you've defined. Thanks for your reply... Can you please tell me how to check the error-code which you mentioned above. Or else, Can you tell me what to do in order to move near to the solution? I will be waiting for reply... Srihari.Ch --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Servlet is not getting called in my GWT application.Why?
Srihari.Ch schrieb: After checking Google, the error-code is returned e.g. if the URL being specified can't be found. Check out your request- log and see if the request the flash is performing lead to a 404-response (or something else than a 200). Personally I think it will be a 404 because your URL above does not fit the mapping you've defined. Can you please tell me how to check the error-code which you mentioned above. Open the request log of your web server with the text-editor of your choice and read the content. Or else, Can you tell me what to do in order to move near to the solution? Fix the URL. I don't think that /webapps/ROOT/ should be really a part of it. The correct URL I can't tell, because I don't know your server-configuration. Regards, Lothar --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
how can capture screenshot for active dialog box without background?
Hi, everyone! We've recently work on a Web Application testing Script which was create with Selenium IDE in Firefox. This automatic testing Script should also capture screenshots. but when a dialog box appear, we want just capture the dialog box, not the all content in web browser. Any advices on such solution? thx --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Linux 64bits package?
Thanks Rajeev. I'll try the out of process hosted mode. --Luigi On Mon, Aug 17, 2009 at 10:15 PM, Lucas Neves Martinssnown...@gmail.com wrote: Rajeev Dayal says: ... the next release of GWT will no longer require that you use a 32-bit JVM. It will support a mode of execution known as Out-of-process-hosted-mode. Instead of debugging your application using the hosted browser, you'll be able to debug it while it runs in a real browser. Since the hosted browser will no longer be required, neither will the 32-bit SWT libraries that we bundle. If you're adventurous, you can try out this functionality right now - check out the GWT source, and do a trunk build. It should work with the plugin. Good luck! On 17 ago, 08:59, Luigi R. Viggiano luigi.viggi...@gmail.com wrote: Hi. I am using Linux 64-Bit (Ubuntu 9.04) with the provided JDK 6 from Sun. Is it planned a 64-Bit distro for GWT? Or, as alternative, is GWT 1.7 Out-of-process-hosted-mode ready? The reason why I am asking, ist that with this configuration, the -d32 option in JDK is not working, I think it's an Ubuntu package bug, and this leads to problems; for example, using hosted mode with maven. P.S. I already found this :http://groups.google.com/group/Google-Web-Toolkit/browse_thread/threa... But I am writing to say that ia32-sun-java6-bin doesn't solve all the problems: when you have to compile+run, the 32 bit JRE is not enough Thanks. Have a nice day. --Luigi Luigi R. Viggiano Web/Blog:http://www.newinstance.it Skype: luigi.viggiano My Professional Profile:http://www.linkedin.com/in/viggiano --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Where is Tomcat webapp Folder.
Hi all, I'm kinda new to GWT and Tomcat :) ... I have a VPS with CentOS 5 installed. Tomcat5 and java is also installed in the system. The CATALINA_HOME is empty when I try to echo it so I cannot find $CATALINA_HOME/webapp. Where is the webapp folder that I use to deploy my GWT app. where is tomcat typically installed? Did I install tomcat wrongly? How can I test if Tomcat is running ? Can you please help. Thanks Alaa Gharbawi --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Servlet is not getting called in my GWT application.Why?
Thanks Lothar. On Aug 18, 1:45 pm, Lothar Kimmeringer j...@kimmeringer.de wrote: Srihari.Ch schrieb: After checking Google, the error-code is returned e.g. if the URL being specified can't be found. Check out your request- log and see if the request the flash is performing lead to a 404-response (or something else than a 200). Personally I think it will be a 404 because your URL above does not fit the mapping you've defined. Can you please tell me how to check the error-code which you mentioned above. Open the request log of your web server with the text-editor of your choice and read the content. Or else, Can you tell me what to do in order to move near to the solution? Fix the URL. I don't think that /webapps/ROOT/ should be really a part of it. The correct URL I can't tell, because I don't know your server-configuration. Regards, Lothar This is the error I found in Apache2.2/conf/error.log file: [Tue Aug 18 10:41:57 2009] [error] [client 127.0.0.1] File does not exist: D:/websites/mymdworld/webapps/ROOT/servlet, referer: file:///C|/Program%20Files/Apache%20Software%20Foundation/Tomcat%206.0/webapps/ROOT/DynaAccess.swf [Tue Aug 18 10:42:05 2009] [error] [client 127.0.0.1] File does not exist: D:/websites/mymdworld/webapps/ROOT/servlet, referer: file:///C|/Program%20Files/Apache%20Software%20Foundation/Tomcat%206.0/webapps/ROOT/DynaAccess.swf Please, Can you explain me with an example on your own? In my system: Tomcat6.0 is present in /Tomcat6.0/ Apache2.2 is present in /Apache2.2/ folders respectively. Thanks in advance... Srihari.Ch --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Where is Tomcat webapp Folder.
Which OS you are using? If Windows then, Check whether Tomcat service is started.. If started..., Once open the following url in browser: http://localhost:8080/ Coming to web-apps: It is present in the drive where OS is installed in your system. In that drive, Open Program files(or Programs)/.../Tomcat 6.0/webapps folder. Check it out On Tue, Aug 18, 2009 at 2:39 PM, AGharbawi agharb...@gmail.com wrote: Hi all, I'm kinda new to GWT and Tomcat :) ... I have a VPS with CentOS 5 installed. Tomcat5 and java is also installed in the system. The CATALINA_HOME is empty when I try to echo it so I cannot find $CATALINA_HOME/webapp. Where is the webapp folder that I use to deploy my GWT app. where is tomcat typically installed? Did I install tomcat wrongly? How can I test if Tomcat is running ? Can you please help. Thanks Alaa Gharbawi Srihari.Ch --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Where is Tomcat webapp Folder.
Hi when I do http://localhost:8080/ i get this html HTTP Status 404 - type Status report message description The requested resource () is not available. Apache Tomcat/5.5.27 so I think think this mean that tomcat is working fine, right? I'm using CentOS 5 (Unix System) for the server.Do you know where can I find it there? And do you know why os CATALINA_HOME is not set? Thanks Srihari On Aug 18, 12:25 pm, Srihari Ch sriharich@gmail.com wrote: Which OS you are using? If Windows then, Check whether Tomcat service is started.. If started..., Once open the following url in browser:http://localhost:8080/ Coming to web-apps: It is present in the drive where OS is installed in your system. In that drive, Open Program files(or Programs)/.../Tomcat 6.0/webapps folder. Check it out On Tue, Aug 18, 2009 at 2:39 PM, AGharbawi agharb...@gmail.com wrote: Hi all, I'm kinda new to GWT and Tomcat :) ... I have a VPS with CentOS 5 installed. Tomcat5 and java is also installed in the system. The CATALINA_HOME is empty when I try to echo it so I cannot find $CATALINA_HOME/webapp. Where is the webapp folder that I use to deploy my GWT app. where is tomcat typically installed? Did I install tomcat wrongly? How can I test if Tomcat is running ? Can you please help. Thanks Alaa Gharbawi Srihari.Ch --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
chrome/safari error
His I am getting the following error in Chrome (and Safari also doesn't work; Firefox and IE are ok) TypeError: Object #a Document has no method 'write' Same problem was reported in http://groups.google.com/group/google-web-toolkit/browse_frm/thread/e84e07a4c36f91db/593492d3689bf731?lnk=gstq=gwt++Object+%23%3Ca+Document%3E+has+no+method+%27write%27#593492d3689bf731 I am also using JSF with RichFaces and the code works without RichFaces code. Has anyone idea/experience of solving the issue? Many thanks, Denis --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Creating Reuseable Modules
Thanks for the reply Lucas - yeh, didn't really answer my question but thanks anyway ;o) The problem is where I work I am the only front-end engineer/designer everyone else is a java programmer - so they *need* something that enables them to write java and forget about the rest - we have been using Echo2 (against my recommendation) and are now looking at GWT - again, against my recommendation (there isn't anything that GWT or Echo2 or AnotherJavaToJavascript Framework can do that a dedicated team of front-end engineers can't do... but I guess thats GWTs (et al) biggest selling point), don't get me wrong I think what the GWT engineers have been able to produce is *very* clever... Is there no one else listening/reading that has come accross this issue/problem of packing reusable modules? On Aug 17, 9:04 pm, Lucas Neves Martins snown...@gmail.com wrote: Yeah I know the feeling, My app was taking around 20-30 seconds to load for the first time - after the first load it was nearly instant I've tested with Google Page Speed and Page Activity as well, and I come to realize that the biggest problem is the huge amount of JS scrips ( at least for me ), Gzip compression helped a lot, in my case, around 7-10 seconds. As the GWT application itself is just pure JS in the client side, a solution I've used that helped a lot the user experience, is to load the application in the background. In my case, I load the login screen first - and it does it very quickly, around 1-2 second(s) - and while the user is still logging in the application I load all the other parts of the application, starting from the parts I think the user will use first. So while the user logs in, and take a look to the main page, all the application is loading without his perception - except for the firefox status spinner : P And then 10-15 seconds comes to be a acceptable time, since my users take just around that time to make a login and try to use any other funcionality after doing it. But of course, I agree that GWT could be better in both performance and best practices, but if you look at the generated code, you will see that that ship is sailed. The browsers are not so compliant to the standards as they could, and the guys from the GWT team can't do miracles. Take a look at gzip compression and and partitioned loading for gwt apps, I know I didn't actually answered you question, but this might help your performance. Good luck! On 17 ago, 07:12, Rodders david.andrew.chap...@googlemail.com wrote: GWT comes with default CSS. If I create a bunch of reuseable Modules (packaged as Jars for use by some of our other internal development teams) with our own corporate style, the compiled application loads 2 stylesheets (the default, and company for example). If one of our development teams uses those Modules to create a new app and adds some CSS specific to that app the compiled application loads 3 stylesheets (default, company and application). These stylesheets are not minified or combined, this can't be correct as Google's own page performance tool states that HTTP requests should be reduced and css files combinded - I must be doing something wrong? However, one of the GWT example apps I've seen is loading over 1Mb data in 59 http requests and takes about 11 secs to load... Can anyone point me at a good tutorial on how to create reuseable modules that don't break web app performance best practices? Thanks. Rodders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT. Images Loading And Composite
Hi, I also have the same problem though, in my case, the image is being updated when using firefox (ie and hosted mode do not seem to realize the image url has been modified). Has anyone managed to solve this problem? I'm using gwt1.6.4 I've tried to update the image both, by using setUrl and DOM.setImgSrc Regards. On Jul 21, 3:18 pm, Дмитрий Николаев blacklit...@gmail.com wrote: Hi! I'm in trouble - very often when Iupdateurlof the images, browser notupdatethem (in hosted mode, firefox) img.setUrl(...); // sometimes won't work Ok, I try to instantiate newImageevery time I needupdateurl. I Use img = newImage(...); on my SimplePanel. In hosted mode ot works, but in firefox - won't, when I press shift +refresh when reloading page (with clearing the cache). Hacks like DOM.setElementAttribute(Image.getElement(), src, path); won't help. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
StatusCodeException: call failed on the server ; see server log for details.
Hi, I'm using GWT 1.5.0. Whenever I try to make an asynchronous call to a service, I get the message: - com.google.gwt.user.client.rpc.StatusCodeException: The call failed on the server; see server log for details I am using files only fro my client side and server side.But whenever i am calling the service, it is raising the above exception. I have included the code below. my class which i calling from client side/// public class FOSFrequentItemsResponse implements Serializable, FOSResponse { private static final long serialVersionUID = 1L; private HashMapString, String freqIOGs; private HashMapString, String freqMarketplaces; private HashMapString, String freqMerchants; private HashSetString freqTestCaseNames; // @gwt.ignore.start public ListfosTestCase FOSTestCaseNames; // @gwt.ignore.end public FOSFrequentItemsResponse(){ } /* public ListfosTestCase getfostestcases(){ return FOSTestCaseNames; }*/ public void initialise() { // @gwt.ignore.start freqIOGs = (HashMapString, String) AppConfig.findMap (frequentIOG); freqMerchants = (HashMapString, String) AppConfig.findMap(frequentMerchantID); freqMarketplaces = (HashMapString, String) AppConfig.findMap(frequentMarketplaceID); // @gwt.ignore.end freqTestCaseNames = new HashSetString(); // @gwt.ignore.start FOSTestCaseNames= new ArrayListfosTestCase(); File file = new File(/home/alekhya/testCases- NA.xml); String fil = file.toString(); xmlFileParser fileparser = new xmlFileParser(fil); fileparser.parseXMLFile(); FOSTestCaseNames= fileparser.getFosTestCases(); // @gwt.ignore.end } public void populate(ListBox freqIOGs, ListBox freqMerchants, ListBox freqMktplaces,ListBox freqTestCaseNames){ freqIOGs.clear(); freqMerchants.clear(); freqMktplaces.clear();freqTestCaseNames.clear(); for(Map.EntryString, String entry : this.freqIOGs.entrySet()){ freqIOGs.addItem(entry.getKey() + ( + entry.getValue() + ) ); } for(Map.EntryString, String entry : this.freqMerchants.entrySet()){ freqMerchants.addItem(entry.getKey() + ( + entry.getValue() + )); } } for(Map.EntryString, String entry : this.freqMarketplaces.entrySet()){ freqMktplaces.addItem(entry.getKey() + ( + entry.getValue() + )); } /*Iterator itr= FOSTestCaseNames.iterator(); while(itr.hasNext()) { //fosTestCase element= (itr.next());*/ // @gwt.ignore.start for(int i=0;i FOSTestCaseNames.size();i++) { String str = ((FOSTestCaseNames).get (i)).getTestCaseName(); freqTestCaseNames.addItem(str);} // freqTestCaseNames.addItem(Promisereduced size); freqTestCaseNames.addItem(other); // @gwt.ignore.end freqIOGs.addItem(other); freqMerchants.addItem(other); freqMktplaces.addItem(other); // freqTestCaseNames.addItem(other);*/ } this is where i called my service like this / public void getFrequentItems(){ AsyncCallbackFOSFrequentItemsResponse callback = new AsyncCallbackFOSFrequentItemsResponse(){ public void onFailure(Throwable ex){ GWT.log(Failed to get frequent items, ex); } public void onSuccess(FOSFrequentItemsResponse freqItems){ freqItems.populate(freqIOGs, freqMerchants, freqMktplaces,freqTestCaseNames); setIOG(iog); setMarketplace (marketplace); setMerchant(merchant); viewNames.drawNames(viewsPanel, reqContextPanel, FOSQueryWidget.this); } }; service.sendRequest(new FOSFrequentItemsRequest(), callback); } / I am just trying to get the items into the listboxes from the server but its showing the error unable to load frequent items Plz show me the right way ASAP. Thanks in advance. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en
Facing issues with RPC - while upgrading GWT from 1.5 to 1.7
Hi, We have upgraded GWT 1.5 to 1.7, and have gotten everything to get compiled properly. However, we didn't create a war file as we are not running pur application in the hosted mode; so we did away with that. Moreover, neither did we rename the module as we didn't think renaming would make any difference, and the reason we didn't do any renaming as it would have affected all our existing pages. What we actually did is- 1.) Included the latest jars i.e. replaced the old ones with the new ones. 2.) Used Compiler instead of GWTCompiler Issue - None of the callbacks seem to be working i.e. RPC - Asynchronous callbacks I would appreciate if I could get any help out of this. Thanks, Karan --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Error parsing JSON
Below is json object that I am having trouble with. When I try to use this object with JSONParser.parse(), I get JSONException. I have verified that the JSON object is of valid form but cannot figure out why I am getting the exception. I have narrowed it down to the particular line of code that contains JSONParser.parse(); Anyone see anything here? {projects:[{id:1,title:Project Number 1,priority:High,openDate:2009-06-05,closeDate:2009-06-07,owner: {firstName:John,lastName:Doe,email:m...@email.com,site:http:// www.mysite.com},notes:[{title:This is a note,content:This is a note. I am typing this to be long just so that it will show up as scrollable when necessary. ,timestamp:2009-06-07 13:28:55},{title:Last note. Will be two there.,content:This is a note. I am typing this to be long just so that it will show up as scrollable when necessary. ,timestamp:2009-06-07 13:30:12}],pictures:[]}, {id:2,title:Project Number 2,priority:Medium,openDate:2009-05-20,closeDate:2009-06-06,owner: {firstName:John,lastName:Doe,email:m...@email.com,site:http:// www.mysite.com},notes:[{title:Another Note,content:This is a note. I am typing this to be long just so that it will show up as scrollable when necessary. ,timestamp:2009-06-07 13:29:09}],pictures:[]}, {id:3,title:Project Number 3,priority:High,openDate:2009-06-04,closeDate:,owner: {firstName:Tom,lastName:Smith,email:t...@email.com,site:http:// www.tomsite.com},notes:[{title:Note again,content:This is a note. I am typing this to be long just so that it will show up as scrollable when necessary. ,timestamp:2009-06-07 13:29:25}],pictures:[]}]} --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Creating Reuseable Modules
OK I think I've found what I'm looking for - CssResource (http:// code.google.com/p/google-web-toolkit/wiki/CssResource). Documentation is a bit thin (and I'm new to GWT)... does anyone have any experience using the CssResource class? On Aug 18, 10:56 am, Rodders david.andrew.chap...@googlemail.com wrote: Thanks for the reply Lucas - yeh, didn't really answer my question but thanks anyway ;o) The problem is where I work I am the only front-end engineer/designer everyone else is a java programmer - so they *need* something that enables them to write java and forget about the rest - we have been using Echo2 (against my recommendation) and are now looking at GWT - again, against my recommendation (there isn't anything that GWT or Echo2 or AnotherJavaToJavascript Framework can do that a dedicated team of front-end engineers can't do... but I guess thats GWTs (et al) biggest selling point), don't get me wrong I think what the GWT engineers have been able to produce is *very* clever... Is there no one else listening/reading that has come accross this issue/problem of packing reusable modules? On Aug 17, 9:04 pm, Lucas Neves Martins snown...@gmail.com wrote: Yeah I know the feeling, My app was taking around 20-30 seconds to load for the first time - after the first load it was nearly instant I've tested with Google Page Speed and Page Activity as well, and I come to realize that the biggest problem is the huge amount of JS scrips ( at least for me ), Gzip compression helped a lot, in my case, around 7-10 seconds. As the GWT application itself is just pure JS in the client side, a solution I've used that helped a lot the user experience, is to load the application in the background. In my case, I load the login screen first - and it does it very quickly, around 1-2 second(s) - and while the user is still logging in the application I load all the other parts of the application, starting from the parts I think the user will use first. So while the user logs in, and take a look to the main page, all the application is loading without his perception - except for the firefox status spinner : P And then 10-15 seconds comes to be a acceptable time, since my users take just around that time to make a login and try to use any other funcionality after doing it. But of course, I agree that GWT could be better in both performance and best practices, but if you look at the generated code, you will see that that ship is sailed. The browsers are not so compliant to the standards as they could, and the guys from the GWT team can't do miracles. Take a look at gzip compression and and partitioned loading for gwt apps, I know I didn't actually answered you question, but this might help your performance. Good luck! On 17 ago, 07:12, Rodders david.andrew.chap...@googlemail.com wrote: GWT comes with default CSS. If I create a bunch of reuseable Modules (packaged as Jars for use by some of our other internal development teams) with our own corporate style, the compiled application loads 2 stylesheets (the default, and company for example). If one of our development teams uses those Modules to create a new app and adds some CSS specific to that app the compiled application loads 3 stylesheets (default, company and application). These stylesheets are not minified or combined, this can't be correct as Google's own page performance tool states that HTTP requests should be reduced and css files combinded - I must be doing something wrong? However, one of the GWT example apps I've seen is loading over 1Mb data in 59 http requests and takes about 11 secs to load... Can anyone point me at a good tutorial on how to create reuseable modules that don't break web app performance best practices? Thanks. Rodders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
GWT 1.7 shell ActiveX/applet problem
Hello! Our web application must embed an existing applet, which is a very important part of the whole application. First I tried to use a simple applet tag but it didn't work. Then I found that the object tag should work better in IE (see http://java.sun.com/javase/6/docs/technotes/guides/plugin/developer_guide/using_tags.html#object). What I tried is very simple: I grabbed the NervousText applet example from the JDK, and embedded it into the GWT application using: object classid=clsid:8AD9C840-044E-11D1-B3E9-00805F499D93 type=application/x-java-applet height=400 width=200 border=0px param name=code value=NervousText.class / /object Web mode works great in IE7, but hosted mode fails with the message: One or more ActiveX controls could not be displayed because either: 1) Your current security settings prohibit running ActiveX controls on this page, or 2) You have blocked a publisher of one of the controls As a result, the page may not display correctly. I tried to set security to a minimum level (using Tools/Internet options/Security) but it doesn't have any effect. Do you have any idea why doesn't it work? Thanks for your help in advance! Best regards: Norbi Environment: Windows XP, IE7/IE8, GWT 1.7, JDK 6; the problem is only in hosted mode --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
MVP design issue - any work around?
Hi all A design question for everyone using MVP for their GWT implementations :-) I have a simple interface like so: interface ArrivalWidgetInterface { HasText getSlotText(); } Let´s say that I want to set the SlotText in my widget implementing the above interface. I´m leaving some code out here, but it should be pretty straight forward if you have been using examples from Google IO 2009 and so on. Pretty simple, in a async success method I put the following: widget.getSlotText().setText(result.getSlot()); Done. Let´s say now that I want to manipulate the Slot textbox in some other way, for example disable it after the value has been set. How can I do this in a good way? Changing the interface to return an TextBox instead of the HasText interface seems like a bad idea, since that would give me problems when testing. If possible you´ll want to keep all the UI-code outside the presenter, right? So what would be best here? Create a new public method in the widget, and expose that method in the interface aswell? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: MVP design issue - any work around?
How about void setEnabled(boolean enabled); It's really up to the view how it indicates whether something is disabled or not. Different views for the same interface might do different things. Ian http://examples.roughian.com 2009/8/18 Dalla dalla_man...@hotmail.com Hi all A design question for everyone using MVP for their GWT implementations :-) I have a simple interface like so: interface ArrivalWidgetInterface { HasText getSlotText(); } Let´s say that I want to set the SlotText in my widget implementing the above interface. I´m leaving some code out here, but it should be pretty straight forward if you have been using examples from Google IO 2009 and so on. Pretty simple, in a async success method I put the following: widget.getSlotText().setText(result.getSlot()); Done. Let´s say now that I want to manipulate the Slot textbox in some other way, for example disable it after the value has been set. How can I do this in a good way? Changing the interface to return an TextBox instead of the HasText interface seems like a bad idea, since that would give me problems when testing. If possible you´ll want to keep all the UI-code outside the presenter, right? So what would be best here? Create a new public method in the widget, and expose that method in the interface aswell? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Migration from 1.5 to 1.6 and 1.7
Hello, I am trying to migrate from GWT 1.5 on Mac to 1.7 and keep running into this error when stating hosted mode. I also switched to 1.6 and the same error occurs there. I did try to add xercesImpl.jar but the problem is still there. Any clues to what is going on? Thanx /Erik Hedblom [WARN] Error deploying web application directory ROOT javax.xml.parsers.FactoryConfigurationError: Provider org.apache.xerces.jaxp.DocumentBuilderFactoryImpl not found at javax.xml.parsers.DocumentBuilderFactory.newInstance (DocumentBuilderFactory.java:104) at org.apache.commons.modeler.util.DomUtil.readXml(DomUtil.java:284) at org.apache.commons.modeler.modules.MbeansDescriptorsDOMSource.execute (MbeansDescriptorsDOMSource.java:130) at org.apache.commons.modeler.modules.MbeansDescriptorsDOMSource.loadDescriptors (MbeansDescriptorsDOMSource.java:120) at org.apache.commons.modeler.Registry.load(Registry.java:819) at org.apache.commons.modeler.Registry.loadDescriptors(Registry.java: 931) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: chrome/safari error
Welcome Sorry I can't help - I'm +1 on this: http://groups.google.com/group/google-web-toolkit/browse_thread/thread/e84e07a4c36f91db/593492d3689bf731 I asked 13 days ago, I wish you more luck with this thread - as it would resolve my problem too. Anyone investigating this quite strange issue can check my thread (one message really) for more debug information. I'm no JS expert + the code is generated by GWT, not even from our Java code. It's the problem in the loader JS. Cheers Virgo On Aug 18, 11:51 am, denis56 denis.ergashb...@gmail.com wrote: His I am getting the following error in Chrome (and Safari also doesn't work; Firefox and IE are ok) TypeError: Object #a Document has no method 'write' Same problem was reported inhttp://groups.google.com/group/google-web-toolkit/browse_frm/thread/e... I am also using JSF with RichFaces and the code works without RichFaces code. Has anyone idea/experience of solving the issue? Many thanks, Denis --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: chrome/safari error
Gosh, you linked me :-) I skipped that paragraph. :-))) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
MVP design issue - any work around?
Hi all A design question for everyone using MVP for their GWT implementations :-) I have a simple interface like so: interface ArrivalWidgetInterface { HasText getSlotText(); } Let´s say that I want to set the SlotText in my widget implementing the above interface. I´m leaving some code out here, but it should be pretty straight forward if you have been using examples from Google IO 2009 and so on. Pretty simple, in a async success method I put the following: widget.getSlotText().setText(result.getSlot()); Done. Let´s say now that I want to manipulate the Slot textbox in some other way, for example disable it after the value has been set. How can I do this in a good way? Changing the interface to return an TextBox instead of the HasText interface seems like a bad idea, since that would give me problems when testing. If possible you´ll want to keep all the UI-code outside the presenter, right? So what would be best here? Create a new public method in the widget, and expose that method in the interface aswell? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: MVP design issue - any work around?
you can do it in two ways: 1. Add a method to enable/disable the component in the interface ArrivalWidgetInterface. This solution makes sense if the enable/disable is a presenter responsability. 2. Extend TextBox setText to disable the component after a call. I would recommend the first option. I think that you can use a HasValueBoolean interface to do it gracefully. Best regards, Eduardo S. Nunes On Tue, Aug 18, 2009 at 9:31 AM, Dalladalla_man...@hotmail.com wrote: Hi all A design question for everyone using MVP for their GWT implementations :-) I have a simple interface like so: interface ArrivalWidgetInterface { HasText getSlotText(); } Let´s say that I want to set the SlotText in my widget implementing the above interface. I´m leaving some code out here, but it should be pretty straight forward if you have been using examples from Google IO 2009 and so on. Pretty simple, in a async success method I put the following: widget.getSlotText().setText(result.getSlot()); Done. Let´s say now that I want to manipulate the Slot textbox in some other way, for example disable it after the value has been set. How can I do this in a good way? Changing the interface to return an TextBox instead of the HasText interface seems like a bad idea, since that would give me problems when testing. If possible you´ll want to keep all the UI-code outside the presenter, right? So what would be best here? Create a new public method in the widget, and expose that method in the interface aswell? -- Eduardo S. Nunes http://e-nunes.com.br --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: How to override module stylesheet definitions
On 18 août, 07:39, Alex Epshteyn alexander.epsht...@gmail.com wrote: Surprisingly was unable to find any prior discussions about this... I'm optimizing my app's load time by merging all my stylesheets into a single CSS file (then minifying it with YUI compressor), to reduce the number of HTTP requests. I'd like to also concatenate all the stylesheets from third party libraries I'm using into this single CSS file, but don't see a way to undefine the stylesheet module XML elements in these third party modules. For example, I'm using Fred Sauer's gwt-dnd library, whose module XML contains stylesheet src=gwt-dnd.css/ This line instructs the browser to request gwt-dnd.css when this module is loaded, but I don't want this to happen. Any ideas? Don't do it by hand, write a linker to be run before the primary linker (@LinkerOrder(Order.PRE)) that'll process all artifacts.find (StylesheetReference.class) and replace them with a single StylesheetReference while emitting the new single CSS file. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: At new item to a list at each position
I had AbsolutePanels with other Widgets added to it, but now I just have one Widget in each. In other cases I used VerticalPanels instead of AbsolutePanels to get access to the different Widgets in the rows. Unfortunately I can't get the Widget of a Widget e. g. when I have a ListBox inside a VerticalPanel and the VerticalPanel inside a FlexTable by using flextable.getWidget(1,0).getWidget(0);, but it works when I get the Widgets step by step and cast it in each step. On Aug 17, 11:48 pm, Ian Bambury ianbamb...@gmail.com wrote: You should only ever have one widget in the cell. The method setWidget(int row, int column, Widget widget) removes any existing widget. I think you might need a design review ;-) Ian http://examples.roughian.com 2009/8/17 Tobe tobias.jungnic...@googlemail.com Ok, but in this case inside the (1,0) there can be some more Elements and always the last one is the nested FlexTable I need. I tried .getElement().getLastChild() but can't cast the received Node to a FlexTable. On Aug 17, 6:41 pm, Ian Bambury ianbamb...@gmail.com wrote: Can we try this in words, not html :-) You have an outer table with 'Insert' buttons in the even rows (0,2,4,...) and child tables in the first column of the odd rows (1,3,...) To access the first child table, you use FlexTable inner = (FlexTable)outer.getWidget(1, 0); Ian http://examples.roughian.com --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Wrap TextBox with span
Hi We would like to extend the gwt TextBox such that it is wrapped by a span. The reason for this is to integrate a validation icon. The rendered html should look something like this: span class=my-TextBox style= input class=text type=text/ div class=validationIcon/ /span How can we achieve this? Regards, Dominic --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Localization workflow?
On 18 août, 06:38, Dobes dob...@gmail.com wrote: What tools are people using for localization? For example, currently I've defined all my strings using @DefaultValue (...) for my Constants interface instead of a properties file - is there a tool out there to convert an interface into a properties file, Add a @Generate(format = com.google.gwt.i18n.rebind.format.PropertiesFormat) attribute to your Messages or Constants interface and then just compile your project (if using GWT 1.6 or higher, pass the -extra argument with the target directory as the value) and it'll generate the properties file from the interface (if using GWT 1.5, in the www/module-aux directory). or validation a properties file against and interface? AFAICT, you'll have exceptions if a key isn't translated, so there's some kind of validation built-in when you compile the project. Has anyone seen a tool to take all the properties from the interface including the @Meaning annotations and generate/update and excel spreadsheet from that with columns Untranslated, Meaning, ID? This could be used as the first step of the translation workflow. Next I could merge this file with any prior translations by detecting any rows where the Untranslated or Meaning has changed or added and produce a new Excel file with additional columns Old Untranslated, Old Meaning, and Old Translation. This file can be sent to the translators for translation, who would be responsible for filling in the translation column only. When it comes back I need another tool to extract the ID and Translation column data and dump that into the appropriate .properties file. I'm thinking I'm not the only one who needs to create and update translations of their GWT app, but so far my Googling hasn't turned up any tools for this - especically the first step where the interface IDs and meanings are extracted out into a useful format. Anybody got anything to help with this? We're in the process of translating our app (read: imported the generated properties file into an Excel sheet –just key/default message, as we do not (yet) use @Meaning et al.– and have it translated, translations not yet turned back into a properties file) so I guess the answer is not yet, but I'm definitely interested in whatever you could find about it. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT 1.7 compiles null.nullMethod() into javascript for HTMLTable sub-class
On 18 août, 01:30, Bob The Cheese bobtheche...@gmail.com wrote: OK, so I'm making a custom type of table which manages a datastore, has expandable sections, etc. I've borrowed a couple of things off FlexTable, but modified/ simplified them. When I run the project, I get this: == [ERROR] Failed to create an instance of 'vdc.module.billing.Billing' via deferred binding java.lang.NullPointerException: null at com.google.gwt.user.client.ui.HTMLTable$CellFormatter.access$0 (HTMLTable.java:373) at com.google.gwt.user.client.ui.HTMLTable.cleanCell(HTMLTable.java: 1370) [...] I compile the project out and run it in firefox, and pull up the error here in the javascript: == function $setHTML(this$static, row, column, html){ var td; $prepareCell(this$static, row, column); td = null.nullMethod(); $internalClearCell(this$static, td, html == null); if (html != null) { null.nullMethod(); }} == in particular this line: td = null.nullMethod(); I've looked around, and can't find anything which really explains to me what's going wrong. Looking at the equivalent method in Java world: public void setHTML(int row, int column, String html) { prepareCell(row, column); Element td = cleanCell(row, column, html == null); if (html != null) { DOM.setInnerHTML(td, html); } } ... private Element cleanCell(int row, int column, boolean clearInnerHTML) { // Clear whatever is in the cell. Element td = getCellFormatter().getRawElement(row, column); internalClearCell(td, clearInnerHTML); return td; } It looks like getCellFormatter() always return 'null' so the compiler translated the getRawElement(row,column) into 'null.nullMethod()' to cause a null pointer exception equivalent in JavaScript. What it means is that you never ever called setCellFormatter(...) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Allow other domains to access a GWT application (running on Google App Engine)
On 18 août, 01:08, Everett everett.to...@gmail.com wrote: Hi All, I would like to allow a particular set of other domains to access my GWT application (running on Google App Engine). Is this possible with GWT and how to do it? For example: Let's say I have the StockWatcher application from the tutorial running onhttp://stockwatcher.appspot.com. Part of the page StockWatcher.html are the lines link type=text/css rel=stylesheet href=StockWatcher.css ... script type=text/javascript language=javascript src=stockwatcher/ stockwatcher.nocache.js/script The application is run ashttp://stockwatcher.appspot.com/StockWatcher.html and everything works fine. Now let's say I want to also allow example.com to run my StockWatcher application. I tell them to make a copy of StockWatcher.html in their root directory and change the lines above to link type=text/css rel=stylesheet href=http:// stockwatcher.appspot.com/StockWatcher.css ... script type=text/javascript language=javascript src=http:// stockwatcher.appspot.com/stockwatcher/stockwatcher.nocache.js/ script The application is run ashttp://www.example.com/StockWatcher.html and, ideally, everything works fine. I tried a scenario similar to this but when I viewedhttp://www.example.com/StockWatcher.htmlI didn't see the StockWatcher application and no errors were reported. When I view the source of the page everything looks fine to me. My questions are: 1. Is this kind of application deployment possible in GWT? yes, provided the app doesn't talk to the server using GWT-RPC or similar (Google for same origin policy to understand why) or the domain where the app runs also runs a proxy (the app calls the proxy at the same origin, which relays the requests to your AppEngine app, therefore bypassing the SOP restriction) In the near future, browsers will implement CORS http://www.w3.org/TR/ cors which will enable safe cross-origin requests (similar to Flash and IE8's XDomainRequest), but for now you'll have to go the proxy way (or use ugly hacks such as JSONP and/or post form to hidden iframe which then sets window.name) 2. If so, how would you go about doing it? I'm a developer new to GWT so I just need a kick in the right direction. Add add-linker name=xs / (it's known as the cross site linker) to your module's gwt.xml to generate *.cache.js instead of *.cache.html; that way it won't use an iframe and won't face the same- origin policy that have been blocking you in your experiment. But your app will run in the context of the page instead of being sandboxed in an iframe, which means that if another script modifies, say, the Array object, you might run into troubles (this is not quite likely but it's still a possibility). I think the choice of GWT to run within an iframe by default also has to do with caching wrt IE (or was it Firefox?) and/or HTTPS, which caches *.html well but won't cache *.js... 3. How would you get the example.com domain to check it against a whitelist of allowed domains in the GWT application? In your app, in onModuleLoad, check that Window.Location.getHostName() is what you expect. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GALGWT, Eclipse 3.5 / Galileo, and GWT 1.7 -- how to add this or any other GWT library to projects?
right, everything looked like it should be ok, compiled completely without warning, but somehow hosted mode only worked with the noredist. I was wondering though why the gears GWT stuff is not distributed as a plugin alongside the rest of GWT. There maybe some technical reason for this but it would be nice to have it all as slick as the core GWT. Or is that just being greedy? On Aug 18, 3:20 am, Julian Harris julian.har...@gmail.com wrote: Thanks Philip! I'll give this a try -- it worked fine in hosted mode I assume. On Tue, Aug 18, 2009 at 3:31 AM, philipmac philipmacmena...@gmail.comwrote: Hey, so I've been mucking about with this for say... a couple of hours. And, ehh, I never actually used Eclipse until tonight, and I'm a Perl coder. So, ahem, take what I say with this in mind... but, I just right click on my project, go to Properties, into the Java Build Path, Add External Jars, and stick in the external jar file into the project. Although, for some magical reason of which I am unaware of, you have to use the noredist gears jar. Give it a try. On Aug 17, 7:03 pm, Julian julian.har...@gmail.com wrote: Hi all, firstly the GWT / AppEngine plugin for Eclipse is sensational. To be able to deploy to production so easily is amazing. However a basic question -- how do you add other GWT libraries? I wanted to extend the template given by making a geolocation API call in gwt-gears I'm struggling to figure out where to add gwt-gears.jar. 1. I added it to my project's lib folder along with the other jars that were included in the default project but they are not presented through the GUI as available to add. 2. Adding them as 'external jars' solves the IDE syntax checking issues but then unsurprisingly crashes in hosted mode. I'm missing something basic I'm sure about how to add GWT libraries -- anyone have any suggestions? thanks! (This is for GALGWT, Eclipse 3.5 / Galileo, and GWT 1.7) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
GWT1.6.4 multiple module and gwt-ext
When putting multiple GWT modules on the html host page that use gwt- ext library there is JavaScript error and only in the OBFuscated mode. Everything works just fine in the PRETTY mode. Most likely the error is caused by the name collision in the obfuscated mode when method aa1 () from one module collides with the same obfuscated name from the second one. Basically when first module executes some method there is an error and stack trace reference to the HTML file from the different module. Is there any way to specify some range for JavaScript method names when compiling in the OBFuscated mode via linker etc. Thanks. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Multiple Projects in Eclipse Sharing RPCs
I'm not sure, could you re-post your original question? On Mon, Aug 17, 2009 at 3:43 PM, Lucas Neves Martins snown...@gmail.comwrote: ??? What happened? On 17 ago, 12:15, Jason Parekh jasonpar...@gmail.com wrote: Hey jhnclvr, FYI, your message was truncated =) On Mon, Aug 17, 2009 at 10:03 AM, jhnclvr jhnc...@gmail.com wrote: Hello everyone, --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: how to deploy a GWT Application online?
Hi Sam, You'll need to run Tomcat or another server that implements the servlet spec instead of your WAMP setup. I don't have any links off hand, but search around and you shall find a bunch of links for achieving this set up. jason On Mon, Aug 17, 2009 at 6:00 PM, sam sabir...@gmail.com wrote: Thanks Jason and Lal, When I run my application in eclipse it works fine. Then, I compiled the application by clicking the red icon ie 'GWT Compile Project'. On settings, I picked 'log level'=all, and 'output style'=detailed. Finally, I get the message:Compilation succeeded -- 97.258s after bunch of other lines. Then, I took the content inside the 'war' folder and posted it online using dreamweaver. Clientside of the application works fine. However, when I click on something that requires to get data from server Implementation method, then it fails and I get the error: com.google.gwt.user.client.rpc.StatusCodeException: As for hosting server, my server has 'apache 2.2.11.' My computer also has WAMP with 'apache 2.2.11'. Is there a way to deploy GWT application online with apache 2.2.11? I am new to this, thanks for the support. sam On Aug 17, 11:13 am, Jason Parekh jasonpar...@gmail.com wrote: Hey Sam, As Lal explains below, creating the war file and deploying it into Tomcat (or another app server) should be enough. Could you explain how you tried to deploy it online? How did you package it all, where did you deploy to, etc.? Have you tried any other apps on your server that are able to access the database? jason On Mon, Aug 17, 2009 at 1:00 AM, sam sabir...@gmail.com wrote: I have been working on my summer GWT Application Project. Finally, I have created an application using eclipse. It has uses RPC, and I use JDBC MYSQL to access database. My application is almost complete; it runs fine in hosted mode and accesses database. But, today I tried to deploy it online. I could not get my client and server side to interact, let alone accessing database. Can anyone help me figure out how to deploy GWT application online? How do I get my client and server side to interact when deployed. Isn't posting the content under 'war' enough? Thanks, sam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT + gears + eclipse, problem.
Hey Philip, Glad everything worked OK. Did your database functionality also work? FWIW, I tried setting up the project locally, and using only gwt-gears.jar worked, though I did not have a server-side component. I'm not sure what the noredist does not contain, but if you notice strange behavior, you may want to try with regular gwt-gears.jar on a clean project. jason On Mon, Aug 17, 2009 at 9:33 PM, philipmac philipmacmena...@gmail.comwrote: Good news everyone! So, I was wondering why there is two gears jars, one called gwt-gears- noredist.jar and one called gwt-gears.jar. Well, instead of adding gwt-gears.jar to the project, I added gwt- gears-noredist.jar. The above seems to work now. I shall have to test the db functionality now. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Server side
Hello guys. I'm trying finally to make my GWT application works client and server sides. I have a simple service (just one method for now). This method, on the server side, uses a Jar file (created for me) to connect in my database (MySql) using hibernate. I am having a problem to use hibernate (the java method that uses hibernate is in the jar file - that is in the class path of my GWT project). It throws me an exception when I am configuring hibernate SessionFactory sessionFactory = new Configuration().configure (guardian.hibernate.cfg.xml).buildSessionFactory(); I don't know if you guys use hibernate, but I am sure this problem is in my GWT project, because if I create a basic java project and try to use this Jar file (that uses hibernate) everithing works fine. The exception is: Aug 18, 2009 1:28:29 PM com.google.appengine.tools.development.ApiProxyLocalImpl log SEVERE: [1250602109691000] javax.servlet.ServletContext log: Exception while dispatching incoming RPC call com.google.gwt.user.server.rpc.UnexpectedException: Service method 'public abstract java.util.List br.com.engsys.voippanel.client.VoippanelService.getCallHistory (java.lang.String,java.lang.String,java.lang.String)' threw an unexpected exception: java.lang.ExceptionInInitializerError at com.google.gwt.user.server.rpc.RPC.encodeResponseForFailure (RPC.java:360) at com.google.gwt.user.server.rpc.RPC.invokeAndEncodeResponse (RPC.java:546) at com.google.gwt.user.server.rpc.RemoteServiceServlet.processCall (RemoteServiceServlet.java:166) at com.google.gwt.user.server.rpc.RemoteServiceServlet.doPost (RemoteServiceServlet.java:86) at javax.servlet.http.HttpServlet.service(HttpServlet.java:713) at javax.servlet.http.HttpServlet.service(HttpServlet.java:806) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java: 487) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1093) at com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter (TransactionCleanupFilter.java:43) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1084) at com.google.appengine.tools.development.StaticFileFilter.doFilter (StaticFileFilter.java:124) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1084) at org.mortbay.jetty.servlet.ServletHandler.handle (ServletHandler.java:360) at org.mortbay.jetty.security.SecurityHandler.handle (SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle (SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle (ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java: 405) at com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle (DevAppEngineWebAppContext.java:54) at org.mortbay.jetty.handler.HandlerWrapper.handle (HandlerWrapper.java:139) at com.google.appengine.tools.development.JettyContainerService $ApiProxyHandler.handle(JettyContainerService.java:313) at org.mortbay.jetty.handler.HandlerWrapper.handle (HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:313) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java: 506) at org.mortbay.jetty.HttpConnection$RequestHandler.content (HttpConnection.java:844) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:644) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381) at org.mortbay.io.nio.SelectChannelEndPoint.run (SelectChannelEndPoint.java:396) at org.mortbay.thread.BoundedThreadPool$PoolThread.run (BoundedThreadPool.java:442) Caused by: java.lang.ExceptionInInitializerError at br.com.engsys.guardian.persistence.HibernateUtil.clinit (HibernateUtil.java:13) at br.com.engsys.guardian.db.DaoApplications.getApplications (DaoApplications.java:57) at br.com.engsys.business.User.init(User.java:15) at br.com.engsys.voippanel.server.VoippanelServiceImpl.getCallHistory (VoippanelServiceImpl.java:23) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:616) at com.google.gwt.user.server.rpc.RPC.invokeAndEncodeResponse (RPC.java:527) ... 27 more Caused by: java.lang.NoClassDefFoundError: org/dom4j/DocumentException at br.com.engsys.guardian.persistence.HibernateUtil.clinit (HibernateUtil.java:11) ... 35 more Caused by: java.lang.ClassNotFoundException: org.dom4j.DocumentException at
Re: GWT + gears + eclipse, problem.
For the Gears API library for GWT version 1.2.1, gwt-gears.jar vs. gwt-gears-noredist.jar, the difference is the xerces library is not bundled. On Tue, Aug 18, 2009 at 10:12 AM, Jason Parekhjasonpar...@gmail.com wrote: Hey Philip, Glad everything worked OK. Did your database functionality also work? FWIW, I tried setting up the project locally, and using only gwt-gears.jar worked, though I did not have a server-side component. I'm not sure what the noredist does not contain, but if you notice strange behavior, you may want to try with regular gwt-gears.jar on a clean project. jason On Mon, Aug 17, 2009 at 9:33 PM, philipmac philipmacmena...@gmail.com wrote: Good news everyone! So, I was wondering why there is two gears jars, one called gwt-gears- noredist.jar and one called gwt-gears.jar. Well, instead of adding gwt-gears.jar to the project, I added gwt- gears-noredist.jar. The above seems to work now. I shall have to test the db functionality now. -- Google Code Jam 2009 http://code.google.com/codejam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
suggestionbox using json
Hello.. I want to use suggestionbox and data should be added dynamically from database. so for that I am going to use JSON. but I am not getting how to do that. I also searched for this kind of example.. but in every example data is hardcoded in suggestionbox so can any one give me the idea for that Thanks --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Wrap TextBox with span
From the look of your html code, your validation icon will continue to be placed below your input because you are using a div as your container for the icon. For GWT you can make this work by using a HorizontalPanel, so basically you will have. HorizontalPanel panel = new HorizontalPanel(); TextBox box = new TextBox(); box.setStylePrimaryName(text); SimplePanel divPanel = new SimplePanel(); divPanel.setStylePrimaryName(validationIcon); panel.add(box); panel.add(divPanel); This will get you to where you want to go, but there are other options such as a FlowPanel or you could also use the InlineHTML widget.The InlineHTML widget wraps text or html in a span. So you could also do: InlineHTML html = new InlineHTML(); html.setStylePrimaryName(validationIcon); Then add it to the panel that contains your TextBox. Hope this helped. James http://www.gwttutorials.com On Aug 18, 7:51 am, Dominic dominic.brueg...@gmail.com wrote: Hi We would like to extend the gwt TextBox such that it is wrapped by a span. The reason for this is to integrate a validation icon. The rendered html should look something like this: span class=my-TextBox style= input class=text type=text/ div class=validationIcon/ /span How can we achieve this? Regards, Dominic --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: generics, events, dependency injection
Quick question...when you say provider, what do you mean exactly? Is there a specific provider method pattern? On Jun 29, 7:41 pm, Ricardo Rocha rocha.po...@gmail.com wrote: Hi again. On Jun 24, 3:16 pm, Thomas Broyer t.bro...@gmail.com wrote: On 24 juin, 12:01, rocha.po...@gmail.com rocha.po...@gmail.com wrote: Hi all. I've been trying to get a nice setup of the best practices presented at google i/o. I have something working, but a few questions. The first one is how fine-grained do you go for the events you define? Say i have events for updates in entities A and B in my model: UpdatedAEvent, UpdatedBEvent. To prevent creating new event classes for every entity i might add, i liked the idea of usinggenericsafter looking at the source code of GWT. Classes like: public class ModelUpdatedEventV extends GwtEventModelUpdatedHandlerV { ... private static TypeModelUpdatedHandler? TYPE; ... public static TypeModelUpdatedHandler? getType() { if (TYPE == null) { TYPE = new TypeModelUpdatedHandler?(); } return TYPE;} I'd rather write: @SuppressWarning(unchecked) public static V TypeModelUpdatedHandlerV getType() { return TYPE; } (TYPE might have to be of type Type?) (Given that you most probably won't use ModelUpdatedEvent without its TYPE, you can just initialize it in the declaration, like GWT does, and have getType() just return TYPE) But then i guess i can't use them with an event bus (the HandlerManager)? I lack complete understand ofgenericsand wildcards, but assuming the class doesn't know the type, this won't work right? Even if the class did use V, it wouldn't work, becausegenericsin Java are hardly more than just syntactic sugar (google for javagenericserasure). eventBus.addHandler(ModelUpdatedEvent.getType(), ...) However you write ModelUpdatedEvent/ModelUpdatedHandler, you'd end up having all your handlers receive all ModelUpdatedEvent? events. The only way you could make this work is having a getType(Class? cls) returning a different TypeModelUpdatedHandler? instance for each class given as argument: public static V TypeModelUpdatedHandlerV getType(ClassV cls) { // do your magic here} ... eventBus.addHandler(ModelUpdatedEvent.getType(A.class), ...); ...or you could instead have a getTypeForA() and getTypeForB() methods: public static TypeModelUpdatedHandlerA getTypeForA() { return TYPE_A; } public static TypeModelUpdatedHandlerB getTypeForB() { return TYPE_B; } ...this wouldn't be that different from having a ModelUpdatedEvent subclass per model class. Thanks for your reply. I've done this (multiple subclasses), but was looking for a better option. The second point is regarding dependency injection. I got it working for things implementing interfaces, to which i bind implementations. But how do you go for the HandlerManager for example? I've tried making it a singleton as in: protected void configure() { ... bind(HandlerManager.class).asEagerSingleton(); ... but i get No @Inject or default constructor found for class com.google.gwt.event.shared.HandlerManager. Same if i use .in(Singleton.class). I've seen that GWT should fallback to GWT.create when there's no injection available, but if i don't mention the HandlerManager in my injector it also fails. ...and GWT.create() expects a default constructor. The solution IMO is to use a provider. Provider it was (as in provider method), it worked fine. Thanks again, Ricardo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Localization workflow?
On Tue, Aug 18, 2009 at 6:04 AM, Thomas Broyer t.bro...@gmail.com wrote: On 18 août, 06:38, Dobes dob...@gmail.com wrote: What tools are people using for localization? For example, currently I've defined all my strings using @DefaultValue (...) for my Constants interface instead of a properties file - is there a tool out there to convert an interface into a properties file, Add a @Generate(format = com.google.gwt.i18n.rebind.format.PropertiesFormat) attribute to your Messages or Constants interface and then just compile your project (if using GWT 1.6 or higher, pass the -extra argument with the target directory as the value) and it'll generate the properties file from the interface (if using GWT 1.5, in the www/module-aux directory). Ah, that is very cool - thanks! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Implementing the HasLoadHandlers interface
Greetings Everyone! I am relatively new to web development and I started to use GWT just a few days ago. I have the following problem: The ListBox widget does not implement the HasLoadHandlers interface and I have a ListBox that I would like to load with some data from a server. I extended ListBox as class LoadableListBox. I searched for some examples and created the code below: public class LoadableListBox extends ListBox implements HasLoadHandlers{ public HandlerRegistration addLoadHandler(LoadHandler handler) { return addHandler(handler, LoadEvent.getType()); } @Override public void fireEvent(GwtEvent? event) { } } I have another class which implements the LoadHandler interface and overrides its void onLoad(LoadEvent event) method. With the code above, the LoadableListBox on the page does not load. What is the correct way of implementing a HasXXXHandlers interface? Thank you very much for your help, Tamás Gömbös P.S.: Alternatively, I tried to load the data into the widget via its parent's void onLoad() method and it doesn't load the ListBox when I open the page, only if I reload it. I suppose this is because of the client-server mechanism or something like that. I don't go into details in this case, because I think the correct way is the former. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
when should we use GWT RPC and HTTP mechanism to communicate to server
Hi to all, I am new to GWT. I read GWT communication with server tutorial. It provides various mechanisms to communicate with the server. Any way i know how to use GWT RPC and HTTP mechanism to communicate with server. I request all of you can you give perfect explanation to when should we use RPC mechanism and when should we use HTTP mechanism. I mean at what type instances we are forced to use particular mechanism. Great thanks in advance.. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Confused about GWT + App Engine
Hello, I have been studying and trying GWT for 2 weeks now. I love it. So I decided to start building something useful. Now, I came across google app engine. For someone, who just wants to build something to learn this sounds like a very good place to install applications without spending $$$ for hosting and other resources. App engine provides data storage, authentication and hosting. GWT will give me ability to manipulate DOM using Java at the same time communicate with server-side. But is it possible to use GWT in JSP pages that are hosted on App Engine? I am confused about what will take precedence. I am sorry if my question sounds stupid but GWT and App Engine are sort of very different architecture for a traditional web developer to understand. Thank you for help. Malay --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Multiple Projects in Eclipse Sharing RPCs
looks like you found a way how to break google groups :) i don't even see the original message, and the left bar displays server error :) On Aug 17, 9:43 pm, Lucas Neves Martins snown...@gmail.com wrote: ??? What happened? On 17 ago, 12:15, Jason Parekh jasonpar...@gmail.com wrote: Hey jhnclvr, FYI, your message was truncated =) On Mon, Aug 17, 2009 at 10:03 AM, jhnclvr jhnc...@gmail.com wrote: Hello everyone, --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Error parsing JSON
On 08/17/2009 10:03 PM, Luke wrote: Below is json object that I am having trouble with. When I try to use this object with JSONParser.parse(), I get JSONException. I have verified that the JSON object is of valid form but cannot figure out why I am getting the exception. I have narrowed it down to the particular line of code that contains JSONParser.parse(); Anyone see anything here? Well, all that JSONParser() does is to call eval() on the string. Try wrapping the object in parenthesis: $! Notice that the string is now quoted. $! This simulates what that client receives. $ head /tmp/foo.js x ='{projects:[{id:1,title:Project Number 1,priority:High,openDate:2009-06-05,closeDate:2009-06-07,owner snip Well I'm a Rhino man Well, don't you know I am? (apologies to F. Zappa) $ rhino js load(/tmp/foo.js) js print(x.toSource()) (new String({\projects\:[{\id\:\1\,\title\:\Project Number 1\,\priority\:\High\,\openDate\:\2009-06-05\,\closeDate\:\2009-06-07\,\owner\: {\firstName\:\John\,\lastName\:\Doe\ snip js print (eval(x)) js: stdin#4(eval), line 1: uncaught JavaScript runtime exception: SyntaxError: missing ; before statement at stdin:4 snip js print(eval('('+x+')')) [object Object] --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Posting back xml to server
Hi, I want to retrieve an XML from the server to my client , changing values of that xml and want to send the modified xml back to the server. Presently i am successful in retrieving the xml and modifying the xml, but how to send it back? i am using: RequestBuilder builder5 = new RequestBuilder (RequestBuilder.POST,file.xml); to post it back to the server but this is not working can anyone tell me where am i going wrong? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
GWT Error
I was following a tutorial on another site for the GWT Eclipse plug in. I followed directions and got this error as a popup box: Could not find the main class: com.google.gwt.dev.HostedMode. Program will exit. On the console, it shows this: And this is printed to the terminal: java.lang.UnsatisfiedLinkError: C:\Program Files\eclipse\plugins \com.google.gwt.eclipse.sdkbundle.win32_1.7.0.v200907131030\gwt- windows-1.7.0\swt-win32-3235.dll: Can't load IA 32-bit .dll on a AMD 64-bit platform at java.lang.ClassLoader$NativeLibrary.load(Native Method) at java.lang.ClassLoader.loadLibrary0(Unknown Source) at java.lang.ClassLoader.loadLibrary(Unknown Source) at java.lang.Runtime.load0(Unknown Source) at java.lang.System.load(Unknown Source) at org.eclipse.swt.internal.Library.loadLibrary(Library.java: 132) at org.eclipse.swt.internal.win32.OS.clinit(OS.java:18) at org.eclipse.swt.widgets.Display.clinit(Display.java:125) at com.google.gwt.dev.SwtHostedModeBase.clinit (SwtHostedModeBase.java:82) Once I click okay, an additional line is printed to the terminal: Exception in thread main I posted a message on their group, and they told me to check this group, where a search found nothing. They say the problem is the cant load message, and it's a bug. So I was wondering if there is anythign I can do about this? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: SmartGWT 1.2 Tile Sort Filtering Example Question Fuzzy Search / (Maybe Bug)?
Problem solved, use setOperator(OperatorId.CONTAINS); Greets, Jan [CODE] final DynamicForm filterForm = new DynamicForm(); filterForm.setIsGroup(true); filterForm.setGroupTitle(Search); filterForm.setNumCols(6); filterForm.setDataSource(AnimalXmlDS.getInstance()); filterForm.setAutoFocus(false); TextItem commonNameItem = new TextItem(commonName); commonNameItem.setOperator(OperatorId.CONTAINS); filterForm.setFields(commonNameItem); filterForm.addItemChangedHandler(new ItemChangedHandler() { public void onItemChanged(ItemChangedEvent event) { tileGrid.fetchData(filterForm.getValuesAsCriteria()); } }); [/CODE] On Aug 18, 2009, at 9:32 AM, Sanjiv Jivan wrote: Jan, Please post SmartGWT specific questions on the SmartGWT forum : http://forums.smartclient.com/forumdisplay.php?f=14 Thanks, Sanjiv On Mon, Aug 17, 2009 at 7:00 PM, Jan weitz@googlemail.com wrote: Hi everybody, I am just new to GWT and experiencing a little bit with SmartGWT, implementing and trying to change the Tile Sort Filtering Example from the Showcase http://www.smartclient.com/smartgwt/showcase/#featured_tile_filtering I am trying to implement the above example with a fuzzy search but without the extra SearchItems, which causes the FuzzySearch to fail and draw back on an EQUALS search. Everything works fine with the example, but here comes my 'error' / 'bug' : Here is an excerpt from the code from the showcase example: code final DynamicForm filterForm = new DynamicForm(); filterForm.setIsGroup(true); filterForm.setGroupTitle(Search); filterForm.setNumCols(6); filterForm.setDataSource(AnimalXmlDS.getInstance()); filterForm.setAutoFocus(false); TextItem commonNameItem = new TextItem(commonName); SliderItem lifeSpanItem = new SliderItem(lifeSpan); lifeSpanItem.setTitle(Max Life Span); lifeSpanItem.setMinValue(1); lifeSpanItem.setMaxValue(60); lifeSpanItem.setDefaultValue(60); lifeSpanItem.setHeight(50); lifeSpanItem.setOperator(OperatorId.LESS_THAN); SelectItem statusItem = new SelectItem(status); statusItem.setOperator(OperatorId.EQUALS); statusItem.setAllowEmptyValue(true); filterForm.setFields(commonNameItem, lifeSpanItem, statusItem); filterForm.addItemChangedHandler(new ItemChangedHandler() { public void onItemChanged(ItemChangedEvent event) { tileGrid.fetchData(filterForm.getValuesAsCriteria()); } }); /code Three search items are created and fit together in the filterForm. Using the form and entering just a part of a Common Name, will break down the results with each letter I type. Now comes the bad part: I do not want the lifeSpanItem and statusItem any more. So I change code filterForm.setFields(commonNameItem, lifeSpanItem, statusItem); /code to code filterForm.setFields(commonNameItem); /code Now, trying to enter just a part of a Common Name will not break down my results with each letter I type, but instead the behaviour is like commonNameItem.setOperator(OperatorId.EQUALS) So what I am saying is that the search works fine for searchItems greater than just one TextField. My workaround therefore was to create a HiddenItem as follows: code HiddenItem tagsItem = new HiddenItem(tags); tagsItem.setOperator(OperatorId.EQUALS); filterForm.setFields(commonNameItem, tagsItem); /code Now I think that this can't be right. Now am I missing something? Do I have to use .setOperator on commonNameItem, if only commonNameItem is present? If yes: Which OperatorId should I choose? Thank you very much for your help, Greets, Jan --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT + gears + eclipse, problem.
That's a great suggestion! On Tue, Aug 18, 2009 at 11:23 AM, philipmacphilipmacmena...@gmail.com wrote: Ah ha. OK. Makes sense. There was actually another poster three posts after me with the same issue. Any idea why gears-gwt is not also released as an Eclipse Plugin? xerces library is not bundled. -- Google Code Jam 2009 http://code.google.com/codejam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Offline GWT Applications
So it seems RPC calls definitely do NOT work when the browser is in Offline Mode. If you just unplug your machine, RPC calls will still work. If you, however, close the browser, and restart your application, it is possible that your application will not load until you've put the browser into Offline Mode. Once the application is loaded, you can of course take it off this mode and the RPC calls will work again. Does anyone know why I might have this problem where the browser must be in Offline Mode to re-load the app? I assume it is because I have built a Maps Application. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Quick fix for broken hosted mode with Snow Leopard 10A380 on x86_64
Great workaround! I dropped Java 1.5.0 into /System/Library/Frameworks/JavaVM.framework/ Versions/ replacing the existing 1.5.0 symlink. Opened Eclipse Preferences Java Installed JREs, and selected JVM 1.5.0 Rebuilt the project and it runs in hosted mode just fine. Thanks! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Use an Event Bus - Ray
Hey GWT peoples, In Ray's GWT talk, he suggests using the Event Bus pattern in GWT applications, to keep things clean. Does anyone have suggestions on how to approach this? Do we think he meant use the EventBus available at https://eventbus.dev.java.net/, or just the general Event Bus idea with a custom implementation for each application, depending on its needs? Are there any people out there with a simple, GWT-oriented (maybe even GWT-optimized) EventBus implementation that covers the basics, and doesn't increase your GWT app size, that they are willing to share? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
RPC Request failure to find matching method.
I have a service that is working from an existing screen. I've added a couple of new methods to it for another screen. When I attempt to call one of these RPC methods, I get an exception indicating that it failed to find a matching method: 2009-08-18 14:17:55.653:/:WARN: Exception while dispatching incoming RPC call java.lang.SecurityException: Failed to locate method upgradeImmediately (class [J, class java.lang.Long) on interface com.allureglobal.harvey.controller.gwt.PlayerServiceController requested through interface com.google.gwt.user.server.rpc.RPCRequest This controller class is implemented using Struts2 (we're slowing swapping out Struts in favor of GWT). So, the service is wired up using ServiceDefTarget to define the entry point in the Struts controller. Because of this setup, I can't run against the real service in hosted mode (that I'm aware of). So, we have a dummy service implementation for that purpose and comment out the ServiceDefTarget stuff. From that point of view, everything seems to be working. It's just when I try to hit the real service that things fail. This works great for the first screen, but the new one is failing. Anyone got any insight that might help me track down the problem? Thanks, Dave --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Code Splitting
Is code splitting available yet in some sort of semi-finished form. I am about to start a rather large portlet project that is going to have several main applications (known as components to those familiar with Joomla) and would like to defer the loading of each of the components until that area of the application is accessed. I found some examples of this for pre 1.4 with dynamic module loading, but I don't think differed binding would work correctly for my application, as from what I understand the code to decide the implementation class is only run once and not every time gwt.create is run. If code splitting is available, could someone please provide an example of how I might write my factory class. Here is my first instinct of how it should be used. public final class ComponentFactory { public static Component getComponent(String pageArg, String[] otherArgs) { if (arg == null) return new BlogComponent(otherArgs); } } public final class ComponentWrapper extends Panel implements HistoryListener { ... public void onHistoryChanged(HistoryEvent e) { GWT.runAsync(){ public void run() { clear(); add(ComponentFactory.getComponent(HistoryManager.getPageArg(), HistoryManager.getArgs())); } }; } } --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
rich und web application in one Eclipse project
Hallo everyone, i have a fine working eclipse-developed java rich client application. Now i want a new way to display my data, namely in a browser. (So i can install my app on a webserver) But the existing solution has to work like it is! I imported the GWT SDK 1.6.4. and the App Engine SDK 1.2.1 for getting GWT components for the websolution. But now my Swing components arn't supported any longer. The question: Is there a possibility to develop my new browser-solution with GWT components alongside my rich client solution in the same eclipse project? Or do you know another solution for my prob? Thanks for replys, jenny --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT + Google Maps [ERROR] Unable to load module entry point class
hey Eric - your solution for IE proxy setting was very helpfull :) I was truggling with the same issue againts gwt 1.7.0. Was working in FF but not in IE or hosted mode. Thanks again. On Fri, Apr 10, 2009 at 4:16 PM, Eric Ayers zun...@google.com wrote: Use the Directions class or Polyline class if you don't want to follow roads. On Fri, Apr 10, 2009 at 6:00 AM, nmadzharov nmadzha...@gmail.com wrote: Oh I see, my IE is not working properly anyway, so that must be the reason. Thanks very much for the help. I have one more question. I have two markers on the map, respectively I have lat and long coordinates for both and I want to have the route (actual travel) distance between them. What is the correct approach to use for that having in mind that I do not care about intermediate points, turns, the route as a whole? I need only the distance (in meters, kms, misle whatever) to travel from point A to point B via car. -- Eric Z. Ayers - GWT Team - Atlanta, GA USA http://code.google.com/webtoolkit/ -- Greetings, Marcin --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Use an Event Bus - Ray
It's been covered here on the list, and he means the pattern of an event bus. It fits in nicely with MVP. At times the lines between an eventbus/dispatching/and command patterns gets blurred, doubly for me =) . There are some samples out there on google code, you can search this mailing list for links to them. On Tue, Aug 18, 2009 at 2:48 PM, Nathannathan.shel...@gmail.com wrote: Hey GWT peoples, In Ray's GWT talk, he suggests using the Event Bus pattern in GWT applications, to keep things clean. Does anyone have suggestions on how to approach this? Do we think he meant use the EventBus available at https://eventbus.dev.java.net/, or just the general Event Bus idea with a custom implementation for each application, depending on its needs? Are there any people out there with a simple, GWT-oriented (maybe even GWT-optimized) EventBus implementation that covers the basics, and doesn't increase your GWT app size, that they are willing to share? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: MVP design issue - any work around?
Eventually, I solved it like you suggested. I can see why this is good, as it will be decoupling the presenter from the view. However, it seems a bit bulky. Let´s say I want to be able to set a style aswell, add a KeyPressHandler, add a ValueChangeHandler and so on, and that I have 10 or more textboxes in the same widget, for example in a widget for user registration requering details about address, phone number, email and so on. I would probably end up with an interface with more than 50 methods... Would this still be the way to go? On 18 Aug, 14:10, Ian Bambury ianbamb...@gmail.com wrote: How about void setEnabled(boolean enabled); It's really up to the view how it indicates whether something is disabled or not. Different views for the same interface might do different things. Ian http://examples.roughian.com 2009/8/18 Dalla dalla_man...@hotmail.com Hi all A design question for everyone using MVP for their GWT implementations :-) I have a simple interface like so: interface ArrivalWidgetInterface { HasText getSlotText(); } Let´s say that I want to set the SlotText in my widget implementing the above interface. I´m leaving some code out here, but it should be pretty straight forward if you have been using examples from Google IO 2009 and so on. Pretty simple, in a async success method I put the following: widget.getSlotText().setText(result.getSlot()); Done. Let´s say now that I want to manipulate the Slot textbox in some other way, for example disable it after the value has been set. How can I do this in a good way? Changing the interface to return an TextBox instead of the HasText interface seems like a bad idea, since that would give me problems when testing. If possible you´ll want to keep all the UI-code outside the presenter, right? So what would be best here? Create a new public method in the widget, and expose that method in the interface aswell? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Use an Event Bus - Ray
I'm really interested in this also. Is GWT planning on implementing this ? On Tue, Aug 18, 2009 at 1:48 PM, Nathan nathan.shel...@gmail.com wrote: Hey GWT peoples, In Ray's GWT talk, he suggests using the Event Bus pattern in GWT applications, to keep things clean. Does anyone have suggestions on how to approach this? Do we think he meant use the EventBus available at https://eventbus.dev.java.net/, or just the general Event Bus idea with a custom implementation for each application, depending on its needs? Are there any people out there with a simple, GWT-oriented (maybe even GWT-optimized) EventBus implementation that covers the basics, and doesn't increase your GWT app size, that they are willing to share? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT + gears + eclipse, problem.
Hey Jason, So, late night last night, baby crying, general pandemonium. Little late to start this morning. Heh. Em, ok, so the gears db stuff does appear to work. Sound! But, it only works when I compile and run in my browser, not in Hosted Mode. I sort of guessed that might be the case, what with where the sqlite db lives in my browser. I imagined that somehow this hosted mode doesn;t have access my default moz dir, that the firefox instance doesn't have quite the same environment as the real firefox instance. Or is that cargo cult thinking? Because I basically haven;t a clue whats going on in this hosted mode. I am running Linux if that's anything to do with anything. On Aug 18, 10:12 am, Jason Parekh jasonpar...@gmail.com wrote: Hey Philip, Glad everything worked OK. Did your database functionality also work? FWIW, I tried setting up the project locally, and using only gwt-gears.jar worked, though I did not have a server-side component. I'm not sure what the noredist does not contain, but if you notice strange behavior, you may want to try with regular gwt-gears.jar on a clean project. jason On Mon, Aug 17, 2009 at 9:33 PM, philipmac philipmacmena...@gmail.comwrote: Good news everyone! So, I was wondering why there is two gears jars, one called gwt-gears- noredist.jar and one called gwt-gears.jar. Well, instead of adding gwt-gears.jar to the project, I added gwt- gears-noredist.jar. The above seems to work now. I shall have to test the db functionality now. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT + gears + eclipse, problem.
Unfortunately, Gears only works under hosted mode on Windows: http://code.google.com/docreader/#p=gwt-google-apiss=gwt-google-apist=GearsFAQ On Tue, Aug 18, 2009 at 12:03 PM, philipmacphilipmacmena...@gmail.com wrote: Hey Jason, So, late night last night, baby crying, general pandemonium. Little late to start this morning. Heh. Em, ok, so the gears db stuff does appear to work. Sound! But, it only works when I compile and run in my browser, not in Hosted Mode. I sort of guessed that might be the case, what with where the sqlite db lives in my browser. I imagined that somehow this hosted mode doesn;t have access my default moz dir, that the firefox instance doesn't have quite the same environment as the real firefox instance. Or is that cargo cult thinking? Because I basically haven;t a clue whats going on in this hosted mode. I am running Linux if that's anything to do with anything. On Aug 18, 10:12 am, Jason Parekh jasonpar...@gmail.com wrote: Hey Philip, Glad everything worked OK. Did your database functionality also work? FWIW, I tried setting up the project locally, and using only gwt-gears.jar worked, though I did not have a server-side component. I'm not sure what the noredist does not contain, but if you notice strange behavior, you may want to try with regular gwt-gears.jar on a clean project. jason On Mon, Aug 17, 2009 at 9:33 PM, philipmac philipmacmena...@gmail.comwrote: Good news everyone! So, I was wondering why there is two gears jars, one called gwt-gears- noredist.jar and one called gwt-gears.jar. Well, instead of adding gwt-gears.jar to the project, I added gwt- gears-noredist.jar. The above seems to work now. I shall have to test the db functionality now. -- Google Code Jam 2009 http://code.google.com/codejam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: MVP design issue - any work around?
You have to decide on the granularity you want. I found it easier to use an interface that would give me the actual widget in my presenter, and then the presenter can do several things on each widget as it needs. I am using the widget's class in the interface, since I am using SmartGWT widgets it seemed easier that way. I kept switching back and forth between different widgets that had different Has Click Handlers types of interfaces. (the kind for Forms and the regular kind) So I may only pass back 4-5 widgets for a simple login widget. Also one of the widgets I modify through a setter in the view, which is also defined in the interface given to the presenter. One setter in a view of my app is a SetStatusText(String text), so the presenter can update as it the RPC is going on. I'm still trying to find a consistent approach that is easiest to manage. On Tue, Aug 18, 2009 at 3:10 PM, Dalladalla_man...@hotmail.com wrote: Eventually, I solved it like you suggested. I can see why this is good, as it will be decoupling the presenter from the view. However, it seems a bit bulky. Let´s say I want to be able to set a style aswell, add a KeyPressHandler, add a ValueChangeHandler and so on, and that I have 10 or more textboxes in the same widget, for example in a widget for user registration requering details about address, phone number, email and so on. I would probably end up with an interface with more than 50 methods... Would this still be the way to go? On 18 Aug, 14:10, Ian Bambury ianbamb...@gmail.com wrote: How about void setEnabled(boolean enabled); It's really up to the view how it indicates whether something is disabled or not. Different views for the same interface might do different things. Ian http://examples.roughian.com 2009/8/18 Dalla dalla_man...@hotmail.com Hi all A design question for everyone using MVP for their GWT implementations :-) I have a simple interface like so: interface ArrivalWidgetInterface { HasText getSlotText(); } Let´s say that I want to set the SlotText in my widget implementing the above interface. I´m leaving some code out here, but it should be pretty straight forward if you have been using examples from Google IO 2009 and so on. Pretty simple, in a async success method I put the following: widget.getSlotText().setText(result.getSlot()); Done. Let´s say now that I want to manipulate the Slot textbox in some other way, for example disable it after the value has been set. How can I do this in a good way? Changing the interface to return an TextBox instead of the HasText interface seems like a bad idea, since that would give me problems when testing. If possible you´ll want to keep all the UI-code outside the presenter, right? So what would be best here? Create a new public method in the widget, and expose that method in the interface aswell? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT + gears + eclipse, problem.
ah. I actually somehow didn;t see that Gears FAQ page. Ok, very good. Thanks! On Aug 18, 3:29 pm, Eric Ayers zun...@google.com wrote: Unfortunately, Gears only works under hosted mode on Windows: http://code.google.com/docreader/#p=gwt-google-apiss=gwt-google-apis... On Tue, Aug 18, 2009 at 12:03 PM, philipmacphilipmacmena...@gmail.com wrote: Hey Jason, So, late night last night, baby crying, general pandemonium. Little late to start this morning. Heh. Em, ok, so the gears db stuff does appear to work. Sound! But, it only works when I compile and run in my browser, not in Hosted Mode. I sort of guessed that might be the case, what with where the sqlite db lives in my browser. I imagined that somehow this hosted mode doesn;t have access my default moz dir, that the firefox instance doesn't have quite the same environment as the real firefox instance. Or is that cargo cult thinking? Because I basically haven;t a clue whats going on in this hosted mode. I am running Linux if that's anything to do with anything. On Aug 18, 10:12 am, Jason Parekh jasonpar...@gmail.com wrote: Hey Philip, Glad everything worked OK. Did your database functionality also work? FWIW, I tried setting up the project locally, and using only gwt-gears.jar worked, though I did not have a server-side component. I'm not sure what the noredist does not contain, but if you notice strange behavior, you may want to try with regular gwt-gears.jar on a clean project. jason On Mon, Aug 17, 2009 at 9:33 PM, philipmac philipmacmena...@gmail.comwrote: Good news everyone! So, I was wondering why there is two gears jars, one called gwt-gears- noredist.jar and one called gwt-gears.jar. Well, instead of adding gwt-gears.jar to the project, I added gwt- gears-noredist.jar. The above seems to work now. I shall have to test the db functionality now. -- Google Code Jam 2009http://code.google.com/codejam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Gin + JSNI
Hi, I'm trying to implement a JSON provider via gin JSNI. I'm not sure I understand the specifics of this technique. Just to give one example, it doesn't seem possible to create the following class: class Flavor extends JavaScriptObject implements ProviderFlavor {} Are there any examples that use Gin and JSNI? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: MVP design issue - any work around?
Probably not. I'm no expert on this, but my intuition would say that if you want to have, say, a telephone number entered then your registration view ought to add a TelephoneNumber widget which would have the logic in it to validate telephone numbers. You would then only need logic in the registration presenter/controller to say thiungs like if(phone.isValid())... or if(!phone.isEntered() || phone.isValid())... or if(!phone.isValid(country.getCountryCode())) phone.indicateInvalid()... depending how complicated you want to get, and somewhere else phone.getPhoneNumber() if everything is OK the registration presenter/controller can easily formulate the business logic required for optional and required fields. It would be a lot simpler than just having a whole load of text fields that the registration presenter/controller had to validate everything in every way. But I haven't really thought it through :-) Ian http://examples.roughian.com 2009/8/18 Dalla dalla_man...@hotmail.com Eventually, I solved it like you suggested. I can see why this is good, as it will be decoupling the presenter from the view. However, it seems a bit bulky. Let´s say I want to be able to set a style aswell, add a KeyPressHandler, add a ValueChangeHandler and so on, and that I have 10 or more textboxes in the same widget, for example in a widget for user registration requering details about address, phone number, email and so on. I would probably end up with an interface with more than 50 methods... Would this still be the way to go? On 18 Aug, 14:10, Ian Bambury ianbamb...@gmail.com wrote: How about void setEnabled(boolean enabled); It's really up to the view how it indicates whether something is disabled or not. Different views for the same interface might do different things. Ian http://examples.roughian.com 2009/8/18 Dalla dalla_man...@hotmail.com Hi all A design question for everyone using MVP for their GWT implementations :-) I have a simple interface like so: interface ArrivalWidgetInterface { HasText getSlotText(); } Let´s say that I want to set the SlotText in my widget implementing the above interface. I´m leaving some code out here, but it should be pretty straight forward if you have been using examples from Google IO 2009 and so on. Pretty simple, in a async success method I put the following: widget.getSlotText().setText(result.getSlot()); Done. Let´s say now that I want to manipulate the Slot textbox in some other way, for example disable it after the value has been set. How can I do this in a good way? Changing the interface to return an TextBox instead of the HasText interface seems like a bad idea, since that would give me problems when testing. If possible you´ll want to keep all the UI-code outside the presenter, right? So what would be best here? Create a new public method in the widget, and expose that method in the interface aswell? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Which use for CSS?
I have a question similar to this one? Has the GWT team ever considered adding a CSS compiler into GWT? Example create classes and such in Java that help with the layout. Offering as much flexibility as possible as CSS does, but then making the CSS browser independant as well as the JS. In this way the CSS can be compiled with the rest of the page, but we can be sure that (to the best of googles ability) our pages will look identical regardless of browser. has this been discussed/considered? On Jul 27, 9:12 am, Jan Ehrhardt jan.ehrha...@googlemail.com wrote: Using horizontal and vertical panels is the prefered way of realizing layouts in GWT. You shouldn't try to implement your layout from scrach. But this doesn't mean, that there is no need for CSS in GWT. GWT should also prevent you from many browser differences, but that doesn't mean, that it will do allways. On Mon, Jul 27, 2009 at 2:33 PM, Mehdi Rabah mehdi.ra...@gmail.com wrote: Hi, Thanks for your answer. So you're saying even when using GWT, a web developper have to fight with the browser differences? It seems like the themes used in GWT only change colors, which is not the main problem (which is positionning) For my layouts I use tables, meaning gwt horizontal and vertical panel, with setCellAlignment method. Regards On Mon, Jul 27, 2009 at 7:19 AM, Jan Ehrhardt jan.ehrha...@googlemail.com wrote: Hi, GWT apps are web apps and they're running inside a browser, thus it's a good choice to use CSS. If you look to the Showcase app ( http://gwt.google.comsqf/samples/Showcase/Showcase.htmlhttp://gwt.google.com/samples/Showcase/Showcase.html), it's using different themes and the switch is done by changing the CSS file, which provides colors, borders, etc. There are lots of other examples, like creating a Dialog, which lays over the rest of your app. The differences of CSS in different browsers is a common problem, but most webdevelopers know how to work around. In GWT this also means, that defered binding allows to create different implementations for different browsers. Another point, you should care about, is, how do you create margin or padding without CSS? In other GUI frameworks like SWT, you've got layout constraints, that can be applied to a component, but in GWT, you don't have. CSS is the prefered way to do. Regards Jan Ehrhardt On Sat, Jul 25, 2009 at 11:25 PM, Mehdi Rabah mehdi.ra...@gmail.comwrote: Hi, I'm trying to use CSS for the layout of my website (for now, the layout is made with layouts). The worst problem I've seen is that the layout is not the same on different browsers. So, since the GWT philosophy is to abstract the development from the browser, I was asking myself if the GWT team recommend the use of CSS? Does GWT developpers really use CSS? For what use? (IMHO positionning with CSS really suck, the margin: auto to center a div doesn't work on IE8) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Which use for CSS?
HI Guys, I am new to Java and everyday i am seing the discussions and i have a small doubt that please give me the simple View about GWT and let me know the full form of GWT. On Tue, Aug 18, 2009 at 3:59 PM, silkcom silk...@gmail.com wrote: I have a question similar to this one? Has the GWT team ever considered adding a CSS compiler into GWT? Example create classes and such in Java that help with the layout. Offering as much flexibility as possible as CSS does, but then making the CSS browser independant as well as the JS. In this way the CSS can be compiled with the rest of the page, but we can be sure that (to the best of googles ability) our pages will look identical regardless of browser. has this been discussed/considered? On Jul 27, 9:12 am, Jan Ehrhardt jan.ehrha...@googlemail.com wrote: Using horizontal and vertical panels is the prefered way of realizing layouts in GWT. You shouldn't try to implement your layout from scrach. But this doesn't mean, that there is no need for CSS in GWT. GWT should also prevent you from many browser differences, but that doesn't mean, that it will do allways. On Mon, Jul 27, 2009 at 2:33 PM, Mehdi Rabah mehdi.ra...@gmail.com wrote: Hi, Thanks for your answer. So you're saying even when using GWT, a web developper have to fight with the browser differences? It seems like the themes used in GWT only change colors, which is not the main problem (which is positionning) For my layouts I use tables, meaning gwt horizontal and vertical panel, with setCellAlignment method. Regards On Mon, Jul 27, 2009 at 7:19 AM, Jan Ehrhardt jan.ehrha...@googlemail.com wrote: Hi, GWT apps are web apps and they're running inside a browser, thus it's a good choice to use CSS. If you look to the Showcase app ( http://gwt.google.comsqf/samples/Showcase/Showcase.html http://gwt.google.com/samples/Showcase/Showcase.html), it's using different themes and the switch is done by changing the CSS file, which provides colors, borders, etc. There are lots of other examples, like creating a Dialog, which lays over the rest of your app. The differences of CSS in different browsers is a common problem, but most webdevelopers know how to work around. In GWT this also means, that defered binding allows to create different implementations for different browsers. Another point, you should care about, is, how do you create margin or padding without CSS? In other GUI frameworks like SWT, you've got layout constraints, that can be applied to a component, but in GWT, you don't have. CSS is the prefered way to do. Regards Jan Ehrhardt On Sat, Jul 25, 2009 at 11:25 PM, Mehdi Rabah mehdi.ra...@gmail.com wrote: Hi, I'm trying to use CSS for the layout of my website (for now, the layout is made with layouts). The worst problem I've seen is that the layout is not the same on different browsers. So, since the GWT philosophy is to abstract the development from the browser, I was asking myself if the GWT team recommend the use of CSS? Does GWT developpers really use CSS? For what use? (IMHO positionning with CSS really suck, the margin: auto to center a div doesn't work on IE8) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
GWT.create() doesn't work outside onModuleLoad()
Hey All, I'm trying to get one very simple line of code to work: MyService service = GWT.create(MyService.class); I've been playing around with this a lot, and I'm noticing that this works fine within in the onModuleLoad() method, but anywhere else in my client code, I get the following error (when in hosted mode): java.lang.ClassCastException: [packagename].shared.MyService_Proxy cannot be cast to [packagename].aspect.shared.MyService Anyone know what might be causing this error? Thanks, Adam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
NullPointerException when annotations are used
I just added google-gin to my project. I set it up and configured it properly, and I've been running hosted mode all day, and it has been doing DI just fine -- as expected. However, now when I try to compile, I get this stack trace: Refreshing TypeOracle [INFO] Processing types in compilation unit: file:/C:/SVN/da- gwt-webapp/src/main/java/com/example/client/presenter/gin/ LoginGinjector.java [INFO] Found type 'LoginGinjector' [INFO]Resolving annotation '@GinModules (com.example.client.presenter.gin.UserModule.class)' [INFO] [ERROR] [INFO] java.lang.ClassNotFoundException: com.example.client.presenter.gin.UserModule which stems from this: [INFO] [ERROR] Unexpected [INFO] java.lang.NullPointerException [INFO] at com.google.gwt.dev.javac.TypeOracleMediator.getAnnotationElementValue (TypeOracleMediator.java:704) [INFO] at com.google.gwt.dev.javac.TypeOracleMediator.createAnnotationInstance (TypeOracleMediator.java:442) I am using GWT 1.7.0. A google search showed several others have similar issues when annotations are added to their project. I'm using maven to build (codehaus plugin), and it has the correct classpath: C:\Program Files\Java\jdk1.6.0_14\jre\bin\java -Xmx512m -classpath C:\SVN\da-gwt-webapp\war\WEB-INF\classes; C:\Docume~1\dford\.m2\repository\com\google\gwt\inject\gin\1.0- SNAPSHOT\gin-1.0-SNAPSHOT.jar [other stuff deleted] gin-1.0-SNAPSHOT.jar I built today from SVN revision 109 of google- gin. The annotation class for @GinModules does exist in the jar at com.google.gwt.inject.client.GinModules I'm at a loss for why this is failing. Can someone help? Thanks! Davis --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT.create() doesn't work outside onModuleLoad()
The problem I was having with MyServiceAsync is that if I want to call service.getSomething(), I had to pass in an AsyncCallBack object with two functions: onSuccess() and onFailure(), both of which are of type void. I can't, within onSuccess(), set a global string variable to a certain value, which is what I'm trying to do (if you don't understand what I mean, check out http://www.java-forums.org/new-java/20629-callbacks.html). Also, if I'm able to use GWT.create() to create a MyService object in onModuleLoad(), why am I unable to do this elsewhere? On Aug 18, 5:03 pm, davis davisf...@zenoconsulting.biz wrote: Hi Brian, I think you want: MyServiceAsync service = GWT.create(MyService.class); On Aug 18, 3:00 pm, Adam Pratt mehmeh...@mailinator.com wrote: Hey All, I'm trying to get one very simple line of code to work: MyService service = GWT.create(MyService.class); I've been playing around with this a lot, and I'm noticing that this works fine within in the onModuleLoad() method, but anywhere else in my client code, I get the following error (when in hosted mode): java.lang.ClassCastException: [packagename].shared.MyService_Proxy cannot be cast to [packagename].aspect.shared.MyService Anyone know what might be causing this error? Thanks, Adam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: NullPointerException when annotations are used
Thank god for online source. line 704 of TypeOracleMediator: http://code.google.com/p/google-web-toolkit/source/browse/releases/1.7/dev/core/src/com/google/gwt/dev/javac/TypeOracleMediator.java if (expectedElementValueType.isArrayType() -- NPE the object is passed into the method from above (line 441-442): TypeBinding expectedElementValueType = mvp.binding.returnType; Object elementValue = getAnnotationElementValue(logger, expectedElementValueType, expressionValue); It seems mvp.binding.returnType returns null -- anyone familiar with GWT code know what might be the root cause? On Aug 18, 4:46 pm, davis davisf...@zenoconsulting.biz wrote: I just added google-gin to my project. I set it up and configured it properly, and I've been running hosted mode all day, and it has been doing DI just fine -- as expected. However, now when I try to compile, I get this stack trace: Refreshing TypeOracle [INFO] Processing types in compilation unit: file:/C:/SVN/da- gwt-webapp/src/main/java/com/example/client/presenter/gin/ LoginGinjector.java [INFO] Found type 'LoginGinjector' [INFO] Resolving annotation '@GinModules (com.example.client.presenter.gin.UserModule.class)' [INFO] [ERROR] [INFO] java.lang.ClassNotFoundException: com.example.client.presenter.gin.UserModule which stems from this: [INFO] [ERROR] Unexpected [INFO] java.lang.NullPointerException [INFO] at com.google.gwt.dev.javac.TypeOracleMediator.getAnnotationElementValue (TypeOracleMediator.java:704) [INFO] at com.google.gwt.dev.javac.TypeOracleMediator.createAnnotationInstance (TypeOracleMediator.java:442) I am using GWT 1.7.0. A google search showed several others have similar issues when annotations are added to their project. I'm using maven to build (codehaus plugin), and it has the correct classpath: C:\Program Files\Java\jdk1.6.0_14\jre\bin\java -Xmx512m -classpath C:\SVN\da-gwt-webapp\war\WEB-INF\classes; C:\Docume~1\dford\.m2\repository\com\google\gwt\inject\gin\1.0- SNAPSHOT\gin-1.0-SNAPSHOT.jar [other stuff deleted] gin-1.0-SNAPSHOT.jar I built today from SVN revision 109 of google- gin. The annotation class for @GinModules does exist in the jar at com.google.gwt.inject.client.GinModules I'm at a loss for why this is failing. Can someone help? Thanks! Davis --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT.create() doesn't work outside onModuleLoad()
Hi Brian, I think you want: MyServiceAsync service = GWT.create(MyService.class); On Aug 18, 3:00 pm, Adam Pratt mehmeh...@mailinator.com wrote: Hey All, I'm trying to get one very simple line of code to work: MyService service = GWT.create(MyService.class); I've been playing around with this a lot, and I'm noticing that this works fine within in the onModuleLoad() method, but anywhere else in my client code, I get the following error (when in hosted mode): java.lang.ClassCastException: [packagename].shared.MyService_Proxy cannot be cast to [packagename].aspect.shared.MyService Anyone know what might be causing this error? Thanks, Adam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: GWT.create() doesn't work outside onModuleLoad()
right, you need to read: http://groups.google.com/group/Google-Web-Toolkit/browse_thread/thread/faca1575f306ba0f/3be719c021aa19bd Now, what you'd get as a return from you method is not at all what you would expect. myVariable will NEVER be set by the time you exit the method. -jason On Aug 18, 2009, at 3:17 PM, Adam Pratt wrote: The problem I was having with MyServiceAsync is that if I want to call service.getSomething(), I had to pass in an AsyncCallBack object with two functions: onSuccess() and onFailure(), both of which are of type void. I can't, within onSuccess(), set a global string variable to a certain value, which is what I'm trying to do (if you don't understand what I mean, check out http://www.java-forums.org/new-java/20629-callbacks.html) . Also, if I'm able to use GWT.create() to create a MyService object in onModuleLoad(), why am I unable to do this elsewhere? On Aug 18, 5:03 pm, davis davisf...@zenoconsulting.biz wrote: Hi Brian, I think you want: MyServiceAsync service = GWT.create(MyService.class); On Aug 18, 3:00 pm, Adam Pratt mehmeh...@mailinator.com wrote: Hey All, I'm trying to get one very simple line of code to work: MyService service = GWT.create(MyService.class); I've been playing around with this a lot, and I'm noticing that this works fine within in the onModuleLoad() method, but anywhere else in my client code, I get the following error (when in hosted mode): java.lang.ClassCastException: [packagename].shared.MyService_Proxy cannot be cast to [packagename].aspect.shared.MyService Anyone know what might be causing this error? Thanks, Adam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
New blank project on eclipse
Hello everyone, can anyone tell me how to create a new blank project on eclipse? I'm using the gwt plugin and when I click on New web application project it creates a sample project which shows how to do an rpc. If I erase the sample code even in the configuration files I get this message: HTTP ERROR: 503 SERVICE_UNAVAILABLE RequestURI=/Wirc.html Powered by jetty:// Thanks in advance and sorry for my english. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: MVP design issue - any work around?
I asked pretty much the same question: http://groups.google.com/group/google-web-toolkit/browse_thread/thread/19b1600e34ca8f99# I am in the same boat as you are. I am trending toward just returning a TextBox when it is really a TextBox I have in the view. Will I really need to change the TextBox with something else? Sure maybe I might add some other widget library's TextBox, but this is not really a future concern, and regardless, re-factoring something like this in an IDE by changing the interface is a 5-second operation. It isn't like this interface is widely used by the rest of the code base -- we're talking about coupling two classes here. You can mock TextBox with EasyMock.createMock(TextBox.class), so testing isn't a problem. Regards, Davis On Aug 18, 3:10 pm, Dalla dalla_man...@hotmail.com wrote: Eventually, I solved it like you suggested. I can see why this is good, as it will be decoupling the presenter from the view. However, it seems a bit bulky. Let´s say I want to be able to set a style aswell, add a KeyPressHandler, add a ValueChangeHandler and so on, and that I have 10 or more textboxes in the same widget, for example in a widget for user registration requering details about address, phone number, email and so on. I would probably end up with an interface with more than 50 methods... Would this still be the way to go? On 18 Aug, 14:10, Ian Bambury ianbamb...@gmail.com wrote: How about void setEnabled(boolean enabled); It's really up to the view how it indicates whether something is disabled or not. Different views for the same interface might do different things. Ian http://examples.roughian.com 2009/8/18 Dalla dalla_man...@hotmail.com Hi all A design question for everyone using MVP for their GWT implementations :-) I have a simple interface like so: interface ArrivalWidgetInterface { HasText getSlotText(); } Let´s say that I want to set the SlotText in my widget implementing the above interface. I´m leaving some code out here, but it should be pretty straight forward if you have been using examples from Google IO 2009 and so on. Pretty simple, in a async success method I put the following: widget.getSlotText().setText(result.getSlot()); Done. Let´s say now that I want to manipulate the Slot textbox in some other way, for example disable it after the value has been set. How can I do this in a good way? Changing the interface to return an TextBox instead of the HasText interface seems like a bad idea, since that would give me problems when testing. If possible you´ll want to keep all the UI-code outside the presenter, right? So what would be best here? Create a new public method in the widget, and expose that method in the interface aswell? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Works on hosted mode but failed on Tomcat
Hi, When I deployed my application on the server, I found something very odd. One service is failed. I don't think it's the RPC's problem. Here is the error message Aug 18, 2009 5:13:53 PM org.apache.catalina.core.ApplicationContext log SEVERE: Exception while dispatching incoming RPC call com.google.gwt.user.server.rpc.UnexpectedException: Service method 'public abstract com.bashpole.mpp.model.UserEntity com.bashpole.mpp.client.rpcGwt.UserRemote.merge (com.bashpole.mpp.model.UserEntity,int)' threw an unexpected exception: java.lang.NoClassDefFoundError: org/apache/commons/digester/ Digester at com.google.gwt.user.server.rpc.RPCCopy_GWT15.encodeResponseForFailure (RPCCopy_GWT15.java:348) at com.google.gwt.user.server.rpc.RPCCopy.encodeResponseForFailure (RPCCopy.java:173) at net.sf.gilead.gwt.PersistentRemoteService.processCall (PersistentRemoteService.java:164) at com.google.gwt.user.server.rpc.RemoteServiceServlet.doPost (RemoteServiceServlet.java:86) at javax.servlet.http.HttpServlet.service(HttpServlet.java:637) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter (ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter (ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke (StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke (StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke (StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke (ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke (StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service (CoyoteAdapter.java:286) at org.apache.coyote.http11.Http11Processor.process (Http11Processor.java:845) at org.apache.coyote.http11.Http11Protocol $Http11ConnectionHandler.process(Http11Protocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java: 447) at java.lang.Thread.run(Unknown Source) Caused by: java.lang.NoClassDefFoundError: org/apache/commons/digester/ Digester at com.bashpole.meetPeoplePlaces.server.crawler.scraper.kmlparser.KmlParser.init (KmlParser.java:79) at com.bashpole.meetPeoplePlaces.server.crawler.scraper.kmlparser.AddressCleaner.init (AddressCleaner.java:88) at com.bashpole.mpp.server.util.MPPServerUtil.lookUpLatLng (MPPServerUtil.java:48) at com.bashpole.mpp.server.util.MPPServerUtil.updateGeocode (MPPServerUtil.java:17) at com.bashpole.mpp.server.rpcGwt.UserRemoteProcessImpl.merge (UserRemoteProcessImpl.java:163) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at com.google.gwt.user.server.rpc.RPCCopy_GWT15.invoke (RPCCopy_GWT15.java:563) at com.google.gwt.user.server.rpc.RPCCopy.invoke(RPCCopy.java:134) at net.sf.gilead.gwt.PersistentRemoteService.processCall (PersistentRemoteService.java:149) ... 15 more Caused by: java.lang.ClassNotFoundException: org.apache.commons.digester.Digester at org.apache.catalina.loader.WebappClassLoader.loadClass (WebappClassLoader.java:1387) at org.apache.catalina.loader.WebappClassLoader.loadClass (WebappClassLoader.java:1233) at java.lang.ClassLoader.loadClassInternal(Unknown Source) ... 27 more Is there anyone here that has any idea what's going on? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Error parsing JSON
On 18 août, 19:43, Jeff Chimene jchim...@gmail.com wrote: On 08/17/2009 10:03 PM, Luke wrote: Below is json object that I am having trouble with. When I try to use this object with JSONParser.parse(), I get JSONException. I have verified that the JSON object is of valid form but cannot figure out why I am getting the exception. I have narrowed it down to the particular line of code that contains JSONParser.parse(); Anyone see anything here? Well, all that JSONParser() does is to call eval() on the string. Try wrapping the object in parenthesis: Well, JSONParser actually calls eval() *with* the wrapping parentheses. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Gin + JSNI
On 08/18/2009 03:57 PM, Thomas Broyer wrote: On 18 août, 21:54, Jeff Chimene jchim...@gmail.com wrote: Hi, I'm trying to implement a JSON provider via gin JSNI. I'm not sure I understand the specifics of this technique. Just to give one example, it doesn't seem possible to create the following class: class Flavor extends JavaScriptObject implements ProviderFlavor {} Right, but why not just do: class Flavor extends JavaScriptObject {} class FlavorProvider implements ProviderFlavor {} Great! That's the track that I'm on. Thanks for the confirmation. If all goes well, your provider will be inlined so having two classes won't have any runtime overhead. Are there any examples that use Gin and JSNI? I'm not sure I understand what problem you have and/or want to solve. The specific problem is that I want to be able to re-purpose the PagingScrollTable sample using a JSON data source. Right now, I'm working on the tri-state data generator in that sample: generate zero rows; generate data from the server; generate random data. I'm sure that particular routine is a perfect fit for Provider. Right now I'm trying to get the random data generator part to work. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Error parsing JSON
On 08/18/2009 04:01 PM, Thomas Broyer wrote: On 18 août, 19:43, Jeff Chimene jchim...@gmail.com wrote: On 08/17/2009 10:03 PM, Luke wrote: Below is json object that I am having trouble with. When I try to use this object with JSONParser.parse(), I get JSONException. I have verified that the JSON object is of valid form but cannot figure out why I am getting the exception. I have narrowed it down to the particular line of code that contains JSONParser.parse(); Anyone see anything here? Well, all that JSONParser() does is to call eval() on the string. Try wrapping the object in parenthesis: Well, JSONParser actually calls eval() *with* the wrapping parentheses. Are they added in the parent? Checking the trunk source, I don't see that concatenation: public static JSONValue parse(String jsonString) { if (jsonString == null) { throw new NullPointerException(); } if (jsonString.length() == 0) { throw new IllegalArgumentException(empty argument); } try { return evaluate(jsonString); } catch (JavaScriptException ex) { throw new JSONException(ex); } } See http://code.google.com/p/google-web-toolkit/source/browse/trunk/user/src/com/google/gwt/json/client/JSONParser.java --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Use an Event Bus - Ray
I'm just testing out gwt-presenter to achive what you want. You may also be interested in the gwt-dispatch library, which is a GWT implementation of a 'command pattern' that Ray suggested. http://code.google.com/p/gwt-presenter/ gwt-mvp-sample has a branch that shows a more complicated example. http://code.google.com/p/gwt-mvp-sample/source/browse/#svn/branches/gwt-presenter On Aug 19, 6:48 am, Nathan nathan.shel...@gmail.com wrote: Hey GWT peoples, In Ray's GWT talk, he suggests using the Event Bus pattern in GWT applications, to keep things clean. Does anyone have suggestions on how to approach this? Do we think he meant use the EventBus available athttps://eventbus.dev.java.net/, or just the general Event Bus idea with a custom implementation for each application, depending on its needs? Are there any people out there with a simple, GWT-oriented (maybe even GWT-optimized) EventBus implementation that covers the basics, and doesn't increase your GWT app size, that they are willing to share? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Request: programmatically setting the style com.google.gwt.dom.client.Element.getStyle()
There exist the method com.google.gwt.dom.client.Element.getStyle() to get the Style object of the element but there is no corresponding setStyle() method. Also Style has the getProperty() and setProperty() methods but no removeProperty method(). Consider the case : you want to add width and height properties to an image to programmatically zoom it but later want to reset it to the original style. Currently you can not remove the width and height properties, you could only set their values to original size values. But this has not the same effect as resetting the style to the original status without with and height properties. For example if you would like the animate the image, size and width properties cause animation to be not fluid. So either we should have com.google.gwt.dom.client.Element.setStyle (Style s) to set back the original saved style object or Style should have a removeStyle(String property) method to remove a property from a style. Best we should have both as it gives flexibility regarding dynamic styling. What do you think? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Who is using smartgwt?
a few other aspects that i was considering before going with smart. 1) documentation on smart is much better, which is a major issue. 2) dev console is a huge help. 3) although isomorphic on the forums is at times raw , Ext have their own raw posters which when combined with the lack of documentation is a serious issue. 4) i found the ext architecture to be overly complex, for example their data binding , maybe sometimes you need all this complexity , but sometimes you don't , Smart components allow me to start simple and add complexity later, Ext forces me into the complexity from day one. 5) I might be wrong , but Ext feels to me just like Spring, their open source code is just a way to drive , sales of books, trade shows , and support contracts. Now don't get me wrong they should be able to make money , but i i find their approach a bit forced. not to mention the fact that there are as good alternatives like smart that don't suffer from these shortcomings. Shay --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: New blank project on eclipse
Hi, did you erase the service in war/WEB-INF/web.xml ? On Aug 19, 2009, at 12:09 AM, Franco wrote: Hello everyone, can anyone tell me how to create a new blank project on eclipse? I'm using the gwt plugin and when I click on New web application project it creates a sample project which shows how to do an rpc. If I erase the sample code even in the configuration files I get this message: HTTP ERROR: 503 SERVICE_UNAVAILABLE RequestURI=/Wirc.html Powered by jetty:// Thanks in advance and sorry for my english. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Google Eclipse plugin + gin + gwt validation
I'm creating a project for the plugin + guice gin + gwt validation. It looks easy enough to do myself, but I want to check if there's a standard way of doing this. I'd think lots of Google plugin projects would also use gin and perhaps gwt validation. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Which use for CSS?
On 18 août, 21:59, silkcom silk...@gmail.com wrote: I have a question similar to this one? Has the GWT team ever considered adding a CSS compiler into GWT? Example create classes and such in Java that help with the layout. Offering as much flexibility as possible as CSS does, but then making the CSS browser independant as well as the JS. In this way the CSS can be compiled with the rest of the page, but we can be sure that (to the best of googles ability) our pages will look identical regardless of browser. has this been discussed/considered? Have a look at http://code.google.com/p/google-web-toolkit/wiki/LayoutDesign and http://code.google.com/p/google-web-toolkit/wiki/CssResource --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Request: programmatically setting the style com.google.gwt.dom.client.Element.getStyle()
Set the image height and width to 'auto'. That's the default. Ian http://examples.roughian.com 2009/8/18 GWTCurious sad...@gmail.com There exist the method com.google.gwt.dom.client.Element.getStyle() to get the Style object of the element but there is no corresponding setStyle() method. Also Style has the getProperty() and setProperty() methods but no removeProperty method(). Consider the case : you want to add width and height properties to an image to programmatically zoom it but later want to reset it to the original style. Currently you can not remove the width and height properties, you could only set their values to original size values. But this has not the same effect as resetting the style to the original status without with and height properties. For example if you would like the animate the image, size and width properties cause animation to be not fluid. So either we should have com.google.gwt.dom.client.Element.setStyle (Style s) to set back the original saved style object or Style should have a removeStyle(String property) method to remove a property from a style. Best we should have both as it gives flexibility regarding dynamic styling. What do you think? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Drawing graphics without using Canvas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I've got an app which is going to want to draw some simple diagrams client-side. I don't want to use a Canvas for this, partly for compatibility reasons, and partly because the hosted browser doesn't support it which makes it a pig to test. Right now I'm using DOM to create a DIV containing lots of other DIVs - --- all I need is text and horizontal and vertical lines, so this works fine, but it's a bit slow. Right now I have about 500 graphics elements and I'm probably going to want to double that eventually. What other choices do I have? (What I'd *particularly* like is a nice GWT wrapper widget which abstracts over all the implementation details and uses Canvas, VML or if all else fails, this: http://www.walterzorn.com/jsgraphics/jsgraphics_e.htm ...but I haven't found one yet.) - -- ┌─── dg@cowlark.com ─ http://www.cowlark.com ─ │ │ People who think they know everything really annoy those of us who │ know we don't. --- Bjarne Stroustrup -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iD8DBQFKizrNf9E0noFvlzgRAv8uAJ4mM8NXmQA2mCt/hMsV9ZmG/GLPjQCfU0Fc YPqRJrb11MNXsvEHdNFwyhQ= =ASbf -END PGP SIGNATURE- --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: New blank project on eclipse
I tried erasing the xml files and erasing just the classes into server package and client package (except which implements the EntryPoint). On Aug 18, 7:35 pm, Jan Weitz weitz@googlemail.com wrote: Hi, did you erase the service in war/WEB-INF/web.xml ? On Aug 19, 2009, at 12:09 AM, Franco wrote: Hello everyone, can anyone tell me how to create a new blank project on eclipse? I'm using the gwt plugin and when I click on New web application project it creates a sample project which shows how to do an rpc. If I erase the sample code even in the configuration files I get this message: HTTP ERROR: 503 SERVICE_UNAVAILABLE RequestURI=/Wirc.html Powered by jetty:// Thanks in advance and sorry for my english. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Gin + JSNI
On 08/18/2009 03:57 PM, Thomas Broyer wrote: On 18 août, 21:54, Jeff Chimene jchim...@gmail.com wrote: Hi, I'm trying to implement a JSON provider via gin JSNI. I'm not sure I understand the specifics of this technique. Just to give one example, it doesn't seem possible to create the following class: class Flavor extends JavaScriptObject implements ProviderFlavor {} Right, but why not just do: class Flavor extends JavaScriptObject {} class FlavorProvider implements ProviderFlavor {} If all goes well, your provider will be inlined so having two classes won't have any runtime overhead. Are there any examples that use Gin and JSNI? I'm not sure I understand what problem you have and/or want to solve. I think I have a solution. As I understand it, when testing, one modifies the Gin Appmodule as required? In this example, I use the EmptyServer... provider. When in production, I use the Server... provider. The class retrieved as the Provider is never used; the JSNI class is read/written directly. The Gin magic still happens. I can prove this by referencing ServerProvider (which doesn't yet initialize the Server class). Sure enough, the setId() method fails at runtime with a no properties exception. o The JavaScript overlay type Server is as expected, i.e. as described at http://code.google.com/webtoolkit/doc/1.6/DevGuideCodingBasics.html#DevGuideOverlayTypes o The Gin AppModule is basically: package com.foo.client.jsnitest.client; import com.google.gwt.inject.client.AbstractGinModule; public class AppModule extends AbstractGinModule { @Override protected void configure() { bind(Server.class).toProvider(EmptyServerProvider.class); // test or bind(Server.class).toProvider(ServerProvider.class); // production } } o EmptyServerProvider is basically: package com.foo.client.jsnitest.client; import com.google.inject.Inject; import com.google.inject.Provider; public class EmptyServerProvider implements ProviderServer { private final Server server; @Inject public EmptyServerProvider() { this.server = getEmptyServer(); } @Override public Server get() { return server; } public final native Server getEmptyServer() /*-{ var JSONObject = '{server : {id : '}'; return eval('('+JSONObject+')'); }-*/; } o A Server consumer is basically: package com.foo.client.jsnitest.client; import com.google.inject.Inject; public class MainWidget { private final Server server; @Inject public MainWidget(Server server) { this.server = server; GWT.log(1. Server: +server.toSource(),null); server.setId(001); GWT.log(2. Server: +server.toSource(),null); } --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: MVP question
Hi Thomas, thanks for replying... The style thing is I guess questionable, but the basic problem with the pattern as presented which favors the Has* interfaces, etc. I think is still a design issue to consider. Another post shortly after mine basically issued the same question http://groups.google.com/group/google-web-toolkit/browse_thread/thread/19b1600e34ca8f99/b6671eb90041154c#b6671eb90041154c If it isn't addStyle( ) (your point is well taken)...it will be something else the presenter wants to manipulate on the view's widget. I guess my point is that if you have a view that is something beyond most blog/tutorial posts, it just seems to me that not returning the actual widget either makes the interface blow up, or you end up doing lots of nasty casting. My basic question is: why not just return TextBox if that is what is in your view? The coupling is between 2 classes: view and presenter. If you later change TextBox to SuperWidgetTextBox, you can re-factor it in your IDE in 5 seconds and be done with it. Am I missing something? Regards, Davis On Tue, Aug 18, 2009 at 7:05 PM, Thomas Broyert.bro...@gmail.com wrote: On 18 août, 18:40, davis davisf...@zenoconsulting.biz wrote: I'm trying to implement a version of MVP as discussed at Google I/O talk: http://code.google.com/events/io/sessions/GoogleWebToolkitBestPractic... So, one can have a presenter class that defines an internal interface, and I see it typically done like this: class PhoneEditor { interface Display { HasClickHandlers getSaveButton(); ... } It seems to me that this tends to get a bit unwieldly in practice. For example, I have an account registration page. Let's say it contains a TextBox for username and a PasswordTextBox for password. Here are some things I'd like to do to that box in my presenter: get the value, so I could have interface Display { HasValueString getUsername(); HasValueString getPassword(); } But I also have validation code in my presenter, which will validate the content of the fields, and do things like set style errors. #addStyleName( ) is defined on UIObject, so I'm kinda out of luck with that interface unless I define something like: interface Display { HasValueString getUsername(); HasValueString getPassword(); UIObject getUsernameBox(); UIObject getPasswordBox(); } but that is kind of a ridiculous and redundant interface. So, really, my question is what is so wrong with: interface Display { TextBoxBase getUsernameBox(); TextBoxBase getPasswordBox(); } I get the fact that if you can use the Has* interfaces, it helps decouple the presenter from the view more by allowing the view to change to other UI widgets later on, but I find it far too limiting in being able to manipulate the view objects without either having large, redundant interfaces or else doing lots of unsafe casting. Has anyone else encountered this conundrum, and how are they approaching it? I'm inclined to make my Display interfaces explicit. Your presenter shouldn't deal with styles, it should instead tell the view to show error near/on the username and/or password (or nowhere particularly). It's the responsibility of the view to determine (be implemented that way) if it should set a red background and/or red border on the textbox, and/or show an icon next to the box, and/or show an error summary above or below the boxes, etc. -- Zeno Consulting, Inc. home: http://www.zenoconsulting.biz blog: http://zenoconsulting.wikidot.com p: 248.894.4922 f: 313.884.2977 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: MVP question
Sorry, this was the link I meant to post to another thread - http://groups.google.com/group/google-web-toolkit/browse_thread/thread/19b1600e34ca8f99/b6671eb90041154c#b6671eb90041154c think is still a design issue to consider. Another post shortly after mine basically issued the same questionhttp://groups.google.com/group/google-web-toolkit/browse_thread/threa... --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
RichTextArea on IE7 insert p after enter typed
Hi there, why does RichTextArea format the text on IE7 with a p when you type enter? On FF and Safari typing enter just inserts a br into the text and looks more what you would expect after typing enter or line break. Any ideas if this is a bug or a feature? Thanks Dominik --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---
Re: Allow other domains to access a GWT application (running on Google App Engine)
Adding add-linker name=xs / did the trick. After I added it I could see the StockWatcher application from http://www.example.com/StockWatcher.html. Now I need to test out some request/response processing but it's a good start in the right direction. Thanks! On Aug 18, 3:27 am, Thomas Broyer t.bro...@gmail.com wrote: On 18 août, 01:08, Everett everett.to...@gmail.com wrote: Hi All, I would like to allow a particular set of other domains to access my GWT application (running on Google App Engine). Is this possible with GWT and how to do it? For example: Let's say I have the StockWatcher application from the tutorial running onhttp://stockwatcher.appspot.com. Part of the page StockWatcher.html are the lines link type=text/css rel=stylesheet href=StockWatcher.css ... script type=text/javascript language=javascript src=stockwatcher/ stockwatcher.nocache.js/script The application is run ashttp://stockwatcher.appspot.com/StockWatcher.html and everything works fine. Now let's say I want to also allow example.com to run my StockWatcher application. I tell them to make a copy of StockWatcher.html in their root directory and change the lines above to link type=text/css rel=stylesheet href=http:// stockwatcher.appspot.com/StockWatcher.css ... script type=text/javascript language=javascript src=http:// stockwatcher.appspot.com/stockwatcher/stockwatcher.nocache.js/ script The application is run ashttp://www.example.com/StockWatcher.html and, ideally, everything works fine. I tried a scenario similar to this but when I viewedhttp://www.example.com/StockWatcher.htmlIdidn't see the StockWatcher application and no errors were reported. When I view the source of the page everything looks fine to me. My questions are: 1. Is this kind of application deployment possible in GWT? yes, provided the app doesn't talk to the server using GWT-RPC or similar (Google for same origin policy to understand why) or the domain where the app runs also runs a proxy (the app calls the proxy at the same origin, which relays the requests to your AppEngine app, therefore bypassing the SOP restriction) In the near future, browsers will implement CORS http://www.w3.org/TR/ cors which will enable safe cross-origin requests (similar to Flash and IE8's XDomainRequest), but for now you'll have to go the proxy way (or use ugly hacks such as JSONP and/or post form to hidden iframe which then sets window.name) 2. If so, how would you go about doing it? I'm a developer new to GWT so I just need a kick in the right direction. Add add-linker name=xs / (it's known as the cross site linker) to your module's gwt.xml to generate *.cache.js instead of *.cache.html; that way it won't use an iframe and won't face the same- origin policy that have been blocking you in your experiment. But your app will run in the context of the page instead of being sandboxed in an iframe, which means that if another script modifies, say, the Array object, you might run into troubles (this is not quite likely but it's still a possibility). I think the choice of GWT to run within an iframe by default also has to do with caching wrt IE (or was it Firefox?) and/or HTTPS, which caches *.html well but won't cache *.js... 3. How would you get the example.com domain to check it against a whitelist of allowed domains in the GWT application? In your app, in onModuleLoad, check that Window.Location.getHostName() is what you expect. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en -~--~~~~--~~--~--~---