tablet

How to restrict app for tablet in Android?

匆匆过客 提交于 2019-12-03 16:10:54
i want to my app run only mobile device not in the tablet 10 and 7 inch . but my app is run on both tablet size .please help me out Bhavesh Patadiya Yes as @OceanLife says you Should Go with compatible-screens or supports-screens . but I would like to add Something here. if you are using <supports-screens android:largeScreens="false" android:normalScreens="true" android:smallScreens="true" android:xlargeScreens="false" /> then note what official compatible-screens documentation says: if you want your application to be available only for large and xlarge screen devices, the element allows you

Achieve android gmail tablet design in selection (arrow style)

你离开我真会死。 提交于 2019-12-03 13:54:57
问题 I am trying to build a tablet optimized app and I would like to follow the same style of gmail tablet version in selections (the arrow on the right side of the selection). I don't know how to obtain the same style. There is a shadow and an arrow for the selection. This is an image of gmail app: Thanks 回答1: The arrow is just part of the list item background. Here is and example from the Email application where list_selected_holo is a drawable that contains an arrow on its right side (You can

Some Android devices treat Internal Storage as SD Cards and External Storage as EXTSD

社会主义新天地 提交于 2019-12-03 11:50:27
I have a bunch of Android devices from different vendors. Some of them attach /mnt/sdcard to internal storage and /mnt/extsd to external storage(Scenario 1) and others attach /mnt/sdcard to external storage(Scenario 2) I think the second scenario is standard since the Android API provides a handle to this path. Now the problem is that in scenario 1, /mnt/extsd becomes readonly even with WRITE_EXTERNAL_STORAGE permission! This means I can only read data from the actual external sd card and not be able to write to it. Is there a workaround for this so I can write to the extsd folder ?

System bar size on android tablets

二次信任 提交于 2019-12-03 09:01:48
I've got the problem that I need the height of the android tablet system bar. It's the same problem as over here , but I cant use this answer, because it gives me the same size as from the DisplayMetrics. At both ways I get the resolution with this bar allready calculated in it. (This problem doesnt appear at my smartphone, just on my tablet). // status bar (at the top of the screen on a Nexus device) public static int getStatusBarHeight(Context context) { Resources resources = context.getResources(); int resourceId = resources.getIdentifier("status_bar_height", "dimen", "android"); if

CSS Media query landscape android soft keyboard

送分小仙女□ 提交于 2019-12-03 07:36:50
问题 I'm working on a web application for tablets(for android and ios) and I'm facing a problem which is giving me trouble for 2 days already. The problem is that on android when you are in portrait mode and for example you focus an input field so the soft keyboard pops up the css media query orientation changes to landscape. I already have read this question : CSS Media Query - Soft-keyboard breaks css orientation rules - alternative solution? and came up with this : var is_keyboard = false; var

Android: master/detail flow (dual-pane) using 1 activity

拜拜、爱过 提交于 2019-12-03 07:03:07
As reported by the Android guide , dual-pane can be achieved in two ways: Multiple fragments, one activity Multiple fragments, multiple activities I am using the first case (the Android guide only explains the second case). This is what happens on 7" tablets : rotating from landscape to portrait : only the single-pane fragment gets recreated rotating from portrait to landscape : all 3 fragments (single-pane, dual-pane-master, dual-pane-detail) get recreated Question: why is the single-pane fragment (which I create programmatically, but using a FrameLayout defined in the layout as the container

How to find out whether a particular device has SIM Hardware support?

江枫思渺然 提交于 2019-12-03 06:44:39
I wanted to disable features related to CALL and SMS in my application based on whether SIM hardware is present or not. Now a beginners approach towards this will be checking the Phone type using : if (telephonyManager1.getPhoneType() == TelephonyManager.PHONE_TYPE_NONE) If true then its supported. Everything was fine until i came across Sony Tablet S which has a SIM support only for Data and Messaging. No voice support. So for this device i need to disable only CALL feature but continue with SMS support. Sony tablet returns TelephonyManager.PHONE_TYPE_NONE so i can`t use the above methods.

Is it possible to run R from a tablet using Honeycomb (Android 3.0)?

六月ゝ 毕业季﹏ 提交于 2019-12-03 05:13:42
问题 I have a Xoom tablet and it would be great if I could run statistical analysis using R on it. As far as I know it is not possible to use R on iPad due to license problems (GPl x iTunes etc.) and a lack of compiler for Fortran in the Apple tablet. But what about tablets using android? Arguably, the GPL issue is not a problem, so any help here on how to use R on my tablet? 回答1: At some point, smartphones and tablets will have browsers capable enough to run RStudio in its server mode via the

Achieve android gmail tablet design in selection (arrow style)

那年仲夏 提交于 2019-12-03 04:49:26
I am trying to build a tablet optimized app and I would like to follow the same style of gmail tablet version in selections (the arrow on the right side of the selection). I don't know how to obtain the same style. There is a shadow and an arrow for the selection. This is an image of gmail app: Thanks The arrow is just part of the list item background. Here is and example from the Email application where list_selected_holo is a drawable that contains an arrow on its right side (You can find the drawable with simple google search). <selector xmlns:android="http://schemas.android.com/apk/res

Read and writer data via USB port on Android 3.1

孤街浪徒 提交于 2019-12-03 04:22:16
I am trying to write an android app to read and write data from android tablet to our embedded device. The tablet and embedded device are connected via usb to serial converter. Is it possible to read data from the embedded device into our android tablet? Any sample code that I can take a look at? As a serial converter is a USB device , the android tablet has to act as a USB host . This feature is available since Android 3.1. The API documentation is available on the android developer page and includes code examples. To actually communicate with the converter you will have to find out a bit