Skip to content

Commit

Permalink
support x86 phones(jniLib)
Browse files Browse the repository at this point in the history
  • Loading branch information
yhs0602 committed Oct 5, 2018
1 parent 51a824a commit 6e30331
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
package com.kyhsgeekcode.disassembler;
import android.app.*;
import java.util.*;

public class DisasmIterator
{
public DisasmIterator(MainActivity activity, NotificationManager mNotifyManager, Notification.Builder mBuilder, ListViewAdapter adapter, long total)
{
this.activity = activity;
this.mNotifyManager = mNotifyManager;
this.mBuilder = mBuilder;
this.total = total;
this.adapter=adapter;
}
public native void getAll(byte[] bytes, long offset, long size,long virtaddr,ArrayList<DisasmResult> arr);
public void AddItem(final ListViewItem lvi)
{
activity.runOnUiThread(new Runnable(){
@Override
public void run()
{
adapter.addItem(lvi);
adapter.notifyDataSetChanged();
return ;
}
});
}

public void showNoti(int progress)
{
mBuilder.setProgress((int)total,progress, false);
// Displays the progress bar for the first time.
mNotifyManager.notify(0, mBuilder.build());
activity.runOnUiThread(activity.runnableRequestLayout);

}
MainActivity activity;
NotificationManager mNotifyManager;
Notification.Builder mBuilder;
long total;
ListViewAdapter adapter;

}
Binary file added app/src/main/jniLibs/armeabi-v7a/libhello-jni.so
Binary file not shown.
Binary file added app/src/main/jniLibs/x86/libhello-jni.so
Binary file not shown.

0 comments on commit 6e30331

Please sign in to comment.