mobile

What's the point of 'meta viewport user-scalable=no' in the Google Maps API

爱⌒轻易说出口 提交于 2019-12-17 15:34:29
问题 I'm using the Google Maps JavaScript API V3 and the official examples always have you include this meta tag: <meta name="viewport" content="initial-scale=1.0, user-scalable=no" /> Most of the 3rd-party examples I've seen also do it. I wrote a plugin using it, though, and one of my users told me it's preventing him from being able to zoom in and out on his mobile device. I don't have a mobile device to test with, and none of my searches revealed any helpful information. So, what's the point of

Fixed positioning/z-index issue in mobile safari

独自空忆成欢 提交于 2019-12-17 15:27:55
问题 So the site in question: http://kaye.at/baby The main content below scrolls up over the top of the countdown and under the navigation which are both fixed elements. This works fine on desktop but on mobile safari, the content scrolls behind the countdown as the user moves up but once touch is released, it pops in front. Just wondering whether this is a bug or it is something that can be fixed? Here's the CSS: #header { position: fixed; width: 100%; top: 0px; z-index: 10; } #content { width:

how do you get the phone's MCC and MNC in Android?

爱⌒轻易说出口 提交于 2019-12-17 15:22:49
问题 The only way I've found of retrieving MCC and MNC is by overriding an activity's onConfigurationChanged method, as such: public void onConfigurationChanged(Configuration config) { super.onConfigurationChanged(config); DeviceData.MCC = "" + config.mcc; DeviceData.MNC = "" +config.mnc; } However, I need this data as soon as the app starts and can't wait for the user to switch the phone's orientation or equivalent to trigger this method. Is there a better way to access the current Configuration

Best Java Obfuscation Application For Size Reduction [closed]

无人久伴 提交于 2019-12-17 13:43:29
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 6 years ago . An important part of mobile development, especially when you are talking about mobile games, is dealing with the application size restrictions. Some devices enforce their own size limits, while all the carriers have their own size requirements for applications to be released in their deck space. My question is,

html5 drag and drop FOR MOBILE [duplicate]

两盒软妹~` 提交于 2019-12-17 12:34:06
问题 This question already has answers here : HTML Drag And Drop On Mobile Devices (8 answers) Closed 5 years ago . I found this code on w3schools for drag and drop, which works on a desktop, but not mobile devices. What do I need to modify so that it recognizes touch? <!DOCTYPE HTML> <html> <head> <style type="text/css"> #div1 {width:350px;height:70px;padding:10px;border:1px solid #aaaaaa;} </style> <script> function allowDrop(ev) { ev.preventDefault(); } function drag(ev) { ev.dataTransfer

Mobile viewport height after orientation change

若如初见. 提交于 2019-12-17 11:44:21
问题 I am attaching a listener to the orientationchange event: window.addEventListener('orientationchange', function () { console.log(window.innerHeight); }); I need to get the height of the document after the orientationchange . However, the event is triggered before the rotation is complete. Therefore, the recorded height reflects the state before the actual orientation change. How do I register an event that would allow me to capture element dimensions after the orientation change has been

Mobile viewport height after orientation change

我是研究僧i 提交于 2019-12-17 11:43:31
问题 I am attaching a listener to the orientationchange event: window.addEventListener('orientationchange', function () { console.log(window.innerHeight); }); I need to get the height of the document after the orientationchange . However, the event is triggered before the rotation is complete. Therefore, the recorded height reflects the state before the actual orientation change. How do I register an event that would allow me to capture element dimensions after the orientation change has been

How can I edit a .jar file? [duplicate]

删除回忆录丶 提交于 2019-12-17 10:47:52
问题 This question already has answers here : Closed 7 years ago . Possible Duplicate: Modifying a file inside a jar So I have a jar file with one .class file on it. I just need to change some words in the file. What program should I use? I want this to work for my phone. 回答1: Here's what I did: Extracted the files using WinRAR Made my changes to the extracted files Opened the original JAR file with WinRAR Used the ADD button to replace the files that I modified That's it. I have tested it with my

Detect mobile devices - and tablet devices

狂风中的少年 提交于 2019-12-17 10:44:13
问题 I am currently looking at some code for PHP detection of mobiles, which is probably quite easy. Now I just have got one problem - I want to make it possible to make unique view-files in my MVC-framework for tablets, mobiles and web pages. So I need to split the tablet from the rest of the mobile devices. Currently this is the code, that I am using: public function isMobile() { if(preg_match('/(alcatel|amoi|android|avantgo|blackberry|benq|cell|cricket|docomo|elaine|htc|iemobile|iphone|ipad

Phonegap - Choose Image From Gallery

江枫思渺然 提交于 2019-12-17 10:42:29
问题 Can anyone tell me, or point me in the direction of how to get an image from the phone's image gallery in Phonegap / Android? There's docs on accessing the camera (which works great) but not selecting an existing image. I'm looking for Phonegap / Javascript rather than Java. Thanks in advance! 回答1: Erm, the Camera docs cover this. Is this not working for you? Check out Camera.PictureSourceType for details. The docs site givens this example for deriving an image thus: function getPhoto(source)