You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "matt vdb (JIRA)" <Wi...@wicketstuff.org> on 2008/03/22 16:46:21 UTC
JiraStuff Created: (WSGMAPP-9) Behavior onEvent doesn't work with
GMarker
Behavior onEvent doesn't work with GMarker
------------------------------------------
Key: WSGMAPP-9
URL: http://wicketstuff.org/jira/browse/WSGMAPP-9
Project: WicketStuff GMap2
Issue Type: Bug
Environment: firefox/ie
Reporter: matt vdb
Assigned To: Martin Funk
Priority: Blocker
Hi,
I have some problems to catch click component on GMarker, this is my code implement :
GMarkerOptions options = new GMarkerOptions();
options.clickable(true);
marker = new GMarker(topMap.getCenter());
marker.addBehavior(new GMarkerClickListener()
{
@Override
protected void onEvent(AjaxRequestTarget target) {
super.onEvent(target);
}
@Override
protected void onClick(AjaxRequestTarget target, GMarker marker) {
target.appendJavascript("alert('on click')");
}
});
//And this is my GMarkerClickListener class...
public abstract class GMarkerClickListener extends GOverlayListenerBehavior {
@Override
protected String getEvent() {
return "click";
}
@Override
protected void onEvent(AjaxRequestTarget target) {
Request request = RequestCycle.get().getRequest();
GMarker marker = null;
String markerParameter = request.getParameter("marker");
if (markerParameter != null)
{
for (GOverlay ovl : getGMap2().getOverlays())
{
if (ovl.getId().equals(markerParameter) && ovl instanceof GMarker)
{
marker = (GMarker)ovl;
break;
}
}
}
onClick(target, marker);
}
protected abstract void onClick(AjaxRequestTarget target, GMarker marker);
}
the listener doesn't work, is it a good way to implement click code for GMarker ???
Thanks
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://wicketstuff.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
JiraStuff Closed: (WSGMAPP-9) Behavior onEvent doesn't work with
GMarker
Posted by "Martin Funk (JIRA)" <Wi...@wicketstuff.org>.
[ http://wicketstuff.org/jira/browse/WSGMAPP-9?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Funk closed WSGMAPP-9.
-----------------------------
fixed
> Behavior onEvent doesn't work with GMarker
> ------------------------------------------
>
> Key: WSGMAPP-9
> URL: http://wicketstuff.org/jira/browse/WSGMAPP-9
> Project: WicketStuff GMap2
> Issue Type: Bug
> Environment: firefox/ie
> Reporter: matt vdb
> Assigned To: Martin Funk
> Priority: Blocker
>
> Hi,
> I have some problems to catch click component on GMarker, this is my code implement :
> GMarkerOptions options = new GMarkerOptions();
> options.clickable(true);
> marker = new GMarker(topMap.getCenter());
> marker.addBehavior(new GMarkerClickListener()
> {
> @Override
> protected void onEvent(AjaxRequestTarget target) {
> super.onEvent(target);
> }
> @Override
> protected void onClick(AjaxRequestTarget target, GMarker marker) {
> target.appendJavascript("alert('on click')");
> }
>
> });
> //And this is my GMarkerClickListener class...
> public abstract class GMarkerClickListener extends GOverlayListenerBehavior {
> @Override
> protected String getEvent() {
> return "click";
> }
> @Override
> protected void onEvent(AjaxRequestTarget target) {
>
> Request request = RequestCycle.get().getRequest();
> GMarker marker = null;
>
> String markerParameter = request.getParameter("marker");
> if (markerParameter != null)
> {
> for (GOverlay ovl : getGMap2().getOverlays())
> {
> if (ovl.getId().equals(markerParameter) && ovl instanceof GMarker)
> {
> marker = (GMarker)ovl;
> break;
> }
> }
> }
> onClick(target, marker);
>
> }
> protected abstract void onClick(AjaxRequestTarget target, GMarker marker);
>
> }
> the listener doesn't work, is it a good way to implement click code for GMarker ???
> Thanks
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://wicketstuff.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
JiraStuff Resolved: (WSGMAPP-9) Behavior onEvent doesn't work with
GMarker
Posted by "Martin Funk (JIRA)" <Wi...@wicketstuff.org>.
[ http://wicketstuff.org/jira/browse/WSGMAPP-9?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Funk resolved WSGMAPP-9.
-------------------------------
Resolution: Fixed
svn log -r HEAD
------------------------------------------------------------------------
r3756 | funkattack | 2008-03-22 18:41:34 +0100 (Sa, 22 Mär 2008) | 1 line
http://wicketstuff.org/jira/browse/WSGMAPP-9
------------------------------------------------------------------------
> Behavior onEvent doesn't work with GMarker
> ------------------------------------------
>
> Key: WSGMAPP-9
> URL: http://wicketstuff.org/jira/browse/WSGMAPP-9
> Project: WicketStuff GMap2
> Issue Type: Bug
> Environment: firefox/ie
> Reporter: matt vdb
> Assigned To: Martin Funk
> Priority: Blocker
>
> Hi,
> I have some problems to catch click component on GMarker, this is my code implement :
> GMarkerOptions options = new GMarkerOptions();
> options.clickable(true);
> marker = new GMarker(topMap.getCenter());
> marker.addBehavior(new GMarkerClickListener()
> {
> @Override
> protected void onEvent(AjaxRequestTarget target) {
> super.onEvent(target);
> }
> @Override
> protected void onClick(AjaxRequestTarget target, GMarker marker) {
> target.appendJavascript("alert('on click')");
> }
>
> });
> //And this is my GMarkerClickListener class...
> public abstract class GMarkerClickListener extends GOverlayListenerBehavior {
> @Override
> protected String getEvent() {
> return "click";
> }
> @Override
> protected void onEvent(AjaxRequestTarget target) {
>
> Request request = RequestCycle.get().getRequest();
> GMarker marker = null;
>
> String markerParameter = request.getParameter("marker");
> if (markerParameter != null)
> {
> for (GOverlay ovl : getGMap2().getOverlays())
> {
> if (ovl.getId().equals(markerParameter) && ovl instanceof GMarker)
> {
> marker = (GMarker)ovl;
> break;
> }
> }
> }
> onClick(target, marker);
>
> }
> protected abstract void onClick(AjaxRequestTarget target, GMarker marker);
>
> }
> the listener doesn't work, is it a good way to implement click code for GMarker ???
> Thanks
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://wicketstuff.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira