![](https://img-blog.csdnimg.cn/20201014180756923.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
技术
入门级
这个作者很懒,什么都没留下…
展开
-
Android设置全屏,屏幕保持长亮
设置Activity全屏的三种方式1、代码中设置//去掉TitlerequestWindowFeature(Window.FEATURE_NO_TITLE);//保持全屏getWindow().addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);//保持常亮getWindow().addFlags(WindowManager....原创 2019-05-30 21:20:42 · 554 阅读 · 0 评论 -
前台服务,Notification的使用
1.Android6.0 以下版本可以这么用,在Service的onCreate方法中public class MyService extends Service { @Override public void onCreate() { super.onCreate(); Intent intent = new Intent(this, Sec...原创 2018-07-08 22:27:50 · 842 阅读 · 0 评论 -
使用阿里云国内镜像
使用阿里云国内镜像在项目中的build.gradle修改内容buildscript { repositories { maven { url 'http://maven.aliyun.com/nexus/content/groups/public/' } maven { url 'http://maven.aliyun.com/nexus/c...原创 2019-05-03 14:36:28 · 7103 阅读 · 0 评论 -
使用Android Studio将Module项目导出成Jar包
AndroidStudio 3.4 版本:例子:module包名是com.example.mylibrary,在module内部的build.gradle文件中添加任务task exportJar(type: Copy) { //必须先删除旧的包,否则新包不会生成,这个目录对应mylibrary/build/libs/AndroidUtils.jar delete 'bu...原创 2018-11-05 18:56:56 · 687 阅读 · 0 评论 -
Android 中定义dialog类型的Activity
1.第一种a). 需要在styles.xml文件中定义一个Theme<!--继承 @android:style/Theme.Dialog--><style name="CustomTheme" parent="@android:style/Theme.Dialog"> <item name="android:background">#...原创 2018-01-08 17:24:43 · 985 阅读 · 0 评论