Page 1 of 1

Capture Y-Axis Location

Posted: Mon May 21, 2012 1:03 pm
by Chris2656882

I need to capture the Y-axis location when a user taps/clicks

I done this before using JQuery on a website, but it does not seem to be working within Tiggzi

In a project javascript file, I have the code:

Tiggr('button_show_more_items').bind('vclick',function(e){
alert(e.pageY);
});

However, the page hangs whenever it is loaded when this code is present.

I've tried moving it to the page's DeviceReady and Load events to no avail as well.

Please advise.


Capture Y-Axis Location

Posted: Mon May 21, 2012 1:23 pm
by maxkatz

Does it work when you just do a plain alert..? If the page is not loaded, that probably means there is a JavaScript error somewhere. Check with Chrome Developer Tools, in Console tab.

Just as a side note, Tiggzi is just a mobile IDE, the resulting app is still just running in the browser.


Capture Y-Axis Location

Posted: Mon May 21, 2012 1:37 pm
by Chris2656882

Yes, a plain alert functions outside the bind function.

Yes, I know Tiggzi is mobile IDE, but it has a bunch of peculiarities, quirks, and sometimes bugs that prevent me from writing code as I normally do. I have reported a number of them. The product is on the right track, but has a number of issues that need addressing.


Capture Y-Axis Location

Posted: Mon May 21, 2012 3:28 pm
by maxkatz

This works for me on page load:

code
Tiggr('mobilebutton2').bind('vclick',function(e){
console.log(e);
});
/code

Image