Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-714] load event does not fire for image view with url

GitHub Issuen/a
TypeBug
PriorityMedium
StatusClosed
ResolutionInvalid
Resolution Date2011-04-15T02:35:01.000+0000
Affected Version/sn/a
Fix Version/sRelease 1.3.0
ComponentsiOS
Labelsn/a
ReporterNolan Wright
AssigneeBlain Hamon
Created2011-04-15T02:35:00.000+0000
Updated2017-03-02T19:12:49.000+0000

Description

Base UI => Views => Image Views => Basic

logs load event but it never happens

reported from:

http://helpdesk.appcelerator.net/tickets/1767">http://helpdesk.appcelerator.net/tickets/1767

Comments

  1. Stephen Tramer 2011-04-15

    'load' event does happen. It looks like the 'click' event is caught by the table row and not passed along to the imageView in the sample code provided with the helpdesk ticket. I can see if click events can be passed through to subviews from table rows, so that each view fires its own 'click' event.

  2. Stephen Tramer 2011-04-15

    Events are in fact propagated down the view. However, you need to perform a few sanity checks. The following code will, in fact, work when clicking on a subelement of a row:

       // Code to test if you clicked on an image view
           row.addEventListener ('click', function(e)
           {
               Logger.log("Source: "+e.source);
               if (e.source.url != null) {
                   Logger.log ("[messages.js:addRow] ***** clicked on " + e.source.url);
               }
               else {
                   Logger.log("Clicked elsewhere!");
               }
           });
       

    See Base UI->Views->Table View->Layout 2 for more examples about going clicky-clicky on stuff (including a better way to test for what type the source is; checking a property that exists for the source you want to check for is fuzzy).

    Marking as invalid, since it's already fixed. Solution should be sent to the customer.

  3. Lee Morris 2017-03-02

    Closed as invalid.

JSON Source