0

我正在尝试修改现有的应用程序。目前,这是该应用程序的一项操作,选择后将显示无线和网络设置页面。我曾经APKTOOL获取smali并找到了代码:

.line 238
new-instance p5, Landroid/content/Intent;

const-string p7, "android.settings.WIRELESS_SETTINGS"

.end local p7
invoke-direct {p5, p7}, Landroid/content/Intent;-><init>(Ljava/lang/String;)V

我正在尝试制作它而不是调用设置页面,它会调用我自己的应用程序。不幸的是我无法拆卸整个班级,但我得到了以下

var10_10.bitmap = WidgetItem.loadFunctionIcon((Context)var1_1, (String)var8_8, (boolean)var6_6, (boolean)var7_7);
var10_10.pendingIntent = PendingIntent.getActivity((Context)var1_1, (int)0, (Intent)new Intent("android.settings.WIRELESS_SETTINGS"), (int)134217728);
var11_11 = true;

我试图从

const-string p7, "android.settings.WIRELESS_SETTINGS"

const-string p7, "com.mycompany.myapp"

或者

const-string p7, "com.mycompany.myapp@com.mycompany.myapp.MainActivity"

但两者都没有工作。我应该放什么让它调用我的应用程序?

4

1 回答 1

0

修改以下内容后,就可以了!

var10_10.pendingIntent = PendingIntent.getActivity((Context)var1_1, (int)0, (Intent)new Intent("android.settings.WIRELESS_SETTINGS"), (int)134217728);

var53_15 = new Intent("android.intent.action.MAIN");
var53_15.addCategory("android.intent.category.LAUNCHER");
var53_15.setFlags(270532608);
var8_8 = "com.mycompany.myapp";
var9_9 = "com.mycompany.myapp.MainActivity";
var53_15.setComponent(new ComponentName(var8_8, var9_9));
var10_10.pendingIntent = PendingIntent.getActivity((Context)var1_1, (int)0, (Intent)var53_15, (int)134217728);
于 2015-03-13T17:47:16.660 回答