How to tell if an image is done loading (or failed) for sure, given LoadListener is broken on IE?

2009-04-15 Thread dduck

Hi,

Is there a cross-browser compatible, sure-fire way to tell if an image
is loaded? I have used Loadlistener observers, but they do not work
consistently on IE, and that's a deal breaker...

I need it for delaying preloading of hidden images until the visible
ones have loaded, or have failed loading.

Regards,
  Anders S. Johansen, ange.dk
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: GWT 1.6 with Maven and build system questions/survey...

2009-04-15 Thread Salvador Diaz

   Who agrees that having a solid,
  feature complete Maven plugin from Google would increase adoption of
  GWT faster than anything?

I think the google team is focusing in the basics first, and that
implies not being able to deliver all the goodies at the same time, I
think it all fits rather nicely with the agile mantra: deliver early,
deliver often. If they tried delivering the Eclipse plugin (and all
other popular IDEs' plugins for that matter) and the maven plugin at
the same time they deliver the actual product (GWT) they couldn't
possibly deliver that often. Not to mention that they don't seem to be
maven people, they're rather ant users, so why not leave it to the
community, in true open source spirit, to build the tools they need,
they even help out when there's something that doesn't work nicely
with our tools (one of the issues resolved in 1.6 was specifically
adressed to allow a nicer maven integration), I don't think we can
possibly ask for more cooperation from them.

 Maybe file an enhancement request?

I totally agree with Jeff, if you think a great maven plugin would
help with adoption, why not try the one from the mojo project (which
is quite nice by the way) and report any issues that you find with it.
I don't think we can have a more official plugin than that (after all,
they're the maven experts, not google )

Cheers,

Salvador
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Uncaught exception escaped: JavaScriptException: (Error): Invalid argument.

2009-04-15 Thread Suren

Hi All,

I am just trying out the example code given in the book named

Google Web Toolkit Solutions-More cool and useful stuff for
resizable columns in FlexGrid.

I have created (carefully!!) all the required classes as like
mentioned in the book.

When I run the application, its launching without any problem. The
moment, when I try to resize any column, I am getting the following
exception displayed in the Shell window


[ERROR] Uncaught exception escaped
com.google.gwt.core.client.JavaScriptException: (Error): Invalid
argument.
 number: -2147024809
 description: Invalid argument.
at com.google.gwt.dom.client.Element$.setPropertyString$(Native
Method)
at com.google.gwt.user.client.DOM.setElementProperty(DOM.java:1088)
at com.google.gwt.user.client.ui.HTMLTable$ColumnFormatter.setWidth
(HTMLTable.java:411)
at com.ibsplc.client.ui.table.EasyFlexTableResizable.setColumnWidth
(EasyFlexTableResizable.java:43)
at com.ibsplc.client.ui.table.ColumnResizeListener.onResize
(ColumnResizeListener.java:19)
at com.ibsplc.client.ui.ResizeListenerCollection.fireResize
(ResizeListenerCollection.java:12)
at com.ibsplc.client.ui.table.ResizableCellPanel.onMouseMove
(ResizableCellPanel.java:94)
at com.google.gwt.user.client.ui.MouseListenerCollection.fireMouseMove
(MouseListenerCollection.java:122)
at
com.google.gwt.user.client.ui.MouseListenerCollection.fireMouseEvent
(MouseListenerCollection.java:81)
at com.google.gwt.user.client.ui.Label.onBrowserEvent(Label.java:168)
at com.google.gwt.user.client.DOM.dispatchEventImpl(DOM.java:1308)
at com.google.gwt.user.client.DOM.dispatchEventAndCatch(DOM.java:
1287)
at com.google.gwt.user.client.DOM.dispatchEvent(DOM.java:1255)


I have checked the method setColumnWidth, it was like below.

public void setColumnWidth(int column, int width) {
 getColumnFormatter().setWidth(column,width + px);
 }

And I knew that setWidth method args are int and String. so on the
safer side I had changed the args like below.


public void setColumnWidth(int column, int width) {
 getColumnFormatter().setWidth(column,Integer.toString(width) + px);
 }

But still I am getting the same exception. Any one experienced such
issue?

Or please advise what is wrong in this case

Thanks in advance

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



Re: How to share RPC service between GWT applications?

2009-04-15 Thread jfeid

Thanks for the reply.

The RPC servlet uses a db layer jar which configures a Hibernate
factory.
Because of different classloaders I assume that there will be 2
instances of this factory.
But I cannot say if this will present an issue until I test it.

On Apr 14, 9:23 pm, gregor greg.power...@googlemail.com wrote:
 You can do this if you place your RPC services in a separate module
 that is inherited by the two main application modules. In this
 situation you can specify the RPC servlets in the common module
 gwt.xml file and this will work for hosted mode, but I think you have
 to map them separately (i.e. in duplicate) in each main module's
 web.xml for deployment - AFAIK there is no way around that (app server/
 servlet specification issue, not GWT).

 At run time you will end up with two instances of each servlet loaded
 by the two main module's classloaders (again app server/servlet
 specification issue, not GWT) which may or may not present you with an
 issue depending on what you are doing.

 On Apr 14, 4:14 pm, jfeid jannis.feida...@gmail.com wrote:





  Hello,

  I have the following problem that puzzles me.

  Suppose I have 2 different GWT applications running on different
  contexts:
  -http://server/context1
  -http://server/context2

  Is there a way to share an RPC service between them?

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



Re: How to tell if an image is done loading (or failed) for sure, given LoadListener is broken on IE?

2009-04-15 Thread Salvador Diaz

I don't think LoadListener is broken, it's just that there's a catch
in using it. The actual loading of the image doesn't take place if
such image is not attached to the document, so if you really want to
load it without the user seeing the actual load, you have to use a
trick like loading it in a hidden part of the document:

//get the size of the window
int width = Window.getClientWidth();
int height = Window.getClientHeight();

//instantiate image and add loadListeners:
Image img = new Image(example.jpg);
img.addLoadListener(yourloadListener);

//attach image to the rootPanel in a place not visible to the user,
this is where the actual loading takes place
RootPanel.get.add(img, width, height);

//use onLoad to put the image in the right place

This has the effect of showing scrollbars (which you can hide) but the
code gets more complicated and it's beyond what I wantedto show you

Cheers,

Salvador

On Apr 15, 9:01 am, dduck anders.johansen.a...@gmail.com wrote:
 Hi,

 Is there a cross-browser compatible, sure-fire way to tell if an image
 is loaded? I have used Loadlistener observers, but they do not work
 consistently on IE, and that's a deal breaker...

 I need it for delaying preloading of hidden images until the visible
 ones have loaded, or have failed loading.

 Regards,
   Anders S. Johansen, ange.dk
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Catching exception in a filter.

2009-04-15 Thread jolero

I have maven GWT 1.5 project split into few parts. One of them is WAR
with client side and other is WAR with server side included in some
EAR application. There is also some JAR wich is proxy between client
and server, i mean client and server do not see each other, but they
are dependent of this JAR so all common classes and f.e. RPC
interfaces are defined there.
I defined SecurityException in this JAR:

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package pl.fizzycomp.client.common;

import com.google.gwt.user.client.rpc.IsSerializable;
import java.util.ArrayList;
import java.util.List;
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package pl.fizzycomp.client.common;

import com.google.gwt.user.client.rpc.IsSerializable;
import java.util.ArrayList;
import java.util.List;

public class SecurityException extends Exception implements
IsSerializable {

   //CONSTRUCTORS HERE

/**
 * User name of user that didn't have persmission
 */
private String userName;

/**
 * Set of examined and not found roles
 */
private ListString rolesExamined = new ArrayListString();

/**
 * Adds role to @see rolesExamined
 * @param roleName role to add
 */
public void addRole(String roleName){
rolesExamined.add(roleName);
}

/**
 * Adds roles to @see rolesExamined
 * @param roleName list of roles to add
 */
public void addRoles(ListString roleNames){
rolesExamined.addAll(roleNames);
}

/**
 * @return @see rolesExamined as a String
 */
public String getRolesExamined() {
return rolesExamined.toString();
}

/**
 * @return @see userName
 */
public String getUserName() {
return userName;
}

/**
 * Sets @see userName to given value
 * @param userName value
 */
public void setUserName(String userName) {
this.userName = userName;
}

/**
 * Returns message of the exception and values of @see userName
and @see rolesExamined
 * @return
 */
public String toString() {
return super.toString() + ; user:  + userName + , examined
roles:  + rolesExamined.toString();
}

}

All RPC methods that throws SecurityException and their synchronous
interfaces declare this fact in the throws phrase.

This exception I wanna catch and service (by writing info to the log
and database table) in an aspect manner on the server side before it
reaches client side and is silenced by the one trying to break
security policy.

So I declared in web.xml on the server WAR:

!-- This filter handles the
pl.fizzycomp.client.common.SecurityException --
filter
filter-nameSecurityExceptionFilter/filter-name
filter-classpl.xxx.server.filter.SecurityExceptionFilter/
filter-class
/filter
filter-mapping
filter-nameSecurityExceptionFilter/filter-name
url-pattern/services/*/url-pattern
/filter-mapping

And the code of the filter:

public class SecurityExceptionFilter implements Filter {

private FilterConfig filterConfig = null;

private static Logger log = Logger.getLogger
(SecurityExceptionFilter.class);

@EJB
private ErrorCodesFacadeLocal errorCodesFacade;

@Override
public void init(FilterConfig config) throws ServletException {
this.filterConfig = config;
}

@Override
public void doFilter(ServletRequest request, ServletResponse
response, FilterChain chain) throws IOException, ServletException {
if (filterConfig == null){
return;
}
try {
System.out.println(+++
SecurityExceptionFilter);
System.out.println(request.toString());
System.out.println
(---);
System.out.println(response.toString());
System.out.println(++
+);
chain.doFilter(request, response);
}
catch (Throwable t){
log.fatal(Security violation attempt occured. Event will
be written to ERROR_CODES table., t);
//TODO - database stuff
}
}
/*
private SecurityException examineSecurityException(final Throwable
t){
Throwable temp = t;
while (temp != null){
if (temp instanceof SecurityException){
return (SecurityException) temp;
}
temp = temp.getCause();
}
return null;
}
*/
@Override
public void destroy() {
this.filterConfig = null;
}
}

Then I declared RPC method:

 public ListIPersonWindowMember doAdvancedPersonSearch
(IAdvancedPersonSearchParameter apsp) throws SecurityException
{
   if (true){
   SecurityException e = new SecurityException
(testsecurityex);
   e.setUserName(username);
   e.addRole(role1);e.addRole(role2);

Re: Need help understanding code snippet

2009-04-15 Thread Paul Robinson

Yellow Jersey wrote:
 Hi,

 If someone could help me understand this code snippet from
 StockWatcher app.
 I cannot in particular understand the line marked THIS LINE.


 Button removeStock = new Button(x);
 removeStock.addClickListener(new ClickListener(){
  public void onClick(Widget sender) {
 int removedIndex = stocks.indexOf(symbol);   // - THIS
 LINE
 stocks.remove(removedIndex);
 stocksFlexTable.removeRow(removedIndex+1);
}
 });

   
Your code snippet isn't enough on its own to understand what's going on - you 
also need the
definition of stocks. Perhaps this is your problem. It's defined like this:

private ArrayListString stocks = new ArrayListString();

Does that help you to see what's happening?

Paul

--~--~-~--~~~---~--~~
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: Need help understanding code snippet

2009-04-15 Thread Lothar Kimmeringer

Yellow Jersey schrieb:

 I cannot in particular understand the line marked THIS LINE.
 
   int removedIndex = stocks.indexOf(symbol);   // - THIS LINE

List.indexOf(Object) looks for the position of a given object.
So without checking the actual source the implementiation in
e.g. ArrayList should be something like this:

public int indexOf(Object o){
  for (int i = 0; i  elems.length; i++){
if (elems[i] == o){
  return i;
}
  }
  return -1;
}

So the onClick-method looks for the position of the currently
added symbol (I assume that this part of code is embedded
in a loop that fills the stocksFlexTable) inside an internal
list, removes it from there:

   stocks.remove(removedIndex);

and continues by removing the symbol from a FlexTable that
contains a header-row in addition to the data-rows:

   stocksFlexTable.removeRow(removedIndex+1);

The internal list must contain the symbol, otherwise the whole
thing crashes because of list.remove(-1).

If you need more help about this you should change to a group
that covers that topic, e.g. in the comp.lang.java-hierarchy,
because this has nothing to do with GWT but with the Java-API.


Regards, Lothar

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



CSS stylename code generation

2009-04-15 Thread Francois Wauquier

Hello

I am trying android now, and i appreciate the simple code generation
of the class 'R'.
For non android user, it allows to associate a graphic element to an
id. The id given in an xml file is automatically generated in java, in
the class R.

I am thinking about an equivalent code generation for the css files in
GWT.

example :

myStyle.css
.style{
...
}
.style-dependentStyle{
...
}
#element {
...
}

would give something like

/* AUTO-GENERATED FILE.  DO NOT MODIFY.*/
public final class Styles {
public static final class MyStyle {
public static final String style = style;
public static final String style_dependentStyle = 
dependentStyle;
public static final String IDelement = element;
}
}

which could be used like this:
widget.addStyleName(Styles.MyStyle.style);

widget.addStyleDependentName(Styles.MyStyle.style_dependantStyle);

widget.getElement.setId(Styles.MyStyle.IDelement);


The main advantage is to respect the DRY principle by avoiding boring
manual constants declaration.

This feature could be a part of the new GWT eclipse plugin
http://code.google.com/eclipse/, or a standalone eclipse plugin.

What do you think about it ?

Does anyone is interested in ?



--~--~-~--~~~---~--~~
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: Uncaught exception escaped: JavaScriptException: (Error): Invalid argument.

2009-04-15 Thread Salvador Diaz

I've experienced a similar issue on IE (Firefox was fine) when trying
to run a custom animation. More specifically, I got the same
InvalidArgument javascript error. I haven't tried to pin down the
exact specific problem as I don't have an IE javascript debugger but
I'm pretty sure the cause is the buggy javascript interpreter from IE.
If you want to look at a resizable columns example in FlexGrid, try
looking at the one from the incubator, we use it in our projects and
it works pretty well.

http://code.google.com/p/google-web-toolkit-incubator/source/browse/#svn/trunk/src/com/google/gwt/widgetideas/table/client

You should note that the stack trace from your exception points at one
of your classes and you might be able to see what's wrong if you debug
your application and put a breakpoint at that location :
(com.ibsplc.client.ui.table.EasyFlexTableResizable.setColumnWidth
(EasyFlexTableResizable.java:43) ) - That tells you where the
exception is thrown

Cheers,

Salvador

On Apr 15, 9:24 am, Suren nsurendi...@gmail.com wrote:
 Hi All,

 I am just trying out the example code given in the book named

 Google Web Toolkit Solutions-More cool and useful stuff for
 resizable columns in FlexGrid.

 I have created (carefully!!) all the required classes as like
 mentioned in the book.

 When I run the application, its launching without any problem. The
 moment, when I try to resize any column, I am getting the following
 exception displayed in the Shell window

 [ERROR] Uncaught exception escaped
 com.google.gwt.core.client.JavaScriptException: (Error): Invalid
 argument.
  number: -2147024809
  description: Invalid argument.
         at com.google.gwt.dom.client.Element$.setPropertyString$(Native
 Method)
         at com.google.gwt.user.client.DOM.setElementProperty(DOM.java:1088)
         at com.google.gwt.user.client.ui.HTMLTable$ColumnFormatter.setWidth
 (HTMLTable.java:411)
         at com.ibsplc.client.ui.table.EasyFlexTableResizable.setColumnWidth
 (EasyFlexTableResizable.java:43)
         at com.ibsplc.client.ui.table.ColumnResizeListener.onResize
 (ColumnResizeListener.java:19)
         at com.ibsplc.client.ui.ResizeListenerCollection.fireResize
 (ResizeListenerCollection.java:12)
         at com.ibsplc.client.ui.table.ResizableCellPanel.onMouseMove
 (ResizableCellPanel.java:94)
         at com.google.gwt.user.client.ui.MouseListenerCollection.fireMouseMove
 (MouseListenerCollection.java:122)
         at
 com.google.gwt.user.client.ui.MouseListenerCollection.fireMouseEvent
 (MouseListenerCollection.java:81)
         at com.google.gwt.user.client.ui.Label.onBrowserEvent(Label.java:168)
         at com.google.gwt.user.client.DOM.dispatchEventImpl(DOM.java:1308)
         at com.google.gwt.user.client.DOM.dispatchEventAndCatch(DOM.java:
 1287)
         at com.google.gwt.user.client.DOM.dispatchEvent(DOM.java:1255)

 I have checked the method setColumnWidth, it was like below.

 public void setColumnWidth(int column, int width) {
  getColumnFormatter().setWidth(column,width + px);
  }

 And I knew that setWidth method args are int and String. so on the
 safer side I had changed the args like below.

 public void setColumnWidth(int column, int width) {
  getColumnFormatter().setWidth(column,Integer.toString(width) + px);
  }

 But still I am getting the same exception. Any one experienced such
 issue?

 Or please advise what is wrong in this case

 Thanks in advance

 Suren
--~--~-~--~~~---~--~~
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: Deferred Bind on Login to load different user interface

2009-04-15 Thread Thomas Broyer



On 14 avr, 09:09, matttai matt...@hotmail.com wrote:
 Hi everyone,

 Been checking out alot of the deferred binding tutorials that seem to
 involve reading from the meta data in the html before loading the
 appropiate module.

 If i wanted to load a deferred binding class after a user logs in (eg.
 after the user logs in load the same app with a different skin and
 interface)

 Would this involve something like using JSNI to change the meta in the
 html after a user logs in and forcing a refresh?

 Or is there a better approach to doing this.

Decouple your login app (page) and your GWT application? (depends
how you manage authentication though)

As for your other problem: if I were you, I'd compile the skins as
distinct apps, each with its own HTML host page; this would allow
you to setup a filter to deny access to some skins depending on the
logged-in user (again, depends on how you manage authentication).
--~--~-~--~~~---~--~~
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: insert text into a textarea at cursor position

2009-04-15 Thread Salvador Diaz

You should be able to do that with these methods from TextArea:

http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/TextArea.html#getCursorPos()
http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/TextBoxBase.html#setCursorPos(int)
http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/TextBoxBase.html#setText(java.lang.String)


On Apr 14, 11:24 pm, ekaldany kaldi...@gmail.com wrote:
 So it's pretty clear that this is achievable in a regular webpage with
 a javascript function... but how do I insert text into a textarea at
 cursor position in GWT?

 We have it functional in all browsers except IE... it adds like 3000
 character spaces and inserts the text in a random spot in the
 textarea.

 To explain the greater functionality here, the user is filling out a
 form, then inserting portions of it via links of section names into
 the text area to create a customized note.

 Any help?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Deferred Bind on Login to load different user interface

2009-04-15 Thread Salvador Diaz

The Showcase is a pretty neat example of how do you go about handling
skins:
* Go to http://gwt.google.com/samples/Showcase/Showcase.html
* Click in one if the colored rectangles located in the top right
corner of the page
* Voilà ! (Profit ? :) )

You can look at the code that handles that in the samples included in
the GWT distribution and then adapt it to suit your needs

Cheers,

Salvador

On Apr 15, 2:29 am, matttai matt...@hotmail.com wrote:
 Yep you are following my train of thought exactly.

 I'm thinking in terms of using deferred binding for skin/layout
 differences it shouldn't be such a bad idea if it's small alterations
 such as colours/layout.
 Considering that internationalisation/browser layout differences work
 along the same lines in terms of the scope of changes.

 The workflow i've had it laid out in though in my head is like this:

 1. default entry point with default permutation is loaded with login
 form
 2. user logs in with user / pass / layout
 3. system checks for valid login
 4. if successful login redirect back to default entry point with
 when-property-is name=skin value=GREEN_LAYOUT/

 My issue is on the redirect how would i go about setting the property
 value that i wish to load?
 Would this be appended to the URL ala locales in
 internationalisation?

 This then brings up another issue. If it does involve appending to the
 URL what if i only wish to make the skin available to only a
 particular set of users.

 Else i'm thinking at this point maybe dynamically downloading and
 loading skin X after login may be a better choice as opposed to
 deffered binding.

 On Apr 15, 12:23 am, gscholt gsch...@gmail.com wrote:

  On Apr 14, 9:09 am, matttai matt...@hotmail.com wrote:

   Hi everyone,

   Been checking out alot of thedeferredbinding tutorials that seem to
   involve reading from the meta data in the html before loading the
   appropiate module.

   If i wanted to load adeferredbinding class after a user logs in (eg.
   after the user logs in load the same app with a different skin and
   interface)

   Would this involve something like using JSNI to change the meta in the
   html after a user logs in and forcing a refresh?

   Or is there a better approach to doing this.

  Deferredbinding is a feature of the GWT compiler that works by
  generating many versions of code at compile time, only one of which
  needs to be loaded by a particular client during bootstrapping at
  runtime.
  --http://code.google.com/webtoolkit/doc/1.6/DevGuideCodingBasics.html#D...

  If you usedeferredbinding for skin support (which might not be a bad
  idea, depending on the amount of skins and the amount of code they
  generate), you will need to reload the application to get a different
  compiler permutation. This includes reloading the HTML, since you'll
  need to run the GWT bootstrapping code again, which selects the
  correct permutation depending on the set properties, using something
  like property-provider name=skin.../

  Gert
--~--~-~--~~~---~--~~
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: CSS stylename code generation

2009-04-15 Thread Francois Wauquier

It seems to look like what i dreamt.
It is not code generation, but a java view of the CSS ressource
(retrieved as an image Bundle)

http://code.google.com/p/google-web-toolkit-incubator/wiki/CssResourceCookbook

CssResource will use method names as CSS class names to obfuscate at
runtime.

interface MyCss extends CssResource {
  String className();
}

interface MyResources extends ImmutableResourceBundle {
  @Resource(my.css)
  MyCss css();
}
All instances of a selector with .className will be replaced with an
obfuscated symbol when the CSS is compiled. To use the obfuscated
name:

MyResources resources = GWT.create(MyResources.class);
Label l = new Label(Some text);
l.addStyleName(resources.css().className());
If you have class names in your css file that are not legal Java
identifiers, you can use the @ClassName annotation on the accessor
method:

interface MyCss extends CssResource {
  @ClassName(some-other-name)
  String someOtherName();
}


It allows to link java to css. but it is still a rewrite.
If it alert you about an error at compile time (as the imageBundle
do), it is still an enhancement.

I take it!

Thank you Vador ;)
--~--~-~--~~~---~--~~
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: filter for client package in MyApplication.gwt.xml

2009-04-15 Thread Thomas Broyer


On 14 avr, 12:38, SlowFlyer flas...@gmail.com wrote:
 I can define package with client code in MyApplication.gwt.xml.

 source path='myclientpackage'/

 Is it possible to set filter for this package to ignore some classes?

RTFM ? ;-)
http://code.google.com/intl/fr-FR/webtoolkit/doc/1.6/DevGuideOrganizingProjects.html#DevGuidePathFiltering

(it's true of GWT 1.5 too, if you've not switched to 1.6 yet)
--~--~-~--~~~---~--~~
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: Load gwt module before image are loaded on IE7

2009-04-15 Thread Salvador Diaz

I think it should be helpful to understand the bootstrap sequence,
maybe it will inspire you to come up with a better solution and share
it with us :)

http://code.google.com/p/google-web-toolkit-doc-1-5/wiki/FAQ_WhenDoModulesLoad

Cheers,

Salvador

On Apr 14, 6:55 pm, Dominik Steiner dominik.j.stei...@googlemail.com
wrote:
 Hi,

 I have a page that contains a lot of images and some of those images
 take a long time to load (in total like 1 min)

 I have searched the forum and found this similar post

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

 but with no concrete solution to the problem, that IE7 will wait until
 all the images are loaded until it will then load the GWT module.

 Is there a work around for this so that the gwt module will be loaded
 before the images have finished loading? (using gwt 1.5.3)

 Thanks

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



Re: How to include javascript files in GWT with eclipse plugin?

2009-04-15 Thread Salvador Diaz

If all you want to do is include some external js files:
http://code.google.com/docreader/#p=google-web-toolkit-doc-1-5s=google-web-toolkit-doc-1-5t=DevGuideAutomaticResourceInjection
If you're looking at including jars in your war, it could be worth to
look at something for managing your dependencies (like maven):
http://maven.apache.org

Cheers,

Salvador

On Apr 14, 9:58 pm, TimOnGmail timbes...@gmail.com wrote:
 Hi all...

 I'm using GWT-EXT, and it needs to be copied into war/js/ext every
 time I build my project.  However, every time I build my project, it
 gets deleted and I have to copy it manually.

 Does anyone know where I would put the ext folder - or what files I
 modify to point to it - so that the Eclipse plugin will copy it for
 every build?

 - Tim
--~--~-~--~~~---~--~~
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: hosted mode using seperate module for server side code

2009-04-15 Thread Thomas Broyer



On 14 avr, 12:34, Bezge bez...@gmail.com wrote:
 I use a servlet in the hosted mode which acts as a proxy since i
 cannot directly communicate with the server due to the same origin
 policy. Once deployed the servlet is no more needed since both would
 run on the same server. So I decided to have a separate module for the
 servlet which is inherited by the module of the main project. But the
 servlet is only deployed by Jetty when I reference the servlet in the
 web.xml of the main project.
[...]
 Is there a way to use server-side code from an inherited module in the
 hosted mode without modifying the web.xml of the main project?

Just use a different war directory (and use the -war option of the
HostedMode/Compiler to tell it which one to use) with a different
web.xml. Or you could, for example, have a web.xml.deploy file and use
Ant to replace the web.xml (used for HostedMode) content with the one
from the web.xml.deploy file when packaging your app.

If you're not using Jetty on your deployment server, you could
probably configure your proxy in a WEB-INF/jetty-web.xml (I'm not used
to Jetty and haven't found how to do it yet; looks like it would have
to be a proxy *handler*, not servlet).

 Servlet Project:
     Servlet.gwt.xml:
         module
             servlet class=server.Servlet path=/servlet /
         /module

If you're using GWT 1.6, servlet/ is deprecated (and un-needed /
useless)

I personally wouldn't use a GWT module for the proxy servlet, just
package it in a JAR (or add a dependency between two Eclipse projects,
or...) and put it in the WEB-INF/lib (if the class is your project,
you have *nothing* to do, it'll be compiled and put in the WEB-INF/
classes when launching the HostedMode, and you just have to map it
in your web.xml (or jetty-web.xml?))
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: GWT Serialization with CustomFieldSerializer fails because of SerializationPolicy

2009-04-15 Thread Salvador Diaz

 perhaps can we use annotations like @gwt.typeArgs

Those are deprecated, you should really avoid using them

   a simple java class containing a MapString,Object

Can't you just use a MapString, Serializable ? If the map is going
to be travelling through RPCs you really shouldn't be putting objects
that don't implement Serializable into it.

Cheers,

Salvador


  For every service gwt has a list of classes which can be Serialized
  (whitelist). If my understanding is right this list is generated by the
  compiler at compile time by analizing the members of a class.

  But we can have classes (which ARE serializable) inside our transient map,
  but gwt will not serialize this classes because of the SerializationPolicy
  (these classes could not be found by the compiler at compile time).

  Is there any way to extend the white list of SerializationPolicy.java ?

  If I add all classes as private members to my class the members are found
  and the class can be serialized, but this is anoying and we cant do this for
  all classes (we dynamically decide which classes we need to transfer)

  Anyone got any expierence with that?

  Maybe open an issue about this?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Problems with ImageBundle in IE8 when not in compatibility mode

2009-04-15 Thread Thomas Broyer



On 14 avr, 18:41, toont...@googlemail.com toont...@googlemail.com
wrote:
 Greetings,

 Only in IE8 with compatibility mode off do I see the images in the
 ImageBundle displayed in the right location but other images from the
 bundle are displayed to the left of the displayed image. In other
 words it isn't clipping the bundle to the left. In compatibility mode
 it works fine and it works in IE7, FF3, Opera, and Safari.

 This a problem in 1.6.4 and 1.5.3.

Other things will break in IE8's super standards mode.

 I've looked for previous discussions of this and found

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

 where Janie says I'm trying to track down an issue with ImageBundles
 that I'm having in IE8.  This email is not about that issue... . But
 then nothing more about this.

 Suggestions?

Ask IE8 to use the appropriate mode by including the corresponding
HTTP response header or meta to your HTML host page; e.g.

   meta name=X-UA-Compatible content=IE=EmulateIE7

See http://msdn.microsoft.com/en-us/library/cc288325(VS.85).aspx

--~--~-~--~~~---~--~~
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: Problem in downloading Google Plugin for Eclipse

2009-04-15 Thread sandeepla...@gmail.com

That was nice info. Thanks  Paul and Rvanlaak.

I have resolved this by downloading plugin from

http://code.google.com/p/cypal-studio/downloads/list

But the links pointing to actual flavor are still down.  :(

Thanks
Sandeep


On Apr 14, 6:36 pm, Rvanlaak rvanl...@gmail.com wrote:
 Actually, the plugin also is able to download the latest version of
 the GWT package. So, only the update site is needed.

 On Apr 14, 3:34 pm, Rvanlaak rvanl...@gmail.com wrote:



  That are the Eclipse update sites, wich aren't available by http

 http://code.google.com/intl/nl/eclipse/docs/download.html

  On Apr 14, 10:13 am, Paul Grenyer paul.gren...@gmail.com wrote:

   Hi

   On Tue, Apr 14, 2009 at 9:10 AM, sandeepla...@gmail.com

   sandeepla...@gmail.com wrote:

Thanks Paul, do you know some expected time after which these links
will be up ?

   Nope, I just clicked on them to see if they worked.

   --
   Thanks
   Paul

   Paul Grenyer
   e: paul.gren...@gmail.com
   w:http://www.marauder-consulting.co.uk
   b: paulgrenyer.blogspot.com- Hide quoted text -

 - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: How to share RPC service between GWT applications?

2009-04-15 Thread gregor

I would be careful about multiple Hibernate session factories etc. You
may be able to get away with it, but there are potential problems that
might be difficult to trace. I would do some research into your
options as they relate to your particular use case. Two main ways to
deal with this are:

1. configure data source as JNDI lookup. That works with servlet
container only, e.g. Tomcat, Jetty. I'm pretty sure Spring provides
ways to do this in conjunction with Hibernate for example.
2. deploy as an EAR that houses both web apps (as WARs) and a common
data access/transaction management tier (as a JAR). You might delegate
the server side work and data access from your RPC servlets to a
session EJB for example. You will need to use a full blown Java EE app
server like JBoss for this of course, and run GWT hosted mode with -
noserver option etc.

On Apr 15, 8:38 am, jfeid jannis.feida...@gmail.com wrote:
 Thanks for the reply.

 The RPC servlet uses a db layer jar which configures a Hibernate
 factory.
 Because of different classloaders I assume that there will be 2
 instances of this factory.
 But I cannot say if this will present an issue until I test it.

 On Apr 14, 9:23 pm, gregor greg.power...@googlemail.com wrote:

  You can do this if you place your RPC services in a separate module
  that is inherited by the two main application modules. In this
  situation you can specify the RPC servlets in the common module
  gwt.xml file and this will work for hosted mode, but I think you have
  to map them separately (i.e. in duplicate) in each main module's
  web.xml for deployment - AFAIK there is no way around that (app server/
  servlet specification issue, not GWT).

  At run time you will end up with two instances of each servlet loaded
  by the two main module's classloaders (again app server/servlet
  specification issue, not GWT) which may or may not present you with an
  issue depending on what you are doing.

  On Apr 14, 4:14 pm, jfeid jannis.feida...@gmail.com wrote:

   Hello,

   I have the following problem that puzzles me.

   Suppose I have 2 different GWT applications running on different
   contexts:
   -http://server/context1
   -http://server/context2

   Is there a way to share an RPC service between them?

   Thank you.
--~--~-~--~~~---~--~~
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 to listen event after press shift key for grid

2009-04-15 Thread vruddhi shah
Hi,

I am using grid of gwtext, when I select rows with shift+click , Then after
Grid can not listen any event like rowclicklistener and rowdblclicklistener.
Anybody has solution?

-- 
Vruddhi Shah
Pyther Innovations Pvt. Ltd.
Land line: 91 78 40074893
617, Devpath Complex
C.G. Road, Ahmedabad
India
www.gwt4enterprise.com

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



Re: File Upload with rpc call

2009-04-15 Thread evgeniy

Yes, you can do it only in FireFox 3, as far as I know.
If you have FileUpload element then you can acces to file's data from
native JavaScript.
For example you have FileUpload and set its ID to file then
following method returns binary data contained in file:
private native String getFileBinary() /*-{
return $doc.getElementById(file).files[0].getAsBinary();
}-*/;
Then you are free to use returned data in RPC call or whatever you
want.

You can read more here: https://developer.mozilla.org/En/NsIDOMFile

On Apr 14, 11:18 am, loudo lou...@gmail.com wrote:
 Hello

 Can i make a file upload with a rpc call ?
 I want to upload a file with the rpc call but i have not found
 example.
 I have only found example with submit form.

 Thanks a lot for your response.
--~--~-~--~~~---~--~~
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: DateBox and onValueChange in GWT 1.6

2009-04-15 Thread Thomas Broyer



On 14 avr, 16:27, Peterman pserr...@gmail.com wrote:
 Hi

 I'am working with the DateBox component: show a calendar when you
 click on a box. But I have a problem: the listener onValueChange
 doesn't work like in the componente DatePicker. This is my code:

 DateBox dateBox = new DateBox();

                 /*dateBox.setFormat(new DateBox.DefaultFormat
 (DateTimeFormat.getFormat
                                 (MMM dd,  HH:mm aaa)));*/

                 dateBox.addValueChangeHandler(new ValueChangeHandlerDate() {
                       public void onValueChange(ValueChangeEventDate event) 
 {

                         Window.alert(onValueChange datebox);
                         /*Date date = dateBox.getValue();
                         try
                         {
                                 String dateString = 
 DateTimeFormat.getMediumDateFormat
 ().format(date);
                                 okButtton.setEnabled(true);
                                 Window.alert(okbutton a true);
                         }
                         catch (Exception e)
                         {
                                 Window.alert(okbutton a false);
                                 Window.alert(e.getMessage());
                                 okButtton.setEnabled(false);
                         }*/

                       }
                     });

 This code in DatePicker works. Anybody knows why? Maybe it is a bug of
 this componente?

Seems related to issues 1634 and 3553:
http://code.google.com/p/google-web-toolkit/issues/detail?id=1634
http://code.google.com/p/google-web-toolkit/issues/detail?id=3553

namely, when you click on the popup calendar, the textbox looses focus
and fires a value change event (then only the click on the popup
calendar has a chance to select a date, thus set the datebox's value
and fire the expected value change event).

(I don't understand you try/catch check with format(): getValue will
only return a non-null value if the textbox value is a date in the
appropriate format; could it be your actual problem? dateBox.getValue
() being null?)
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: GWT 1.6, JSP's wont compile.

2009-04-15 Thread Salvador Diaz

It looks like the app server on which you're trying to load the jsp
doesn't support java 1.5 or you compiled your jsp with 1.4 or
something like that. Can't really tell without more details though. I
hope that helps you.

Cheers,

Salvador

On Apr 15, 4:13 am, Adrian ahay...@gmail.com wrote:
 Ok, so it's not just me!

 Does anyone have any idea on how to go about finding an answer to this
 problem? Even if you don't know the answer any suggestions are welcome
 because this one has me stumped.

 - Adrian

 On Apr 14, 3:23 pm, Ken kenfehl...@gmail.com wrote:

  I'm having the same exact problem.
  I've tried it on both Mac OS X and Windows.
--~--~-~--~~~---~--~~
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: Uncaught exception escaped: JavaScriptException: (Error): Invalid argument.

2009-04-15 Thread Salvador Diaz

We use the following classes
com.google.gwt.widgetideas.table.client.ScrollTable
com.google.gwt.widgetideas.table.client.FixedWidthGrid
com.google.gwt.widgetideas.table.client.FixedWidthFlexTable

ScrollTable table = new ScrollTable(getDataTable(), getHeaderTable());
table.setPixelSize(tableWidth, pixelHeight);
table.setResizePolicy(ScrollTable.ResizePolicy.UNCONSTRAINED);

protected FixedWidthFlexTable getHeaderTable() {
return new FixedWidthFlexTable();
}

protected FixedWidthGrid getDataTable(){
return new FixedWidthGrid();
}

There are some pretty good examples included in the incubator, you
should really take a look at them

On Apr 15, 1:30 pm, Suren nsurendi...@gmail.com wrote:
 Hi Salvador,

 Thanks for the reply.

 I just had a look at the incubator and I have downloaded the latest
 jar.

 My requirement would be having a table with fixed header and resizable
 columns.

 So which demo/filename you suggess to use?

 btw, on the exception side, I tried it in Firefox, where I didnt get
 the exception but column resizing are not workin. I will do the
 debugging anyway.

 Thanks
 Suren

 On Apr 15, 2:44 pm, Salvador Diaz diaz.salva...@gmail.com wrote:

  I've experienced a similar issue on IE (Firefox was fine) when trying
  to run a custom animation. More specifically, I got the same
  InvalidArgument javascript error. I haven't tried to pin down the
  exact specific problem as I don't have an IE javascript debugger but
  I'm pretty sure the cause is the buggy javascript interpreter from IE.
  If you want to look at a resizable columns example in FlexGrid, try
  looking at the one from the incubator, we use it in our projects and
  it works pretty well.

 http://code.google.com/p/google-web-toolkit-incubator/source/browse/#...

  You should note that the stack trace from your exception points at one
  of your classes and you might be able to see what's wrong if you debug
  your application and put a breakpoint at that location :
  (com.ibsplc.client.ui.table.EasyFlexTableResizable.setColumnWidth
  (EasyFlexTableResizable.java:43) ) - That tells you where the
  exception is thrown

  Cheers,

  Salvador

  On Apr 15, 9:24 am, Suren nsurendi...@gmail.com wrote:

   Hi All,

   I am just trying out the example code given in the book named

   Google Web Toolkit Solutions-More cool and useful stuff for
   resizable columns in FlexGrid.

   I have created (carefully!!) all the required classes as like
   mentioned in the book.

   When I run the application, its launching without any problem. The
   moment, when I try to resize any column, I am getting the following
   exception displayed in the Shell window

   [ERROR] Uncaught exception escaped
   com.google.gwt.core.client.JavaScriptException: (Error): Invalid
   argument.
    number: -2147024809
    description: Invalid argument.
           at com.google.gwt.dom.client.Element$.setPropertyString$(Native
   Method)
           at 
   com.google.gwt.user.client.DOM.setElementProperty(DOM.java:1088)
           at 
   com.google.gwt.user.client.ui.HTMLTable$ColumnFormatter.setWidth
   (HTMLTable.java:411)
           at 
   com.ibsplc.client.ui.table.EasyFlexTableResizable.setColumnWidth
   (EasyFlexTableResizable.java:43)
           at com.ibsplc.client.ui.table.ColumnResizeListener.onResize
   (ColumnResizeListener.java:19)
           at com.ibsplc.client.ui.ResizeListenerCollection.fireResize
   (ResizeListenerCollection.java:12)
           at com.ibsplc.client.ui.table.ResizableCellPanel.onMouseMove
   (ResizableCellPanel.java:94)
           at 
   com.google.gwt.user.client.ui.MouseListenerCollection.fireMouseMove
   (MouseListenerCollection.java:122)
           at
   com.google.gwt.user.client.ui.MouseListenerCollection.fireMouseEvent
   (MouseListenerCollection.java:81)
           at 
   com.google.gwt.user.client.ui.Label.onBrowserEvent(Label.java:168)
           at com.google.gwt.user.client.DOM.dispatchEventImpl(DOM.java:1308)
           at com.google.gwt.user.client.DOM.dispatchEventAndCatch(DOM.java:
   1287)
           at com.google.gwt.user.client.DOM.dispatchEvent(DOM.java:1255)

   I have checked the method setColumnWidth, it was like below.

   public void setColumnWidth(int column, int width) {
    getColumnFormatter().setWidth(column,width + px);
    }

   And I knew that setWidth method args are int and String. so on the
   safer side I had changed the args like below.

   public void setColumnWidth(int column, int width) {
    getColumnFormatter().setWidth(column,Integer.toString(width) + px);
    }

   But still I am getting the same exception. Any one experienced such
   issue?

   Or please advise what is wrong in this case

   Thanks in advance

   Suren- Hide quoted text -

  - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to 

efficiency of my gwt application

2009-04-15 Thread ytbryan

hi folks,

my application has been running very slowly and i would like to know
why.
can somebody advise me on what are the common bottleneck that i need
to optimise? I am pretty new with gwt.

i read the  speed up gwt compiler series
http://blog.bazoud.com/post/2008/07/31/Can-I-speed-up-the-GWT-compiler-Part-III
but i think it is quite irrelevant in speeding up the running speed of
the application. correct me if i am wrong.

i copy my gwt.xml if it is necessary. i have rpc, google map, ofcgwt,
smartgwt inside the application.

?xml version=1.0 encoding=UTF-8 standalone=no?module
!-- Inherit the core Web Toolkit stuff.  --
inherits name=com.google.gwt.user.User/
inherits name=com.smartgwt.SmartGwt/
inherits name=com.smartgwt.SmartGwtNoScript/
inherits name=com.smartclient.theme.enterprise.Enterprise/
inherits name='com.rednels.ofcgwt.OFCGWT'/
inherits name=com.google.gwt.maps.GoogleMaps /
!-- Specify the app entry point class.   --
entry-point class=com.eviware.gwt.test.mysqlconn.client.MySQLConn/

script src=http://maps.google.com/maps?gwt=1amp;file=apiamp;v=2; /

!-- servlet context - path is arbritray, but must match up with
the rpc init inside java class --
!-- Tomcat will listen for this from the server and waits for rpc
request in this context --
servlet
class=com.eviware.gwt.test.mysqlconn.server.MySQLConnServiceImpl
path=/MySQLConnService/
/module


thank you!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: GWT 1.6 and GXT

2009-04-15 Thread Rvanlaak

I think I'm permanently going to switch to GXT after i've read the
following blog:
http://www.sambastream.com/blogs/agiannone/26-01-09/rich-internet-applications-and-web-20-gwt-ext-gxt-and-smartgwt
He makes some very good points!

I've been messing around with the layouts in GXT1.2.3 (with GWT1.6),
and found out that they aren't completely compatible. Besides that I
really want to use the new Google Eclipse Plugin, just because it's
awesome. GXT2 should have been released yesterday, but i haven't found
anything about it.


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



Re: Problem uploading SmartGWT and GWT to Java GAE

2009-04-15 Thread ivo

Ok, but my question is how to set-up gwt in such a way that it can
look for static files from other urls (for the time being regardless
of the specific IE quircks)
thanks!

On Apr 15, 12:25 pm, Salvador Diaz diaz.salva...@gmail.com wrote:
 You'll probably run into trouble with the Same Origin Policy (with IE7
 for instance, we have an issue where an image isn't loaded if the url
 isn't in the same domain the module is deployed on, even though the
 url points to the IP for that domain)

 Let us know if you succeed

 On Apr 15, 1:13 pm, ivo ivo.reduto.fre...@gmail.com wrote:

  Hello,

  I'm using gwt and smartgwt for an aplication and now I want to try out
  the java GAE for the backend.

  When I upload my application to GAE I get an error saying Max number
  of files and blobs is 1000.

  The problem is that smartgwt inserts thousands of static files into my
  app (javascript, css, xml, png...).
  One solution would be to host smartgwt files in some other domain and
  then point gwt to look for these static files from the proper url.

  So, is it possible to configure gwt in such a way?

  Thanks!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Uncaught exception escaped: JavaScriptException: (Error): Invalid argument.

2009-04-15 Thread Suren

Hi Salvador,

Thanks for the reply.

I just had a look at the incubator and I have downloaded the latest
jar.

My requirement would be having a table with fixed header and resizable
columns.

So which demo/filename you suggess to use?

btw, on the exception side, I tried it in Firefox, where I didnt get
the exception but column resizing are not workin. I will do the
debugging anyway.

Thanks
Suren

On Apr 15, 2:44 pm, Salvador Diaz diaz.salva...@gmail.com wrote:
 I've experienced a similar issue on IE (Firefox was fine) when trying
 to run a custom animation. More specifically, I got the same
 InvalidArgument javascript error. I haven't tried to pin down the
 exact specific problem as I don't have an IE javascript debugger but
 I'm pretty sure the cause is the buggy javascript interpreter from IE.
 If you want to look at a resizable columns example in FlexGrid, try
 looking at the one from the incubator, we use it in our projects and
 it works pretty well.

 http://code.google.com/p/google-web-toolkit-incubator/source/browse/#...

 You should note that the stack trace from your exception points at one
 of your classes and you might be able to see what's wrong if you debug
 your application and put a breakpoint at that location :
 (com.ibsplc.client.ui.table.EasyFlexTableResizable.setColumnWidth
 (EasyFlexTableResizable.java:43) ) - That tells you where the
 exception is thrown

 Cheers,

 Salvador

 On Apr 15, 9:24 am, Suren nsurendi...@gmail.com wrote:



  Hi All,

  I am just trying out the example code given in the book named

  Google Web Toolkit Solutions-More cool and useful stuff for
  resizable columns in FlexGrid.

  I have created (carefully!!) all the required classes as like
  mentioned in the book.

  When I run the application, its launching without any problem. The
  moment, when I try to resize any column, I am getting the following
  exception displayed in the Shell window

  [ERROR] Uncaught exception escaped
  com.google.gwt.core.client.JavaScriptException: (Error): Invalid
  argument.
   number: -2147024809
   description: Invalid argument.
          at com.google.gwt.dom.client.Element$.setPropertyString$(Native
  Method)
          at com.google.gwt.user.client.DOM.setElementProperty(DOM.java:1088)
          at com.google.gwt.user.client.ui.HTMLTable$ColumnFormatter.setWidth
  (HTMLTable.java:411)
          at com.ibsplc.client.ui.table.EasyFlexTableResizable.setColumnWidth
  (EasyFlexTableResizable.java:43)
          at com.ibsplc.client.ui.table.ColumnResizeListener.onResize
  (ColumnResizeListener.java:19)
          at com.ibsplc.client.ui.ResizeListenerCollection.fireResize
  (ResizeListenerCollection.java:12)
          at com.ibsplc.client.ui.table.ResizableCellPanel.onMouseMove
  (ResizableCellPanel.java:94)
          at 
  com.google.gwt.user.client.ui.MouseListenerCollection.fireMouseMove
  (MouseListenerCollection.java:122)
          at
  com.google.gwt.user.client.ui.MouseListenerCollection.fireMouseEvent
  (MouseListenerCollection.java:81)
          at 
  com.google.gwt.user.client.ui.Label.onBrowserEvent(Label.java:168)
          at com.google.gwt.user.client.DOM.dispatchEventImpl(DOM.java:1308)
          at com.google.gwt.user.client.DOM.dispatchEventAndCatch(DOM.java:
  1287)
          at com.google.gwt.user.client.DOM.dispatchEvent(DOM.java:1255)

  I have checked the method setColumnWidth, it was like below.

  public void setColumnWidth(int column, int width) {
   getColumnFormatter().setWidth(column,width + px);
   }

  And I knew that setWidth method args are int and String. so on the
  safer side I had changed the args like below.

  public void setColumnWidth(int column, int width) {
   getColumnFormatter().setWidth(column,Integer.toString(width) + px);
   }

  But still I am getting the same exception. Any one experienced such
  issue?

  Or please advise what is wrong in this case

  Thanks in advance

  Suren- Hide quoted text -

 - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: GWT 1.6 and GXT

2009-04-15 Thread Paul Grenyer

Hi

 I think I'm permanently going to switch to GXT after i've read the
 following blog:
 http://www.sambastream.com/blogs/agiannone/26-01-09/rich-internet-applications-and-web-20-gwt-ext-gxt-and-smartgwt
 He makes some very good points!


Thanks! Very enlightening!

-- 
Thanks
Paul

Paul Grenyer
e: paul.gren...@gmail.com
w: http://www.marauder-consulting.co.uk
b: paulgrenyer.blogspot.com

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



How to get URL for image within an image bundle - if possible

2009-04-15 Thread Joe Hudson

Hi,

I'm trying to use SmartGWT which doesn't seem to support GWT Image
Bundles.

I would like to set a background image on a canvas to be an image from
an image bundle.  Is it possible to get a url from an image within an
image bundle to do this?  Thanks.

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



Re: GWT 1.6, JSP's wont compile.

2009-04-15 Thread Ken

The app server is the one bundled with GWT hosted mode, I believe it's
Jetty.  If you use a servlet that has 1.5 stuff in it, it works fine.
When I was investigating, I noticed that the JSP does successfully
produce a servlet.  I copied this servlet and compiled it myself and
it worked fine, even in hosted mode.  I believe it's failing at the
point where the generated servlet (.java) is being compiled into a
class (.class).  Like you said, it seems like for some reason it's
targeting version 1.4 or something like that.

On Apr 15, 7:31 am, Salvador Diaz diaz.salva...@gmail.com wrote:
 It looks like the app server on which you're trying to load the jsp
 doesn't support java 1.5 or you compiled your jsp with 1.4 or
 something like that. Can't really tell without more details though. I
 hope that helps you.

 Cheers,

 Salvador

 On Apr 15, 4:13 am, Adrian ahay...@gmail.com wrote:

  Ok, so it's not just me!

  Does anyone have any idea on how to go about finding an answer to this
  problem? Even if you don't know the answer any suggestions are welcome
  because this one has me stumped.

  - Adrian

  On Apr 14, 3:23 pm, Ken kenfehl...@gmail.com wrote:

   I'm having the same exact problem.
   I've tried it on both Mac OS X and Windows.
--~--~-~--~~~---~--~~
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: efficiency of my gwt application

2009-04-15 Thread Thomas Broyer



On 15 avr, 13:51, ytbryan ytbr...@gmail.com wrote:
 hi folks,

 my application has been running very slowly and i would like to know
 why.

You could try compiling in -style DETAILED (or at least PRETTY) and
run a JavaScript profiler (Firebug or IE8 developer tools).
GWT comes with a benchmark framework, but you'd have to know what you
want/have to measure...

 can somebody advise me on what are the common bottleneck that i need
 to optimise? I am pretty new with gwt.

1. optimize network exchanges (generally, you'd better have 1 RPC call
return 3 kinds of data, than 3 RPC calls)
2. but GWT-RPC might be slow, particularly while serializing/
deserializing large object graphs
3. when updating the UI, working with hidden (display:none) or, even
better, detached widgets is faster; sometimes, building a new widget
from scratch, populating it and replacing an existing equivalent
widget might be faster than updating the existing widget
4. rendering-wise, try to set table-layout:fixed on your tables
(including Horizontal/VerticalPanel, FlexTable, Grid, DecoratorPanel,
DecoratedPopupPanel, DialogBox, etc.)

5. what does slow mean?

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



Re: GWT 1.6, JSP's wont compile.

2009-04-15 Thread Ken

The app server is the one bundled with GWT hosted mode, I believe it's
Jetty.  If you use a servlet that has 1.5 stuff in it, it works fine.
When I was investigating, I noticed that the JSP does successfully
produce a servlet.  I copied this servlet and compiled it myself and
it worked fine, even in hosted mode.  I believe it's failing at the
point where the generated servlet (.java) is being compiled into a
class (.class).  Like you said, it seems like for some reason it's
targeting version 1.4 or something like that.  It's confusing though
that the problem is during compilation, because if you start with a
servlet (rather than a JSP) it compiles with no problem.

I have a feeling this might have something to do with it:
http://code.google.com/p/google-web-toolkit/source/detail?r=5109

It appears that something different happens underneath when a servlet
is compiled as opposed to when a servlet generated by a JSP is
compiled.

On Apr 15, 7:31 am, Salvador Diaz diaz.salva...@gmail.com wrote:
 It looks like the app server on which you're trying to load the jsp
 doesn't support java 1.5 or you compiled your jsp with 1.4 or
 something like that. Can't really tell without more details though. I
 hope that helps you.

 Cheers,

 Salvador

 On Apr 15, 4:13 am, Adrian ahay...@gmail.com wrote:

  Ok, so it's not just me!

  Does anyone have any idea on how to go about finding an answer to this
  problem? Even if you don't know the answer any suggestions are welcome
  because this one has me stumped.

  - Adrian

  On Apr 14, 3:23 pm, Ken kenfehl...@gmail.com wrote:

   I'm having the same exact problem.
   I've tried it on both Mac OS X and Windows.
--~--~-~--~~~---~--~~
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: insert text into a textarea at cursor position

2009-04-15 Thread ekaldany

Thanks guys, I will study the links and post up if I continue to have
trouble.

On Apr 15, 5:50 am, Salvador Diaz diaz.salva...@gmail.com wrote:
 You should be able to do that with these methods from TextArea:

 http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...()http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...)http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...)

 On Apr 14, 11:24 pm, ekaldany kaldi...@gmail.com wrote:

  So it's pretty clear that this is achievable in a regular webpage with
  a javascript function... but how do I insert text into a textarea at
  cursor position in GWT?

  We have it functional in all browsers except IE... it adds like 3000
  character spaces and inserts the text in a random spot in the
  textarea.

  To explain the greater functionality here, the user is filling out a
  form, then inserting portions of it via links of section names into
  the text area to create a customized note.

  Any help?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: efficiency of my gwt application

2009-04-15 Thread ytbryan

thanks for your reply thomas. for me, there is two cases of slowness.

- the rpc is quite slow. i am using it to return a few thousand by
eleven column of data(String)
- i have a tabset within my application which i copied from the
smartgwt showcase when i click on new tab with google map on
it.. it will normally hang and need  a few minutes to finally
display the result. sometimes, it will hang forever.

can you give me some links to these tutorials? if you have any.

thanks again..

On Apr 15, 3:13 pm, Thomas Broyer t.bro...@gmail.com wrote:
 On 15 avr, 13:51, ytbryan ytbr...@gmail.com wrote:

  hi folks,

  my application has been running very slowly and i would like to know
  why.

 You could try compiling in -style DETAILED (or at least PRETTY) and
 run a JavaScript profiler (Firebug or IE8 developer tools).
 GWT comes with a benchmark framework, but you'd have to know what you
 want/have to measure...

  can somebody advise me on what are the common bottleneck that i need
  to optimise? I am pretty new with gwt.

 1. optimize network exchanges (generally, you'd better have 1 RPC call
 return 3 kinds of data, than 3 RPC calls)
 2. but GWT-RPC might be slow, particularly while serializing/
 deserializing large object graphs
 3. when updating the UI, working with hidden (display:none) or, even
 better, detached widgets is faster; sometimes, building a new widget
 from scratch, populating it and replacing an existing equivalent
 widget might be faster than updating the existing widget
 4. rendering-wise, try to set table-layout:fixed on your tables
 (including Horizontal/VerticalPanel, FlexTable, Grid, DecoratorPanel,
 DecoratedPopupPanel, DialogBox, etc.)

 5. what does slow mean?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: How to get URL for image within an image bundle - if possible

2009-04-15 Thread Magius

The imageBundle has a unique URL for all the images, in fact it's a
one big image made by all the little ones.
GWT loads the whole image but uses a clipper control to show only the
clip containing the image.


On Apr 15, 2:53 pm, Joe Hudson joe...@gmail.com wrote:
 Hi,

 I'm trying to use SmartGWT which doesn't seem to support GWT Image
 Bundles.

 I would like to set a background image on a canvas to be an image from
 an image bundle.  Is it possible to get a url from an image within an
 image bundle to do this?  Thanks.

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



Re: GWT 1.6, JSP's wont compile.

2009-04-15 Thread Miguel Méndez
It looks like it is a bug with Jetty instance used when a GWT-only web app
has JSPs with generics.
It does not appear that the App Engine
devserverhttp://code.google.com/appengine/docs/java/tools/devserver.html
has
this problem.  I went ahead and filed a bug against GWT for this,
Issue 3557http://code.google.com/p/google-web-toolkit/issues/detail?id=3557.
 As a workaround, you could add App Engine to your project.

On Wed, Apr 15, 2009 at 9:15 AM, Ken kenfehl...@gmail.com wrote:


 The app server is the one bundled with GWT hosted mode, I believe it's
 Jetty.  If you use a servlet that has 1.5 stuff in it, it works fine.
 When I was investigating, I noticed that the JSP does successfully
 produce a servlet.  I copied this servlet and compiled it myself and
 it worked fine, even in hosted mode.  I believe it's failing at the
 point where the generated servlet (.java) is being compiled into a
 class (.class).  Like you said, it seems like for some reason it's
 targeting version 1.4 or something like that.  It's confusing though
 that the problem is during compilation, because if you start with a
 servlet (rather than a JSP) it compiles with no problem.

 I have a feeling this might have something to do with it:
 http://code.google.com/p/google-web-toolkit/source/detail?r=5109

 It appears that something different happens underneath when a servlet
 is compiled as opposed to when a servlet generated by a JSP is
 compiled.

 On Apr 15, 7:31 am, Salvador Diaz diaz.salva...@gmail.com wrote:
  It looks like the app server on which you're trying to load the jsp
  doesn't support java 1.5 or you compiled your jsp with 1.4 or
  something like that. Can't really tell without more details though. I
  hope that helps you.
 
  Cheers,
 
  Salvador
 
  On Apr 15, 4:13 am, Adrian ahay...@gmail.com wrote:
 
   Ok, so it's not just me!
 
   Does anyone have any idea on how to go about finding an answer to this
   problem? Even if you don't know the answer any suggestions are welcome
   because this one has me stumped.
 
   - Adrian
 
   On Apr 14, 3:23 pm, Ken kenfehl...@gmail.com wrote:
 
I'm having the same exact problem.
I've tried it on both Mac OS X and Windows.
 



-- 
Miguel

--~--~-~--~~~---~--~~
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: efficiency of my gwt application

2009-04-15 Thread ytbryan

thanks for your reply thomas. for me, there is two cases of slowness.

- the rpc is quite slow. i am using it to return a few thousand by
eleven column of data(String)
- i have a tabset within my application which i copied from the
smartgwt showcase when i click on new tab with google map on
it.. it will normally hang and need  a few minutes to finally
display the result. sometimes, it will hang forever.

can you give me some links to these tutorials? if you have any.

thanks again..

On Apr 15, 3:13 pm, Thomas Broyer t.bro...@gmail.com wrote:
 On 15 avr, 13:51, ytbryan ytbr...@gmail.com wrote:

  hi folks,

  my application has been running very slowly and i would like to know
  why.

 You could try compiling in -style DETAILED (or at least PRETTY) and
 run a JavaScript profiler (Firebug or IE8 developer tools).
 GWT comes with a benchmark framework, but you'd have to know what you
 want/have to measure...

  can somebody advise me on what are the common bottleneck that i need
  to optimise? I am pretty new with gwt.

 1. optimize network exchanges (generally, you'd better have 1 RPC call
 return 3 kinds of data, than 3 RPC calls)
 2. but GWT-RPC might be slow, particularly while serializing/
 deserializing large object graphs
 3. when updating the UI, working with hidden (display:none) or, even
 better, detached widgets is faster; sometimes, building a new widget
 from scratch, populating it and replacing an existing equivalent
 widget might be faster than updating the existing widget
 4. rendering-wise, try to set table-layout:fixed on your tables
 (including Horizontal/VerticalPanel, FlexTable, Grid, DecoratorPanel,
 DecoratedPopupPanel, DialogBox, etc.)

 5. what does slow mean?
--~--~-~--~~~---~--~~
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: does com.google.gwt.dev.Compiler need to run prior to hosted mode?

2009-04-15 Thread Tony Strauss

Perhaps I'm not understanding the previous discussion completely and I
do not use NetBeans, but I do use GWT's hosted mode with the -noserver
option and enjoy the benefits of hosted mode's rapid develop/test
cycle.  All it takes for me to see a change in the client code is
hitting the hosted mode browser's reload button.

We use our own ant-based build system.  To use hosted mode, we:
1.) Do one compilation of the client code (GWTCompiler)
2.) Compile the server code.
3.) Launch our web server (Jetty, in our case)
4.) Launch hosted mode

After this, hitting reload in hosted mode reflects changes in the
client's source files (we never need to re-run GWTCompiler).  Of
course, for changes to the server code, jetty needs to reload the war
(although not for css changes, which also saves time).

Tony
--
Tony Strauss
Designing Patterns, LLC
http://www.designingpatterns.com
http://blogs.designingpatterns.com

On Apr 14, 2:12 pm, pohl pohl.longs...@gmail.com wrote:
 On Apr 13, 6:48 pm, Jeff Chimene jchim...@gmail.com wrote:



  Also, remember that GWT does not implement the entire JRE. From the
  looks of the above error, you might be hitting that limitation, i.e.
  delete method not implemented, as well.

 Well, I started with a working application, and only changed the value
 of a String.  So if it was correctly built before, such a change could
 not have introduced new API calls outside of the subset that GWT
 supports.  It looks to me like that delete method is a problem with
 low-level class reloading that may be broken on the current JDK that
 comes with MacOS X.  I've never seen that before, though.

 Vitali Lovich wrote:

  So change the ant script so that it does what you want it to.  I've never
  gone the noserver route as I've always used the embedded app server (Jetty
  in 1.6).

 Alas, this is not possible in my application.   Neither Tomcat nor
 Jetty are able to deploy EARs, let alone the stateless session beans
 and entity beans within them.   Therefore noserver is my only
 option, and therefore no quick-turnaround-via-hosted-mode love for me.

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



When does an ImageBundle get downloaded?

2009-04-15 Thread JoeB

Here's a technical question for you GWT gurus - when does the client
actually download an ImageBundle from the server?  Does this happen
during the initial GWT bootstrap sequence, when the browser- and
locale-specific JavaScript file is downloaded?  Or does it happen when
the client code eventually reaches and executes the GWT.create
(MyImages.class) line?

-- Joe
--~--~-~--~~~---~--~~
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: When does an ImageBundle get downloaded?

2009-04-15 Thread Thomas Broyer



On 15 avr, 17:15, JoeB joe.berm...@gmail.com wrote:
 Here's a technical question for you GWT gurus - when does the client
 actually download an ImageBundle from the server?  Does this happen
 during the initial GWT bootstrap sequence, when the browser- and
 locale-specific JavaScript file is downloaded?  Or does it happen when
 the client code eventually reaches and executes the GWT.create
 (MyImages.class) line?

The third and last option.
--~--~-~--~~~---~--~~
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: weekend styles and DatePicker

2009-04-15 Thread Thomas Broyer



On 15 avr, 16:49, klas klas3...@hotmail.com wrote:
 Should I use
 datepicker.setStylePrimaryName(myOwnPlain)
 ?

If you do this, you'll lose the theme style.

 After reading DatePicker source code it seems like the primary style
 will *always* be applied.
 And, by default, it will set the background-color of weekends.

the *theme* sets the style of weekends, using a CSS selector based on
the primary style defined in the code. If you don't use a theme, or
want to make your own theme, you then don't have to set a specific
primary style on the datepicker and you can just the default one
on your CSS selectors.

I bet your issue has something to do with the cascading part of CSS:
as stated here several times during the past few weeks, unless you
inject your style using a stylesheet in your module's gwt.xml, the
stylesheet from the theme you're using will override your styles
(because it'll always be inserted *after* yours, in document order).
Search the group, you'll find the answers (several possibilities;
hint: search for StandardResources)
--~--~-~--~~~---~--~~
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: Load gwt module before image are loaded on IE7

2009-04-15 Thread Vitali Lovich
if you read it, you'll notice it says that body.onload gets fired after all
resources are fetched.  this is when onModuleLoad gets fired.  there doesn't
appear to be anything wrong with that documentation.

On Wed, Apr 15, 2009 at 9:13 AM, Dominik Steiner 
dominik.j.stei...@googlemail.com wrote:


 Thanks Salvador for pointing out the interesting link above.

 I read through it and I must admit that I found an error in it, namely
 exactly my problem on IE7, that the

 img src='reallyBigImageTwo.jpg'/img

 will block on IE7 the firing of the onModuleLoad() event in GWT until
 the image has finished loading.

 I will post back once I implement a working solution.

 Thanks

 Dominik
 Am 15.04.2009 um 04:08 schrieb Salvador Diaz:

 
  I think it should be helpful to understand the bootstrap sequence,
  maybe it will inspire you to come up with a better solution and share
  it with us :)
 
 
 http://code.google.com/p/google-web-toolkit-doc-1-5/wiki/FAQ_WhenDoModulesLoad
 
  Cheers,
 
  Salvador
 
  On Apr 14, 6:55 pm, Dominik Steiner dominik.j.stei...@googlemail.com
  wrote:
  Hi,
 
  I have a page that contains a lot of images and some of those images
  take a long time to load (in total like 1 min)
 
  I have searched the forum and found this similar post
 
  http://groups.google.com/group/Google-Web-Toolkit/browse_thread/
  threa...
 
  but with no concrete solution to the problem, that IE7 will wait
  until
  all the images are loaded until it will then load the GWT module.
 
  Is there a work around for this so that the gwt module will be loaded
  before the images have finished loading? (using gwt 1.5.3)
 
  Thanks
 
  Dominik
  


 


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



Re: Load gwt module before image are loaded on IE7

2009-04-15 Thread Dominik Steiner

Ok, i must have understand something wrong then, but from the wiki i
read the last four sequences as following

9. ...cache.js completes. onModuleLoad() is not called yet, as we're
still waiting on externalScriptOne.js to complete before the document
is considered 'ready'.
10. externalScriptOne.js completes. The document is ready, so
onModuleLoad() fires.
11. reallyBigImageTwo.jpg completes.
12. body.onload() fires, in this case showing an alert() box.

So as described in the wiki the onModuleLoad will fire once the last
js script is loaded, but before the reallyBigImageTwo is loaded. This
applies to all normal browsers it seems except IE...

On 15 Apr., 09:52, Vitali Lovich vlov...@gmail.com wrote:
 if you read it, you'll notice it says that body.onload gets fired after all
 resources are fetched.  this is when onModuleLoad gets fired.  there doesn't
 appear to be anything wrong with that documentation.

 On Wed, Apr 15, 2009 at 9:13 AM, Dominik Steiner 

 dominik.j.stei...@googlemail.com wrote:

  Thanks Salvador for pointing out the interesting link above.

  I read through it and I must admit that I found an error in it, namely
  exactly my problem on IE7, that the

  img src='reallyBigImageTwo.jpg'/img

  will block on IE7 the firing of the onModuleLoad() event in GWT until
  the image has finished loading.

  I will post back once I implement a working solution.

  Thanks

  Dominik
  Am 15.04.2009 um 04:08 schrieb Salvador Diaz:

   I think it should be helpful to understand the bootstrap sequence,
   maybe it will inspire you to come up with a better solution and share
   it with us :)

 http://code.google.com/p/google-web-toolkit-doc-1-5/wiki/FAQ_WhenDoMo...

   Cheers,

   Salvador

   On Apr 14, 6:55 pm, Dominik Steiner dominik.j.stei...@googlemail.com
   wrote:
   Hi,

   I have a page that contains a lot of images and some of those images
   take a long time to load (in total like 1 min)

   I have searched the forum and found this similar post

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

   but with no concrete solution to the problem, that IE7 will wait
   until
   all the images are loaded until it will then load the GWT module.

   Is there a work around for this so that the gwt module will be loaded
   before the images have finished loading? (using gwt 1.5.3)

   Thanks

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



Re: No JSNI method generated

2009-04-15 Thread Thomas Broyer



On 15 avr, 15:25, dayre david.c.a...@gmail.com wrote:
 HI Vitali,

 Thank you for taking the time to respond.  I very much appreciate it.

 The reason i'm not using existing GWT widgets, which my example
 doesn't show, is because i'm trying to attach an onclick() event to
 ordered list items (litext/li).   There doesn't seem to be a
 widget which easily allows for this.   Someone else in this group had
 suggested they do what i was trying to do.   I'm trying to port an
 existing interface which i did in jquery() to GWT... one of the key
 components uses plain list items which i attach listeners to.

While the JSNI path is (more than) OK when prototyping your port, I'd
recommend you create a widget that suits your needs instead.
You could also (now, or as part of the widget) take advantage of event
bubbling: register a ClickHandler at the container level, look at the
ClickEvent.getNativeEvent().getEventTarget() (it should be an Element,
check with Element.is(...) and cast with Element.as(...)) and walk up
the tree (getParent) until you find a LI (elem.getTagName
().equalsIgnoreCase(LIElement.TAG)) or your widget's element
(getElement()). FYI, that's what the grids (Grid and FlexTable) in GWT
do for the cell click events.

 What you explain makes sense and your option #2 for using the jsni
 name of the java function seems the easiest.

I doubt it'll work (I'm almost sure it won't; JSNI reference resolving
is done by parsing the JavaScript code, not using regexes and find/
replace).



--~--~-~--~~~---~--~~
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: Load gwt module before image are loaded on IE7

2009-04-15 Thread Thomas Broyer



On 15 avr, 15:13, Dominik Steiner dominik.j.stei...@googlemail.com
wrote:
 Thanks Salvador for pointing out the interesting link above.

 I read through it and I must admit that I found an error in it, namely  
 exactly my problem on IE7, that the

 img src='reallyBigImageTwo.jpg'/img

 will block on IE7 the firing of the onModuleLoad() event in GWT until  
 the image has finished loading.

 I will post back once I implement a working solution.

Have a look at 
http://code.google.com/p/google-web-toolkit/wiki/LightweightMetricsDesign
to find out what exactly happens in your case (though Firebug might
give you all you want too)
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Smartgwt ListGrid Tick boxes

2009-04-15 Thread eoc...@googlemail.com

Hi,

I've written an application in gwt which makes use of smartGWT in
particular ListGrids with check boxes.
Under linux I have no problems. However using a Mac or Windows
smartgwt does not appear to have the SelectionAppearance.CHECKBOX
option and gives me an error in Eclipse.

(someResultsGrid.setSelectionAppearance
(SelectionAppearance.CHECKBOX);)

Is this a bug?

I'm using the smartgwt-1.0b2-SNAPSHOT.jar.


Thanks,

Ed

--~--~-~--~~~---~--~~
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: Load gwt module before image are loaded on IE7

2009-04-15 Thread Vitali Lovich
Try putting your script for nocache.js in your body instead of head

On Wed, Apr 15, 2009 at 11:59 AM, Dominik Steiner 
dominik.j.stei...@googlemail.com wrote:


 Ok, i must have understand something wrong then, but from the wiki i
 read the last four sequences as following

 9. ...cache.js completes. onModuleLoad() is not called yet, as we're
 still waiting on externalScriptOne.js to complete before the document
 is considered 'ready'.
 10. externalScriptOne.js completes. The document is ready, so
 onModuleLoad() fires.
 11. reallyBigImageTwo.jpg completes.
 12. body.onload() fires, in this case showing an alert() box.

 So as described in the wiki the onModuleLoad will fire once the last
 js script is loaded, but before the reallyBigImageTwo is loaded. This
 applies to all normal browsers it seems except IE...

 On 15 Apr., 09:52, Vitali Lovich vlov...@gmail.com wrote:
  if you read it, you'll notice it says that body.onload gets fired after
 all
  resources are fetched.  this is when onModuleLoad gets fired.  there
 doesn't
  appear to be anything wrong with that documentation.
 
  On Wed, Apr 15, 2009 at 9:13 AM, Dominik Steiner 
 
  dominik.j.stei...@googlemail.com wrote:
 
   Thanks Salvador for pointing out the interesting link above.
 
   I read through it and I must admit that I found an error in it, namely
   exactly my problem on IE7, that the
 
   img src='reallyBigImageTwo.jpg'/img
 
   will block on IE7 the firing of the onModuleLoad() event in GWT until
   the image has finished loading.
 
   I will post back once I implement a working solution.
 
   Thanks
 
   Dominik
   Am 15.04.2009 um 04:08 schrieb Salvador Diaz:
 
I think it should be helpful to understand the bootstrap sequence,
maybe it will inspire you to come up with a better solution and share
it with us :)
 
  http://code.google.com/p/google-web-toolkit-doc-1-5/wiki/FAQ_WhenDoMo.
 ..
 
Cheers,
 
Salvador
 
On Apr 14, 6:55 pm, Dominik Steiner 
 dominik.j.stei...@googlemail.com
wrote:
Hi,
 
I have a page that contains a lot of images and some of those images
take a long time to load (in total like 1 min)
 
I have searched the forum and found this similar post
 
   http://groups.google.com/group/Google-Web-Toolkit/browse_thread/
threa...
 
but with no concrete solution to the problem, that IE7 will wait
until
all the images are loaded until it will then load the GWT module.
 
Is there a work around for this so that the gwt module will be
 loaded
before the images have finished loading? (using gwt 1.5.3)
 
Thanks
 
Dominik
 


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



Re: File Upload with rpc call

2009-04-15 Thread Vitali Lovich
http://igstan.blogspot.com/2009/01/pure-javascript-file-upload.html

From the comments you cannot read more than 100MB (although I doubt this is
an actual restriction)  you have to read the whole file (meaning large
files will pause your program for quite a while).

More importantly, this is FF3 only, which leaves out users of any other
browser which is even worse than the flash option.

On Wed, Apr 15, 2009 at 7:12 AM, evgeniy kim.euge...@gmail.com wrote:


 Yes, you can do it only in FireFox 3, as far as I know.
 If you have FileUpload element then you can acces to file's data from
 native JavaScript.
 For example you have FileUpload and set its ID to file then
 following method returns binary data contained in file:
private native String getFileBinary() /*-{
return $doc.getElementById(file).files[0].getAsBinary();
}-*/;
 Then you are free to use returned data in RPC call or whatever you
 want.

 You can read more here: https://developer.mozilla.org/En/NsIDOMFile

 On Apr 14, 11:18 am, loudo lou...@gmail.com wrote:
  Hello
 
  Can i make a file upload with a rpc call ?
  I want to upload a file with the rpc call but i have not found
  example.
  I have only found example with submit form.
 
  Thanks a lot for your response.
 


--~--~-~--~~~---~--~~
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: File Upload with rpc call

2009-04-15 Thread Vitali Lovich
On Wed, Apr 15, 2009 at 12:39 PM, Vitali Lovich vlov...@gmail.com wrote:

 http://igstan.blogspot.com/2009/01/pure-javascript-file-upload.html

 From the comments you cannot read more than 100MB (although I doubt this is
 an actual restriction)  you have to read the whole file (meaning large
 files will pause your program for quite a while).

Sorry - meant to make it clear, particularly since this is FF specific (if
Chrome had this API, it would only apply to the tab), this will hang your
browser until the entire file is read into memory.  Only background threads
would solve this issue, but that would further lower your user base to FF
3.5  Google Gears users (assuming you created an API wrapper that supported
both).



 More importantly, this is FF3 only, which leaves out users of any other
 browser which is even worse than the flash option.


 On Wed, Apr 15, 2009 at 7:12 AM, evgeniy kim.euge...@gmail.com wrote:


 Yes, you can do it only in FireFox 3, as far as I know.
 If you have FileUpload element then you can acces to file's data from
 native JavaScript.
 For example you have FileUpload and set its ID to file then
 following method returns binary data contained in file:
private native String getFileBinary() /*-{
return $doc.getElementById(file).files[0].getAsBinary();
}-*/;
 Then you are free to use returned data in RPC call or whatever you
 want.

 You can read more here: https://developer.mozilla.org/En/NsIDOMFile

 On Apr 14, 11:18 am, loudo lou...@gmail.com wrote:
  Hello
 
  Can i make a file upload with a rpc call ?
  I want to upload a file with the rpc call but i have not found
  example.
  I have only found example with submit form.
 
  Thanks a lot for your response.
 



--~--~-~--~~~---~--~~
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 eclipse plug manual install?

2009-04-15 Thread gcr

All,

I have looked and I cannot find a link from where I can download GWT
1.6 for a manual install.  (I could also be blind.)  Is there such a
thing, or is it update site or nothing?

I am trying to upgrade to GWT 1.6.  When I attempt to do so using the
update site, It throws an error (see below).  Has anyone seen this
kind of thing before?

I have successfully upgraded two other machines.  It's only this third
box that gives me trouble.  All three machines have eclipse 3.4 on
WinXP.

An error occurred while collecting items to be installed
  Error closing the output stream for
org.eclipse.datatools.sqldevtools.data.feature/
org.eclipse.update.feature/1.6.2.v200810071455-3109oA55V589K5QA5 on
repository file:/C:/Program Files/eclipse-ganymede/.
  Error unzipping C:\DOCUME~1\groberts\LOCALS~1\Temp
\org.eclipse.datatools.sqldevtools.data.feature_1.6.2.v200810071455-3109oA55V589K5QA54838407210649109424.jar:
Invalid zip file format
  Problems downloading artifact:
osgi.bundle,org.eclipse.datatools.sqltools.data.core,
1.1.0.v200901140930.
Exception connecting to
http://download.eclipse.org/datatools/downloads/drops/N_updates/plugins/org.eclipse.datatools.sqltools.data.core_1.1.0.v200901140930.jar.
 
http://download.eclipse.org/datatools/downloads/drops/N_updates/plugins/org.eclipse.datatools.sqltools.data.core_1.1.0.v200901140930.jar
Exception connecting to
http://download.eclipse.org/datatools/downloads/drops/N_updates/plugins/org.eclipse.datatools.sqltools.data.core_1.1.0.v200901140930.jar.
 
http://download.eclipse.org/datatools/downloads/drops/N_updates/plugins/org.eclipse.datatools.sqltools.data.core_1.1.0.v200901140930.jar


--~--~-~--~~~---~--~~
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: Announcing GWT 1.6...and quite a bit more

2009-04-15 Thread Darkflame

I've changed the libs over, but when it compiles it gives the message;

WARNING: 'com.google.gwt.dev.GWTShell' is deprecated and will be
removed in a future release.
Use 'com.google.gwt.dev.HostedMode' instead.
(To disable this warning, pass -Dgwt.nowarn.legacy.tools as a JVM
arg.)


If I replace GWTShell with HostedMode on the Eclipse run dialogue main
class however, it gives an error that it dosnt recognise the -out
flag. (presumably the one in arguments telling it where my html is).

Whats the correct settings for the main class,arguments etc now in
1.6?

On Apr 9, 7:58 pm, Jason Essington jason.essing...@gmail.com wrote:
 replace your 1.5.3 libs with the 1.6 libs ...

 that's pretty much it ... if the compiler wants to put your code in  
 war/ then add the compiler flag -war www to get it back to the 1.5 way  
 of doing things ...

 from there, you should be good to go. you can migrate from listeners  
 to handlers as time allows, they are deprecated, but not removed so no  
 need to do any work if you don't want to :-)

 this really isn't that tough of an upgrade.

 -jason

 On Apr 9, 2009, at 11:48 AM, Ed wrote:





  Hi all,

  I am running in no-server mode with GWT 1.5.3

  I read bits and peaces about the changes, but still not completely
  sure how to merge to GWT 1.6.

  How/Where can I find the changes that will effect my no-server
  configuration? and what about my gwt directly structure ? I like it as
  it is and don't want it in a war :(... as I perform a separate
  deployement for the java backend and my gwt front -end.
  BTW: I am using my own Eclipse launch files to start in hosted mode...
  I think that also changes...

  Maybe it will be very easy to merge to GWT 1.6, but any tips will be
  more then welcome to overcome afterwards thoughts like If I knew
  that... 

  -- Ed
--~--~-~--~~~---~--~~
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 do I open a file on the client-side?

2009-04-15 Thread Soren Johnson

I have an XML file that is served to the client automatically by being
in the root folder of my war. How do I open in my GWT client code it
so that I can parse the contents? Or am I going about this wrong?
thanks...
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Announcing GWT 1.6...and quite a bit more

2009-04-15 Thread Vitali Lovich
Html files go into the war directory.

On Wed, Apr 15, 2009 at 1:00 PM, Darkflame darkfl...@gmail.com wrote:


 I've changed the libs over, but when it compiles it gives the message;

 WARNING: 'com.google.gwt.dev.GWTShell' is deprecated and will be
 removed in a future release.
 Use 'com.google.gwt.dev.HostedMode' instead.
 (To disable this warning, pass -Dgwt.nowarn.legacy.tools as a JVM
 arg.)


 If I replace GWTShell with HostedMode on the Eclipse run dialogue main
 class however, it gives an error that it dosnt recognise the -out
 flag. (presumably the one in arguments telling it where my html is).

 Whats the correct settings for the main class,arguments etc now in
 1.6?

 On Apr 9, 7:58 pm, Jason Essington jason.essing...@gmail.com wrote:
  replace your 1.5.3 libs with the 1.6 libs ...
 
  that's pretty much it ... if the compiler wants to put your code in
  war/ then add the compiler flag -war www to get it back to the 1.5 way
  of doing things ...
 
  from there, you should be good to go. you can migrate from listeners
  to handlers as time allows, they are deprecated, but not removed so no
  need to do any work if you don't want to :-)
 
  this really isn't that tough of an upgrade.
 
  -jason
 
  On Apr 9, 2009, at 11:48 AM, Ed wrote:
 
 
 
 
 
   Hi all,
 
   I am running in no-server mode with GWT 1.5.3
 
   I read bits and peaces about the changes, but still not completely
   sure how to merge to GWT 1.6.
 
   How/Where can I find the changes that will effect my no-server
   configuration? and what about my gwt directly structure ? I like it as
   it is and don't want it in a war :(... as I perform a separate
   deployement for the java backend and my gwt front -end.
   BTW: I am using my own Eclipse launch files to start in hosted mode...
   I think that also changes...
 
   Maybe it will be very easy to merge to GWT 1.6, but any tips will be
   more then welcome to overcome afterwards thoughts like If I knew
   that... 
 
   -- Ed
 


--~--~-~--~~~---~--~~
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: efficiency of my gwt application

2009-04-15 Thread gregor


 - the rpc is quite slow. i am using it to return a few thousand by
 eleven column of data(String)

a) RPC is *much* slower in hosted mode than deployed in web mode. You
should time your RPC performance (separately to the table draw time)
when deployed to find out how it is really performing
b) having said that, fetching several thousand rows of data and
displaying it in one operation is likely to be unacceptably slow. It
takes javascript engines quite a long time attach thousands of HTML
elements to the DOM. It is generally much faster to do it in page-
fulls even though it takes multiple RPC calls to do it that way. You
might want to check out the PagingScrollTable in the incubator.

 - i have a tabset within my application which i copied from the
 smartgwt showcase when i click on new tab with google map on
 it.. it will normally hang and need  a few minutes to finally
 display the result. sometimes, it will hang forever.


SmartGWT is a GWT wrapper around a javascript library. It might be
difficult to figure out why it is not performing well for your use
case, and very difficult to do anything about it if you can. Generally
speaking, if you use pure GWT you will get higher performance and more
flexibility and code transparency.


 can you give me some links to these tutorials? if you have any.

 thanks again..

 On Apr 15, 3:13 pm, Thomas Broyer t.bro...@gmail.com wrote:

  On 15 avr, 13:51, ytbryan ytbr...@gmail.com wrote:

   hi folks,

   my application has been running very slowly and i would like to know
   why.

  You could try compiling in -style DETAILED (or at least PRETTY) and
  run a JavaScript profiler (Firebug or IE8 developer tools).
  GWT comes with a benchmark framework, but you'd have to know what you
  want/have to measure...

   can somebody advise me on what are the common bottleneck that i need
   to optimise? I am pretty new with gwt.

  1. optimize network exchanges (generally, you'd better have 1 RPC call
  return 3 kinds of data, than 3 RPC calls)
  2. but GWT-RPC might be slow, particularly while serializing/
  deserializing large object graphs
  3. when updating the UI, working with hidden (display:none) or, even
  better, detached widgets is faster; sometimes, building a new widget
  from scratch, populating it and replacing an existing equivalent
  widget might be faster than updating the existing widget
  4. rendering-wise, try to set table-layout:fixed on your tables
  (including Horizontal/VerticalPanel, FlexTable, Grid, DecoratorPanel,
  DecoratedPopupPanel, DialogBox, etc.)

  5. what does slow mean?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: How do I open a file on the client-side?

2009-04-15 Thread Jeff Chimene

On 04/15/2009 10:06 AM, Soren Johnson wrote:
 I have an XML file that is served to the client automatically by being
 in the root folder of my war. How do I open in my GWT client code it
 so that I can parse the contents? Or am I going about this wrong?
 thanks...

Javascript cannot read/write client-side files [1]. There's nothing 
inherent in GWT that changes that behavior. Absent 3rd party tools, 
you'll have to deploy the XML file to your server, use RequestBuilder() 
to retrieve the contents, and XMLParser() to turn it into a Document 
instance.




[1]
   unless you use Flash, Gears or some other 3rd party library

--~--~-~--~~~---~--~~
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: Announcing GWT 1.6...and quite a bit more

2009-04-15 Thread Darkflame

I've changed the libs over in eclipse, but when it compiles it gives
the message;

WARNING: 'com.google.gwt.dev.GWTShell' is deprecated and will be
removed in a future release.
Use 'com.google.gwt.dev.HostedMode' instead.
(To disable this warning, pass -Dgwt.nowarn.legacy.tools as a JVM
arg.)


If I replace GWTShell with HostedMode on the Eclipse run dialogue main
class however, it gives an error that it dosnt recognise the -out
flag. (presumably the one in arguments telling it where my html is).

Whats the correct settings for the main class,arguments etc now in
1.6?
So I can remove this message.


On Apr 9, 7:58 pm, Jason Essington jason.essing...@gmail.com wrote:
 replace your 1.5.3 libs with the 1.6 libs ...

 that's pretty much it ... if the compiler wants to put your code in  
 war/ then add the compiler flag -war www to get it back to the 1.5 way  
 of doing things ...

 from there, you should be good to go. you can migrate from listeners  
 to handlers as time allows, they are deprecated, but not removed so no  
 need to do any work if you don't want to :-)

 this really isn't that tough of an upgrade.

 -jason

 On Apr 9, 2009, at 11:48 AM, Ed wrote:





  Hi all,

  I am running in no-server mode with GWT 1.5.3

  I read bits and peaces about the changes, but still not completely
  sure how to merge to GWT 1.6.

  How/Where can I find the changes that will effect my no-server
  configuration? and what about my gwt directly structure ? I like it as
  it is and don't want it in a war :(... as I perform a separate
  deployement for the java backend and my gwt front -end.
  BTW: I am using my own Eclipse launch files to start in hosted mode...
  I think that also changes...

  Maybe it will be very easy to merge to GWT 1.6, but any tips will be
  more then welcome to overcome afterwards thoughts like If I knew
  that... 

  -- Ed
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Postgres

2009-04-15 Thread Marcos Robson

Hi,

I'm new in world of gwt and i need a help for access the DataBase.
Where can I find tutorial for connection postgres with gwt

thx

Marcos

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



error in RemoteServiceServlet

2009-04-15 Thread sith

Hi All!

I have got problem error 500 with RPC service.

my RPC Class

public class ComputersListServiceImpl extends RemoteServiceServlet
implements ComputersListService {

@Override
public String[][] getComputersList() {
//  COBExplorer explorer = ExplorerHelper.getExplorer
(getThreadLocalRequest());

TestCOBExplorer explorer = new TestCOBExplorer();

ListCOBResource list = explorer.list(PathConstants.ROOT_PATH);

COBResourceHelper.clearNotIntrestingResource(list);

String[][] computers = new String[list.size()][2];

for (int i = 0; i  list.size(); i++) {
COBResource resource = list.get(i);
computers[i][0] = resource.getName();
computers[i][1] = resource.getPath();

}
return computers;
}



}


and then i run my app i recived error message

SEVERE: Exception while dispatching incoming RPC call
java.io.IOException: Stream closed
at org.apache.catalina.connector.InputBuffer.read(InputBuffer.java:
325)
at org.apache.catalina.connector.CoyoteInputStream.read
(CoyoteInputStream.java:193)
at com.google.gwt.user.server.rpc.RPCServletUtils.readContentAsUtf8
(RPCServletUtils.java:146)
at com.google.gwt.user.server.rpc.RemoteServiceServlet.readContent
(RemoteServiceServlet.java:343)
at com.google.gwt.user.server.rpc.RemoteServiceServlet.doPost
(RemoteServiceServlet.java:77)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter
(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter
(ApplicationFilterChain.java:206)
at com.comodo.onlinebackup.web.servlets.AuthFilter.doFilter
(AuthFilter.java:54)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter
(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter
(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke
(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke
(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke
(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke
(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke
(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service
(CoyoteAdapter.java:286)
at org.apache.coyote.http11.Http11Processor.process
(Http11Processor.java:845)
at org.apache.coyote.http11.Http11Protocol
$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:
447)
at java.lang.Thread.run(Thread.java:619)
Apr 15, 2009 11:42:37 AM org.apache.catalina.core.StandardWrapperValve
invoke
SEVERE: Servlet.service() for servlet computersListServiceServlet
threw exception
java.lang.IllegalStateException: getOutputStream() has already been
called for this response
at org.apache.catalina.connector.Response.getWriter(Response.java:
610)
at org.apache.catalina.connector.ResponseFacade.getWriter
(ResponseFacade.java:198)
at
com.google.gwt.user.server.rpc.RPCServletUtils.writeResponseForUnexpectedFailure
(RPCServletUtils.java:255)
at
com.google.gwt.user.server.rpc.RemoteServiceServlet.doUnexpectedFailure
(RemoteServiceServlet.java:285)
at com.google.gwt.user.server.rpc.RemoteServiceServlet.doPost
(RemoteServiceServlet.java:99)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter
(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter
(ApplicationFilterChain.java:206)
at com.comodo.onlinebackup.web.servlets.AuthFilter.doFilter
(AuthFilter.java:54)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter
(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter
(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke
(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke
(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke
(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke
(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke
(StandardEngineValve.java:109)
at 

JAXB generated classes under GWT

2009-04-15 Thread RalfM

I also tried to use JAXB generated classes in GWT. When i add the JAXB
Sources to the GWT Compiler it works with a lot of errors. But when i
tried to use some imports( import
javax.xml.bind.annotation.XmlElement; import
javax.xml.bind.annotation.XmlRootElement;) the compiler fails.

Has anyone a solution to use JAXB generated classes in GWT?

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



Environment variables for servlet in hosted mode

2009-04-15 Thread confusion

I just upgraded to GWT 1.6 and have the following problem. The servlet
of my web app calls a native application on the server. In order to
test this on my local machine I had used environment variables to
specify where the binary resides.
With GWT 1.5 I could set them in my Eclipse launch config for
debugging in hosted mode on my local machine and as init parameters in
the web.xml file for the deployed version running on the web server.

So my RemoteServiceServlet contains this init method:

public void init(ServletConfig config) throws ServletException{
  super.init(config);
  myapp_cmd = config.getInitParameter(MYAPP_CMD);
  myapp_param = config.getInitParameter(MYAPP_PARAM);
  output_dir = config.getInitParameter(OUTPUT_DIR);

  if (myapp_cmd == null) {
myapp_cmd = System.getenv(MYAPP_CMD);
  }
  if (myapp_param == null) {
myapp_param = System.getenv(MYAPP_PARAM);
  }
  if (output_dir == null) {
output_dir = System.getenv(OUTPUT_DIR);
  }
}

GWT 1.6 seems to load the web.xml file even when running in hosted
mode, thereby breaking my code. I searched the help for information on
the issue, but couldn't find anything. Could someone tell me how I
should include these parameters/environment variables instead?

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



Re: How to include javascript files in GWT with eclipse plugin?

2009-04-15 Thread TimOnGmail

Well, what I was concerned with was, in Hosted mode, Eclipse making
sure to copy local JS resources into the desired place in the target
folder in the 'war' hierarchy.

I found the answer to my problem, however:

1. Put my 'js' folder in myProject/war/WEB-INF/classes/com/mycompany/
myproject/web/public
2. The references in the .gwt.xml file used relative paths 'js/...'

The GWT builder in Eclipse then copied everything in 'js' to myproject/
war/mymodule/js

I don't know why it works this way, but it does.

- Tim

On Apr 15, 3:15 am, Salvador Diaz diaz.salva...@gmail.com wrote:
 If all you want to do is include some external js 
 files:http://code.google.com/docreader/#p=google-web-toolkit-doc-1-5s=goog...
 If you're looking at including jars in your war, it could be worth to
 look at something for managing your dependencies (like 
 maven):http://maven.apache.org

 Cheers,

 Salvador

 On Apr 14, 9:58 pm, TimOnGmail timbes...@gmail.com wrote:



  Hi all...

  I'm using GWT-EXT, and it needs to be copied into war/js/ext every
  time I build my project.  However, every time I build my project, it
  gets deleted and I have to copy it manually.

  Does anyone know where I would put the ext folder - or what files I
  modify to point to it - so that the Eclipse plugin will copy it for
  every build?

  - Tim- Hide quoted text -

 - Show quoted text -
--~--~-~--~~~---~--~~
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: Problem in downloading Google Plugin for Eclipse

2009-04-15 Thread Keith Platfoot

Hi Sandeep,

The URLs are working, although it may not appear so if you navigate
directly to them in a web browser.  These URLs are Eclipse update
sites, which means you'll need to use Eclipse's update mechanism to
install the plugin.  See the documentation for Eclipse 3.3 (http://
code.google.com/eclipse/docs/install-eclipse-3.3.html) or Eclipse 3.4
(http://code.google.com/eclipse/docs/install-eclipse-3.4.html).

From a web browser, these URLs will indeed produce a 404, even when
the update site is ok.  To test them from a browser, just tack on /
site.xml to the end of the URL, and you should see a short message
indicating that you're hitting the Google plugin update site.

Keith

On Apr 14, 3:56 am, sandeepla...@gmail.com sandeepla...@gmail.com
wrote:
 Hello ,
    I am trying to download Google Plug-in for Eclipse using below
 URLs , which seems not working.

 Eclipse 3.3 (Europa)http://dl.google.com/eclipse/plugin/3.3
 Eclipse 3.4 (Ganymede)http://dl.google.com/eclipse/plugin/3.4

 Both the URLs are not working.

 Can someone please provide guidelines to download this plug in  ?

 Thanks
 Sandeep S. Lawar

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



Re: GWT eclipse plug manual install?

2009-04-15 Thread Keith Platfoot

GWT 1.6 download: http://code.google.com/webtoolkit/download.html

Keith

On Apr 15, 12:45 pm, gcr geoffry.robe...@gmail.com wrote:
 All,

 I have looked and I cannot find a link from where I can download GWT
 1.6 for a manual install.  (I could also be blind.)  Is there such a
 thing, or is it update site or nothing?

 I am trying to upgrade to GWT 1.6.  When I attempt to do so using the
 update site, It throws an error (see below).  Has anyone seen this
 kind of thing before?

 I have successfully upgraded two other machines.  It's only this third
 box that gives me trouble.  All three machines have eclipse 3.4 on
 WinXP.

 An error occurred while collecting items to be installed
   Error closing the output stream for
 org.eclipse.datatools.sqldevtools.data.feature/
 org.eclipse.update.feature/1.6.2.v200810071455-3109oA55V589K5QA5 on
 repository file:/C:/Program Files/eclipse-ganymede/.
   Error unzipping C:\DOCUME~1\groberts\LOCALS~1\Temp
 \org.eclipse.datatools.sqldevtools.data.feature_1.6.2.v200810071455-3109oA5 
 5V589K5QA54838407210649109424.jar:
 Invalid zip file format
   Problems downloading artifact:
 osgi.bundle,org.eclipse.datatools.sqltools.data.core,
 1.1.0.v200901140930.
     Exception connecting 
 tohttp://download.eclipse.org/datatools/downloads/drops/N_updates/plugi

 http://download.eclipse.org/datatools/downloads/drops/N_updates/plugi...
     Exception connecting 
 tohttp://download.eclipse.org/datatools/downloads/drops/N_updates/plugi

 http://download.eclipse.org/datatools/downloads/drops/N_updates/plugi...
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Problem matching an empty cell in a Grid

2009-04-15 Thread Daniel

Hi all

I hope that you can help me with a small issue I am having.

Basically I am trying to get my program to return true when a cell in
a grid is empty. I have found that if I print the contents of the
'empty' grid to console it is a single space character but if I try to
match it to that it returns false!

Here is a copy of my code:

String s = t.getText(1, 1); //the empty cel in the grid
String r =  ; //a string with just a single space

boolean b = t.getText(1, 1).equals(r);
System.out.println(Empty:  + b);

This outputs: Empty: false
in the console

I have tried matching a cell that has data in it and this returns true
which is confusing me!

Here is that copy:
boolean b2 = t.getText(3, 1).equals(event1);
System.out.println(Event1:  + b2);

This outputs: Event1: true
in console

Any help will be greatly appreciated!

--~--~-~--~~~---~--~~
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: Two clients one session

2009-04-15 Thread davidst...@gmail.com

Thank you for explanations.
Can you just to tell a little bit more about sharing a cookie
 cache/address space.
How can i configure clients to make them use separate cookie space ?

On Apr 15, 2:05 am, Dean S. Jones deansjo...@gmail.com wrote:
 Sessions are usually bound to a browser, for a given host/Application
 Context(war), by a Cookie ( likely called JSESSIONID ), if the two
 browsers share a cookie cache/address space, they'll see the same
 session cookie, and share the same session.

 On Apr 13, 6:40 am, davidst...@gmail.com davidst...@gmail.com
 wrote:

  Hi.
  While trying to test my app, i open two clients in Hosted Mode.
  After i log, i return to the client the session id

  HttpSession session = getThreadLocalRequest().getSession(true);
  session.setAttribute( userId, id );
  return session.getId();

  The problem is, that GWT does not open new session for the second
  client, but
  reuses the session that was opened for the previous one.

  Does any body have any idea why does it happens ?
  Does it depend on the mode ?
  Thanks.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Two clients one session

2009-04-15 Thread davidst...@gmail.com

To speak the truth i don't know about what video you are talking
about,
but I'm quite satisfied that the topics title sounds clever 

On Apr 15, 2:38 am, matttai matt...@hotmail.com wrote:
 I was unsure if this topic title was a clever play on a popular video
 circulating the internet. If so very clever :)
--~--~-~--~~~---~--~~
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: Postgres

2009-04-15 Thread salvador.ce
Hello Marcos,

  Access to the database to be with gwt servlet.



2009/4/15 Marcos Robson marcos...@gmail.com


 Hi,

 I'm new in world of gwt and i need a help for access the DataBase.
 Where can I find tutorial for connection postgres with gwt

 thx

 Marcos

 



-- 
Carlos Salvador
Consultor BI / SAP BW BPS
021-8426-8120
011-9579-7865

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



Re: GWT Serialization with CustomFieldSerializer fails because of SerializationPolicy

2009-04-15 Thread Daniel Kurka
The problem is that the compiler will create the code for al objects in the
classpath that implement serialiazable (which are more ore less 1+).
This results in enormous compile time and huge javascript...

absolutely not doable

any more suggestions?

2009/4/15 Salvador Diaz diaz.salva...@gmail.com


  perhaps can we use annotations like @gwt.typeArgs

 Those are deprecated, you should really avoid using them

a simple java class containing a MapString,Object

 Can't you just use a MapString, Serializable ? If the map is going
 to be travelling through RPCs you really shouldn't be putting objects
 that don't implement Serializable into it.

 Cheers,

 Salvador

 
   For every service gwt has a list of classes which can be Serialized
   (whitelist). If my understanding is right this list is generated by the
   compiler at compile time by analizing the members of a class.
 
   But we can have classes (which ARE serializable) inside our transient
 map,
   but gwt will not serialize this classes because of the
 SerializationPolicy
   (these classes could not be found by the compiler at compile time).
 
   Is there any way to extend the white list of SerializationPolicy.java ?
 
   If I add all classes as private members to my class the members are
 found
   and the class can be serialized, but this is anoying and we cant do
 this for
   all classes (we dynamically decide which classes we need to transfer)
 
   Anyone got any expierence with that?
 
   Maybe open an issue about this?
 


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



Re: GWT 1.6 with Maven and build system questions/survey...

2009-04-15 Thread Benju

On second though I think I agree with Salvador.  Looking closer at the
Codehaus plugin it should do the job job in the long term.

On Apr 15, 1:20 am, Salvador Diaz diaz.salva...@gmail.com wrote:
    Who agrees that having a solid,
   feature complete Maven plugin from Google would increase adoption of
   GWT faster than anything?

 I think the google team is focusing in the basics first, and that
 implies not being able to deliver all the goodies at the same time, I
 think it all fits rather nicely with the agile mantra: deliver early,
 deliver often. If they tried delivering the Eclipse plugin (and all
 other popular IDEs' plugins for that matter) and the maven plugin at
 the same time they deliver the actual product (GWT) they couldn't
 possibly deliver that often. Not to mention that they don't seem to be
 maven people, they're rather ant users, so why not leave it to the
 community, in true open source spirit, to build the tools they need,
 they even help out when there's something that doesn't work nicely
 with our tools (one of the issues resolved in 1.6 was specifically
 adressed to allow a nicer maven integration), I don't think we can
 possibly ask for more cooperation from them.

  Maybe file an enhancement request?

 I totally agree with Jeff, if you think a great maven plugin would
 help with adoption, why not try the one from the mojo project (which
 is quite nice by the way) and report any issues that you find with it.
 I don't think we can have a more official plugin than that (after all,
 they're the maven experts, not google )

 Cheers,

 Salvador
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Is it possible to extend a Popup or DialogBox to detect when its moved?

2009-04-15 Thread darkflame

umm..what the title says  ;)

I just want to trigger some realignment of stuff when the user stops
dragging.



--~--~-~--~~~---~--~~
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: Is it possible to extend a Popup or DialogBox to detect when its moved?

2009-04-15 Thread Vitali Lovich
id 
*onMouseDownhttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/DialogBox.html#onMouseDown%28com.google.gwt.user.client.ui.Widget,%20int,%20int%29
*(Widgethttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/Widget.html
sender,
int x, int y)
  Fired when the user depresses the mouse button over a widget.
 void 
*onMouseEnterhttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/DialogBox.html#onMouseEnter%28com.google.gwt.user.client.ui.Widget%29
*(Widgethttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/Widget.html
 sender)
  Fired when the mouse enters a widget's area.   void
*onMouseLeavehttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/DialogBox.html#onMouseLeave%28com.google.gwt.user.client.ui.Widget%29
*(Widgethttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/Widget.html
 sender)
  Fired when the mouse leaves a widget's area.   void
*onMouseMovehttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/DialogBox.html#onMouseMove%28com.google.gwt.user.client.ui.Widget,%20int,%20int%29
*(Widgethttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/gwt/user/client/ui/Widget.html
sender,
int x, int y)
  Fired when the user moves the mouse over a widget.
You have to override them yourself seeing as how it doesn't have support for
this.

On Wed, Apr 15, 2009 at 4:08 PM, darkflame darkfl...@gmail.com wrote:


 umm..what the title says  ;)

 I just want to trigger some realignment of stuff when the user stops
 dragging.



 


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



Trouble with asynchronous calls

2009-04-15 Thread badgerduke

Hello:

Just started using GWT and I am having difficult tailoring my code to
the asynchronous nature of RPC calls.  Specifically, my code asks for
the results of an RPC call before anything is returned.

Here is my class which calls a service.  Instead of using an inner
class for the AsyncCallback, I use a separate implementation,
FormAsyncCallback, whose code is also below:


package com.gallup.client;

import com.google.gwt.core.client.GWT;
import com.google.gwt.user.client.rpc.AsyncCallback;
import com.google.gwt.user.client.rpc.ServiceDefTarget;

public class FormService {

public String call(FormBean formBean) throws FormException{

FormRemoteServiceAsync serviceProxy = (FormRemoteServiceAsync)
GWT.create(FormRemoteService.class);
ServiceDefTarget target = (ServiceDefTarget) serviceProxy;

String serviceURL = GWT.getModuleBaseURL() + formservice;
if (GWT.isScript()) {
serviceURL = /Struts2GWT/formservice;
}
target.setServiceEntryPoint(serviceURL);

final String successMessage = null;

FormAsyncCallback callback = new FormAsyncCallback();

serviceProxy.setForm(formBean, callback);

if (!callback.isHadError()) {
GWT.log(A, null);
return callback.getSuccessMessage();
}
else {
throw new FormException(callback.getErrorMessage());
}
}

}


package com.gallup.client;

import com.google.gwt.core.client.GWT;
import com.google.gwt.user.client.rpc.AsyncCallback;

public class FormAsyncCallback implements AsyncCallback {


private String successMessage = null;
private boolean hadError = false;
private String errorMessage = null;

public void onFailure(Throwable t) {
hadError = true;
GWT.log(, null);
errorMessage = t.getMessage();
}

public void onSuccess(Object result) {
GWT.log(C, null);
successMessage = (String) result;

}

public String getSuccessMessage() {
return successMessage;
}

public boolean isHadError() {
return hadError;
}

public String getErrorMessage() {
return errorMessage;
}
public boolean isReturned() {
return returned;
}

}



My problem is that AAA  always prints before B or
CCC.   I really want my code to wait for the RPC call to return
before I interrogate the results.  Does anybody have suggestions?

Thanks
Eric
--~--~-~--~~~---~--~~
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: Is it possible to extend a Popup or DialogBox to detect when its moved?

2009-04-15 Thread Darkflame

I'm not sure precisely how to override in this case though.

I see the onMouseUp event in the class, and I try putting this into my
widget (which extends DialogBox).

@Override
public void onMouseUp(Widget sender, int x, int y) {
dragging = false;
DOM.releaseCapture(getElement());
  }

(basicaly an exact copy of whats in the class's over mouseup event).

However;
a) dragging is not visible error
b) It says onMouseUp is depreciated anyway and to use endDragging.

(Looking at enddragging;

protected void endDragging(MouseUpEvent event) {
onMouseUp(caption, event.getX(), event.getY());
  }

)



On Apr 15, 10:19 pm, Vitali Lovich vlov...@gmail.com wrote:
 id 
 *onMouseDownhttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
 *(Widgethttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
 sender,
 int x, int y)
           Fired when the user depresses the mouse button over a widget.
  void 
 *onMouseEnterhttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
 *(Widgethttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
  sender)
           Fired when the mouse enters a widget's area.   void
 *onMouseLeavehttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
 *(Widgethttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
  sender)
           Fired when the mouse leaves a widget's area.   void
 *onMouseMovehttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
 *(Widgethttp://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
 sender,
 int x, int y)
           Fired when the user moves the mouse over a widget.
 You have to override them yourself seeing as how it doesn't have support for
 this.



 On Wed, Apr 15, 2009 at 4:08 PM, darkflame darkfl...@gmail.com wrote:

  umm..what the title says  ;)

  I just want to trigger some realignment of stuff when the user stops
  dragging.
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Add Checkbox item inside GWT Listbox

2009-04-15 Thread Ghostcoder

How can we add Checkbox item inside Listbox ,is it available ?.I
googled but couldn't find anything useful.

Today the Listbox  takes only String as arg in addItem ,is it possible
to have addItem(Widget widget) if so how ?

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



Re: GWT 1.6 with Maven and build system questions/survey...

2009-04-15 Thread Daniel Kurka
I invested more ore less 8h and dont have a wokring configuration of the
trunk of the mojo gwt plugin and gwt 1.6

Some things work, but many don't. Kinda anoying...

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



Re: Smartgwt ListGrid Tick boxes

2009-04-15 Thread Sanjiv Jivan
Hi Ed,
You probably have a stale jar as the API exists. Try getting a new download,
or use the one from your linux box.

If you're still having issues, please post on the SmartGWT forum :
http://forums.smartclient.com/forumdisplay.php?f=14

Sanjiv

On Wed, Apr 15, 2009 at 12:16 PM, eoc...@googlemail.com 
eoc...@googlemail.com wrote:


 Hi,

 I've written an application in gwt which makes use of smartGWT in
 particular ListGrids with check boxes.
 Under linux I have no problems. However using a Mac or Windows
 smartgwt does not appear to have the SelectionAppearance.CHECKBOX
 option and gives me an error in Eclipse.

 (someResultsGrid.setSelectionAppearance
 (SelectionAppearance.CHECKBOX);)

 Is this a bug?

 I'm using the smartgwt-1.0b2-SNAPSHOT.jar.


 Thanks,

 Ed

 


--~--~-~--~~~---~--~~
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: efficiency of my gwt application

2009-04-15 Thread Jason Essington


On Apr 15, 2009, at 8:51 AM, ytbryan wrote:

 thanks for your reply thomas. for me, there is two cases of slowness.

 - the rpc is quite slow. i am using it to return a few thousand by
 eleven column of data(String)

There are probably two issues here, one the speed of the RPC, and the  
second the speed of populating the table.

But at issue is the attempt to return 33,000 cells worth of data in  
one shot. how much of this data is going to be immediately visible to  
the user? How likely is the user to use all of this data immediately?  
Does your use case present you the opportunity to fetch this data in  
some paged way?

you need to figure out how much of your time is spent with the RPC  
(deserialization) and how much is spent rendering the table. I would  
be inclined to believe that you are likely to find that most of the  
time is actually spent rendering the 33,000 cells. however you do have  
some options here.
You can move the rendering into an IncrementalCommand which will draw  
a few rows at a time which gives the appearance of a much more  
responsive application, and will begin rendering immediately, rather  
than waiting until all rows are populated before showing the data on  
screen.

If your RPC data graph is pretty large, you could switch away from RPC  
and use a JSON data graph with Javascript Overlay types on the client  
side. a javascript eval() of the object graph from JSON is quite a bit  
(like orders of magnitude) faster than RPC deserialization with very  
large object graphs. NOTE your design shouldn't rely on large object  
graphs, paging is a much better option.

And as gregor mentioned, if you are profiling your code in hosted  
mode, the performance has no correlation with real life. you need to  
check the performance in web mode, and remember that something that  
happens instantaneously in Firefox or Safari (or chrome) could take  
forever in IE (particularly IE6), its javascript engine operates at a  
glacial speed when compared to other options.

 thanks again..

good luck

-jason

--~--~-~--~~~---~--~~
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 to create GWT Bar Chart from Database data

2009-04-15 Thread Sam

Hi,

Can somebody suggest me how to create a GWT Bar Chart or Pie Chart
which get populated from Database dynamically by querying the
database? The charts should get refreshed every 5 min. Also, which API
to use in this regard.

Any help is highly appreciated!

Thanks,
Sam

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



1.6 Compile problem on Mac OSX

2009-04-15 Thread Dave Finch

Hi,

I am using the new eclipse (3.4) plugin with GWT 1.6.4 on Mac OSX
10.5.

Everything works great when my project is using Java 5 but when I
switch to Java 6 and try to GWT compile I get the following error:

Invalid memory access of location  rip=01160767

This is a problem for me because I want to use a server side library
that depends on Java 6.

I have had a search through the issue log and the groups but haven't
found anyone with a similar problem - am I doing something wrong?

Does anyone know whether this is a known issue or a possible work
around?

Thanks in advance,
Dave
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Vertical MenuBar and IE cellspacing

2009-04-15 Thread David Durham

I have an issue where I'd like to remove the cellspacing on a vertical
MenuBars underlying Table element.  In firefox, I can accomplish this
with css: border-spacing: 0px;, but this does not appear to work in
IE.  Has anyone on this list ran into this issue and have a good fix
for it?

Thanks.

-Dave

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



Re: GWT Serialization with CustomFieldSerializer fails because of SerializationPolicy

2009-04-15 Thread fvisticot

I have exactly the same issue with post:
http://groups.google.com/group/Google-Web-Toolkit/browse_thread/thread/1b7e3851b943b130/2aa2077f4e6c90e1#2aa2077f4e6c90e1

I have used the Serializable solution but my code/library contains a
lot of Serializable classes as well... I really would like to avoid
this solution...
Is it not possible:
1. to implement the SerializationPolicy and add the class that are
Serializable.
2. define annotations in the RPC service with allowed Serializable
objects.

Fred

On Apr 15, 9:30 pm, Daniel Kurka kurka.dan...@googlemail.com wrote:
 The problem is that the compiler will create the code for al objects in the
 classpath that implement serialiazable (which are more ore less 1+).
 This results in enormous compile time and huge javascript...

 absolutely not doable

 any more suggestions?

 2009/4/15 Salvador Diaz diaz.salva...@gmail.com





   perhaps can we use annotations like @gwt.typeArgs

  Those are deprecated, you should really avoid using them

 a simple java class containing a MapString,Object

  Can't you just use a MapString, Serializable ? If the map is going
  to be travelling through RPCs you really shouldn't be putting objects
  that don't implement Serializable into it.

  Cheers,

  Salvador

For every service gwt has a list of classes which can be Serialized
(whitelist). If my understanding is right this list is generated by the
compiler at compile time by analizing the members of a class.

But we can have classes (which ARE serializable) inside our transient
  map,
but gwt will not serialize this classes because of the
  SerializationPolicy
(these classes could not be found by the compiler at compile time).

Is there any way to extend the white list of SerializationPolicy.java ?

If I add all classes as private members to my class the members are
  found
and the class can be serialized, but this is anoying and we cant do
  this for
all classes (we dynamically decide which classes we need to transfer)

Anyone got any expierence with that?

Maybe open an issue about this?- Hide quoted text -

 - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



RPC

2009-04-15 Thread Chakroun.M

Hi

I have 2 project : ejb and gwt(rpc asynchronous)

i would to execute one methode from ejb to gwt(serviceimpl  server)

I have executed a methode but it show me this message
[WARN] StandardContext[]Exception while dispatching incoming RPC call
ejb


HOW EXECUTE A QUERY FROM EJB PROJECT IN GWT PROJECT WITH RPC-ASYNCH
RONOUS

thinks



--~--~-~--~~~---~--~~
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: Trouble with asynchronous calls

2009-04-15 Thread Ian Petersen

On Wed, Apr 15, 2009 at 1:22 PM, badgerduke badgerd...@gmail.com wrote:
 Just started using GWT and I am having difficult tailoring my code to
 the asynchronous nature of RPC calls.  Specifically, my code asks for
 the results of an RPC call before anything is returned.

 Here is my class which calls a service.  Instead of using an inner
 class for the AsyncCallback, I use a separate implementation,
 FormAsyncCallback, whose code is also below:


 package com.gallup.client;

 import com.google.gwt.core.client.GWT;
 import com.google.gwt.user.client.rpc.AsyncCallback;
 import com.google.gwt.user.client.rpc.ServiceDefTarget;

 public class FormService {

        public String call(FormBean formBean) throws FormException{

                FormRemoteServiceAsync serviceProxy = (FormRemoteServiceAsync)
 GWT.create(FormRemoteService.class);
                ServiceDefTarget target = (ServiceDefTarget) serviceProxy;

                String serviceURL = GWT.getModuleBaseURL() + formservice;
                if (GWT.isScript()) {
                        serviceURL = /Struts2GWT/formservice;
                }
                target.setServiceEntryPoint(serviceURL);

                final String successMessage = null;

                FormAsyncCallback callback = new FormAsyncCallback();

                serviceProxy.setForm(formBean, callback);

                if (!callback.isHadError()) {
                        GWT.log(A, null);
                        return callback.getSuccessMessage();
                }
                else {
                        throw new FormException(callback.getErrorMessage());
                }
        }

 }


 package com.gallup.client;

 import com.google.gwt.core.client.GWT;
 import com.google.gwt.user.client.rpc.AsyncCallback;

 public class FormAsyncCallback implements AsyncCallback {


        private String successMessage = null;
        private boolean hadError = false;
        private String errorMessage = null;

        public void onFailure(Throwable t) {
                hadError = true;
                GWT.log(, null);
                errorMessage = t.getMessage();
        }

        public void onSuccess(Object result) {
                GWT.log(C, null);
                successMessage = (String) result;

        }

        public String getSuccessMessage() {
                return successMessage;
        }

        public boolean isHadError() {
                return hadError;
        }

        public String getErrorMessage() {
                return errorMessage;
        }
        public boolean isReturned() {
                return returned;
        }

 }



 My problem is that AAA  always prints before B or
 CCC.   I really want my code to wait for the RPC call to return
 before I interrogate the results.  Does anybody have suggestions?

Change your mind.  No, seriously.  Read
http://groups.google.com/group/Google-Web-Toolkit/browse_thread/thread/faca1575f306ba0f?pli=1
and then figure out how to redesign your app to be asynchronous.
Chances are you're going to want to pass an instance of an anonymous
inner class as the AsyncCallback and have it delegate in onSuccess or
onFailure to business logic somewhere else.

One thing that might help you is to think of RPC in an event-oriented
manner.  You're presumably already comfortable handling button-clicks
and widget-focuses.  Start thinking about RPC responses as events that
happen sometime after their corresponding requests.  Build your app
around this line of thought and your life will be much easier.
Perhaps more importantly, your user's lives will be at least tolerable
(which they won't be if you force your RPCs to be synchronous).

Ian

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



Re: GWT 1.6, JSP's wont compile.

2009-04-15 Thread Ken

Wow, thanks for this tip!  I've been meaning to explore App Engine,
and this gave me even more reason to.  I just tested it all out and it
works like a charm.  I was worried it wouldn't allow the quick
turnaround, but you can use GWT hosted mode with it.  They did a
really sweet job with this.

Thank you also for filing the bug report.  You got the gist of it.
It's not just generics, it's other 1.5+ features too (like for each
loops) but it's probably not a huge deal.

Thanks,
Ken

On Apr 15, 10:48 am, Miguel Méndez mmen...@google.com wrote:
 It looks like it is a bug with Jetty instance used when a GWT-only web app
 has JSPs with generics.
 It does not appear that the App Engine
 devserverhttp://code.google.com/appengine/docs/java/tools/devserver.html
 has
 this problem.  I went ahead and filed a bug against GWT for this,
 Issue 3557http://code.google.com/p/google-web-toolkit/issues/detail?id=3557.
  As a workaround, you could add App Engine to your project.



 On Wed, Apr 15, 2009 at 9:15 AM, Ken kenfehl...@gmail.com wrote:

  The app server is the one bundled with GWT hosted mode, I believe it's
  Jetty.  If you use a servlet that has 1.5 stuff in it, it works fine.
  When I was investigating, I noticed that the JSP does successfully
  produce a servlet.  I copied this servlet and compiled it myself and
  it worked fine, even in hosted mode.  I believe it's failing at the
  point where the generated servlet (.java) is being compiled into a
  class (.class).  Like you said, it seems like for some reason it's
  targeting version 1.4 or something like that.  It's confusing though
  that the problem is during compilation, because if you start with a
  servlet (rather than a JSP) it compiles with no problem.

  I have a feeling this might have something to do with it:
 http://code.google.com/p/google-web-toolkit/source/detail?r=5109

  It appears that something different happens underneath when a servlet
  is compiled as opposed to when a servlet generated by a JSP is
  compiled.

  On Apr 15, 7:31 am, Salvador Diaz diaz.salva...@gmail.com wrote:
   It looks like the app server on which you're trying to load the jsp
   doesn't support java 1.5 or you compiled your jsp with 1.4 or
   something like that. Can't really tell without more details though. I
   hope that helps you.

   Cheers,

   Salvador

   On Apr 15, 4:13 am, Adrian ahay...@gmail.com wrote:

Ok, so it's not just me!

Does anyone have any idea on how to go about finding an answer to this
problem? Even if you don't know the answer any suggestions are welcome
because this one has me stumped.

- Adrian

On Apr 14, 3:23 pm, Ken kenfehl...@gmail.com wrote:

 I'm having the same exact problem.
 I've tried it on both Mac OS X and Windows.

 --
 Miguel
--~--~-~--~~~---~--~~
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: Relative Position of a Widget

2009-04-15 Thread Vitali Lovich
Try actually adding a mouse click handler, not overriding onBrowserEvent.
If you are writing your own widget, I believe there's a guide on the wiki
that explains event handling.

On Wed, Apr 15, 2009 at 6:11 PM, raulsan ufreeurs...@gmail.com wrote:


 Nope, it is not doing the same as before, I have tryed with:
/**
* Handling events
*/
public void onBrowserEvent(Event event) {
super.onBrowserEvent(event);
if (mouseListeners != null) {
int x = event.getClientX() - this.getAbsoluteLeft();
int y = event.getClientY() - this.getAbsoluteTop();
switch (event.getTypeInt()) {
case Event.ONCLICK:
if (clickListeners != null) {
clickListeners.fireClick(this);
}
break;
case Event.ONMOUSEDOWN:
if (mouseListeners != null) {
mouseListeners.fireMouseDown(this, x, y);
}
break;
case Event.ONMOUSEMOVE:
if (mouseListeners != null) {
mouseListeners.fireMouseMove(this, x, y);
}
break;
case Event.ONMOUSEUP:
if (mouseListeners != null) {
mouseListeners.fireMouseUp(this, x, y);
}
break;
case Event.ONMOUSEOUT:
if (mouseListeners != null) {
mouseListeners.fireMouseLeave(this);
}
 break;
}
}
}

 and the canvas is still receiving the events, but it does not get the
 correct coordinates.
 Any idea why?
 


--~--~-~--~~~---~--~~
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: Is it possible to extend a Popup or DialogBox to detect when its moved?

2009-04-15 Thread Vitali Lovich
Sorry, was looking at the 1.5 doc.

protected void beginDragging(MouseDownEvent event)
{
   super.beginDragging(event);

  // my code goes here
}


protected void continueDragging(MouseDownEvent event)
{
   super.continueDragging(event);

  // my code goes here
}


protected void endDragging(MouseDownEvent event)
{
   super.endDragging(event);

  // my code goes here
}


On Wed, Apr 15, 2009 at 4:32 PM, Darkflame darkfl...@gmail.com wrote:


 I'm not sure precisely how to override in this case though.

 I see the onMouseUp event in the class, and I try putting this into my
 widget (which extends DialogBox).

@Override
public void onMouseUp(Widget sender, int x, int y) {
dragging = false;
DOM.releaseCapture(getElement());
  }

 (basicaly an exact copy of whats in the class's over mouseup event).

 However;
 a) dragging is not visible error
 b) It says onMouseUp is depreciated anyway and to use endDragging.

 (Looking at enddragging;

 protected void endDragging(MouseUpEvent event) {
onMouseUp(caption, event.getX(), event.getY());
  }

 )



 On Apr 15, 10:19 pm, Vitali Lovich vlov...@gmail.com wrote:
  id *onMouseDown
 http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
  *(Widget
 http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
  sender,
  int x, int y)
Fired when the user depresses the mouse button over a widget.
   void *onMouseEnter
 http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
  *(Widget
 http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
   sender)
Fired when the mouse enters a widget's area.   void
  *onMouseLeave
 http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
  *(Widget
 http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
   sender)
Fired when the mouse leaves a widget's area.   void
  *onMouseMove
 http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
  *(Widget
 http://google-web-toolkit.googlecode.com/svn/javadoc/1.5/com/google/g...
  sender,
  int x, int y)
Fired when the user moves the mouse over a widget.
  You have to override them yourself seeing as how it doesn't have support
 for
  this.
 
 
 
  On Wed, Apr 15, 2009 at 4:08 PM, darkflame darkfl...@gmail.com wrote:
 
   umm..what the title says  ;)
 
   I just want to trigger some realignment of stuff when the user stops
   dragging.
 


--~--~-~--~~~---~--~~
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 EJB

2009-04-15 Thread Midou

Hi
Please i like create an application uses GWT+EJB+MySQL+RPC
Have you some sources,tutorials or documentations to help me to create
this application.
thinks.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: GWT 1.6, JSP's wont compile.

2009-04-15 Thread Adrian

Thanks for the replies guys, this is very helpful.

I've added a link to this discussion in the bug report.

- Adrian



On Apr 16, 10:09 am, Ken kenfehl...@gmail.com wrote:
 Wow, thanks for this tip!  I've been meaning to explore App Engine,
 and this gave me even more reason to.  I just tested it all out and it
 works like a charm.  I was worried it wouldn't allow the quick
 turnaround, but you can use GWT hosted mode with it.  They did a
 really sweet job with this.

 Thank you also for filing the bug report.  You got the gist of it.
 It's not just generics, it's other 1.5+ features too (like for each
 loops) but it's probably not a huge deal.

 Thanks,
 Ken

 On Apr 15, 10:48 am, Miguel Méndez mmen...@google.com wrote:

  It looks like it is a bug with Jetty instance used when a GWT-only web app
  has JSPs with generics.
  It does not appear that the App Engine
  devserverhttp://code.google.com/appengine/docs/java/tools/devserver.html
  has
  this problem.  I went ahead and filed a bug against GWT for this,
  Issue 
  3557http://code.google.com/p/google-web-toolkit/issues/detail?id=3557.
   As a workaround, you could add App Engine to your project.

  On Wed, Apr 15, 2009 at 9:15 AM, Ken kenfehl...@gmail.com wrote:

   The app server is the one bundled with GWT hosted mode, I believe it's
   Jetty.  If you use a servlet that has 1.5 stuff in it, it works fine.
   When I was investigating, I noticed that the JSP does successfully
   produce a servlet.  I copied this servlet and compiled it myself and
   it worked fine, even in hosted mode.  I believe it's failing at the
   point where the generated servlet (.java) is being compiled into a
   class (.class).  Like you said, it seems like for some reason it's
   targeting version 1.4 or something like that.  It's confusing though
   that the problem is during compilation, because if you start with a
   servlet (rather than a JSP) it compiles with no problem.

   I have a feeling this might have something to do with it:
  http://code.google.com/p/google-web-toolkit/source/detail?r=5109

   It appears that something different happens underneath when a servlet
   is compiled as opposed to when a servlet generated by a JSP is
   compiled.

   On Apr 15, 7:31 am, Salvador Diaz diaz.salva...@gmail.com wrote:
It looks like the app server on which you're trying to load the jsp
doesn't support java 1.5 or you compiled your jsp with 1.4 or
something like that. Can't really tell without more details though. I
hope that helps you.

Cheers,

Salvador

On Apr 15, 4:13 am, Adrian ahay...@gmail.com wrote:

 Ok, so it's not just me!

 Does anyone have any idea on how to go about finding an answer to this
 problem? Even if you don't know the answer any suggestions are welcome
 because this one has me stumped.

 - Adrian

 On Apr 14, 3:23 pm, Ken kenfehl...@gmail.com wrote:

  I'm having the same exact problem.
  I've tried it on both Mac OS X and Windows.

  --
  Miguel
--~--~-~--~~~---~--~~
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: efficiency of my gwt application

2009-04-15 Thread ytbryan

thank you all for your advices... i learn something new again
today. :D

On Apr 15, 11:11 pm, Jason Essington jason.essing...@gmail.com
wrote:
 On Apr 15, 2009, at 8:51 AM,ytbryanwrote:

  thanks for your reply thomas. for me, there is two cases of slowness.

  - the rpc is quite slow. i am using it to return a few thousand by
  eleven column of data(String)

 There are probably two issues here, one the speed of the RPC, and the  
 second the speed of populating the table.

 But at issue is the attempt to return 33,000 cells worth of data in  
 one shot. how much of this data is going to be immediately visible to  
 the user? How likely is the user to use all of this data immediately?  
 Does your use case present you the opportunity to fetch this data in  
 some paged way?

 you need to figure out how much of your time is spent with the RPC  
 (deserialization) and how much is spent rendering the table. I would  
 be inclined to believe that you are likely to find that most of the  
 time is actually spent rendering the 33,000 cells. however you do have  
 some options here.
 You can move the rendering into an IncrementalCommand which will draw  
 a few rows at a time which gives the appearance of a much more  
 responsive application, and will begin rendering immediately, rather  
 than waiting until all rows are populated before showing the data on  
 screen.

 If your RPC data graph is pretty large, you could switch away from RPC  
 and use a JSON data graph with Javascript Overlay types on the client  
 side. a javascript eval() of the object graph from JSON is quite a bit  
 (like orders of magnitude) faster than RPC deserialization with very  
 large object graphs. NOTE your design shouldn't rely on large object  
 graphs, paging is a much better option.

 And as gregor mentioned, if you are profiling your code in hosted  
 mode, the performance has no correlation with real life. you need to  
 check the performance in web mode, and remember that something that  
 happens instantaneously in Firefox or Safari (or chrome) could take  
 forever in IE (particularly IE6), its javascript engine operates at a  
 glacial speed when compared to other options.

  thanks again..

 good luck

 -jason
--~--~-~--~~~---~--~~
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: IE6 + history support

2009-04-15 Thread Ian Bambury
It's a security thing and you can't do anything about it. If you could, it
wouldn't be much use as a security thing.
Why do you need to do it that way, anyway? Perhaps there's a better way.
What is the bigger picture?

--~--~-~--~~~---~--~~
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: Relative Position of a Widget

2009-04-15 Thread raulsan

But the thing is that it used to work perfectly with gwt-1.6.1 and

 int x = Event.getRelativeX(event, this.getElement());
 int y = Event.getRelativeY(event, this.getElement());

I don't understand why I can not override onBrowserEvent, I have also
overriden an addMouseListener
and I would not like to change much code, I thought there could be a
shortcut, but maybe the best way to go is to change again to 1.6.1
Thank you for you help anyway Vitali,
--~--~-~--~~~---~--~~
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: Two clients one session

2009-04-15 Thread Adligo

Hi,

  Generally with J2EE serverside (or .net) your session object has a
one to one relation ship with your user, it is communicated to the
server one of two ways;
1) As a cookie (what your seeing with the session id in the cookie)
2) As a cgi parameter of the url (ie 
http://foo.com/index.html?jsessionid=987298429847)
[for users who have cookies turned off]

On the server the session is looked up and added to your HttpRequest
(getThreadLocalRequest) object before your code (regular Servlet
onService or rpc method) does anything.  You can use the session
paradigm to store state full information (like the users name Chris)
when the protocol is stateless (http).

If you don't need state full information just ignore the session api.

Cheers,
Scott



On Apr 15, 2:05 pm, davidst...@gmail.com davidst...@gmail.com
wrote:
 To speak the truth i don't know about what video you are talking
 about,
 but I'm quite satisfied that the topics title sounds clever 

 On Apr 15, 2:38 am, matttai matt...@hotmail.com wrote:

  I was unsure if this topic title was a clever play on a popular video
  circulating the internet. If so very clever :)
--~--~-~--~~~---~--~~
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: Relative Position of a Widget

2009-04-15 Thread Vitali Lovich
Can you post your code for your class.  I can't really comment further
without understanding what it is you are trying to do.

On Wed, Apr 15, 2009 at 7:56 PM, raulsan ufreeurs...@gmail.com wrote:


 But the thing is that it used to work perfectly with gwt-1.6.1 and

  int x = Event.getRelativeX(event, this.getElement());
  int y = Event.getRelativeY(event, this.getElement());

 I don't understand why I can not override onBrowserEvent, I have also
 overriden an addMouseListener
 and I would not like to change much code, I thought there could be a
 shortcut, but maybe the best way to go is to change again to 1.6.1
 Thank you for you help anyway Vitali,
 


--~--~-~--~~~---~--~~
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: Relative Position of a Widget

2009-04-15 Thread raulsan



Yes, of course

I did not post it before because I thought it was not the right place
to do it. The class is an extended class from GWTCanvas, but I was
asking about mouse events and about the disappearing of a
function  :)  and because of that I posted here.
The class is:

/**
 *
 */
package com.mapvs.client;

import com.google.gwt.i18n.client.NumberFormat;
import com.google.gwt.user.client.Event;
import com.google.gwt.user.client.ui.ClickListener;
import com.google.gwt.user.client.ui.ClickListenerCollection;
import com.google.gwt.user.client.ui.Label;
import com.google.gwt.user.client.ui.MouseListener;
import com.google.gwt.user.client.ui.MouseListenerCollection;
import com.google.gwt.user.client.ui.Widget;
import com.google.gwt.widgetideas.graphics.client.Color;
import com.google.gwt.widgetideas.graphics.client.GWTCanvas;

/**
 * @author raulsan
 *
 */
@SuppressWarnings(deprecation)
public class CompassCanvas extends GWTCanvas {

private MouseListenerCollection mouseListeners;
private ClickListenerCollection clickListeners;

private Label angleLab = new Label(0);
/**
 * the size of the canvas
 */
private int x = 90;
private int y = 90;
/**
 * the size of the compass
 */
private float radius = x/2 -5;
/**
 * distance from the top of the arrow
 * to the top of the stick
 */
private int distArr = (int)radius/5;
/**
 * the size of the arrow
 */
private int arrSize = (int)radius-distArr;
/**
 * The angle to draw the arrow
 */
private double alfa = 0;
/**
 * the with of the lines
 */
private int lineW = 7;
/**
 * the colors
 */
private Color c1 = Color.YELLOW;
private Color c2 = Color.BLUE;
/**
 * Constructor
 */
public CompassCanvas() {
super(90,90);
// draw
drawCompass(alfa,c1,c1);
// the listeners
this.sinkEvents(Event.MOUSEEVENTS | Event.ONCLICK);
this.addMouseListener(new MouseListener(){
// variable
boolean dragging = false;

public void onMouseDown(Widget sender, int x, int y) {
drawCompass(x, y, c2, c2);
dragging = true;
}

public void onMouseEnter(Widget sender) {
drawCompass(alfa, c2, c1);

}

public void onMouseLeave(Widget sender) {
drawCompass(alfa, c1, c1);
dragging = false;
}

public void onMouseMove(Widget sender, int x, int y) {
if (dragging)
drawCompass(x,y,c2,c2);
else
drawCompass(alfa,c2,c1);

}

public void onMouseUp(Widget sender, int x, int y) {
drawCompass(x,y,c2,c1);
dragging = false;
}

});
}
/**
 * Handling events
 */
public void onBrowserEvent(Event event) {
event.preventDefault();
super.onBrowserEvent(event);
if (mouseListeners != null) {
int x = Event.getRelativeX(event, this.getElement());
int y = Event.getRelativeY(event, this.getElement());
switch (event.getTypeInt()) {
case Event.ONCLICK:
if (clickListeners != null) {
clickListeners.fireClick(this);
}
break;
case Event.ONMOUSEDOWN:
if (mouseListeners != null) {
mouseListeners.fireMouseDown(this, x, y);
}
break;
case Event.ONMOUSEMOVE:
if (mouseListeners != null) {
mouseListeners.fireMouseMove(this, x, y);
}
break;
case Event.ONMOUSEUP:
if (mouseListeners != null) {
mouseListeners.fireMouseUp(this, x, y);
}
break;
case Event.ONMOUSEOUT:
if (mouseListeners != null) {
mouseListeners.fireMouseLeave(this);
}
 break;
}
}
}

/**
 *
 * @param listener
 */
public void addClickListener(ClickListener listener) {
if (clickListeners == null) {
clickListeners = new ClickListenerCollection();
sinkEvents(Event.ONCLICK);
}
clickListeners.add(listener);
}
/**

Re: erro while try to do Store data in the datastore Example

2009-04-15 Thread Kevin

Same here...

On Apr 13, 9:44 am, @lex alexmonte...@gmail.com wrote:
 Hi, I would like some help to resolve this problem at the example of
 GWT using Gdatastore:
  http://code.google.com/webtoolkit/tutorials/1.6/appengine.html#data

 All application run well following the getting start tutorial, so when
 I try to improve using data store at this implementation an erro
 occurs because stockService is not declare yet.
 I tryed to force the declaration using StockService stockService =
 GWT.create(StockService.class); but another erro is get with the
 method getStocks.

   private void loadStocks() {
     stockService = GWT.create(StockService.class);
     stockService.getStocks(new AsyncCallbackString[]() {
       public void onFailure(Throwable error) {
       }
       public void onSuccess(String[] symbols) {
         displayStocks(symbols);
       }
     });
   }

   private void displayStocks(String[] symbols) {
     for (String symbol : symbols) {
       displayStock(symbol);
     }
   }

 If there is no mistake I would like to know where I can download the
 caomplete example with datastore workings.

 Ty.

--~--~-~--~~~---~--~~
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: erro while try to do Store data in the datastore Example

2009-04-15 Thread Kevin

Yes, hitting the same problem.  So far the example was great.
Outstanding in fact. Being new to Java I'm afraid I'm stuck

On Apr 14, 8:11 am, Jake B jakeboon...@gmail.com wrote:
 I'm having the same problem.  If anyone else has gone through the app
 engine tutorial and fixed this issue on their own, any help would be
 greatly appreciated.  Or as the OP said, a complete set of the working
 code would be nice as well.

 On Apr 13, 9:44 am, @lex alexmonte...@gmail.com wrote:

  Hi, I would like some help to resolve this problem at the example of
  GWT using Gdatastore:
   http://code.google.com/webtoolkit/tutorials/1.6/appengine.html#data

  All application run well following the getting start tutorial, so when
  I try to improve using data store at this implementation an erro
  occurs because stockService is not declare yet.
  I tryed to force the declaration using StockService stockService =
  GWT.create(StockService.class); but another erro is get with the
  method getStocks.

    private void loadStocks() {
      stockService = GWT.create(StockService.class);
      stockService.getStocks(new AsyncCallbackString[]() {
        public void onFailure(Throwable error) {
        }
        public void onSuccess(String[] symbols) {
          displayStocks(symbols);
        }
      });
    }

    private void displayStocks(String[] symbols) {
      for (String symbol : symbols) {
        displayStock(symbol);
      }
    }

  If there is no mistake I would like to know where I can download the
  caomplete example with datastore workings.

  Ty.

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



  1   2   >