Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-13100] Android: Maps V2 Module - Annotation click event not triggered

GitHub Issuen/a
TypeNew Feature
PriorityMedium
StatusClosed
ResolutionFixed
Resolution Date2013-04-04T17:09:10.000+0000
Affected Version/sRelease 3.0.2
Fix Version/sRelease 3.1.0, 2013 Sprint 07 API, 2013 Sprint 07
ComponentsAndroid
Labelsmapv2, qe-testadded, triage
Reporterjason hu
AssigneePing Wang
Created2013-03-04T04:05:20.000+0000
Updated2013-09-25T07:24:14.000+0000

Description

after clicking the annotation, it will pop up the decent white box view with title and subtitle, however, No event is triggered when the pop view is clicked. Previously, we can get event from mapview and distinguish different click source for leftButton, rightButton, title, subtitle. map.addEventListener('click', function(evt) { Titanium.API.info('map is clicked'); var clickSource = evt.clicksource; Titanium.API.info('map is clicked :: '+clickSource); });

Comments

  1. Daniel Sefton 2013-03-04

    Hi jason, Before we can escalate this, we need the following info: - Ti SDK version - Android version, device version / emulator - A runnable test case We appreciate your time in helping to improve the platform. Thanks!
  2. jason hu 2013-03-04

    SDK: 3.02GA Android: 2.3.4, 2.3.6, 4.1.2 Device: Nexus S, Galaxy Note 2 As far as the runnable test case, you should be able to easily reproduce this yourself. Since this requires V2 private key, I can't upload my project.
  3. jason hu 2013-03-04

    why is the status changed to Resolved? This is so far the biggest show stopper for this module. With this bug, the V2 module becomes unpresentable literally.
  4. Dustin Hume 2013-03-18

    Why has this been closed? Maps V2 is unusable to me until this issue has been resolved.
  5. Stefan Schüller 2013-03-22

    Titanium SDK: 3.0.2GA Maps module: 2.0.0 Samsung Galaxy S3: 4.1.2 Sasmung Galaxy Ace Plus: 2.3.6 Asus Nexus 7: 4.1.1 Here is a test case:
       var window = Titanium.UI.createWindow({});
       window.open();
        
       var view = Ti.UI.createView({});
       window.add(view);
        
       var MapModule = require('ti.map');
         
       var map = MapModule.createView({
           userLocation: true,
           mapType: MapModule.NORMAL_TYPE,
           animate: true,
           region: {latitude: -33.87365, longitude: 151.20689, latitudeDelta: 0.1, longitudeDelta: 0.1 }, 
       });
        
       var anno = MapModule.createAnnotation({
                       latitude: -33.86665,
                       longitude: 151.20689,
                       title: "Test Annotation",
                       subtitle: "Test Point subtitle",
                       animate: true,
       });
       
       anno.addEventListener('click', function(e) {
           Ti.API.info("Annotation popup clicked");
       });
       
       map.addAnnotations([anno]); 
        
       view.add(map);
       
  6. Hieu Pham 2013-04-04

    PR: https://github.com/appcelerator/titanium_mobile/pull/4061 (3_1_X PR: https://github.com/appcelerator/titanium_mobile/pull/4077) PR: https://github.com/appcelerator/titanium_modules/pull/95
  7. Ping Wang 2013-04-04

    The click event listener must be added to the map view not the annotation. Here is the [doc](http://docs.appcelerator.com/titanium/3.0/#!/api/Modules.Map.View-event-click). Therefore, the test case attached by Stefan Schüller won't work. Please use the test case in TIMOB-12810.
  8. Dhirendra Jha 2013-09-25

    The issue TIMOB-12810 is already tested and closed. The test app (mentioned in the bug TIMOB-12810) shows the mentioned expected results. Hence closing this issue.

JSON Source