吾爱破解 - 52pojie.cn

 找回密码
 注册[Register]

QQ登录

只需一步,快速开始

查看: 6231|回复: 24
收起左侧

[Android 原创] Anyview 本地(补充)

[复制链接]
Minister 发表于 2022-2-14 12:35
本帖最后由 Minister 于 2022-2-14 12:58 编辑

上一贴 https://www.52pojie.cn/thread-1584601-1-1.html

此次更改的效果图:

2022-02-14_104836.jpg
用到的工具:
  • Android Killer
  • jadx-gui-1.2.0-no-jre-win.exe



更改过程:
1.搜索关键词 "上传至A盘"
2.jpg

2.用jadx 搜关键词"upload_file_to_a_disk"
3.jpg
百度一下adapter 适配器
猜:com.anyview.core.AppShelfAdapter 是App的适配,宏观
    com.anyview.core.FileIndexAdapter  是APP下主观文件索引的适配,等级低于App的适配
应该点进去com.anyview.core.AppShelfAdapter,(万一错了,重来)
[Java] 纯文本查看 复制代码
    @Override // com.anyview.api.core.AbsBaseAdapter
    public void showPopMenu(int position) {
        super.showPopMenu(position);
        String fullPath = ((ReaderHistoryBean) this.mDataHolders.get((this.mDataHolders.size() - 1) - this.selection)).getFullpath();
        Activity activity = this.mActivity;
        BaseDialog.Builder builder = new BaseDialog.Builder(activity);
        String[] stringlist = ((fullPath == null || !fullPath.endsWith(".aikan")) && fullPath != null && !"".equals(fullPath)) ? new String[]{activity.getString(C0031R.string.delete), activity.getString(C0031R.string.property), activity.getString(C0031R.string.replace_cover), activity.getString(C0031R.string.rename), activity.getString(C0031R.string.upload_file_to_a_disk)} : new String[]{activity.getString(C0031R.string.delete), activity.getString(C0031R.string.property), activity.getString(C0031R.string.replace_cover), activity.getString(C0031R.string.rename)};
        String path = ((ReaderHistoryBean) this.mDataHolders.get((this.mDataHolders.size() - 1) - this.selection)).getFullpath();
        if (path.endsWith(".html") || path.endsWith(".htm")) {
            stringlist = new String[]{activity.getString(C0031R.string.delete), activity.getString(C0031R.string.property), activity.getString(C0031R.string.replace_cover)};
        }
        builder.setItems(stringlist, this);
        builder.create().setCanceledOnTouchOutside(true);
        builder.show();
    }

对比一下
4.jpg

修改位置如图
5.jpg



以下是改完后的完整代码
[Asm] 纯文本查看 复制代码
.method protected showPopMenu(I)V
    .locals 14
    .param p1, "position"    # I

    .prologue
    const v13, 0x7f0600c6

    const/4 v12, 0x3

    const/4 v11, 0x2

    const/4 v10, 0x0

    const/4 v9, 0x1

    .line 309
    invoke-super {p0, p1}, Lcom/anyview/api/core/AbsBaseAdapter;->showPopMenu(I)V

    .line 310
    iget-object v6, p0, Lcom/anyview/core/AppShelfAdapter;->mDataHolders:Ljava/util/ArrayList;

    .line 311
    iget-object v7, p0, Lcom/anyview/core/AppShelfAdapter;->mDataHolders:Ljava/util/ArrayList;

    invoke-virtual {v7}, Ljava/util/ArrayList;->size()I

    move-result v7

    add-int/lit8 v7, v7, -0x1

    iget v8, p0, Lcom/anyview/core/AppShelfAdapter;->selection:I

    sub-int/2addr v7, v8

    .line 310
    invoke-virtual {v6, v7}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v6

    check-cast v6, Lcom/anyview/reader/bean/ReaderHistoryBean;

    .line 311
    invoke-virtual {v6}, Lcom/anyview/reader/bean/ReaderHistoryBean;->getFullpath()Ljava/lang/String;

    move-result-object v2

    .line 312
    .local v2, "fullPath":Ljava/lang/String;
    iget-object v0, p0, Lcom/anyview/core/AppShelfAdapter;->mActivity:Lcom/anyview/api/core/HandlerActivity;

    .line 313
    .local v0, "activity":Landroid/app/Activity;
    new-instance v1, Lcom/anyview/api/core/BaseDialog$Builder;

    invoke-direct {v1, v0}, Lcom/anyview/api/core/BaseDialog$Builder;-><init>(Landroid/app/Activity;)V

    .line 314
    .local v1, "builder":Lcom/anyview/api/core/BaseDialog$Builder;
    const/4 v5, 0x0

    .line 315
    .local v5, "stringlist":[Ljava/lang/String;
    if-eqz v2, :cond_0

    const-string v6, ".aikan"

    invoke-virtual {v2, v6}, Ljava/lang/String;->endsWith(Ljava/lang/String;)Z

    move-result v6

    if-nez v6, :cond_1

    :cond_0
    if-eqz v2, :cond_1

    .line 316
    const-string v6, ""

    invoke-virtual {v6, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v6

    if-eqz v6, :cond_4

    .line 317
    :cond_1
    const/4 v6, 0x4

    new-array v5, v6, [Ljava/lang/String;

    .line 319
    .end local v5    # "stringlist":[Ljava/lang/String;
    invoke-virtual {v0, v13}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v10

    .line 320
    const v6, 0x7f0600c9

    invoke-virtual {v0, v6}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v9

    .line 321
    const v6, 0x7f0600c7

    invoke-virtual {v0, v6}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v11

    .line 322
    const v6, 0x7f060116

    invoke-virtual {v0, v6}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v12

    .line 333
    .restart local v5    # "stringlist":[Ljava/lang/String;
    :goto_0
    iget-object v6, p0, Lcom/anyview/core/AppShelfAdapter;->mDataHolders:Ljava/util/ArrayList;

    iget-object v7, p0, Lcom/anyview/core/AppShelfAdapter;->mDataHolders:Ljava/util/ArrayList;

    invoke-virtual {v7}, Ljava/util/ArrayList;->size()I

    move-result v7

    add-int/lit8 v7, v7, -0x1

    .line 334
    iget v8, p0, Lcom/anyview/core/AppShelfAdapter;->selection:I

    sub-int/2addr v7, v8

    .line 333
    invoke-virtual {v6, v7}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v4

    check-cast v4, Lcom/anyview/reader/bean/ReaderHistoryBean;

    .line 335
    .local v4, "rh":Lcom/anyview/reader/bean/ReaderHistoryBean;
    invoke-virtual {v4}, Lcom/anyview/reader/bean/ReaderHistoryBean;->getFullpath()Ljava/lang/String;

    move-result-object v3

    .line 336
    .local v3, "path":Ljava/lang/String;
    const-string v6, ".html"

    invoke-virtual {v3, v6}, Ljava/lang/String;->endsWith(Ljava/lang/String;)Z

    move-result v6

    if-nez v6, :cond_2

    const-string v6, ".htm"

    invoke-virtual {v3, v6}, Ljava/lang/String;->endsWith(Ljava/lang/String;)Z

    move-result v6

    if-eqz v6, :cond_3

    .line 337
    :cond_2
    new-array v5, v12, [Ljava/lang/String;

    .line 339
    .end local v5    # "stringlist":[Ljava/lang/String;
    invoke-virtual {v0, v13}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v10

    .line 340
    const v6, 0x7f0600c9

    invoke-virtual {v0, v6}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v9

    .line 341
    const v6, 0x7f0600c7

    invoke-virtual {v0, v6}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v11

    .line 344
    .restart local v5    # "stringlist":[Ljava/lang/String;
    :cond_3
    invoke-virtual {v1, v5, p0}, Lcom/anyview/api/core/BaseDialog$Builder;->setItems([Ljava/lang/CharSequence;Landroid/content/DialogInterface$OnClickListener;)Lcom/anyview/api/core/BaseDialog$Builder;

    .line 345
    invoke-virtual {v1}, Lcom/anyview/api/core/BaseDialog$Builder;->create()Lcom/anyview/api/core/BaseDialog;

    move-result-object v6

    invoke-virtual {v6, v9}, Lcom/anyview/api/core/BaseDialog;->setCanceledOnTouchOutside(Z)V

    .line 346
    invoke-virtual {v1}, Lcom/anyview/api/core/BaseDialog$Builder;->show()Lcom/anyview/api/core/BaseDialog;

    .line 347
    return-void

    .line 324
    .end local v3    # "path":Ljava/lang/String;
    .end local v4    # "rh":Lcom/anyview/reader/bean/ReaderHistoryBean;
    :cond_4
    const/4 v6, 0x4 # 这里是创建文本型数组及元素个数,屏蔽掉一个 在元数组成员数基础上减掉一个 改为0x4

    new-array v5, v6, [Ljava/lang/String;

    .line 326
    .end local v5    # "stringlist":[Ljava/lang/String;
    invoke-virtual {v0, v13}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v10

    .line 327
    const v6, 0x7f0600c9

    invoke-virtual {v0, v6}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v9

    .line 328
    const v6, 0x7f0600c7

    invoke-virtual {v0, v6}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v11

    .line 329
    const v6, 0x7f060116

    invoke-virtual {v0, v6}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v12

    #const/4 v6, 0x4  屏蔽索引及内容

    .line 330
    #const v7, 0x7f0601d4

    #invoke-virtual {v0, v7}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    #move-result-object v7

    #aput-object v7, v5, v6

    .line 324
    .restart local v5    # "stringlist":[Ljava/lang/String;
    goto :goto_0
.end method









免费评分

参与人数 10吾爱币 +14 热心值 +10 收起 理由
qtfreet00 + 7 + 1 欢迎分析讨论交流,吾爱破解论坛有你更精彩!
d19980122 + 1 谢谢@Thanks!
留住我你有福 + 1 + 1 谢谢@Thanks!
某些人 + 1 + 1 谢谢@Thanks!
喜欢dubled + 1 + 1 谢谢@Thanks!
MMoney + 1 + 1 谢谢@Thanks!
芽衣 + 1 + 1 用心讨论,共获提升!
fkuejinn + 1 + 1 谢谢@Thanks!
李佑辰 + 1 用心讨论,共获提升!
Dboykey + 1 + 1 用心讨论,共获提升!

查看全部评分

发帖前要善用论坛搜索功能,那里可能会有你要找的答案或者已经有人发布过相同内容了,请勿重复发帖。

Dboykey 发表于 2022-2-14 12:56
学习到了!谢谢大神分享经验
ulife 发表于 2022-2-14 13:54
感谢分享,如果能提供本版成品APP链接就更好了
cl19980429 发表于 2022-2-14 14:12
臭味香头 发表于 2022-2-14 14:16
楼主的目的是取消上传A盘菜单吗?
鑫鑫鑫鑫 发表于 2022-2-14 14:16
感谢分享,学习了
我今天是大佬 发表于 2022-2-14 14:42
学习了, 有空研究, 感谢分享
lwlwss 发表于 2022-2-14 14:46
伸手党默默点赞寻找下成品
fkuejinn 发表于 2022-2-14 15:07
最新的成品有分享吗,伸手党点赞~~
df2k 发表于 2022-2-14 15:47
教程很详尽, 感谢分享
您需要登录后才可以回帖 登录 | 注册[Register]

本版积分规则

返回列表

RSS订阅|小黑屋|处罚记录|联系我们|吾爱破解 - LCG - LSG ( 京ICP备16042023号 | 京公网安备 11010502030087号 )

GMT+8, 2024-11-24 12:45

Powered by Discuz!

Copyright © 2001-2020, Tencent Cloud.

快速回复 返回顶部 返回列表