上一页 1 2 3 4 5 6 7 8 9 ··· 38 下一页
摘要: 设置view的背景颜色,有两种方法,一种是通过代码写的形式,一种是通过写一个xml的形式 先说第一种,用代码实现view的背景渐变色: int colors[] = { 0xff2D0081 , 0xff8B3097, 0xffD14E7A }; GradientDrawable bg = new 阅读全文
posted @ 2022-09-19 10:16 野生野鸡码农 阅读(309) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2022-09-08 17:57 野生野鸡码农 阅读(8) 评论(0) 推荐(0) 编辑
摘要: //java class UIUtils { public static int getScreenWidthInPx(Context context) { DisplayMetrics dm = context.getApplicationContext().getResources().getD 阅读全文
posted @ 2022-05-13 18:13 野生野鸡码农 阅读(1674) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2022-04-13 16:08 野生野鸡码农 阅读(0) 评论(0) 推荐(0) 编辑
摘要: https://www.kancloud.cn/apachecn/programiz-zh/1951767 val num = 1.34567 var o = list.get(i).ori_price.toDouble()var p = list.get(i).price.toDouble()va 阅读全文
posted @ 2022-03-30 16:34 野生野鸡码农 阅读(1590) 评论(0) 推荐(0) 编辑
摘要: var list: ArrayList<PayItem> = Gson().fromJson(resultStr, object : TypeToken<ArrayList<PayItem>>() {}.type) 阅读全文
posted @ 2022-03-24 17:50 野生野鸡码农 阅读(368) 评论(0) 推荐(0) 编辑
摘要: 拿走不谢!! import android.content.Context;import android.graphics.drawable.Drawable;import android.util.AttributeSet;import android.widget.ImageView; publ 阅读全文
posted @ 2022-03-24 16:33 野生野鸡码农 阅读(388) 评论(0) 推荐(0) 编辑
摘要: 需求 有时会需要改变布局颜色透明度,比如设置控件(如View,Button等)的透明度,有3种方法。 实现方法 java代码实现 text = (TextView) findViewById(R.id.text); text.getBackground().setAlpha(12); setAlph 阅读全文
posted @ 2022-03-22 17:01 野生野鸡码农 阅读(1997) 评论(0) 推荐(0) 编辑
摘要: 支付宝SDK与友盟SDK都有同样的utdid包,所以需要移除其中一个 app的build.gradle中 dependencies { api('com.umeng.umsdk:push:6.4.0') { exclude group: 'com.umeng.umsdk', module: 'utd 阅读全文
posted @ 2022-02-23 16:31 野生野鸡码农 阅读(680) 评论(0) 推荐(0) 编辑
摘要: 修改前: 修改后: 步骤: 1,定义style:在工程的res/values/styles.xml中添加👇下面配置 <style name="zhuTextStyle" parent="AppTheme.NoActionBar"> <item name="android:colorControlA 阅读全文
posted @ 2022-01-25 15:00 野生野鸡码农 阅读(254) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 ··· 38 下一页