![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Android
daydreamor
这个作者很懒,什么都没留下…
展开
-
Android TabLayout+SearchView 组成TitleBar
Android TabLayout+SearchView 组成TitleBar效果预览布局如下<androidx.constraintlayout.widget.ConstraintLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingTop="30dp" android:background="@color/colorPrim原创 2020-07-31 15:31:49 · 238 阅读 · 0 评论 -
Android dialog设置不可取消后,返回键不可用(onKeyDown无效)
Android dialog设置不可取消后,返回键不可用(onKeyDown无效)当activity中dialog设置为不可取消时,点击系统返回键是不会使dialog消失,也不会退出当前activitydialog.setCancelable(false);dialog.setCanceledOnTouchOutside(false);但是,如果此时需求需要系统返回键发挥作用时,重写activity中的onKeyDown是不起作用的//返回键事件会先被dialog拦截,onKeyDown方法并不原创 2020-07-18 08:59:21 · 3300 阅读 · 1 评论 -
Android shortcut快捷方式使用-静态方法
Android shortcut快捷方式使用-静态方法静态声明shortcut需要Android Api V25以上的支持资源文件xml增加shortcut配置文件在res-xml中新建shortcusts.xml文件<?xml version="1.0" encoding="utf-8"?><shortcuts xmlns:android="http://schemas.android.com/apk/res/android"> <shortcut原创 2020-06-20 16:30:06 · 569 阅读 · 0 评论