show the result of ffprobe

show the result of ffprobe
pull/107/head
xufulong 6 years ago
parent aa7a6cd17e
commit 464b4ad796
  1. 6
      app/src/main/java/com/frank/ffmpeg/activity/ProbeFormatActivity.java
  2. 2
      app/src/main/java/com/frank/ffmpeg/handler/FFmpegHandler.java

@ -4,6 +4,7 @@ import android.annotation.SuppressLint;
import android.os.Bundle; import android.os.Bundle;
import android.os.Handler; import android.os.Handler;
import android.os.Message; import android.os.Message;
import android.text.TextUtils;
import android.view.View; import android.view.View;
import android.widget.ProgressBar; import android.widget.ProgressBar;
import android.widget.RelativeLayout; import android.widget.RelativeLayout;
@ -43,6 +44,10 @@ public class ProbeFormatActivity extends BaseActivity {
case MSG_FINISH: case MSG_FINISH:
progressProbe.setVisibility(View.GONE); progressProbe.setVisibility(View.GONE);
layoutProbe.setVisibility(View.VISIBLE); layoutProbe.setVisibility(View.VISIBLE);
String result = (String) msg.obj;
if (!TextUtils.isEmpty(result) && txtProbeFormat != null) {
txtProbeFormat.setText(result);
}
break; break;
default: default:
break; break;
@ -59,7 +64,6 @@ public class ProbeFormatActivity extends BaseActivity {
protected void onCreate(Bundle savedInstanceState) { protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
hideActionBar();
initView(); initView();
ffmpegHandler = new FFmpegHandler(mHandler); ffmpegHandler = new FFmpegHandler(mHandler);
} }

@ -82,7 +82,7 @@ public class FFmpegHandler {
if(isContinue) { if(isContinue) {
mHandler.obtainMessage(MSG_CONTINUE).sendToTarget(); mHandler.obtainMessage(MSG_CONTINUE).sendToTarget();
}else { }else {
mHandler.obtainMessage(MSG_FINISH).sendToTarget(); mHandler.obtainMessage(MSG_FINISH, resultMsg).sendToTarget();
} }
} }
}); });

Loading…
Cancel
Save