English 中文(简体)
拖曳应用程序电话gap
原标题:Drag the application phonegap

I wonder how I do that the scroll PhoneGap does not have this in my application when I drag the mouse on the application, it will go up or down, as I do Ileave it fixed? I posted pictures of what is happening, thanks! http://postimage.org/image/pa2kyvvwb/ http://postimage.org/image/gf8cnrjsx/

最佳回答

您可以使用此脚本, 但是如果页面比屏幕大, 您必须处理滚动自己 :

//Prevent dragging of canvas on iOS
$(document.body).bind( touchmove , function(event) {
    event.preventDefault();
});
问题回答

这似乎在每个苹果设备上都是一样的。 这不是一个 PhoneGap 功能。 当拖动我的 Mac 迷你网站时, 也会发生同样的情况 。 所以, 您需要用程序化方式在 effectiv- c 上做 。 也许这可以工作 。

CGSize scrollableSize = CGSizeMake(320, myScrollableWidth);
[myScrollView setContentSize:scrollableSize];




相关问题
CSS working only in Firefox

I am trying to create a search text-field like on the Apple website. The HTML looks like this: <div class="frm-search"> <div> <input class="btn" type="image" src="http://www....

image changed but appears the same in browser

I m writing a php script to crop an image. The script overwrites the old image with the new one, but when I reload the page (which is supposed to pickup the new image) I still see the old one. ...

Firefox background image horizontal centering oddity

I am building some basic HTML code for a CMS. One of the page-related options in the CMS is "background image" and "stretch page width / height to background image width / height." so that with large ...

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签