Re: GWT & Dagger 2

2015-09-22 Thread alucard
Are there any examples/tutorials on how to use Dagger2 with GWT. It would 
be very helpful. 

On Tuesday, August 18, 2015 at 4:13:59 PM UTC+2, Jens wrote:
>
> Could you please be a little more precise? I didn't manage to install the 
>> fork, and since the pull request still hasn't been accepted it would be 
>> great if you could elaborate more on this.
>>
>
> Since my fork is already 6 month old and I haven't rebased my changes yet 
> it is probably best if you just clone the google dagger repository. Once 
> you have done that you can do
>
> git fetch origin pull/119/head:gwt-integration
>
> This should give you a new local branch named gwt-integration which 
> contains the changes of my pull request. Now you can decide if you want to 
> rebase that local branch on a release tag (e.g. dagger-2.0.1) or on the 
> master branch. Finally you just build dagger using mvn package or mvn 
> install.
>
> -- J.
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Super Dev mode, intellij Idea 14 and File size exceeds configured limit...

2014-11-12 Thread alucard
I managed to somehow make work the superdev mode in Idea 14. I put a 
breakpoint at the beginning of my code and it is hit. The appropriate java 
source file is presented in Idea. However, after a couple reloads (change 
something + recompile) the breakpoint is hit but a javascript file is shown 
- not a java file. At the top of said javascript file there is a message: 
File size exceeds configured limit (256). Code insught features are not 
available. The project is fairly large.
Does anybody have any idea on how to solve this? Is it possible to increase 
the mentioned limit, and if so, how?
Thanks for your time.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Re: Super Dev mode, intellij Idea 14 and File size exceeds configured limit...

2014-11-12 Thread alucard
Thanks for the suggestion. Indeed stepping over/into eventualy switches 
back to java. Anyway it is a really annoying feature. I'll try and report 
it to intellij.

On Wednesday, November 12, 2014 12:11:54 PM UTC+1, Jens wrote:

 It seems like a timing issue / bug in intellij. If you use the step over, 
 step into buttons etc it should switch back to java source at some point.

 The message you are seeing has nothing to do with source maps itself. It 
 means that IntelliJ will not give you code insight features for the 
 JavaScript file because the file is too big. That means you do not get 
 advanced JavaScript code completion / code analysis and such things. It 
 does not mean it can not display source maps.

 -- J.


-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Re: Unable to use debugger

2014-09-24 Thread alucard
Are you using dev mode or super dev mode to debug?

On Sunday, September 21, 2014 12:01:03 PM UTC+2, Vineet G H wrote:

 Hi All, 

 I am using Eclipse Luna - Luna Release (4.4.0) with GWT and I put in a 
 breakpoint and attempt debug the code, it fails to stop at the breakpoint. 
 Any one knows why this might be occurring?

 Regards,
 Vineet


-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Source maps and Chrome Apps

2014-03-10 Thread alucard
I managed to create a GWT Chrome 
Apphttps://developer.chrome.com/apps/about_appsbut now I would like to use 
source map debugging with that app. Is this 
feasible? I guess I'd need to turn on the source map generation, somehow 
embed the java sources in the .crx file and tell the source maps where the 
java sources are. Can anyone help?
Any advice would be greatly appreciated. Thanks in advance.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Re: Chrome apps and GWT

2014-02-14 Thread alucard
This worked for me:

You have to add a new linker extended from DirectInstallLinker.

public class CspLinker extends DirectInstallLinker {

@Override
protected String getJsInstallLocation(LinkerContext context) {
return path/to/modified/script/installLocationMainWindow.js;
}
}


then you need to modify the installLocationMainWindow.js script (the 
setupInstallLocation function) like so:

function setupInstallLocation() {
if (init) {
return;
}
//  var script = window.document.createElement('script');
//  script.language='javascript';
//  script.text = var $wnd = window;;
//  window.document.body.appendChild(script);
window.$wnd = window;
init = true;
}


finally add this to your .gwt.xml file:

define-linker name=cspLinker class=
com.foo.bar.chrome.linker.CspLinker /
add-linker name=cspLinker /




On Monday, February 10, 2014 9:52:12 AM UTC+1, Andrew Mackenzie wrote:

 You might need to try a different GWT linker that supports cross-site 
 requests. I'll look to see which one I used tonight.
 On Feb 10, 2014 8:52 AM, alucard slice.of...@gmail.com javascript: 
 wrote:

 I am not sure I understood well but it seems that you loaded the GWT app 
 in a webview or something similar. That is not what I meant. I'd like to be 
 able to invoke the chrome.* apis from my GWT app (after I wrap them). I 
 tried this by modifying the Browser sample 
 apphttps://github.com/GoogleChrome/chrome-app-samples/tree/master/browser. 
 I modified the browser.html file to load the GWT app. The GWT app is 
 trivial, just an entry point with a simple JSNI method that logs a simple 
 message via console.log (this part shouldn't break CSP). I tried with and 
 without the DirectInstallLinker, the result is a bit better with the 
 linker (it reports fewer errors in the app console) but it does not work 
 either way.
 I didn't get the part about the loaders.
 Thanks for your help.

 On Sunday, February 9, 2014 3:18:42 PM UTC+1, Andrew Mackenzie wrote:

 I've developed a Chrome extension using mainly GWT, but it's mostly 
 loaded by the extension remotely (loading JS handcrafted). It's mainly a 
 build/packaging problem. GWT will build the JS for you and the loaders 
 then you have to include into your extension file hierarchy in your build, 
 and load as you desire.

  -- 
 You received this message because you are subscribed to a topic in the 
 Google Groups Google Web Toolkit group.
 To unsubscribe from this topic, visit 
 https://groups.google.com/d/topic/google-web-toolkit/Y1pPOVZmeoU/unsubscribe
 .
 To unsubscribe from this group and all its topics, send an email to 
 google-web-toolkit+unsubscr...@googlegroups.com javascript:.
 To post to this group, send email to 
 google-we...@googlegroups.comjavascript:
 .
 Visit this group at http://groups.google.com/group/google-web-toolkit.
 For more options, visit https://groups.google.com/groups/opt_out.



-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Chrome apps and GWT

2014-02-09 Thread alucard
Is it possible to develop Chrome 
Appshttp://developer.chrome.com/apps/about_apps.html in 
GWT. I have tried and have encountered the dreaded CSP problem as described 
herehttp://stackoverflow.com/questions/12123178/can-not-make-gwt-application-work-as-chrome-packaged-app-probably-due-to-csp.
 
I couldn't make it work with the solution mentioned therein. Has someone 
succeed to make it work? If so a minimal Hello world example would be 
nice. Thanks in advance.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Chrome apps and GWT

2014-02-09 Thread alucard
I am not sure I understood well but it seems that you loaded the GWT app in 
a webview or something similar. That is not what I meant. I'd like to be 
able to invoke the chrome.* apis from my GWT app (after I wrap them). I 
tried this by modifying the Browser sample 
apphttps://github.com/GoogleChrome/chrome-app-samples/tree/master/browser. 
I modified the browser.html file to load the GWT app. The GWT app is 
trivial, just an entry point with a simple JSNI method that logs a simple 
message via console.log (this part shouldn't break CSP). I tried with and 
without the DirectInstallLinker, the result is a bit better with the linker 
(it reports fewer errors in the app console) but it does not work either 
way.
I didn't get the part about the loaders.
Thanks for your help.

On Sunday, February 9, 2014 3:18:42 PM UTC+1, Andrew Mackenzie wrote:

 I've developed a Chrome extension using mainly GWT, but it's mostly loaded 
 by the extension remotely (loading JS handcrafted). It's mainly a 
 build/packaging problem. GWT will build the JS for you and the loaders 
 then you have to include into your extension file hierarchy in your build, 
 and load as you desire.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: How to execute periodic timers on the server side GAE?

2013-04-29 Thread alucard
This is not a GWT question so you better check for info 
herehttps://groups.google.com/forum/?fromgroups=#!forum/google-appengine. 
I can suggest to read 
thishttps://developers.google.com/appengine/docs/java/config/cron?hl=en
.

On Friday, April 26, 2013 9:09:15 PM UTC+2, membersound wrote:

 Hi,

 how can I schedule a periodic timer (every X minutes) on the serverside?
 I have a ScheduledExecutorService, but discovered that I cannot use this 
 on GAE serverside.

 Is there any possibility to create a schedule task that just runs in the 
 background, without having to trigger it explicit from the client side?
 Thnx


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




Re: Saving results from GWT-RPC call on client

2013-03-19 Thread alucard
Hello JeanV,

I made a googlecode project https://code.google.com/p/gwt-serialization/for 
you (and whoever else wishes to use the serialization library). I 
included instructions on how to use it. Check it out and let me know if 
there are problems. I'll try to fix them.

Cheers

On Tuesday, March 19, 2013 11:05:08 AM UTC+1, JeanV wrote:

 Thanks Moneyboy,

 Can you post an example of how you achieved this. Not the storage part but 
 the implementation of the streamwriter on the client side.
 Many thanks,

 Jean

 On Wednesday, October 10, 2012 9:30:31 AM UTC+2, monkeyboy wrote:

 It is feasible. In my solution I used GWT-RPC's serialization but I had 
 to tweak it since GWT-RPC messages are assymetric (the message sent from 
 the client to the server is in a different format than the message sent 
 from the server to the client even if they transfer the same object). 
 Basically you have to make the serialization symetric. I did this by 
 implementing the streamwriter to output the same message that the 
 serverside would output. I did this basically by porting the server code to 
 the gwt side. I then leveraged the already existing reader in the client 
 and generated (by using generators) a class that returns the desired reader 
 and writer. The reader is of course used to read the string and outputs the 
 object and the writer takes the object and outputs the string. By using 
 this method you can not only save results from RPC calls but any 
 serializable object in the LocalStorage.
 Since the storage in the LocalStorage is limited a further improvement is 
 to compress the string. For this I use the LZMA algorithm which can 
 compress the strings to about 60% of their original size. Based on my 
 tests, bigger objects compress better but this is based on objects in my 
 project and might not be the case for other kinds of objects.

 Hope this helps.   
 Regards,
M

 On Wednesday, October 10, 2012 7:13:20 AM UTC+2, JeanV wrote:

 I was wondering if there's anyway to save the returned results from an 
 RPC call to an HTML5 enabled browser. Basically the only way I have found 
 would be to convert the results into strings and use LocalStorage to save 
 them to the browser. I guess my question then would be how can 
 IsSerializable java objects be converted to a string and back.
 Any help would be appreciated.

 Jean



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




Re: Is there any ArrayMap?

2013-03-18 Thread alucard
Have you tried looking into 
guava-gwthttps://code.google.com/p/guava-libraries/
?

On Monday, March 18, 2013 1:40:06 PM UTC+1, membersound wrote:

 Hi,

 I'd need some client-side ArrayMap: a combination of a LinkedHashMap that 
 preserves the order of insertion, and some kind of index() method that 
 provides insertion of an element at a specific index position (like 
 ArrayList.add(index, 
 object)).

 Is there anything build in GWT, or maybe a module that can be used like 
 Guava?

 Or would I have to use both ArrayList and LinkedHashMap and keep them 
 synchronized myself to achive both key-value access and index-aware listing?


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




Re: GWT 2.5.1 now available

2013-03-12 Thread alucard
Thank You for the great work, it is much appreciated. Keep the new stuff 
coming.

On Tuesday, March 12, 2013 2:11:16 AM UTC+1, Matthew Dempsky wrote:

 Hi everyone,

 We're excited to announce the GWT 2.5.1 release!  There will be an 
 announcement soon on the GWT Blog http://googlewebtoolkit.blogspot.com/, 
 and you can download it 
 herehttps://code.google.com/p/google-web-toolkit/downloads/detail?name=gwt-2.5.1.zip.
  
  This release has been uploaded to Maven Central with the version string of 
 2.5.1.

 GWT 2.5.1 contains over 50 new bug fixes, many of which were contributed 
 by the community.  Thanks to everyone who reported issues and/or submitted 
 patches.

 -Matthew, on behalf of the GWT team


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




Re: I/O 2013 - GWT Sessions?

2013-03-08 Thread alucard
There is some info 
here: https://plus.google.com/u/0/116224868564491909221/posts/M5ctPLTwp6W
Ray says there might be a couple of sessions but isn't sure.

On Wednesday, March 6, 2013 11:56:52 PM UTC+1, James wrote:

 I know it's earlybut is anyone familiar with the planned Google Web 
 Toolkit sessions for Google I/O 2013?  It was a bit disappointing last year 
 when there was only one real GWT session...after there had been many in all 
 the previous years.  GWT Team...any comments?

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




Re: GWT dev mode and GIN and dependency injection in general

2013-03-01 Thread alucard
You know you re both right. Funny thing is I had GIN 2.0 in my project a 
long time but since I had not realised that gin was improved God knows how 
many times I needlessly rebuilt my project. *facepalm*

On Thursday, February 28, 2013 11:43:57 PM UTC+1, Thomas Broyer wrote:



 On Thursday, February 28, 2013 11:21:48 PM UTC+1, alucard wrote:



 On Thursday, February 28, 2013 6:43:11 PM UTC+1, Marc wrote:

 Hello!

 I just experimented somewhat with Gin and realized that it (v2.0) seems 
 to break the incremental compilation feature of GWT's development mode, ie. 
 where I just have to save the .java source file and the gwt dev mode server 
 automatically incorporates the changes.

 Can someone confirm this or is it my own fault?

  
 I believe you're right. If you mess with DI stuff (for example add a 
 new parameter to a constructor annotated with @Inject) the code will break 
 when you reload. You have to rebuild the project at that point. I believe 
 this is due to gin using generators which are not triggered on reload.  


 While this was true in previous versions, I believe it no longer is 
 starting with GIN 2.0.


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




Re: GWT dev mode and GIN and dependency injection in general

2013-02-28 Thread alucard


On Thursday, February 28, 2013 6:43:11 PM UTC+1, Marc wrote:

 Hello!

 I just experimented somewhat with Gin and realized that it (v2.0) seems to 
 break the incremental compilation feature of GWT's development mode, ie. 
 where I just have to save the .java source file and the gwt dev mode server 
 automatically incorporates the changes.

 Can someone confirm this or is it my own fault?

 
I believe you're right. If you mess with DI stuff (for example add a new 
parameter to a constructor annotated with @Inject) the code will break when 
you reload. You have to rebuild the project at that point. I believe this 
is due to gin using generators which are not triggered on reload.  


 In general: what DI frameworks are there for GWT? I'd like to have 
 something akin to Spring's auto-wiring based on interfaces+class path 
 scanning, but, of course, *before* runtime, ie. at compile time to avoid 
 performance loss in production. I'm even thinking about an annotation 
 processor that generates the GinModule bindery code, however, using 
 something that already exists and is properly maintained is always an 
 advantage ;-).


I believe gin is the best DI for GWT out there. 


 Best regards,
 Mark


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




Re: How to invoke Java String methods from JSNI code

2013-02-16 Thread alucard
Thanks for the tip. I'll go with that.

On Saturday, February 16, 2013 12:34:05 AM UTC+1, Thomas Broyer wrote:



 On Saturday, February 16, 2013 12:13:04 AM UTC+1, alucard wrote:

 On Friday, February 15, 2013 11:15:40 PM UTC+1, Thomas Broyer wrote:

 String is a special beast, as it's emulated by a JS String. It wouldn't 
 surprise me if that use case weren't supported. I grep'ed the source code 
 of GWT and didn't find any such use.

 Yeah. I found this in the docs for the emulated string:

 For efficiency we handle String in a specialized way, in fact, a
 java.lang.String is actually implemented as a native JavaScript String. 
 Then
 we just load up the prototype of the JavaScript String object with the
 appropriate instance methods.

 So it should be possible to use the instance methods but not with the 
 obje...@java.lang.String... notation. Any ideas on what could be used 
 instead?



 You can use a bridge method:

 public static int stringCompareTo(String a, String b) {
   return a.compareTo(b);
 }

 private static native int test(String str) /*-{
return 
 @com.example.MyClass::stringCompareTo(Ljava/lang/String;Ljava/lang/String;)(str,
  
 test);
 }-*/;


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




How to invoke Java String methods from JSNI code

2013-02-15 Thread alucard
This does not work:

private static native int test(String str) /*-{
   return s...@java.lang.String::compareTo(Ljava/lang/String;)(test);
}-*/;

It dies with the following exception:

com.google.gwt.core.client.JavaScriptException: (Error) 
@test.client.Test::test(Ljava/lang/String;)([string: 'hello']): Error 
calling method on NPObject.
at 
com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:249)
at 
com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:571)

Is it possible (if yes please write how) to invoke String methods from JSNI?

Thanks for the help.

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




Re: How to invoke Java String methods from JSNI code

2013-02-15 Thread alucard
Yes, but that was not the question. I'd like to be able to invoke methods 
from the Java String implementation. The code above is meant just as an 
example for the error I get.

On Friday, February 15, 2013 2:26:43 PM UTC+1, Patrick Tucker wrote:

 Does str  test not get the result you want?

 On Friday, February 15, 2013 5:53:58 AM UTC-5, alucard wrote:

 This does not work:

 private static native int test(String str) /*-{
return s...@java.lang.String::compareTo(Ljava/lang/String;)(test);
 }-*/;

 It dies with the following exception:

 com.google.gwt.core.client.JavaScriptException: (Error) 
 @test.client.Test::test(Ljava/lang/String;)([string: 'hello']): Error 
 calling method on NPObject.
 at 
 com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:249)
 at 
 com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
 at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:571)

 Is it possible (if yes please write how) to invoke String methods from 
 JSNI?

 Thanks for the help.



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




Re: How to invoke Java String methods from JSNI code

2013-02-15 Thread alucard
On Friday, February 15, 2013 11:15:40 PM UTC+1, Thomas Broyer wrote:

 String is a special beast, as it's emulated by a JS String. It wouldn't 
 surprise me if that use case weren't supported. I grep'ed the source code 
 of GWT and didn't find any such use.

Yeah. I found this in the docs for the emulated string:

For efficiency we handle String in a specialized way, in fact, a
java.lang.String is actually implemented as a native JavaScript String. Then
we just load up the prototype of the JavaScript String object with the
appropriate instance methods.

So it should be possible to use the instance methods but not with the 
obje...@java.lang.String... notation. Any ideas on what could be used 
instead?

On Friday, February 15, 2013 11:53:58 AM UTC+1, alucard wrote:

 This does not work:

 private static native int test(String str) /*-{
return s...@java.lang.String::compareTo(Ljava/lang/String;)(test);
 }-*/;

 It dies with the following exception:

 com.google.gwt.core.client.JavaScriptException: (Error) 
 @test.client.Test::test(Ljava/lang/String;)([string: 'hello']): Error 
 calling method on NPObject.
 at 
 com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:249)
 at 
 com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
 at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:571)

 Is it possible (if yes please write how) to invoke String methods from 
 JSNI?

 Thanks for the help.



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




Re: GWT Window Scroll Bottom hit detection

2012-11-27 Thread alucard
Have you seen this showcase 
examplehttp://gwt.google.com/samples/Showcase/Showcase.html#!CwCellList. 
When you scroll down the list it triggers an event when it reaches the end 
of the list on which You could load more data. See the code for 
ShowMorePagerPanel.
HTH

On Tuesday, November 27, 2012 10:35:45 AM UTC+1, Alp Yilancioglu wrote:

 Hello;
  
 how can i make the main page ( the page only uses the HTML Scroll Bar  
 (navigators scroll bar) )
 auto load more results when the page hits the bottom. (like in ios apps ) 
  
 unfortunetly i can only get the Scroll Top and ClientHeight and 
 OffSetHeight .. these are not enough values for detecting page the bottom 
 hit ?
  
  


-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-web-toolkit/-/UO7NbJ9Oe2AJ.
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: Increasing Client-side Storage

2012-11-08 Thread alucard
If you are developing for mobile devices you could try with 
Phonegaphttp://phonegap.com/ (aka 
Apache Cordova http://incubator.apache.org/cordova/). They have a 
filehttp://docs.phonegap.com/en/2.2.0/cordova_file_file.md.html#Fileand a 
storagehttp://docs.phonegap.com/en/2.2.0/cordova_storage_storage.md.html#StorageAPI.
 I believe these support large ammounts of data. Also checkout 
gwt-phonegap https://code.google.com/p/gwt-phonegap/.

Hope this helps.

On Thursday, November 8, 2012 12:00:47 PM UTC+1, Nukeface wrote:

 So i read the Client-side Storage introduction article. I do have a 
 question.

 The company I'm doing my work experience is having trouble with the 
 Client-side storage of all browsers as the size limits are met. We're 
 developing an app which requires offline capability and uses lots and lots 
 of data on the mobile device. 

 Is there a way to automatically increase the maximum size, or set it to 
 unlimited size, for the application? Or is there a way to achieve this with 
 user confirmation? 

 Our problem is that the application crashes when the limit is hit, which 
 happens during synchronization, so not all of the required user data is yet 
 present. 

 Thx in advance.


-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-web-toolkit/-/vL9mJi4UXTEJ.
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.



Will there be GWT sessions on this year's (2012) Google I/O?

2012-04-20 Thread alucard
The title says it all. 

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-web-toolkit/-/7UhyLIt1z14J.
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.



addWindowClosingHandler on new opened window

2010-06-07 Thread alucarD
Hi
I am implementing hybrid protocol (openid + oauth) in popup window. I
want know when the helper popup window is closing becouse I must do
some code before it's close.
Code like this dont work on new opened helper window, but on entire
application:
Window.open(http://www.google.pl;, popup log in, );
Window.addWindowClosingHandler(new Window.ClosingHandler() {

@Override
public void 
onWindowClosing(ClosingEvent event) {
// TODO Auto-generated method 
stub
event.setMessage(leave page?);
}
});

When I close helper window then nothing is happen. When I refresh
app then function onWindowClosing is fire.
Please 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-tool...@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.