安卓手机更改串号用户名更改

实现应用内用户头像更改
今天有点累,我就直接把代码粘上了,不过我在里面加了注释,方便大家理解。
public class IntentActivity extends AppCompatActivity implements View.OnClickListener {
private View popV
private GridView gv1;
private Button popC
private PopupW
RoundImageV
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_intent);
Button bt1 = (Button) findViewById(R.id.bt1);
bt1.setOnClickListener(this);
Button bt2 = (Button) findViewById(R.id.bt2);
bt2.setOnClickListener(this);
Button bt3 = (Button) findViewById(R.id.bt3);
bt3.setOnClickListener(this);
Button bt4 = (Button) findViewById(R.id.bt4);
bt4.setOnClickListener(this);
Button bt5 = (Button) findViewById(R.id.bt5);
bt5.setOnClickListener(this);
Button bt6 = (Button) findViewById(R.id.bt6);
bt6.setOnClickListener(this);
Button bt7 = (Button) findViewById(R.id.bt7);
bt7.setOnClickListener(this);
riv = (RoundImageView) findViewById(R.id.riv);
riv.setOnClickListener(this);
//加载popWindow的布局
popView = getLayoutInflater().inflate(R.layout.popwindow_layout,null);
gv1 = (GridView) popView.findViewById(R.id.gv1);
//从popWindow布局中取得控件
popCancel = (Button) popView.findViewById(R.id.popCancle);
popCancel.setOnClickListener(this);
popView.findViewById(R.id.camera).setOnClickListener(this);
popView.findViewById(R.id.photo).setOnClickListener(this);
List list = new ArrayList();
Map map = new HashMap();
map.put(&img&,R.mipmap.picture04);
map.put(&name&,&拍照&);
list.add(map);
map = new HashMap();
map.put(&img&,R.mipmap.picture01);
map.put(&name&,&从手机相册选择&);
list.add(map);
map = new HashMap();
map.put(&img&,R.mipmap.picture08);
map.put(&name&,&嘿嘿嘿~&);
list.add(map);
SimpleAdapter sa = new SimpleAdapter(this,list,R.layout.gridview_layout,
new String[]{&img&,&name&},new int[]{R.id.iv,R.id.tv});
gv1.setAdapter(sa);
//显示Intent,明确的指明它要跳转到哪个Activity
Intent intent = new Intent(IntentActivity.this,IntentActivity.class);
startActivity(intent);
//隐示Intent,由帮助匹配
//匹配规则:清单文件中的Intent-filter 标签中的 action
Uri uri = Uri.parse(&tel:1008611&);
Intent intent = new Intent(Intent.ACTION_DIAL,uri);
startActivity(intent);
public void onClick(View view) {
int id = view.getId();
switch (id) {
case R.id.bt1:
Uri uri1 = Uri.parse(&tel:&);
Intent intent1 = new Intent(Intent.ACTION_CALL, uri1);
if (ActivityCompat.checkSelfPermission(this, Manifest.permission.CALL_PHONE) != PackageManager.PERMISSION_GRANTED) {
// TODO: Consider calling
ActivityCompat#requestPermissions
// here to request the missing permissions, and then overriding
public void onRequestPermissionsResult(int requestCode, String[] permissions,
int[] grantResults)
// to handle the case where the user grants the permission. See the documentation
// for ActivityCompat#requestPermissions for more details.
startActivity(intent1);
case R.id.bt2:
Intent intent2 = new Intent(Intent.ACTION_VIEW);
intent2.putExtra(&sms_body&,&发送短信&);
intent2.setType(&vnd.android-dir/mms-sms&);
startActivity(intent2);
case R.id.bt3:
Uri uri2 = Uri.parse(&&);
Intent intent3 = new Intent(Intent.ACTION_VIEW,uri2);
startActivity(intent3);
case R.id.bt4:
Intent intent4 = new Intent(Intent.ACTION_VIEW);
File file1 = new File(&/storage/sdcard1/酷派/酷派8297数据/1989/01 Welcome To New York.m4a&);
intent4.setDataAndType(Uri.fromFile(file1),&audio/*&);
startActivity(intent4);
case R.id.bt5:
Intent intent5 = new Intent(Intent.ACTION_VIEW);
File file2 = new File(&/storage/sdcard1/video/虫子.jpeg&);
intent5.setDataAndType(Uri.fromFile(file2),&image/*&);
startActivity(intent5);
case R.id.bt6:
Intent intent6 = new Intent(Intent.ACTION_VIEW);
intent6.setDataAndType(Uri.parse(&file:///storage/sdcard1/video/Beytagh最佳.apk&),
&application/vnd.android.package-archive&);
startActivity(intent6);
case R.id.bt7:
notification();
case R.id.riv:
pw = getPopWindow(popView);
case R.id.popCancle:
pw.dismiss();
case R.id.camera:
tackPhoto();
case R.id.photo:
phonePhoto();
public void phonePhoto(){
Intent intent = new Intent(Intent.ACTION_PICK,
MediaStore.Images.Media.EXTERNAL_CONTENT_URI);
startActivityForResult(intent,2);
private String capturePath =&&;
public void tackPhoto(){
Intent camera = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);
File parent = FileUitlity.getInstance(getApplicationContext())
.makeDir(&head_img&);
//给拍完的照片起名字
capturePath = parent.getPath()
+File.separatorChar
+System.currentTimeMillis()
camera.putExtra(MediaStore.EXTRA_OUTPUT,
Uri.fromFile(new File(capturePath)));
camera.putExtra(MediaStore.EXTRA_VIDEO_QUALITY,1);
//该方法的值会返回到onActivityResult里
startActivityForResult(camera,1);
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
if(resultCode != Activity.RESULT_OK){
Toast.makeText(this,&系统异常&,Toast.LENGTH_SHORT).show();
//相机返回结果,再去调用系统裁剪
if(requestCode==1){
startPicZoom(Uri.fromFile(new File(capturePath)));
}//相册返回结果,再去调用系统裁剪
else if(requestCode==2){
//Cursor相当于一个指针,是一个结果集,一个游标
Cursor cursor = getContentResolver().query(data.getData(),
new String[]{MediaStore.Images.Media.DATA},null,null,null);
cursor.moveToFirst();
String capturePath = cursor.getString(cursor.getColumnIndex(MediaStore.Images.Media.DATA));
cursor.close();
startPicZoom(Uri.fromFile(new File(capturePath)));
}else if(requestCode==3){
Bundle bundle = data.getExtras();
if(bundle!=null){
Bitmap bitmap = bundle.getParcelable(&data&);
riv.setImageBitmap(bitmap);
pw.dismiss();
//消息栏通知
public void notification(){
//先定义一个Intent
Intent intent = new Intent(this,SecondActivity.class);
//使用PendingIntent 封装 Intent
/*PendingIntent第四个参数(常量)的种类及说明:
FLAG_CANCEL_CURRENT:如果要创建的PendingIntent已经存在了,
那么在创建新的PendingIntent之前,原先已经存在的PendingIntent中的intent将不能使用
FLAG_NO_CREATE:如果要创建的PendingIntent尚未存在,则不创建新的PendingIntent,直接返回null
FLAG_ONE_SHOT:相同的PendingIntent只能使用一次,且遇到相同的PendingIntent时不会
去更新PendingIntent中封装的Intent的extra部分的内容
FLAG_UPDATE_CURRENT:如果要创建的PendingIntent已经存在了,那么在保留原
先PendingIntent的同时,将原先PendingIntent封装的Intent中的extra部分替换为现
在新创建的PendingIntent的intent中extra的内容
PendingIntent pi = PendingIntent.getActivities(this,0,new Intent[]{intent},
PendingIntent.FLAG_UPDATE_CURRENT);
//获取通知服务
NotificationManager nm = (NotificationManager)
getSystemService(Activity.NOTIFICATION_SERVICE);
//设置各个属性
Notification notification = new NotificationCompat.Builder(this)
.setSmallIcon(R.mipmap.ic_launcher)
.setTicker(&A&)
.setContentInfo(&我是通知栏信息&)
.setContentTitle(&奥运会&)
.setContentText(&PendingIntent使用演示&)
.setAutoCancel(true)
.setDefaults(Notification.DEFAULT_ALL)
.setContentIntent(pi)
//通过通知服务显示通知栏,这个0是Id,如果再设置一个通知,而ID不变的话,那么会覆盖掉该通知
nm.notify(0,notification);
//设置PopWindow背景透明度的方法
public void backgroundAlpha(float bgAlpha){
WindowManager.LayoutParams lp = getWindow().getAttributes();
lp.alpha= bgA
getWindow().setAttributes(lp);
//构建一个popwindow
//方法PopWindow
public PopupWindow getPopWindow(View view){
PopupWindow popupWindow = new PopupWindow(view, LinearLayout.LayoutParams.MATCH_PARENT,
LinearLayout.LayoutParams.WRAP_CONTENT,false);
popupWindow.setAnimationStyle(R.style.pop1);
//设置背景透明度
backgroundAlpha(0.6f);
//-------------
//获取光标
popupWindow.setOutsideTouchable(true);
popupWindow.setBackgroundDrawable(new ColorDrawable());
//显示的位置,第一个参数为参照物,随便找一个就行
popupWindow.showAtLocation(riv, Gravity.BOTTOM,0,0);
popupWindow.setOnDismissListener(new PopupWindow.OnDismissListener() {
public void onDismiss() {
backgroundAlpha(1f);
return popupW
调用系统的裁剪功能
public void startPicZoom(Uri uri){
Intent intent = new Intent(&com.android.camera.action.CROP&);
intent.setDataAndType(uri,&image/*&);
//允许裁剪
intent.putExtra(&crop&,&true&);
//设置裁剪比例
intent.putExtra(&ectX&,1);
intent.putExtra(&aspectY&,1);
//设置图片的高度和宽度
intent.putExtra(&outputX&,150);
intent.putExtra(&outputY&,150);
//是否返回数据
intent.putExtra(&return-data&,true);
startActivityForResult(intent,3);
RoundImageView让图片变圆的工具类(直接复制即可):
public class RoundImageView extends ImageView { public RoundImageView(Context context) { super(context); // TODO Auto-generated constructor stub } public RoundImageView(Context context, AttributeSet attrs) { super(context, attrs); // TODO Auto-generated constructor stub } public RoundImageView(Context context, AttributeSet attrs, int defStyle) { super(context, attrs, defStyle); // TODO Auto-generated constructor stub } @Override protected void onDraw(Canvas canvas) { Drawable drawable = getDrawable(); if (drawable == null) { } if (getWidth() == 0 || getHeight() == 0) { } Bitmap b = if(drawable instanceof BitmapDrawable){ b = ((BitmapDrawable) drawable).getBitmap(); }else if(drawable instanceof Drawable){ b = Bitmap.createBitmap( getWidth(), getHeight(), drawable.getOpacity() != PixelFormat.OPAQUE ? Bitmap.Config.ARGB_8888 : Bitmap.Config.RGB_565); Canvas canvas1 = new Canvas(b); // canvas.setBitmap(bitmap); drawable.setBounds(0, 0, getWidth(), getHeight()); drawable.draw(canvas1); } if (null == b) { } Bitmap bitmap = b.copy(Bitmap.Config.ARGB_8888, true); int w = getWidth(), h = getHeight(); Bitmap roundBitmap = getCroppedBitmap(bitmap, w); canvas.drawBitmap(roundBitmap, 0, 0, null); } public static Bitmap getCroppedBitmap(Bitmap bmp, int radius) { B if (bmp.getWidth() != radius || bmp.getHeight() != radius) sbmp = Bitmap.createScaledBitmap(bmp, radius, radius, false); else sbmp = Bitmap output = Bitmap.createBitmap(sbmp.getWidth(), sbmp.getHeight(), Bitmap.Config.ARGB_8888); Canvas canvas = new Canvas(output); final int color = 0xffa19774; final Paint paint = new Paint(); final Rect rect = new Rect(0, 0, sbmp.getWidth(), sbmp.getHeight()); paint.setAntiAlias(true); paint.setFilterBitmap(true); paint.setDither(true); canvas.drawARGB(0, 0, 0, 0); paint.setColor(Color.parseColor(&#BAB399&)); canvas.drawCircle(sbmp.getWidth() / 2 + 0.7f, sbmp.getHeight() / 2 + 0.7f, sbmp.getWidth() / 2 + 0.1f, paint); paint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC_IN)); canvas.drawBitmap(sbmp, rect, rect, paint); } }
FileUitlity给相机拍照的照片设置存放文件夹的工具类(可直接复制)
public class FileUitlity { public final static String USER_HAED=&head&; private static String ROOT_CACHE; public static String ROOT_DIR=&yt_xyt&; private static FileUitlity instance = private FileUitlity() { } public static FileUitlity getInstance(Context context) { if (instance == null) { if (Environment.getExternalStorageState().equals( Environment.MEDIA_MOUNTED)) { ROOT_CACHE = (Environment.getExternalStorageDirectory() + &/& + ROOT_DIR + &/&); } else { ROOT_CACHE = (context.getFilesDir().getAbsolutePath() + &/&+ROOT_DIR+&/&); } File dir = new File(ROOT_CACHE); if (!dir.exists()) { dir.mkdirs(); } instance = new FileUitlity(); } } public File makeDir(String dir) { File fileDir = new File(ROOT_CACHE + dir); if (fileDir.exists()) { return fileD } else { fileDir.mkdirs(); return fileD } } }
因为要用到PopWindow,所以建一个PopWindow的layout:
千万记得在清单文件AndroidManifest中设置权限哦~
我这里面用到了两个动画效果设置了下PopWindow的动画:
pop_enter1
记得在Styles文件夹中定义个样式:
OK,效果图如下:安卓MTK改串号IMEI 一键修改 一键新机各种手机app注册
无限次_手机app注册吧_百度贴吧
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&签到排名:今日本吧第个签到,本吧因你更精彩,明天继续来努力!
本吧签到人数:0可签7级以上的吧50个
本月漏签0次!成为超级会员,赠送8张补签卡连续签到:天&&累计签到:天超级会员单次开通12个月以上,赠送连续签到卡3张
关注:17贴子:
安卓MTK改串号IMEI 一键修改 一键新机各种手机app注册
成都北路500号近南京西路,021-专业订制APP,原生开发
app一机注册多账号。现在很多手机软件都会需要注册账号,而且一机只能注册一个,基于各种原因想注册多个会提示类似“本机已绑定某某账号”,此种情况基本也是因为软件已经将手机串号和账号绑定了,那么修改串号就派上用场了。
软件链接何在???
在哪里下载
贴吧热议榜
使用签名档&&
保存至快速回贴怎样修改安卓手机文件权限、所有者和用户组_文档库
文档库最新最全的文档下载
当前位置: & 怎样修改安卓手机文件权限、所有者和用户组
怎样修改安卓手机文件权限、所有者和用户组
安卓手机刷机或者美化时,有时需要将文件放到系统文件夹内,并且需要修改权限、所有者和用户组,否则可能会引起强制关闭。下面就告诉大家如何修改文件权限、所有者和用户组。
? ? 一部安卓系统的手机(已root) 安装有R.E.管理器软件
1. 首先在内存卡中选中该文件,选择移动,如下图所示:
Word文档免费下载:
(共13页)
任何其他用户不能改变文件所有者;需要共享对一组文 件的访问的多咯用户可放置...怎样修改安卓手机文件权... 13页 免费
修改LINUX目录或文件的权... 3页 免费...确定了一个文件的访问权限后,用户可以利用 Linux 系统提供的 chmod 命令来重新设定不同的访问 权限。也可以利用 chown 命令来更改某个文件或目录的所有者。利用 ...用户和文件权限管理_IT/计算机_专业资料。unix/linux...更改用户的有关属性,如用户号,主目录,用户组,登录...的所有者是 www,您可以设置用户 wwwadm 与 www ...文件操作命令 文件权限:文件类型、文件权限(rwx=421)(所有者所属组其它用户)三、修改文件权限折方法 1、修改权限:chmod a|u|g|o +/- rwx filename chmod ...查看设置结果。 ● 用数字形式为文件 file1 设置权限,所有者可读、可写、可执行;其他用户和所属组用户只有读和执 行的权限。设置完成后查看设置结果。 ● 用...3.所有者是?所属组是? 4.如何对李磊用户开放test目录(有rwx权限)? 5.如何修改所属组?所有者? 6.如何修改文件权限? chgrp: change group chown :change ...扫描二维码下载 支持Android / iPhone / iPad文档信息...用数字形式为文件 filel 设置权限,所有者可读、可...sdb1 分区添加用户和组的磁盘限额,重新启动 系统. ...查看设置结果。 ● 用数字形式为文件 file1 设置权限,所有者可读、可写、可执行;其他用户和所属组用户只有读和执 行的权限。设置完成后查看设置结果。 ● 用...更多频道内容在这里查看
爱奇艺用户将能永久保存播放记录
过滤短视频
暂无长视频(电视剧、纪录片、动漫、综艺、电影)播放记录,
使用您的微博帐号登录,即刻尊享微博用户专属服务。
使用您的QQ帐号登录,即刻尊享QQ用户专属服务。
使用您的人人帐号登录,即刻尊享人人用户专属服务。
按住视频可进行拖动
把视频贴到Blog或BBS
当前浏览器仅支持手动复制代码
视频地址:
flash地址:
html代码:
通用代码:
通用代码可同时支持电脑和移动设备的分享播放
收藏成功,可进入查看所有收藏列表
方式1:用手机看
用爱奇艺APP或微信扫一扫,在手机上继续观看:
一键霸气修改手机唯一识别号androidid最便捷教程
方式2:一键下载至手机
限爱奇艺安卓6.0以上版本
使用微信扫一扫,扫描左侧二维码,下载爱奇艺移动APP
其他安装方式:手机浏览器输入短链接http://71.am/udn
下载安装包到本机:&&
设备搜寻中...
请确保您要连接的设备(仅限安卓)登录了同一爱奇艺账号 且安装并开启不低于V6.0以上版本的爱奇艺客户端
连接失败!
请确保您要连接的设备(仅限安卓)登录了同一爱奇艺账号 且安装并开启不低于V6.0以上版本的爱奇艺客户端
部安卓(Android)设备,请点击进行选择
请您在手机端下载爱奇艺移动APP(仅支持安卓客户端)
使用微信扫一扫,下载爱奇艺移动APP
其他安装方式:手机浏览器输入短链接http://71.am/udn
下载安装包到本机:&&
爱奇艺云推送
请您在手机端登录爱奇艺移动APP(仅支持安卓客户端)
使用微信扫一扫,下载爱奇艺移动APP
180秒后更新
打开爱奇艺移动APP,点击“我的-扫一扫”,扫描左侧二维码进行登录
没有安装爱奇艺视频最新客户端?
爸爸去哪儿2游戏 立即参与
一键霸气修改手机唯一识别号androidid最便捷教程
播放量数据:
154人已订阅
你可能还想订阅他们:
{{#needAdBadge}} 广告{{/needAdBadge}}
&正在加载...
您使用浏览器不支持直接复制的功能,建议您使用Ctrl+C或右键全选进行地址复制
安装爱奇艺视频客户端,
马上开始为您下载本片
5秒后自动消失
&li data-elem="tabtitle" data-seq="{{seq}}"& &a href="javascript:void(0);"& &span>{{start}}-{{end}}&/span& &/a& &/li&
&li data-downloadSelect-elem="item" data-downloadSelect-selected="false" data-downloadSelect-tvid="{{tvid}}"& &a href="javascript:void(0);"&{{pd}}&/a&
选择您要下载的《
色情低俗内容
血腥暴力内容
广告或欺诈内容
侵犯了我的权力
还可以输入
您使用浏览器不支持直接复制的功能,建议您使用Ctrl+C或右键全选进行地址复制

我要回帖

更多关于 手机用户名更改 的文章

 

随机推荐