com.google.gwt.i18n.client.DateTimeFormat parseStrict problem

2012-02-03 Thread tong123123
the code is as follow:


DateTimeFormat df = DateTimeFormat.getFormat(/MM/dd hh:mm:ss
a);
try{
  df.parseStrict(2010/Jan/20 13:10:59 AM);
}catch{IllegalArgumentException iae){
 System.out.println(error);
}



As the datetimeformat is using hh, so according to api
h   hour in am/pm (1-12)Number  12
H   hour in day (0-23)  Number  0
so 13 AM should be error, but out of my expectation, the above code
can pass!!
why?
any method to check the hour cannot over 12 if using AM/pm?

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



Synchronise view loading and activity start in MVP

2012-02-03 Thread Thomas Lefort
Hi,

Let's say you have a view that needs to load a library, eg the google
maps library. Some of the method offered by the view should only be
called by the activity when the map is fully loaded otherwise
resulting in errors. I need a way to hold off any UI call from the
activity until the view is fully loaded, and if loaded with errors act
accordingly. What is the recommended way of doing this with the GWT
MVP framework?

Thanks,

Thomas

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

2012-02-03 Thread saurabh saurabh
Hi everyone,
  there are lots of MVP frameworks out there like
MVP4G, Guit etc and also google's official 'Places and Activities'. I
wanted to know which is most popular framework or way of MVP
implementation in industry working with GWT.

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.



Re: in Firefox9, when i press enter key, enent.getCharCode() is 0.

2012-02-03 Thread Juan Pablo Gardella
Use event.getNativeCode (or simillar)

El 3 de febrero de 2012 00:14, yl chen nicola.j...@gmail.com escribió:

   newSymbolTextBox = new TextBox();
newSymbolTextBox.addKeyPressHandler(new KeyPressHandler() {
public void onKeyPress(KeyPressEvent event) {

  Window.alert(keycode:+(int)event.getCharCode());
if (event.getCharCode() ==
 KeyCodes.KEY_ENTER){
addStock();
}

}
});

 in ie. when i press enter  key, event.getCharCode() is 13.
 in Firefox9, when i press enter key, enent.getCharCode() is 0.

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



-- 
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: in Firefox9, when i press enter key, enent.getCharCode() is 0.

2012-02-03 Thread Thomas Broyer
See http://code.google.com/p/google-web-toolkit/issues/detail?id=5003

-- 
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/-/NYr_Z190Tl8J.
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: Synchronise view loading and activity start in MVP

2012-02-03 Thread Thomas Broyer
Simply wait for all your code to be loaded (could be required scripts, or 
RPC/RequestFactory calls to the server) before pushing your view into the 
AcceptsOneWidget passed to the Activity#start() method.

-- 
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/-/vSuWwf5PYOUJ.
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: Using the Force.com App Engine connector to pass data to the client side

2012-02-03 Thread Drew Spencer
Just thought I'd post an update here as I solved this problem The problem 
was not at all that I couldn't pass data to the client side. You can indeed 
create a regular RPC Service which makes calls to the Force.com api instead 
of the datastore, then pass this data to the client as a list or whatever 
you like.

My mistake was not putting my security token after the password while 
trying to login. Doh!

Here is the code that is in my ServiceImpl class:

   public ListAccount getStuff()
{
ListAccount list = new ArrayListAccount();
 try
{
// config
ConnectorConfig config = new ConnectorConfig();
config.setTransport(GaeHttpTransport.class);
config.setUsername(usernamehere);
config.setPassword(pasword+TOKEN);

config.setTraceMessage(true);
 // initialise connection
PartnerConnection connection = Connector.newConnection(config);
 // give it a query
QueryResult qr = connection.query(SELECT Id, Name FROM Account ORDER BY 
Name ASC);
 // put records in array
SObject[] records = qr.getRecords();
 // add to list as Account
for(int i = 0; i  qr.getSize() ; i++)
{
String id = records[i].getId();
String name = (String) records[i].getField(Name);
 Account account = new Account(id, name);
 list.add(account);
}
 return list;
}
catch(ConnectionException e)
{
System.out.print(e.getMessage());
System.out.print(e.getStackTrace());
//System.out.print(e.getMessage());
return null; // empty
}
}

It converts the SObjects to Account objects and returns them in a list, as 
I prefer this to returning an array or SObjects.

Drew

-- 
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/-/75n3Th65xI0J.
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 framework

2012-02-03 Thread Drew Spencer
I had this problem for ages. I think for a beginner you are best learning 
to do it from scratch as described here:  
http://code.google.com/webtoolkit/articles/mvp-architecture.html

It's a lot to get your head around, it took me weeks and weeks to really 
get what was going on.

Everyone has their preference though.

Regards,

Drew

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



raphael4gwt - a new porting to raphaeljs vector graphics library to GWT

2012-02-03 Thread Sebastian Gurin
Hi all

I would like to present you my new GWT library, raphael4gwt : 

http://code.google.com/p/raphael4gwt/. 

Raphaeljs is an easy to use api for vector drawing that support all browsers, 
inclusive old versions of internet explorer

Unlike the project raphaelgwt, raphael4gwt implements 100% of raphaeljs drawing 
API natively for zero overhead and it is only based on gwt.dom.client for 
relating it with the DOM. 

Examples of current progress (almos all raphaeljs API is dome) can be found 
with java source code at raphael4gwt gallery demo, I hope example java source 
can help new users to start using it: 

http://cancerbero.vacau.com/gwt/raphael4gwtGallery/

Thanks to this list users for guide me on learning best practices on porting 
javascript toolkits using GWT overlay types and jsni. 

Any suggestion or comment is appreciated. 

Regards
-- 
Sebastian Gurin sgu...@softpoint.org

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



JSNI error when using GWT canvas

2012-02-03 Thread Karel
Hey guys,

I am getting quite random internal GWT errors when I am using the GWT
canvas widget in complex cases. Sometimes, seemingly random, JSNI
errors are fired such as:

com.google.gwt.dev.shell.HostedModeException: Something other than an
int was returned from JSNI method
'@com.google.gwt.dom.client.CanvasElement::getWidth()': JS value of
type JavaScript object(20511), expected int
at com.google.gwt.dev.shell.JsValueGlue.getIntRange(JsValueGlue.java:
266)
at com.google.gwt.dev.shell.JsValueGlue.get(JsValueGlue.java:144)
at
com.google.gwt.dev.shell.ModuleSpace.invokeNativeInt(ModuleSpace.java:
247)
at
com.google.gwt.dev.shell.JavaScriptHost.invokeNativeInt(JavaScriptHost.java:
75)
at com.google.gwt.dom.client.CanvasElement$.getWidth$
(CanvasElement.java)
at
com.google.gwt.canvas.client.Canvas.getCoordinateSpaceWidth(Canvas.java:
127)
 at...

These errors occur quite often, but do not seem to break anything.
They usually originate from a getCoordinateSpaceHeight() call on the
canvas. I tried digging in the debugger to find out what's wrong, but
the debugger does not cross the JSNI boundary, so I can't see what's
going on in javascript.

Anyone got any idea what is causing these errors?

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



Custom widget with custom UiBinder markup

2012-02-03 Thread dparish
I have a widget that would benefit from custom UiBinder markup (like
DockLayoutPanel)

I've looked through the docs, the source and the web and not found an
example of how this is implemented. Has anyone done this?

I'm looking to do something like this

custom:mywidget ui:field=widget
left!-your widget/left
right!- your widget/right
left!-your widget/left
right!- your widget/right
left!-your widget/left
right!- your widget/right
!- your widget!- your widget!- your widget
/custom:mywidget

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



Spring Security Integration with 2.4

2012-02-03 Thread bendg25
Hi

Is there an officially documented way on integrating GWT with Spring
Security.  There are numerous blog entries around, all specifying
different methods.

'Surely', there must be an official line on how to secure your app ?

I don't think this is good enough:

http://code.google.com/webtoolkit/articles/security_for_gwt_applications.html

I am looking for detailed notes on how to secure my Web app which has
been approved, or has been pen tested by a security expert.

Is there anything out there, and if not, what is considered to be the
'best' reference on this subject?

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.



how should i read my styles applied

2012-02-03 Thread karthik
i have a css where i placed my styles,and i wanted to read the styles
from my program,is there any way to read them.
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.



Re: To any Editors Gurus: I could use some ListEditor use help for the GWT demo I've made...

2012-02-03 Thread Patrick Julien
Start by checking your paths.


PeopleDataProxy has a field called todos but PersonEditor has @UiField 
called todosEditor with no custom path



-- 
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/-/2dGWzRfXQNYJ.
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.



g:ListBox g:item use i18n

2012-02-03 Thread Luke
g:ListBox
  g:item
how to use i18n  for list box's item ?
  /g:item
/g:ListBox

-- 
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: g:ListBox g:item use i18n

2012-02-03 Thread Patrick Julien
http://code.google.com/webtoolkit/doc/latest/DevGuideUiBinderI18n.html 

-- 
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/-/aWLqgmI4oKsJ.
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: Custom widget with custom UiBinder markup

2012-02-03 Thread Jens
You can use @UiChild, see:

http://google-web-toolkit.googlecode.com/svn/javadoc/latest/com/google/gwt/uibinder/client/UiChild.html

-- J.

-- 
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/-/YwvdkJgim4sJ.
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: g:ListBox g:item use i18n

2012-02-03 Thread Luke
g:item value='test'
ui:text from={msg.SomeValue}somevalue/ui:text
   /g:item

i tried above, and not working

-- 
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: g:ListBox g:item use i18n

2012-02-03 Thread Luke
 Illegal child ui:text in a text-only context. Perhaps you are
trying to use unescaped HTML where text is required, as in a HasText
widget? Element g:item value='test' (:83)

-- 
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: To any Editors Gurus: I could use some ListEditor use help for the GWT demo I've made...

2012-02-03 Thread Thomas Broyer


On Friday, February 3, 2012 3:06:29 PM UTC+1, Patrick Julien wrote:

 Start by checking your paths.


 PeopleDataProxy has a field called todos but PersonEditor has @UiField 
 called todosEditor with no custom path


Yes, but that's how it's supposed to be: in the absence of @Path 
annotation, any Editor suffix is automatically removed before using the 
field name as the path.
http://code.google.com/webtoolkit/doc/latest/DevGuideUiEditors.html#Editor_contract

I haven't see anything wrong in the files (except your –Brandon's– 
EditorSource should override dispose and setIndex to respectively remove 
and reorder your subeditors from/within the FlowPanel container, and to be 
future-proof, you should check the index passed to methods to be positive: 
see http://code.google.com/p/google-web-toolkit/issues/detail?id=6959 )

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



Node.isSameNode removed in Firefox 10 (GWT 1.4)

2012-02-03 Thread Nathan Williams
For anyone still (*sigh*) dependent on GWT 1.4, the removal of the
isSameNode function in Firefox 10 will likely result in JavaScript
errors in your compiled modules.

https://bugzilla.mozilla.org/show_bug.cgi?id=687400
https://developer.mozilla.org/en/Firefox_10_for_developers
https://developer.mozilla.org/en/DOM/Node.isSameNode

This is a similar situation to the removal of getBoxObjectFor in
Firefox 3.6: 
http://groups.google.com/group/google-web-toolkit/browse_thread/thread/88a8437754345092/e519ad6f11a081ad

The problem can be fixed by editing DOMImplMozilla.java in gwt-
user.jar and replacing the 4 isSameNode tests with === comparisons.
The comments indicate that isSameNode was used because direct
comparison was unreliable, but presumably this is no longer an issue
in later versions of Firefox.  If you need to support a wide range of
Firefox versions, then testing for the existence of the function and
using it if it exists or falling back to direct comparison if it
doesn't is probably the safest approach.

DOMImplMozilla.java is the only file you need to modify.  The
corresponding .class file is not used for compilation or in hosted
mode, and gwt-servlet.jar does not include this class.

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



CSSResource Classname Obfuscation

2012-02-03 Thread Clint Checketts
Last night I was tying to turn off CSSResource class obfuscation by reading
the docs:
http://code.google.com/webtoolkit/doc/latest/DevGuideClientBundle.html#Selector_obfuscation

It talks about using *set-configuration-property name=CssResource.style
value=pretty / *that still changed the class names (adding prefixes) and
I eventually had to dig into the code to find the following:

*pretty*, (include original CSS classname and prefix of package/Java
classname and random stuff)
*stable*, (original CSS classname, prefixed with package and Java classname)
*stable-shorttype*, (original CSS classname, prefixed with package)
*stable-notype*, (original CSS classname)
*obf/default *(obfuscated, no original CSS classname included)

So what is the best way to note this? Is there a wiki or way to contribute
back to the original documentation? Or am I just supposed to post this on a
blog hoping others will find 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: To any Editors Gurus: I could use some ListEditor use help for the GWT demo I've made...

2012-02-03 Thread Brandon Donnelson
Thanks for the comments and looking at my code! :)

I may be getting close to the solution. I have forgotten .with(todos) in 
the request factory request so they aren't being loaded in the initial 
request. Not sure if this triggers the correct backing. But all the 
chaining and list editor stuff seems to have been instantiated correctly 
from what I can tell. Although the listwrapper never gets used b/c the 
value is null. 


ListEditor.setValue(listTodoDataProxy value) {
   //... I think sets up the backing here in list editor
} 
I've found that this is always null in all the configurations I've tried.

*
*String s = EditorHierarchyPrinter.toString(driver);
System.out.println(EditorHierarchyPrinter =  + s);
*
*EditorHierarchyPrinter = 
com.gonevertical.client.app.requestfactory.dto.PeopleDataProxy
com.gonevertical.client.views.peopleedit.editor.PersonEditor
ValueAwareEditor 
nameFirst
java.lang.String
com.google.gwt.editor.ui.client.adapters.ValueBoxEditor
ValueAwareEditor 
nameFirst
java.lang.String
com.google.gwt.editor.ui.client.ValueBoxEditorDecorator
ValueAwareEditor 
nameLast
java.lang.String
com.google.gwt.editor.ui.client.adapters.ValueBoxEditor
ValueAwareEditor 
nameLast
java.lang.String
com.google.gwt.editor.ui.client.ValueBoxEditorDecorator
ValueAwareEditor 
active
java.lang.Boolean
com.google.gwt.editor.client.adapters.TakesValueEditor
ValueAwareEditor 
gender
java.lang.Integer
com.google.gwt.editor.client.adapters.TakesValueEditor
ValueAwareEditor 
note
java.lang.String
com.gonevertical.client.views.widgets.richtextarea.RichTextAreaEditor
ValueAwareEditor 
todos
java.util.List
com.google.gwt.editor.client.adapters.ListEditor
ValueAwareEditor

-- 
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/-/40uckOlUu20J.
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: Custom widget with custom UiBinder markup

2012-02-03 Thread dparish
That will work.  I'd still prefer to use descriptive xml like
DocLayoutPanel. From what I see of @UiChild it just enforces the types
of children it does not allow for quite what I was looking for. (but
probably good enough)

-Dave

On Feb 3, 8:09 am, Jens jens.nehlme...@gmail.com wrote:
 You can use @UiChild, see:

 http://google-web-toolkit.googlecode.com/svn/javadoc/latest/com/googl...

 -- J.

-- 
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: Custom widget with custom UiBinder markup

2012-02-03 Thread dparish
I take that back. UiChild should do it perfect.  Good example here:

http://stackoverflow.com/questions/8375480/gwt-custom-widget-with-child-elements-configuration-in-uibinder-like-custombutt

On Feb 3, 8:09 am, Jens jens.nehlme...@gmail.com wrote:
 You can use @UiChild, see:

 http://google-web-toolkit.googlecode.com/svn/javadoc/latest/com/googl...

 -- J.

-- 
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: Custom widget with custom UiBinder markup

2012-02-03 Thread Paul Stockley
Add two methods

@UiChild
public void addLeft(Widget w) {...}

@UiChild
public void addRight(Widget w) {..}

Then make sure you widget implements HasWidgets or similar.

In your uibinder you can now use


custom:mywidget ui:field=widget 

custom:left!-your widgetcustom:/left  

custom:right!-your widgetcustom:/right 
!- your widget

!- your widget
!- your widget 

/custom:mywidget 

-- 
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/-/pkucQe-mMbwJ.
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: To any Editors Gurus: I could use some ListEditor use help for the GWT demo I've made...

2012-02-03 Thread Brandon Donnelson
Thomas thanks for putting so much work into the GWT codebase! :) Amazing!

Can I ask if the having the ListEditor as a sub editor if driver should 
call the context.edit  or context.create (for TodoDataProxy in list) for 
list creation or editing?

I'm puzzled that on save the flush, the ListEditor.flush() { list.flush() } 
is null and throws the exception. Then I find that ListEditor.setValue(T 
value) needs to take place. 

I'm wondering if i need to tell the driver more here about the list, that 
is edit or create? On list null I'm wondering if I should create array list 
to get things going. But I'm thinking the editor should take care of this, 
but maybe not?
http://code.google.com/p/gwt-examples/source/browse/trunk_2012/DemoGwtEditor/src/com/gonevertical/client/views/peopleedit/editor/EditPersonWorkFlow.java#104

The index is =0 on list instantiation.
http://code.google.com/p/gwt-examples/source/browse/trunk_2012/DemoGwtEditor/src/com/gonevertical/client/views/peopleedit/editor/todos/TodoListEditor.java#48

Thanks for the help. 

-- 
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/-/TxVSfjPXRaUJ.
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: To any Editors Gurus: I could use some ListEditor use help for the GWT demo I've made...

2012-02-03 Thread Patrick Julien


On Friday, February 3, 2012 11:58:16 AM UTC-5, Brandon Donnelson wrote:

 Thanks for the comments and looking at my code! :)

 I may be getting close to the solution. I have forgotten .with(todos) in 
 the request factory request so they aren't being loaded in the initial 
 request. Not sure if this triggers the correct backing. But all the 
 chaining and list editor stuff seems to have been instantiated correctly 
 from what I can tell. Although the listwrapper never gets used b/c the 
 value is null. 



You don't need .with(todos), you need to 
RequestFactoryEditorDriver#getPaths.  Your driver knows all the paths you 
need to put in your request.

http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/gwt/requestfactory/client/RequestFactoryEditorDriver.html
 


-- 
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/-/OKsV-lRV27cJ.
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.



Sharing @eval between CSS resources

2012-02-03 Thread KevMo
I was hoping to implement some simple customizable themes for my
project.  Nothing fancy, just pretty much changing color schemes.
Based on the wiki for CssResource I was planning on using @eval to
determine colors and things at runtime like so:

@eval userBackground com.module.UserPreferences.getUserBackground();
div {
  background: userBackground;
}

Is there a way to share userBackground between CSS resources?   I know
I can provide multiple .css files and GWT will concatenate them for me
like @Source(common.css, other.css),  but I need to provide a
relative path to common.css, which isn't too convenient when
common.css and other.css are in different packages.

I would also like to be able to access the variables from within
ui:style maybe something like this:
ui:with field='common' type='com.my.app.common.Resources'/
ui:style
.user{
  background-color: {common.style.userBackground};
}
/ui:style

Is there a way to use @eval's between different css resources an
ui.xml files?

-- 
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: RequestFactory with Use of Locator

2012-02-03 Thread MagusDrk
Hi hkopp Right now I'm facing the argument type mismatch error, but i'm 
unable to find the cause. I guess you were able to do it since there were 
no more comments. How did you found the cause? how did you solved? thanks a 
lot.

-- 
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/-/sDJlM6Yf9RcJ.
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 do i add an image link with uibinder?

2012-02-03 Thread Philippe Lhoste

On 03/02/2012 00:19, chstrong wrote:

How can I add an image with a surrounding link within uibinder? I have
an image resource and around that I need a link.

!-- Display rackspace cloudhosting teaser box 
--
g:HTMLPanel 
addStyleNames={res.main.teaserbox}
g:Image 
resource='{res.rackspaceteaser}'/
/g:HTMLPanel


Perhaps you can wrap it in a g:Hyperlink or g:InlineHyperlink

--
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 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: To any Editors Gurus: I could use some ListEditor use help for the GWT demo I've made...

2012-02-03 Thread Brandon Donnelson
Thanks Patrick for checking into this. I really appreciate the help. :)

I added getPaths to the context. Although I'm still puzzled by why the 
ListEditor list is null on flush. 

http://code.google.com/p/gwt-examples/source/browse/trunk_2012/DemoGwtEditor/src/com/gonevertical/client/views/peopleedit/editor/EditPersonWorkFlow.java#132

I also added dispose and setIndex to the listeditor... So when the 
listeditor adds a inputbox and then disposes it on instantiation. This also 
creates a challenge to add another input box b/c I would then need to have 
reference to the context in the subeditor so I could create an instance of 
the dtoproxy. Where if I use ListEditor.createEditorforTransversal() 
creates a new editor source but then it removes it on the same hand.
http://code.google.com/p/gwt-examples/source/browse/trunk_2012/DemoGwtEditor/src/com/gonevertical/client/views/peopleedit/editor/todos/TodoListEditor.java#56

My goal is to figure out why the ListWrapper in ListEditor.setValue(T 
value) doesn't get instantiated and why list.flush throws on a driver 
flush. 

-- 
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/-/EcZKSy6LhNUJ.
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: To any Editors Gurus: I could use some ListEditor use help for the GWT demo I've made...

2012-02-03 Thread Brandon Donnelson
Wahoo!! I just solved the issue. This got the ListEditor.setValue(T value) 
to work correctly and then rendered the items. Awesome! I'll disclose the 
results later.

I had forgotten to annote the owned collection in PeopleData:

@Persistent(defaultFetchGroup = true, dependentElement = true)

http://code.google.com/p/gwt-examples/source/browse/trunk_2012/DemoGwtEditor/src/com/gonevertical/server/jdo/PeopleData.java#93

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



Can't add css class to CellTable Header

2012-02-03 Thread Vova
Hello,
I have an issue setting css class to the CellTable header.
After initiating all columns and their headers I'am trying to
mannually add css class. I'am doing this in scheduler in order to have
all elements attached  into DOM.
This code works perfectly in Google Chrome, but fails in Mozilla, here
it has no effect. Compiling project and running without gwt browser
plugin hasn't help.
Please help to find out why the problem occurs or maybe you have any
workarounds.

The code listed below:

class MyCellTable extends CellTableE { ..

public void init()
{
Scheduler.get().scheduleDeferred(new
ScheduledCommand()
{

@Override
public void execute()
{
Element thread = getTableHeadElement().cast();

if (thread.getChildCount()  0)
{
Element th = 
thread.getFirstChildElement();

int i = 0;

int end = th.getChildCount();

while (i  end)
{
Element el = 
th.getChild(i).cast();

el.addClassName(classnameXXX 
+ i);

i++;
}
}
}
});
.
 }
}

One more thing to add: When launched in Mozilla, while debugging in
eclipse, watcher variables 'thread', th, el are represented as
JavaScript object(Id) but in Chrome you see inner html as it is.
Mozila version: 3.6.25
Google Chrome: 16.0.904.0

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



Re: To any Editors Gurus: I could use some ListEditor use help for the GWT demo I've made...

2012-02-03 Thread Brandon Donnelson
I committed the working code that will load the ListEditor items and flush 
list will not fail. Works quite nice. I added some data on the server side 
to figure that out. 

I'm wondering what the best method to* add an item* to the list is. 
Typically I would need a reference to the context, but it seems like the 
editor should have a method.

http://code.google.com/p/gwt-examples/source/browse/trunk_2012/DemoGwtEditor/src/com/gonevertical/client/views/peopleedit/editor/todos/TodoListEditor.java#78

-- 
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/-/4Kg8PNRpakMJ.
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: To any Editors Gurus: I could use some ListEditor use help for the GWT demo I've made...

2012-02-03 Thread Brandon Donnelson
I sent the context into the list editor. AddItem or adding an item 
(element) works good now. Would be nice if it took care of adding an 
element on its own. Seems it carries request factory context in the editors 
chain. 

http://code.google.com/p/gwt-examples/source/browse/trunk_2012/DemoGwtEditor/src/com/gonevertical/client/views/peopleedit/editor/todos/TodoListEditor.java#78

The working demo  https://demogwtpeople.appspot.com 

Thanks for the help!

-- 
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/-/UCJjhgjYzgEJ.
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: com.google.gwt.i18n.client.DateTimeFormat parseStrict problem

2012-02-03 Thread Tong123123
So is this a bug?

Sent from my iPhone

On 2012/2/4, at 上午7:41, Patrick Tucker tucker...@gmail.com wrote:

 Interesting, MM should also not be happy about Jan...
 
 On Feb 3, 4:12 am, tong123123 tong123...@gmail.com wrote:
 the code is as follow:
 
 DateTimeFormat df = DateTimeFormat.getFormat(/MM/dd hh:mm:ss
 a);
 try{
   df.parseStrict(2010/Jan/20 13:10:59 AM);
 }catch{IllegalArgumentException iae){
  System.out.println(error);
 }
 
 As the datetimeformat is using hh, so according to api
 h   hour in am/pm (1-12)Number  12
 H   hour in day (0-23)  Number  0
 so 13 AM should be error, but out of my expectation, the above code
 can pass!!
 why?
 any method to check the hour cannot over 12 if using AM/pm?
 
 -- 
 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.
 

-- 
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-contrib] Re: Provide onRefresh hook for Activities (issue1635804)

2012-02-03 Thread t . broyer

-1

See http://code.google.com/p/google-web-toolkit/issues/detail?id=7140#c4

http://gwt-code-reviews.appspot.com/1635804/

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors


[gwt-contrib] Re: Fixed issue 1394 : Need a new getSplitter() method in SplitPanel (issue1398801)

2012-02-03 Thread tuckerpmt

Do you guys have any objections to setting hidden child widget's size to
0 instead of actually changing their display value?  Changing the
display value causes Firefox, Chrome and what not to destroy child flash
objects... and setting its size to 0 seems to have caused 0 problems for
me.

http://gwt-code-reviews.appspot.com/1398801/

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors


[gwt-contrib] Re: Fixed issue 1394 : Need a new getSplitter() method in SplitPanel (issue1398801)

2012-02-03 Thread jlabanca

Sounds reasonable to me.

http://gwt-code-reviews.appspot.com/1398801/

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors


[gwt-contrib] A previous change broke some backward-compatibility with RowHoverEvent (issue1637803)

2012-02-03 Thread isoos

Reviewers: jlabanca,

Description:
A previous change broke some backward-compatibility with RowHoverEvent
(events did not fire when expected). This change fixes the compatibility
issue, clarifies the event's scope and introduces a new field in the
event
(hovering scope).

Clients can use this field to differentiate between hover events on the
same
row and hovering between different rows, allowing more control on the
event's
processing.

Review by: pengzhu...@google.com

Please review this at http://gwt-code-reviews.appspot.com/1637803/

Affected files:
  M user/src/com/google/gwt/user/cellview/client/AbstractCellTable.java
  M user/src/com/google/gwt/user/cellview/client/RowHoverEvent.java


--
http://groups.google.com/group/Google-Web-Toolkit-Contributors


[gwt-contrib] Re: Fixed issue 1394 : Need a new getSplitter() method in SplitPanel (issue1398801)

2012-02-03 Thread tuckerpmt

That would be great!

It looks like this fix is also going to take care of issue 5264 via the
addition of setWidgetHidden(Widget, boolean).

Thanks!

http://gwt-code-reviews.appspot.com/1398801/

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors