2012-1-10 17:53:07 阅读21 评论0 102012/01 Jan10
在AndroidManifest.xml的application加个name属性就可以了,如下面所示:
android:name=".MyApp" android:icon="@drawable/icon"
android:label="@string/app_name">
2011-12-9 10:24:29 阅读69 评论0 92011/12 Dec9
最近android developer官网给出了ADT 14的升级包,很多朋友选择了升级,然后在开发的时候,编译工程出现了下面的错误提示
android ERROR:Unknown option '--no-crunch'
Android Asset Packaging Tool
Usage:
aapt l[ist] [-v] [-a] file.{zip,jar,apk}
总结一下,原因就是只更新了ADT而没有对Android SDK tools 和Android
2011-12-7 17:18:33 阅读45 评论0 72011/12 Dec7
res/values文件夹新建名为 dialogStyle.xml的resources样式文件,具体代码如下:
2011-10-27 16:33:46 阅读228 评论0 272011/10 Oct27
getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_VISIBLE);
/**
* 收起软键盘并设置提示文字
*/
public void collapseSoftInputMethod(){
InputMethodManager imm = (InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE);
imm.hideSoftInputFromWindow(inputText.getWindowToken(), InputMethodManager.HIDE_IMPLICIT_ONLY);
}