Re: Design Decision RPC with AsyncDataProvider

2013-06-18 Thread Jochen Schnaidt
Hi,

I now started to give my columns DataStoreNames, works much better for a 
couple of requirements.

Thank you so much for helping me on this topic.

Best regards

Jochen

-- 
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: RequestFactory, entity Id not populated when it reaches the server?

2013-06-18 Thread Thomas Broyer


On Monday, June 17, 2013 9:55:09 PM UTC+2, GWTter wrote:
>
> Hi,
>
> So I went back using the dev tools, inspected the payload, and confirmed 
> what I had before: the ID is not set at all in the user object payload. 
> Just to make sure I wasn't crazy or missing something I created just a User 
> object and tried to save it. I checked the payload in that request and 
> could clearly see the ID set in the object.
>
> I've persisted/sent entities that had field values set with other entities 
> before. The only difference I can make between the two cases is that in the 
> previous case the entity I was setting as the field value was from a 
> request to the server (I had not created it on the client). In this case 
> the booking entity is created on the client and the user entity is also 
> created on the client. Could this be the reason why it's failing? maybe 
> because RF only lets you add entities as fields if they already have 
> stableIDs? 
>
> Thanks again in advance.
>

If you can make a small repro case, please file an issue; it looks like a 
critical regression (which would also mean our test suite is weak)

-- 
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: JUnitShell: Why is the log level overriden to WARN?

2013-06-18 Thread Thomas Broyer


On Monday, June 17, 2013 10:54:16 PM UTC+2, Maik Riechert wrote:
>
> Hi,
>
> when developing JUnit runstyles I want to do info/trace logging, e.g.:
>
> shell.getTopLogger().log(TreeLogger.TRACE, "Letting PhantomJS fetch " + 
> url);
>
> I have to change all those logging outputs to at least WARN to see 
> anything. This is caused by the following code in JUnitShell I guess:
>
>   // Override log level to set WARN by default..
>   registerHandler(new ArgHandlerLogLevel(options) {
> @Override
> protected Type getDefaultLogLevel() {
>   return TreeLogger.WARN;
> }
>   });
>
> My question is: Why? I find it very strange that I can't set a custom log 
> level via command line argument or system property. What is the reasoning 
> behind this and can it be changed?
>

You definitely *can* change the log level from the command line, WARN is 
just the default value.
Arguments are passed to JUnitShell through the gwt.args system property, 
the same you use to set your custom RunStyle: -Dgwt.args="-logLevel DEBUG 
-out www-test -runStyle com.example.PhantomJS:/path/to/phantomjs"

-- 
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: JUnitShell: Why is the log level overriden to WARN?

2013-06-18 Thread Maik Riechert

Thomas Broyer wrote:
You definitely *can* change the log level from the command line, WARN 
is just the default value.
Arguments are passed to JUnitShell through the gwt.args system 
property, the same you use to set your custom RunStyle: 
-Dgwt.args="-logLevel DEBUG -out www-test -runStyle 
com.example.PhantomJS:/path/to/phantomjs"


Hmm, I already tried setting the logLevel through the maven configuration:
https://github.com/neothemachine/KineticGWT/blob/master/pom.xml#L122

Am I doing something wrong?

--
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: AWS (CDN) GWT file deployment and 'Blocked a frame with origin' issue

2013-06-18 Thread Thomas Broyer


On Monday, June 17, 2013 7:26:43 PM UTC+2, Joseph Lust wrote:
>
> Thomas,
>
> Sorry I didn't catch you at the GWTogether in SF last month. I owe you a 
> number of beers. :)
>
> *That did the trick*. I'll bang out an article for GWTProject.org on AWS 
> (and similar) CDN deployments.
>
> BTW, I shamefully plead ignorance on the *xsiframe* linker. I'd only used 
> the linkers in the GWT 
> Docs
> .
>
> Yet, a grepping against the GWT source reveals:
>
>- appcachelinker (sample)
>- direct_install
>- xs
>- sso
>- std
>- xsiframe
>
> We'll need to ensure the new official 
> docsinclude
>  these as I've seen little documentation on most of them, or perhaps 
> I'm missing something and they're not all meant for prime time yet.
>

Yes, we need to document them (or update existing documentation) and 
possibly deprecate a few of them.
When xsiframe was introduced a few releases ago, it was said that it could 
eventually replace std as the default linker: it combines the best of 
iframe (sandboxing in an iframe, DevMode) and xs (cross-origin), and is 
modular and extensible (you can even "plug" your own script "fragments" 
using ), and of course also brings 
SuperDevMode. I think "xs" should be deprecated, maybe sso too (who 
compiles a single permutation anyway?)
AFAICT, Google's  linker (Server-Side Selection Script) is based on 
xsiframe (or direct_install, which extends xsiframe)

-- 
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: JUnitShell: Why is the log level overriden to WARN?

2013-06-18 Thread Thomas Broyer


On Tuesday, June 18, 2013 10:11:57 AM UTC+2, Maik Riechert wrote:
>
>  Thomas Broyer wrote:
>  
> You definitely *can* change the log level from the command line, WARN is 
> just the default value. 
> Arguments are passed to JUnitShell through the gwt.args system property, 
> the same you use to set your custom RunStyle: -Dgwt.args="-logLevel DEBUG 
> -out www-test -runStyle com.example.PhantomJS:/path/to/phantomjs"
>  
>
> Hmm, I already tried setting the logLevel through the maven configuration:
> https://github.com/neothemachine/KineticGWT/blob/master/pom.xml#L122
>
> Am I doing something wrong?
>

No, the gwt-maven-plugin is doing something wrong: it does not allow you to 
configure the logLevel: 
https://github.com/gwt-maven-plugin/gwt-maven-plugin/blob/2fa0f0065aecde5e6ced88eb5f82a6e914ec2cdb/src/main/java/org/codehaus/mojo/gwt/shell/TestMojo.java#L300

-- 
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.




Dynamic place navigation

2013-06-18 Thread Prince
Hi,

I have a requirement to navigate to the places where place is dynamically 
decided.

For example,

I have an "Edit User" link from Screen-1 & Screen-2. When I click on the 
link, it takes me to EditUserView.java. Now, when I click on Save button 
from my EditUserView.java, it should take me to Screen-1 if I come 
from Screen-1 and to Screen-2 if I come from Screen-2.

Is there any way I can achieve this?

Thanks

-- 
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: Dynamic place navigation

2013-06-18 Thread Jens
History.back(); maybe? 

If this doesn't work for you then store the previous place in the current 
place so you can call 
placeController.goTo(editUserPlace.getPreviousPlace()); later on.

-- 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/groups/opt_out.




Re: Dynamic place navigation

2013-06-18 Thread Thomas Broyer


On Tuesday, June 18, 2013 11:19:39 AM UTC+2, Prince wrote:
>
> Hi,
>
> I have a requirement to navigate to the places where place is dynamically 
> decided.
>
> For example,
>
> I have an "Edit User" link from Screen-1 & Screen-2. When I click on the 
> link, it takes me to EditUserView.java. Now, when I click on Save button 
> from my EditUserView.java, it should take me to Screen-1 if I come 
> from Screen-1 and to Screen-2 if I come from Screen-2.
>
> Is there any way I can achieve this?
>

Add the "return-to place" to the "edit user" place (that doesn't mean you 
surface it in the URL through the PlaceTokenizer though), so you can use in 
from your EditUserView (and choose a sane default when the place is 
constructed from the URL and doesn't have a "return-to place"; as an 
alternative, just put the "return-to place" in the URL, serializing it 
using the PlaceHistoryMapper).
As an alternative, you can use 2 distinct places *resolving* to the same 
EditUserView.
In any case, the idea is to choose the next place based on the current 
place.

-- 
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.




How to update and refresh a Cell by code?

2013-06-18 Thread membersound
Hi,

I have a CellWidget (EditTextCell) that I want to set a specific value 
manually by code. But the UI is not updated? What am I missing?

@UiField(provided = true)
CellWidget cell;

cell.setValue(text, true);
cell.redraw();

-- 
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.




JUnitShell.getModuleUrl() produces invalid URL for IPv6 addresses

2013-06-18 Thread Maik Riechert
Hi,

it seems the JUnitShell is generating invalid URLs if IPv6 is used:

http://2607:f700:8000:12d:dd58:687b:744c:800c:48579/...

You can observe this here:
https://travis-ci.org/neothemachine/KineticGWT/builds/8191369#L881

The URL should be 
http://[2607:f700:8000:12d:dd58:687b:744c:800c]:48579/...

Is this a known issue? I couldn't find anything related to that.


Cheers
Maik

-- 
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: JUnitShell.getModuleUrl() produces invalid URL for IPv6 addresses

2013-06-18 Thread Thomas Broyer


On Tuesday, June 18, 2013 11:59:49 AM UTC+2, Maik Riechert wrote:
>
> Hi,
>
> it seems the JUnitShell is generating invalid URLs if IPv6 is used:
>
> http://2607:f700:8000:12d:dd58:687b:744c:800c:48579/...
>
> You can observe this here:
> https://travis-ci.org/neothemachine/KineticGWT/builds/8191369#L881
>
> The URL should be 
> http://[2607:f700:8000:12d:dd58:687b:744c:800c]:48579/...
>
> Is this a known issue? I couldn't find anything related to that.
>
>
I don't think I've seen a bug report about that. This is due to 
constructing the URL by string concatenations; using java.net.URL or 
java.net.URI, the brackets could be added automatically if needed 
(depending on the constructor used).
As a workaround, because you're working on a custom RunStyle, override 
RunStyle#getLocalHostName to add the brackets when the InetAddress is an 
Inet6Address.
Feel free to file a bug in the issue tracker. And it'd be awesome if you 
could provide a patch! (note that there's a similar issue in 
RunStyleSelenium I guess)

-- 
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: Application architecture question

2013-06-18 Thread Imy
Follow up on this matter.

Thanks you for all the inputs, we considered them and decided what is the
best solution for our project.

In the end we created an object that models the data that we receive from
the database and from the after calculations.
In the HomeActivity class of the HomeView (in case of mGWT) or Presenter
class (case of GWT) we create an onModelLoaded event handler which fills
the model. We also implemented states and the readyState is only activated
when the model is loaded. From the model we also fill the GUI afterwards.

Cheers,
Timea


On 11 June 2013 23:08, Joseph Lust  wrote:

> Timea,
>
> If you've got the case of waiting on a multiplicity of RPC's to complete
> before continuing, something like Jen's suggestion is best. I've
> implemented it before with a multibit latches.
>
> However you get into the issue of syncing. For example, let's say you have
> N RPC calls for a given event. If someone triggers this event twice quickly
> (say event A and B) that fires off 2*N RPC calls. You've no guarantee that
> all of A's RPC's will return before all of B's RPC's. What if B completed
> first? Should A update the UI too or is it no longer
> relevant? Essentially all of the thread locking goodness you normally avoid
> with JS creeps in. That is why when I've run into this pattern, I usually
> try to find a way to do the grouping server side rather than UI side if
> possible.
>
> If you must, make sure you:
>
>- Block all UI interaction until the event's RPC's return
>- Unblock the UI on error for any RPC
>- Have a way to cancel all inflight RPC's if you need to cancel the
>update from the UI
>- Make sure you reset you latches on error/success
>
> Sincerely,
> Joseph
>
> --
> 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/eZLxnlpixL0/unsubscribe?hl=en
> .
> To unsubscribe from this group and all its topics, send an email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> Visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
> 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.




Beginning...Problems with navigation

2013-06-18 Thread Carmen
Hi, 

i'm just beginning with GWT  and I have a problem to make my application 
behave as I want. The fact is that I have one main static html page that 
links to three "subpages" that are similar but contain a dynamic part each 
one. Must I use one single entry point to the main page? If I choose this 
option...how can I continue navigation (as events, perhaps)? I also thought 
of creating three modules for each "subpage", each one with its XML file 
that make me able to control the dynammic part, but I really think this is 
not useful

Has anyone an idea of how to manage this?
Thanks a lot

-- 
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: Beginning...Problems with navigation

2013-06-18 Thread Joseph Lust
Carmen,

Can you elaborate on what you're trying to build and what it does? GWT is 
intended for Web *Apps*, not Web *Sites*. So, typically GWT would not be 
used for a blog, but it would be used for say an employee time tracking 
application. Take this forum reader as a good example of GWT.

The strength of GWT is that you are only on a single (physical) web page. 
All user interactions update the page content and the browser history, but 
the user does not need to make a trip to your server to reload the page, 
making everything faster and lower overhead.

Of course it is a different ball game from PHP or JSP's, but I'd posit it 
is more straight forward with less boilerplate than those implementations. 
Check out frameworks like GWTP which handle those events and pages you just 
mentioned rather seemlessly. They've got a number of ready to code demos 
too.


Sincerely,
Joseph

-- 
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: Setting TreeItem userObject with uiBinder?

2013-06-18 Thread Philippe Lhoste

On 17/06/2013 16:38, Pascal Heus wrote:

Tried that one but fails with
Cannot parse value: "FooKeyValue" as type java.lang.Object: 
On 17/06/2013 10:55, Kulnor wrote:

Is there any way to set a TreeItem user object in the UI Binder XML?

Something like 


Have you tried it? (I haven't!)
I see TreeItem has a setUserObject(Object userObj) method, so maybe it
can work.


Ah, I expected the String to be an Object, but UiBinder tries to be 
"smarter"... :-P
Perhaps you can open a bug against UiBinder?

--
Philippe Lhoste
--  (near) Paris -- France
--  http://Phi.Lho.free.fr
--  --  --  --  --  --  --  --  --  --  --  --  --  --

--
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.




problem to test the widget TabPanel

2013-06-18 Thread fatimaAngel
I work on a gwt project, I should create some interfaces using widgets, and 
everything is good.

here a part of my file .ui.xml 



 blabla



But when i try to test this widget, i have this exception :

com.googlecode.gwt.test.exceptions.GwtTestUiBinderException: Cannot find 
class 'com.google.gwt.user.client.ui.Tab' declared in file 
creationInterface.ui.xml

Anybady have idea where is the problem ??

Thanks

-- 
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: problem to test the widget TabPanel

2013-06-18 Thread Thomas Broyer
This is likely a bug in gwt-test-utils. Does your app compile? Does the 
creationInterface.ui.xml works in a GWTTestCase?

On Tuesday, June 18, 2013 4:38:04 PM UTC+2, fatimaAngel wrote:
>
> I work on a gwt project, I should create some interfaces using widgets, 
> and everything is good.
>
> here a part of my file .ui.xml 
>
>  xmlns:g="urn:import:com.google.gwt.user.client.ui"> height="130px">
>   
>  blabla
>   
>
>
> But when i try to test this widget, i have this exception :
>
> com.googlecode.gwt.test.exceptions.GwtTestUiBinderException: Cannot find 
> class 'com.google.gwt.user.client.ui.Tab' declared in file 
> creationInterface.ui.xml
>
> Anybady have idea where is the problem ??
>
> Thanks
>

-- 
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: RequestFactory, entity Id not populated when it reaches the server?

2013-06-18 Thread GWTter
Hi Thomas,

I just submitted the issue 
http://code.google.com/p/google-web-toolkit/issues/detail?id=8204, thanks 
again.

On Tuesday, June 18, 2013 9:39:33 AM UTC+2, Thomas Broyer wrote:
>
>
>
> On Monday, June 17, 2013 9:55:09 PM UTC+2, GWTter wrote:
>>
>> Hi,
>>
>> So I went back using the dev tools, inspected the payload, and confirmed 
>> what I had before: the ID is not set at all in the user object payload. 
>> Just to make sure I wasn't crazy or missing something I created just a User 
>> object and tried to save it. I checked the payload in that request and 
>> could clearly see the ID set in the object.
>>
>> I've persisted/sent entities that had field values set with other 
>> entities before. The only difference I can make between the two cases is 
>> that in the previous case the entity I was setting as the field value was 
>> from a request to the server (I had not created it on the client). In this 
>> case the booking entity is created on the client and the user entity is 
>> also created on the client. Could this be the reason why it's failing? 
>> maybe because RF only lets you add entities as fields if they already have 
>> stableIDs? 
>>
>> Thanks again in advance.
>>
>
> If you can make a small repro case, please file an issue; it looks like a 
> critical regression (which would also mean our test suite is weak)
>

-- 
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.




How to change corner color of DecoratedTabBar?

2013-06-18 Thread membersound
Hi,

I can see a DecoratedTabBar depends on some images ("images/corner.png").
If I edit them and change the color, where to I have to place them in order 
to make the TabBar respect my changes?

Thanks

-- 
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.




How come the ScrollEvent is never fired in this code?

2013-06-18 Thread Mohammad Al Quraian
I'm playing around with some code, but I couldn't figure out how come 
the ScrollEvent is never fired, I put a breakpoint on onScroll and it never 
breaks!
Here is the code:

public class InfiniteScrollPanel implements ScrollHandler {
String text = "Lorem ipsum dolor sit amet, consectetuer...";
ScrollPanel panel;
String height = "1200px";
String width = "200px";

public InfiniteScrollPanel() {
panel = new ScrollPanel(new HTML(text));
panel.setSize(width, height);
panel.addScrollHandler(this);
panel.getElement().getStyle().setBackgroundColor("rgb(216, 216, 216)");
}

@Override
public void onScroll(ScrollEvent event) {
if (panel.getVerticalScrollPosition() == 1100) {
panel.add(new HTML(text));
}
}
}

Then I add it like this:

InfiniteScrollPanel demo = new InfiniteScrollPanel();
RootPanel.get().add(demo.panel);

Any ideas?

-- 
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 come the ScrollEvent is never fired in this code?

2013-06-18 Thread Jens
Your ScrollPanel never needs to scroll if it really has a height of 1200px 
but only contains such a short text.

Also ScrollPanel extends SimplePanel so it can only have exactly one child 
widget. That means if onScroll() executes you will see an exception because 
you are trying to add a second child to ScrollPanel. What you want is: 

ScrollPanel (height 1200px)
---> FlowPanel
  -> child 1 (should be taller than 1200px so ScrollPanel can 
actually scroll it)
  -> child 2


-- 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/groups/opt_out.




Re: Dynamic place navigation

2013-06-18 Thread Akbar Gadhiya
Hi All,

Thanks for responding. I will try to add return place in my new place.


On Tue, Jun 18, 2013 at 3:01 PM, Thomas Broyer  wrote:

>
>
> On Tuesday, June 18, 2013 11:19:39 AM UTC+2, Prince wrote:
>>
>> Hi,
>>
>> I have a requirement to navigate to the places where place is dynamically
>> decided.
>>
>> For example,
>>
>> I have an "Edit User" link from Screen-1 & Screen-2. When I click on the
>> link, it takes me to EditUserView.java. Now, when I click on Save button
>> from my EditUserView.java, it should take me to Screen-1 if I come
>> from Screen-1 and to Screen-2 if I come from Screen-2.
>>
>> Is there any way I can achieve this?
>>
>
> Add the "return-to place" to the "edit user" place (that doesn't mean you
> surface it in the URL through the PlaceTokenizer though), so you can use in
> from your EditUserView (and choose a sane default when the place is
> constructed from the URL and doesn't have a "return-to place"; as an
> alternative, just put the "return-to place" in the URL, serializing it
> using the PlaceHistoryMapper).
> As an alternative, you can use 2 distinct places *resolving* to the same
> EditUserView.
> In any case, the idea is to choose the next place based on the current
> place.
>
> --
> 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.
>
>
>

-- 
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 come the ScrollEvent is never fired in this code?

2013-06-18 Thread Mohammad Al Quraian
Ok I got it, Thank you very much Jens. One question though, I wanted to 
make an infinite loop panel, is this the way to do it, how can I do without 
having the scroll bars, I know I can hide them in CSS but this would stop 
the scrolling event from firing. You don't have to answer me in detail I 
just need a general idea if you have the time.

Cheers and thanks again.

On Wednesday, June 19, 2013 2:58:39 AM UTC+3, Jens wrote:
>
> Your ScrollPanel never needs to scroll if it really has a height of 1200px 
> but only contains such a short text.
>
> Also ScrollPanel extends SimplePanel so it can only have exactly one child 
> widget. That means if onScroll() executes you will see an exception because 
> you are trying to add a second child to ScrollPanel. What you want is: 
>
> ScrollPanel (height 1200px)
> ---> FlowPanel
>   -> child 1 (should be taller than 1200px so ScrollPanel can 
> actually scroll it)
>   -> child 2
>
>
> -- 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/groups/opt_out.




Gwt Time picker widget

2013-06-18 Thread Kedar Vyawahare
Hi,
I am looking for a widget in GWT that allows the user to choose a specific
time. I am using the GWT Date Picker to choose the date but I am not able
to find a suitable Time Picker. I have had a look at a couple of
suggestions  that emulate the jQuery Time Picker as well as GWT Incubator
Demo but none match my requirement. I am looking for a space-efficient
widget maybe like a textbox that allows to enter suitable time values.
Thanks in advance

-- 

Thanks & regards ,

Kedar

-- 
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.