Checkbox inside an item that also has a click callback.

9 views
Skip to first unread message

Brian Hayward

unread,
Jan 24, 2013, 1:28:42 AM1/24/13
to mo...@googlegroups.com
Trying a configuration like this,  Item with callback and a checkBox inside the item:

item (onclick = {myEditScreen();})
{
    checkBox(boolval, label="my label")
}

Is there any way to allow myEditScreen to fire if you click OUTSIDE the checkbox or it's label, but not when you toggle the checkbox itself?

I tried this but it didn't work:
item (onclick = {myEditScreen();})
{
    checkBox(boolval, label="my label", onchange={event.preventDefault()};)
}

Happens with the context menu as well (e.g. it opens context menu but then fires the item callback as well).

Thanks,
Brian

Chris Melman

unread,
Jan 24, 2013, 2:53:58 AM1/24/13
to mo...@googlegroups.com
Can't you place an if statement in the on click?


Date: Wed, 23 Jan 2013 22:28:42 -0800
From: bhay...@gmail.com
To: mo...@googlegroups.com
Subject: [mobl] Checkbox inside an item that also has a click callback.
--
 
 
Reply all
Reply to author
Forward
0 new messages