I can see several ways of "fixing" this (depending on the exact use case you're trying to solve):
- assuming this is "on initial load": have your "have to go to here first" logic in the PlaceTokenizer, to return the HaveToGoHereFirstPlace - add a flag to your "somewhere" places that, when set, changes the equals() implementation to always return false; that way, "somewhere"(initial) is different from "somewhere"(from haveToGoHereFirst). Actually, depending on your needs, you might not even need the flag, and simply not override equals(), having each instance only equals() itself (default behavior from Object#equals) - don't redirect automatically, instead, return an activity that displays a "you should go there first" message to the user. - implement the whole thing within the activity/activities itself, possibly wrapping it within a special HaveToReadThisFirstActivity to keep concerns separate, and using another mean than a goTo(Place) to switch from the "haveToGoHereFirst" screen to the "actual" activity. There might be other solutions. -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To view this discussion on the web visit https://groups.google.com/d/msg/google-web-toolkit/-/BAR1wcqGZJwJ. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
