自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(60)
  • 资源 (1)
  • 收藏
  • 关注

原创 keytool及apksigner常用指令

keytool查看密钥库keytool -list -v -keystore 密钥库名参数: -list 查看密钥列表 -v 查看密钥详情keytool -list -rfc -keystore xxx.jks参数: -list 查看密钥列表 -v 以RFC样式输出,可以查看证书信息查看apk签名证书keytool -printcert -jarfile MyApp.apk (显示签名证书信息,只支持V1签名校验)参数: -p

2022-07-14 17:54:21 609 1

原创 Uri转File Path(兼容Android 7.0+)

/** * 文件Uri转路径(兼容各品牌手机) */public class PathUtils { /** * android7.0以上处理方法 */ private static String getFilePathForN(Context context, Uri uri) { try { Cursor returnCursor = context.getContentResolver().query(uri, nul.

2020-06-04 15:38:32 724

原创 Android 性能优化

一、ANR(Application not responding)程序无响应主要原因:1. 主线程做耗时操作超过5s2. Service做耗时操作超过20s(Service默认执行在主线程,可以使用IntentService)3. BroadcastReceiver中做耗时操作超过10s解决办法:开启子线程来处理二、 内存溢出(Out of Memory)主要...

2019-07-19 11:45:44 169

原创 Android 原生API获取经纬度

注意:Android 6.0以上需要处理动态权限,该类未做权限处理<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" /><uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />...

2019-03-21 14:02:58 1324

转载 常用工具类合集

各种Utilshttps://github.com/Blankj/AndroidUtilCode/blob/master/utilcode/README-CN.md

2018-12-13 14:50:27 215

转载 添加aar的两种方式

https://blog.csdn.net/fengyulinde/article/details/79989813

2018-12-13 11:22:25 2319

原创 Ripple

 res/drawable-v21/ripple_touch.xml&lt;?xml version="1.0" encoding="utf-8"?&gt;&lt;ripple xmlns:android="http://schemas.android.com/apk/res/android" android:color="?android:attr/colorControlH...

2018-11-14 17:01:11 401

转载 Tint着色

https://blog.csdn.net/qq_31370269/article/details/50752211

2018-11-14 10:49:17 304

原创 获取xxx.jks SHA1签名

方法一.android 目录下有keytool工具,将xxx.jks文件放到keytool同级目录下执行命令:keytool -list -v -kestore xxx.jks 方法二:在Android Studio 中打开Terminal,在xxx.jks同级目录执行命令:keytool -list -v -kestore xxx.jks...

2018-11-02 11:41:28 235

原创 ClearEditText

ClearEditText package com.example.lambert.ipconfig.widget;import android.content.Context;import android.graphics.drawable.Drawable;import android.support.v4.content.ContextCompat;import andr...

2018-11-01 19:57:33 412

原创 PermissionDelegate

核心代码 PermissionDelegatepackage com.maibei.mall.utils;import android.app.Activity;import android.app.AlertDialog;import android.content.DialogInterface;import android.content.Intent;import and...

2018-09-09 20:25:27 936

转载 常用的图片处理开源框架

https://blog.csdn.net/axi295309066/article/details/56984137

2018-04-18 17:24:30 2439

转载 ImageView源码详解

http://www.jb51.net/article/85983.htm

2018-03-29 11:00:22 501

转载 多媒体文件扫描

请看这里:http://www.jb51.net/article/59977.htm

2018-03-21 10:16:59 241

转载 BitmapShader

http://blog.csdn.net/harvic880925/article/details/52039081

2018-03-07 11:09:51 164

原创 SingleThreadPool

public class SingleThreadPool { private static final Log.Tag TAG = new Log.Tag("SingleThreadPool"); // Thread Pool private static final int MAX_QUEUE_SIZE = 5000; private static final in

2018-02-02 15:52:58 580

转载 动态代理(转载)

https://www.cnblogs.com/haodawang/p/5967185.html

2018-01-22 15:20:35 199

原创 ModeSwitchView(用于相机中横向切换状态)

核心类public class ModeSwitchView extends LinearLayout implements View.OnClickListener { private ModeScroller mCameraScroller; private TextView document; private TextView idcard; priv

2017-12-29 15:41:10 336

原创 分享功能(自定义UI + app过滤)

核心类public class Share { private static final com.argus.camera.debug.Log.Tag TAG = new com.argus.camera.debug.Log.Tag("Share"); private Context mContext; private List<ResolveInfo> mResolveFil

2017-12-29 14:43:45 499

原创 FileUriExposedException处理方法

if (Build.VERSION.SDK_INT >= 24) { try { Method m = StrictMode.class.getMethod("disableDeathOnFileUriExposure"); m.invoke(null); } catch (Excepti

2017-12-27 17:34:40 583

转载 onInterceptTouchEvent()和requestDisallowInterceptTouchEvent()方法的使用

原帖链接

2017-12-27 13:45:57 375

原创 ViewGrop 滑动与 子View点击事件冲突解决办法

ViewGroup中做如下操作 private boolean mScrolling; private float touchDownX; private float touchDownY; @Override public boolean onInterceptTouchEvent(MotionEvent event) { switch (eve

2017-12-27 11:39:24 777

转载 Android studio下载

Android studio 各版本下载:点击这里Gradle 各版本下载:点击这里

2017-12-15 14:05:38 520

原创 文件大小long转KB,MB,GB

private String formatSize(long size) { return Formatter.formatFileSize(this, size);}formatSize(123456);结果:121KBformatSize(12345612);11.77MBformatSize(1234561234);结果:1.15GB

2017-11-29 17:26:10 2600 2

原创 View获取自身坐标的方法和点击事件中坐标的获取文章标题

一张图搞定:

2017-11-03 15:21:49 279

原创 gradle(release版本配置)

apply plugin: 'com.android.application'android { signingConfigs { release { keyAlias 'ArgusCamera' keyPassword 'arguscamera' storeFile project.rootProjec

2017-11-03 14:43:10 1622

转载 解决Ubuntu上ADB devices找不到设备的问题

有些手机练到Ubuntu上用adb devices找不到设备,原因是“adb内建有一个知名的厂商ID列表,对于列表内的设备,adb可以直接连接,而不在列表中的设备,它会直接返回,这也就是为什么android设备的驱动已经安装好了,而adb连接不上的原因。” 解决方案: 1. 用lsusb命令查询usb设备id 其中,Device 027是我的手机设备,usb id为2717。 2. 进入

2017-10-11 16:10:34 3597

转载 TaskAffinity解析

以前对于Android的四种LaunchMode有一些了解,其中比较有意思的就是SingleTask和SingleInstance 。(四种LaunchMode的了解可以参见这篇文章,对于Activity栈的讲述很详细)。这两种LaunchMode的理解都跟Task有很大关系。 一个Task可以理解成一个Activtiy栈,可以装载一个或者多个Activity,回退和打开的顺序逻辑和基

2017-09-19 17:03:43 479

原创 GifImageView使用

## GifDecoder.java##/** * Copyright (c) 2013 Xcellent Creations, Inc. * Copyright 2014 Google, Inc. All rights reserved. * * Permission is hereby granted, free of charge, to any person obtaining a

2017-09-11 10:44:17 1244

原创 ListView中包含EditText,修改并保存EditText中内容的处理办法

private List<Event> eventList = new ArrayList<>(); private HashMap<Integer, String> eventMap = new HashMap<>(); private class EventListAdapter extends BaseAdapter { @Override pub

2017-09-01 10:30:36 655

原创 ubuntu eclipse android 环境搭建

配置流程链接SDK下载链接

2017-08-24 10:13:46 260

原创 配置成系统Service

AndroidManifest.xml<?xml version="1.0" encoding="utf-8"?><manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.lenovo.cava" coreApp="true" android:sharedUserId=

2017-08-22 10:25:30 279

原创 ContentProvider模板

package com.lenovo.seeplus.provider;import android.content.Context;import android.database.sqlite.SQLiteDatabase;import android.database.sqlite.SQLiteOpenHelper;public class DatabaseHelper extends SQ

2017-08-17 15:43:32 245

原创 设置状态栏颜色

private void setStatusBarColor() { Window window = getWindow(); //取消设置透明状态栏,使 ContentView 内容不再覆盖状态栏 window.clearFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS);

2017-08-14 14:24:28 313

原创 属性动画

public static void animateProperty(final View view, Animator.AnimatorListener animationListener) { /*ObjectAnimator a1 = ObjectAnimator.ofFloat(view, "scaleX", 1.1f, 1f); ObjectAnimator

2017-07-31 11:22:12 214

转载 HandlerThread简介

请参考此链接

2017-06-14 14:36:01 268

原创 String.xml(加粗,下划线,倾斜,换行)

加粗字体 斜体字体 给字体加下划线 \n 换行 \u0020表示空格 \u2026表示省略号 使用<b>和<b>来打印出 这样的文字;“<”表示“<”的意思; 使用textView.setText(Html.fromHtml(“Hello World,AnalysisXmlActivty!“));设置类似于html那样的效果 如果你需要使用 String.format(String, Objec

2017-04-24 17:50:39 4827 1

原创 framework编译后烧录系统

步骤: 1.android source code 根目录下,执行make systemimage; 2.cd out/target/product/shamu; 3.adb reboot bootloader; 4.fastboot flash system system.img; 5.fastboot reboot

2017-04-07 13:56:59 818

原创 monkeyrunner使用

1.monkeyrunner工具位于android-sdk/tools目录下命令行模式下: 1.monkeyrunner运行 2.import 3.连接 4.向下拖拽 第一个参数,第一点的x,y坐标 第二个参数,移动点的x,y坐标 第三个参数,执行时间duration 第四个参数,选取的点数,默认10Python脚本模式: 1.在monkeyrunner同级目录下创

2016-11-15 18:28:03 296

转载 Android动态权限

转载

2016-11-02 10:52:37 599

融云libsqlite.so

RongIM.connect()失效,Android7.0以后禁止访问系统.so导致

2018-10-30

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除