上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 31 下一页
摘要: 在src目录创建(main.js所在目录) filter目录 创建index.js 在main.js中 import 该js文件即可 (或者直接把定义的filter放到main.js 中 ,建议新建一个js文件,都放mian.js里面看起来东西太多了有点乱) 我这里定义一个 日期格式化过滤器 ,可以 阅读全文
posted @ 2020-08-24 11:08 荣超 阅读(512) 评论(0) 推荐(0)
摘要: 宽高一定要设置否者设置宽高时,(popupwindow)需要注意高度要减去顶部状态栏的高度 (如果你的activity是全屏模式的话,可以不用处理)当然我们也可以自己设置高度 比如可以设置屏幕高度的一半或者其他 //获取顶部状态栏的高度val resourceId: Int = context.re 阅读全文
posted @ 2020-08-20 18:24 荣超 阅读(568) 评论(0) 推荐(0)
摘要: val resourceId: Int = activity.resources.getIdentifier("status_bar_height", "dimen", "android") val statusBarHeight: Int = activity.resources.getDimen 阅读全文
posted @ 2020-08-20 18:07 荣超 阅读(4026) 评论(0) 推荐(1)
摘要: 显示输入法 val manager = context?.getSystemService(Context.INPUT_METHOD_SERVICE) as InputMethodManager? manager?.showSoftInput(v, InputMethodManager.SHOW_I 阅读全文
posted @ 2020-08-20 16:01 荣超 阅读(762) 评论(0) 推荐(0)
摘要: //添加tab 并设置为已选中 tab_layout.addTab(tab_layout.newTab().setText("请选择"),0,true) //跳转到selectedPos位置,并让其置顶(只要有置顶的条件) (recycle_view.layoutManager as LinearL 阅读全文
posted @ 2020-08-08 09:40 荣超 阅读(1151) 评论(0) 推荐(0)
摘要: 首先要重写 DataSource ItemKeyedDataSource 根据数据的最后一条数据的ID 得到下一页的数据 PageKeyedDataSource 这个是普通的分页(第一页,第二页) PositionalDataSource 按照索引位置加载数据 比如是索引0 一页显示20条数据 对应 阅读全文
posted @ 2020-08-07 15:51 荣超 阅读(437) 评论(0) 推荐(0)
摘要: 需要在res/value/下常见attrs.xml 文件 <?xml version="1.0" encoding="utf-8"?> <resources> <declare-styleable name="MyView"> <attr name="bgColor" format="color" 阅读全文
posted @ 2020-08-03 10:43 荣超 阅读(216) 评论(0) 推荐(0)
摘要: 安装 npm install vue-lazyload --save 在main.js全局引入 //使用默认配置 Vue.use(VueLazyload) // 自己配置参数 Vue.use(VueLazyload, { preLoad: 1.3, error: 'dist/error.png', 阅读全文
posted @ 2020-07-31 18:59 荣超 阅读(222) 评论(0) 推荐(0)
摘要: 语法 SELECT expression1, expression2, ... expression_n FROM tables [WHERE conditions] UNION [ALL | DISTINCT] SELECT expression1, expression2, ... expres 阅读全文
posted @ 2020-07-31 10:15 荣超 阅读(1171) 评论(0) 推荐(0)
摘要: 首先安装 npm install vuedraggable --save 页面使用时引入import Draggable from 'vuedraggable' export default { name: "draggable", components: { Draggable }, data() 阅读全文
posted @ 2020-07-30 18:16 荣超 阅读(1488) 评论(0) 推荐(0)
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 31 下一页