JQuery Phonegap

Webview orientation with Phonegap

I was having this really weird problem in PhoneGap where when the orientation would change the webview would not resize to fit the whole screen.  Turns out that the meta viewport tag was causing the problem.  My viewport setting was this: 1 <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"/><meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"/>Continue Reading “Webview orientation with Phonegap”

JQuery

Get viewport size width and height with javascript – Javascript – Blog / Andy Langtons Website

Get viewport size width and height with javascript – Javascript – Blog / Andy Langtons Website. This is a neat little snippet of JavaScript code to get the size of your viewport on a browser.  I’m doing some work with progressive HTML rendering and viewport height is pretty important there.  This seems to  work.  WillContinue Reading “Get viewport size width and height with javascript – Javascript – Blog / Andy Langtons Website”

CSS JavaScript JQuery Phonegap

Transform performance on mobile applications

Just a quick one today.  I have read on several web pages that if you want to speed up the rendering of your site that you need to add -webkit-transform: translate3d(0,0,0) to the page elements to have the browser use the GPU to render the page instead of the CPU. I tried this trick several timesContinue Reading “Transform performance on mobile applications”

JQuery Phonegap

Handling clicks for mobile platforms [UPDATED]

I’ve been doing a lot of work in Phonegap lately and I really like it.  However, one of the things I don’t like is that click events are really, really slow.  There’s a reason for this.  How does the browser know if it’s a click or the beginning of a move?  The answer to thisContinue Reading “Handling clicks for mobile platforms [UPDATED]”