WebView not shown inside TabHost on Honeycomb when open tab first time

对着背影说爱祢 提交于 2020-01-17 02:54:10
问题 Have the following view in my app: <TabHost xmlns:android="" android:id="@android:id/tabhost" android:layout_width="fill_parent" android:layout_height="fill_parent"> <LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:paddingTop="0dip"> <TabWidget android:id="@android:id/tabs" android:layout_width="fill_parent" android:layout_height="wrap_content" /> <FrameLayout android:id="

Tablelayout in Scrollview not working

微笑、不失礼 提交于 2020-01-15 11:59:27
问题 My fragment loads its data into a tablelayout inside a scrollview. At first, it will load saying "Click on image to view more data". I have a onclick listener from the gallery that should delete all the rows from the tablelayout with tableLayout.removeAllViews(); . Then the fragment will add row/rows to a tablelayout inside a scrollview. The tablelayout should change on every click from the gallery. However I am getting: **java.lang.IllegalStateException: ScrollView can host only one direct

Android 3.0 Use Physical Keyboard Setting

限于喜欢 提交于 2020-01-15 08:08:24
问题 Background: I recently purchased a Motorola XOOM Tablet along with the Desktop Dock and Bluetooth Keyboard accessories. The dock and keyboard work great, but when I take the tablet off the dock to move away from my desk, the keyboard still remains paired with the device and I have to manually change the settings to use the soft keyboard. The same goes for when I set it back on the dock, I need to manually switch it back. It's not a huge problem, but it would be nice not to have to think about

Is there a way to display fragments in TabHost?

安稳与你 提交于 2020-01-12 05:56:25
问题 I'd like to show a different fragment in a TabHost, for every tab. But it seems that there's no easy way to do this. TabHost can only accept A. Views or B. Intents that launch Activities when the user selects a tab. Going with A means that I have to initialize every fragment and load them into container Views that are given to the TabHost. But I want these fragments to load only when needed - when the user selects their tab that is. Going with B means that I load the fragments into separate

OutOfMemory error though free memory is available

有些话、适合烂在心里 提交于 2020-01-12 03:13:25
问题 I'm seeing a pretty odd problem. Essentially sometimes large bitmap memory allocations will fail even though there's apparently tons of memory. There are a number of posts that appear to ask a similar question but they are all related to pre-honeycomb android. My understanding is that images are allocated on heap now, instead of some outside memory. Anyway, please look at this log below: 10-14 13:43:53.020: INFO/dalvikvm-heap(31533): Grow heap (frag case) to 40.637MB for 942134-byte

Device Policy Manager - Reset Password - Android 3.0 Problems

落花浮王杯 提交于 2020-01-03 03:49:12
问题 I am using Device Policy Manager in my Android App and I have a problem with Honeycomb devices. When attempting to call resetPassword I get an exception thrown. This is not the case in Froyo or Gingerbread, as both of those work fine. The error is: java.lang.RuntimeException: Unable to start receiver Package.Name.Test: java.lang.SecurityException: Permission Denial: writing uri content://settings/secure from pid=x, uid=y requires android

Android 3.0 Honeycomb problem in parsing RSS feed

爷,独闯天下 提交于 2020-01-03 02:50:12
问题 I am trying to parse rss feed in honeycomb 3.0 but it gives error as follows. ERROR/AndroidNews::PullFeedParser(444): android.os.NetworkOnMainThreadException I tried same code in android lower version it works but it doesn't work in Honeycomb. Please suggest some help This is in main activity try{ FeedParser parser = new XmlPullFeedParser(feedUrl); messages = parser.parse(); titles = new ArrayList<String>(messages.size()); String description ="";//= new ArrayList<String>(messages.size()); for

Device administrator disabling

≡放荡痞女 提交于 2020-01-02 11:47:48
问题 Device administration app can not be uninstalled if it is not disabled. User can disable "Device Administrators" from the settings. When company gives android devices to its employees, company wants to have a control over devices, their statuses and policies, but user can easily get rid of that control. Does anybody know how it is possible to prevent user from disabling Device Administrators? Thanks. 回答1: There's no way to prevent the user from disabling Device Administrators, at least using

Adding a Fragment with add() method doesn't hide previous fragments

流过昼夜 提交于 2020-01-01 09:46:55
问题 I'm experiencing "unexpected behaviour" when using add() method to add a new fragment. I want to add a new fragment on a FrameLayout, but when I do it the previous fragment stills visible. Is this the expected result when using add() method? It is because I am using a FrameLayout and add() method just place a fragment over the FrameLayout without affect the previous one? Thx 回答1: Not a bug. Try replace(..). instead adding to the back stack if required. EDIT I think that using replace or

Global Loader (LoaderManager) for reuse in multiple Activities / Fragments

余生颓废 提交于 2020-01-01 07:42:04
问题 What I would like to achieve: I have two different fragments. I would like them both to show the same data in two forms (in a list and on a map). I would like them to share one Loader ( AsyncTaskLoader in particular). Everything works fine, but the Loader isn't re-used. Another one is created and the data is loaded twice. What I do: In the Fragment s I use LoaderManager lm = getActivity().getSupportLoaderManager(); In both of them I implement LoaderCallbacks<ArrayList<Item>> and the required