mobile

MVC 4 Beta with Mobile Project FIle Upload does not work

六眼飞鱼酱① 提交于 2019-12-11 08:21:57
问题 I am playing around with the new MVC 4 beta release. I created a new web project using the Mobile Application template. I simply added a controller and a view to upload a file, but the file is always null in the action result. Is this a bug, or am I doing something wrong? Controller Code: using System.IO; using System.Web; using System.Web.Mvc; namespace MobileWebExample.Controllers { public class FileUploadController : Controller { public ActionResult Index() { return View(); }

How to detect if unity game is running on (web keyboard) or (mobile touch)

房东的猫 提交于 2019-12-11 08:20:03
问题 basically, I have a unity game supported by physical keyboards and touch screens in mobile devices. I already finished my movement script for physical keyboards, and now, I'm coding for touch screens. How can I achieve that detect feature? I was thinking something like that... private void HandleInput() { if (detect if physical keyboard here...) { if (Input.GetKey(KeyCode.RightArrow)) { _normalizedHorizontalSpeed = 1; } else if (Input.GetKey(KeyCode.LeftArrow)) { _normalizedHorizontalSpeed =

Why is CSS min-width causing my responsive site to be zoomed in on a mobile?

心已入冬 提交于 2019-12-11 08:15:49
问题 I'm building a responsive website and I'm having a problem with it which means that when I view it on a mobile, it's automatically zoomed in by a small amount. I can zoom out to view the whole width of the page, but when I click on a link to another page, the new page loads in slightly zoomed in as well (maybe by 10% or so). I've set an appropriate viewport which should deal with the problem: <meta name="viewport" content="width=device-width, initial-scale=1" /> I also have set a minimum

How to center 'Getting Data' on mobile screen

好久不见. 提交于 2019-12-11 08:11:53
问题 While developing a site for many browsers, mobile and desktop, I've noticed that the following CSS works nicely to center a loading div. img.loading1 { position:absolute; left:50%; margin-left:-16px; top:50%; margin-top:-16px; z-index:10 } .loading2 { color:#006BB2; position:absolute; left:50%; margin-left:0px; top:40%; z-index:5 } .loading3 { position:absolute; width:100%; height:100%; left:0; top:0; background-color:lightgrey; opacity:0.85 } <div id="container" style="position:relative"> ..

Changing the value of an EditText inside onCreate() has no effect when changing device orientation

▼魔方 西西 提交于 2019-12-11 08:11:37
问题 My understanding is that when you change the device orientation, your app gets destroyed and created again. This means that onCreate() should run every time I rotate the device. I'm trying to set an EditText every time the app is created, including whenever the screen is rotated. So, I start up the app, and the text field says "Bap". I then change the contents of the field to "Boop", then rotate the screen. I would expect the field to now say "Bap", but it doesn't, it remains whatever it was

Mobile Browser Address Bar not hiding

对着背影说爱祢 提交于 2019-12-11 08:09:39
问题 Hey I got a "beta" site it works well in mobile except address bar. Address br is always there. When I scroll it must go away. but it is still there. And in iOS Chrome scrooling is laggy. I think they are same problem. Website: http://goo.gl/nx1HME Thanks 回答1: Oh I think I must answer my question. It cause by html { height:100%; } line. 来源: https://stackoverflow.com/questions/25523847/mobile-browser-address-bar-not-hiding

Make Slicknav menu close when outside click on IOS devices

梦想与她 提交于 2019-12-11 08:04:37
问题 I'm using the Slicknav mobile menu script: http://slicknav.com/ And it's working great except I can't figure out how to get it to close when one clicks outside of the menu on ios devices. It closes fine when clicking outside when I test it on desktop and Android, but on my Ipad it's not working. Here's the current code. Any insight? Thank you! <script src="slicknav.js"></script> <script type="text/javascript"> $(document).ready(function(){ $('.menu').slicknav({ label:'', closeOnClick:true });

Should I upload files to Amazon S3 from mobile devices or from my server?

杀马特。学长 韩版系。学妹 提交于 2019-12-11 08:02:19
问题 I have Amazon S3 as my file storage server and EC2 instances as my application logic server. Now my app needs to upload some files which need necessary processing. I can think of two ways to do this: Upload the file directly from mobile devices and get the file name and location(url), then send the url to my backend. Backend get the file by URL and do its job. Send the file to backend using a multipart form, backend accepts the file do its job and finally save the file to Amazon S3. Which is

How do you play a local flv video file in flex mobile project?

时光总嘲笑我的痴心妄想 提交于 2019-12-11 07:56:21
问题 Good afternoon, I trying to play a flv file in a flex mobile (flex 4.6) The files will all be locally stored and on the device. Would it be better to use the video even if it is not supported or can i use a movieClip? I am going to try and fade out a picture and then play the video with out any user controls and then fade back to the picture. The this will all be on a tablet. I am using Flash Builder 4.6. If I can use a movieClip would someone please give me a tutorial or a snippet of code on

js device and orientation detection

白昼怎懂夜的黑 提交于 2019-12-11 07:52:14
问题 I have written this script based on other scripts i have read about, and take into consideration i'm a novice to js / jquery. I want to detect the size and orientation of the device on page load and on orientation change. So that i can apply different rules on each situation. It works great on android devices, but i found it didnt work in portrait mode on ipad's Now i cant figure out what i did wrong. Even on js lint i get that all my scripting is not set and so on. a bit of help would be