text viewer loading

This commit is contained in:
Page Asgardius 2022-09-07 11:39:28 -07:00
parent 1ecc379d96
commit d40f3ddaf6
2 changed files with 13 additions and 0 deletions

View file

@ -5,6 +5,7 @@ import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.EditText;
import android.widget.ProgressBar;
import android.widget.Toast;
import com.amazonaws.services.s3.model.ListObjectsRequest;
@ -29,6 +30,7 @@ public class TextViewer extends AppCompatActivity {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_text_viewer);
filecontent = (EditText)findViewById(R.id.textShow);
final ProgressBar simpleProgressBar = (ProgressBar) findViewById(R.id.simpleProgressBar);
String videoURL = getIntent().getStringExtra("video_url");
Thread textread = new Thread(new Runnable() {
@ -49,6 +51,7 @@ public class TextViewer extends AppCompatActivity {
@Override
public void run() {
// Sending reference and data to Adapter
simpleProgressBar.setVisibility(View.INVISIBLE);
filecontent.setText(str);
}

View file

@ -17,4 +17,14 @@
tools:ignore="MissingConstraints"
tools:layout_editor_absoluteX="79dp"
tools:layout_editor_absoluteY="25dp" />
<ProgressBar
android:id="@+id/simpleProgressBar"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:max="100"
android:progress="50"
android:padding="20dp"
tools:ignore="MissingConstraints"
android:indeterminate="true" />
</androidx.constraintlayout.widget.ConstraintLayout>