Skip to content

Commit

Permalink
Merge pull request #3286 from krowley/timob-11389
Browse files Browse the repository at this point in the history
[TIMOB-11389] Android: TableViewRow - Longpress on tableViewRow gives a ...
  • Loading branch information
billdawson committed Oct 19, 2012
2 parents a381885 + e67ab88 commit 2842e39
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -137,10 +137,10 @@ public TiUITableView getTableView()

@Override
public boolean fireEvent(String eventName, Object data) {
if (eventName.equals(TiC.EVENT_LONGPRESS)) {
if (eventName.equals(TiC.EVENT_LONGPRESS) && (data instanceof HashMap)) {
// The data object may already be in use by the runtime thread
// due to a child view's event fire. Create a copy to be thread safe.
KrollDict dataCopy = new KrollDict((KrollDict)data);
KrollDict dataCopy = new KrollDict((HashMap)data);
double x = dataCopy.getDouble(TiC.PROPERTY_X);
double y = dataCopy.getDouble(TiC.PROPERTY_Y);
int index = getTableView().getTableView().getIndexFromXY(x, y);
Expand Down

0 comments on commit 2842e39

Please sign in to comment.