English 中文(简体)
• 如何处理APICA版本的建筑 minSdkVersion?
原标题:How to handle build API version > minSdkVersion?
  • 时间:2012-01-14 05:56:34
  •  标签:
  • android

my app has minSdkVersion = 8, targetSdkVersion = 15 and SDK build version = 8. In general it works well, including on ICS but I would like to provide few more features to ICS users, for example resizeable widgets. This requires increasing also the SDK build version to 15.

我对安普森静态安全感到关切。 例如,如果我无意中使用旧电话上无法提供的亚普特特征。

What are good practices to handle SDK build version > minSdkVersion? How can I verify before shipping a new version that it does not break on old phones? What are good practices to address it?

最佳回答

我不知道这是否被视为“良好做法”,但我只是将文件<代码>>项目.properties<>/code>开放,并将财产编号<>target=android-11改为我想要检查的APIC级。 一旦档案得到保存,Eclipse将开始出现标语错误,因为APIC在设计书上发出呼吁。 我只通过这些检查点进行扫描,检查这些检查是否包含在APIC级检查中,然后改变财产。

问题回答

我尝试了Glitch的回答(晚!),这种回答是哪类工作,但并非我所期望的那样。 我的植被信息档案有AP 15等特性。

android:minResizeWidth="40dp"
android:minResizeHeight="40dp"
android:resizeMode="horizontal|vertical"

When I change the SDK build version from 15 to 8, these lines are flagged at error (which is fine) which fail the generation of the R class. This in turn flags every reference to R as an error (hundrads). Now, if I have something like

someApi15SpecificMethod(R.xyz)

由于这一论点没有界定,因此如果Api15SpecificMethod(......)在A/60/88中存在的话,就无法安全地说明。

由于格利奇的回答是迄今为止最好的,我在回答时表示了这一点,但请在此提出想法。





相关问题
Android - ListView fling gesture triggers context menu

I m relatively new to Android development. I m developing an app with a ListView. I ve followed the info in #1338475 and have my app recognizing the fling gesture, but after the gesture is complete, ...

AsyncTask and error handling on Android

I m converting my code from using Handler to AsyncTask. The latter is great at what it does - asynchronous updates and handling of results in the main UI thread. What s unclear to me is how to handle ...

Android intent filter for a particular file extension?

I want to be able to download a file with a particular extension from the net, and have it passed to my application to deal with it, but I haven t been able to figure out the intent filter. The ...

Android & Web: What is the equivalent style for the web?

I am quite impressed by the workflow I follow when developing Android applications: Define a layout in an xml file and then write all the code in a code-behind style. Is there an equivalent style for ...

TiledLayer equivalent in Android [duplicate]

To draw landscapes, backgrounds with patterns etc, we used TiledLayer in J2ME. Is there an android counterpart for that. Does android provide an option to set such tiled patterns in the layout XML?

Using Repo with Msysgit

When following the Android Open Source Project instructions on installing repo for use with Git, after running the repo init command, I run into this error: /c/Users/Andrew Rabon/bin/repo: line ...

Android "single top" launch mode and onNewIntent method

I read in the Android documentation that by setting my Activity s launchMode property to singleTop OR by adding the FLAG_ACTIVITY_SINGLE_TOP flag to my Intent, that calling startActivity(intent) would ...

From Web Development to Android Development

I have pretty good skills in PHP , Mysql and Javascript for a junior developer. If I wanted to try my hand as Android Development do you think I might find it tough ? Also what new languages would I ...

热门标签