het sloopte wel :(((
This commit is contained in:
@@ -30,7 +30,6 @@ android {
|
|||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
|
|
||||||
implementation 'com.facebook.shimmer:shimmer:0.5.0'
|
|
||||||
implementation 'com.android.support:appcompat-v7:28.0.0'
|
implementation 'com.android.support:appcompat-v7:28.0.0'
|
||||||
implementation 'com.android.support.constraint:constraint-layout:2.0.4'
|
implementation 'com.android.support.constraint:constraint-layout:2.0.4'
|
||||||
implementation 'com.android.support:cardview-v7:28.0.0'
|
implementation 'com.android.support:cardview-v7:28.0.0'
|
||||||
|
@@ -34,7 +34,6 @@ import com.example.fitbot.exercise.ExerciseManager;
|
|||||||
import com.example.fitbot.pepper.Pepper;
|
import com.example.fitbot.pepper.Pepper;
|
||||||
import com.example.fitbot.util.NavigationManager;
|
import com.example.fitbot.util.NavigationManager;
|
||||||
import com.example.fitbot.util.processing.InputProcessor;
|
import com.example.fitbot.util.processing.InputProcessor;
|
||||||
import com.facebook.shimmer.ShimmerFrameLayout;
|
|
||||||
|
|
||||||
public class FitnessActivity extends RobotActivity implements RobotLifecycleCallbacks {
|
public class FitnessActivity extends RobotActivity implements RobotLifecycleCallbacks {
|
||||||
|
|
||||||
@@ -94,10 +93,6 @@ public class FitnessActivity extends RobotActivity implements RobotLifecycleCall
|
|||||||
progressText = findViewById(R.id.progressText);
|
progressText = findViewById(R.id.progressText);
|
||||||
progressCircle.setMax(maxProgress);
|
progressCircle.setMax(maxProgress);
|
||||||
|
|
||||||
ShimmerFrameLayout shimmerLayout = findViewById(R.id.shimmerFrameLayout);
|
|
||||||
shimmerLayout.startShimmer(); // Start shimmer animation
|
|
||||||
|
|
||||||
|
|
||||||
// Set color of loading circle
|
// Set color of loading circle
|
||||||
ProgressBar loadingCircle = findViewById(R.id.loadingCircle);
|
ProgressBar loadingCircle = findViewById(R.id.loadingCircle);
|
||||||
loadingCircle.setIndeterminateTintList(ColorStateList.valueOf(Color.RED));
|
loadingCircle.setIndeterminateTintList(ColorStateList.valueOf(Color.RED));
|
||||||
@@ -166,9 +161,6 @@ public class FitnessActivity extends RobotActivity implements RobotLifecycleCall
|
|||||||
// exerciseDescriptionTextView.setText(exercise.description);
|
// exerciseDescriptionTextView.setText(exercise.description);
|
||||||
exerciseVideoUrl = exercise.videoUrl;
|
exerciseVideoUrl = exercise.videoUrl;
|
||||||
|
|
||||||
ShimmerFrameLayout shimmerLayout = findViewById(R.id.shimmerFrameLayout);
|
|
||||||
shimmerLayout.stopShimmer(); // Start shimmer animation
|
|
||||||
|
|
||||||
// Play the video
|
// Play the video
|
||||||
playVideo(videoView, this);
|
playVideo(videoView, this);
|
||||||
|
|
||||||
|
@@ -60,81 +60,73 @@
|
|||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<com.facebook.shimmer.ShimmerFrameLayout
|
<LinearLayout
|
||||||
android:id="@+id/shimmerFrameLayout"
|
|
||||||
android:layout_width="450dp"
|
android:layout_width="450dp"
|
||||||
android:layout_height="450dp"
|
android:layout_height="450dp"
|
||||||
android:layout_marginTop="20dp"
|
android:layout_marginTop="20dp"
|
||||||
android:layout_marginEnd="20dp"
|
android:layout_marginEnd="20dp"
|
||||||
android:background="@drawable/border_background"
|
android:background="@drawable/border_background"
|
||||||
|
android:orientation="vertical"
|
||||||
android:padding="20dp"
|
android:padding="20dp"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent">
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/textViewFitnessTitle"
|
||||||
|
style="@style/TextStyleTitle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_gravity="center_horizontal"
|
||||||
|
android:text="@string/exerciseTitle"
|
||||||
|
android:textAlignment="center" />
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical">
|
android:layout_gravity="center_horizontal"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:background="@drawable/border_background_3"
|
||||||
|
android:padding="5dp">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/textViewFitnessTitle"
|
android:id="@+id/textViewFitnessShortDescription"
|
||||||
style="@style/TextStyleTitle"
|
style="@style/TextStyleDesc"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_gravity="center_horizontal"
|
android:text="@string/exerciseDesc"
|
||||||
android:text="@string/exerciseTitle"
|
|
||||||
android:textAlignment="center" />
|
android:textAlignment="center" />
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_gravity="center_horizontal"
|
|
||||||
android:layout_margin="10dp"
|
|
||||||
android:background="@drawable/border_background_3"
|
|
||||||
android:padding="5dp">
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/textViewFitnessShortDescription"
|
|
||||||
style="@style/TextStyleDesc"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:text="@string/exerciseDesc"
|
|
||||||
android:textAlignment="center" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<RelativeLayout
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_gravity="center_horizontal"
|
|
||||||
android:layout_margin="10dp"
|
|
||||||
android:background="@drawable/border_background_circle">
|
|
||||||
|
|
||||||
<ProgressBar
|
|
||||||
android:id="@+id/progressCircle"
|
|
||||||
style="?android:attr/progressBarStyleHorizontal"
|
|
||||||
android:layout_width="150dp"
|
|
||||||
android:layout_height="150dp"
|
|
||||||
android:layout_centerInParent="true"
|
|
||||||
android:layout_gravity="center"
|
|
||||||
android:indeterminate="false"
|
|
||||||
android:max="10"
|
|
||||||
android:progress="0"
|
|
||||||
android:progressDrawable="@drawable/progress_circle" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/progressText"
|
|
||||||
style="@style/TextStyle"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_centerInParent="true"
|
|
||||||
android:text="0/10" />
|
|
||||||
|
|
||||||
</RelativeLayout>
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</com.facebook.shimmer.ShimmerFrameLayout>
|
<RelativeLayout
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_gravity="center_horizontal"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:background="@drawable/border_background_circle">
|
||||||
|
|
||||||
|
<ProgressBar
|
||||||
|
android:id="@+id/progressCircle"
|
||||||
|
style="?android:attr/progressBarStyleHorizontal"
|
||||||
|
android:layout_width="150dp"
|
||||||
|
android:layout_height="150dp"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:indeterminate="false"
|
||||||
|
android:max="10"
|
||||||
|
android:progress="0"
|
||||||
|
android:progressDrawable="@drawable/progress_circle" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/progressText"
|
||||||
|
style="@style/TextStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
android:text="0/10" />
|
||||||
|
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/homeButtonFitness"
|
android:id="@+id/homeButtonFitness"
|
||||||
|
@@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
|
|||||||
# resources declared in the library itself and none from the library's dependencies,
|
# resources declared in the library itself and none from the library's dependencies,
|
||||||
# thereby reducing the size of the R class for that library
|
# thereby reducing the size of the R class for that library
|
||||||
android.nonTransitiveRClass=true
|
android.nonTransitiveRClass=true
|
||||||
android.useAndroidX=true
|
|
||||||
android.enableJetifier=true
|
|
||||||
|
Reference in New Issue
Block a user