Update Fitbot app styles and themes
This commit is contained in:
5
code/src/Fitbot/.idea/misc.xml
generated
5
code/src/Fitbot/.idea/misc.xml
generated
@@ -8,13 +8,14 @@
|
||||
<entry key="..\:/Users/31687/muupooviixee66-1/code/src/Fitbot/app/src/main/res/layout/activity_main_screen.xml" value="0.358695652173913" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/layout/activity_bicepvideo.xml" value="0.136" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/layout/activity_completion_screen.xml" value="0.18541666666666667" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/layout/activity_main.xml" value="0.2" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/layout/activity_main.xml" value="0.12" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/layout/activity_main_screen.xml" value="0.1" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/layout/activity_power_screen.xml" value="0.1" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/layout/activity_sport_item.xml" value="0.18541666666666667" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/layout/activity_sport_menu.xml" value="0.18541666666666667" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/layout/header.xml" value="0.18125" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/layout/toolbar.xml" value="0.1" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/menu/main_menu.xml" value="0.18125" />
|
||||
<entry key="..\:/Users/sebas/Documents/HvA/Reposetories/muupooviixee66/code/src/Fitbot/app/src/main/res/menu/main_menu.xml" value="0.1" />
|
||||
</map>
|
||||
</option>
|
||||
</component>
|
||||
|
@@ -16,13 +16,7 @@
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".ui.SportMenuActivity"
|
||||
android:exported="true" >
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".BicepVideo"
|
||||
android:exported="false" />
|
||||
@@ -31,6 +25,9 @@
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".MainScreen"
|
||||
android:exported="true" >
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
|
@@ -1,11 +1,13 @@
|
||||
package com.example.fitbot;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.os.Bundle;
|
||||
import android.support.design.widget.NavigationView;
|
||||
import android.support.v4.view.GravityCompat;
|
||||
import android.support.v4.widget.DrawerLayout;
|
||||
import android.support.v7.app.ActionBarDrawerToggle;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.widget.Toolbar;
|
||||
import android.support.v7.widget.Toolbar;
|
||||
|
||||
public class MainScreen extends AppCompatActivity {
|
||||
|
||||
@@ -14,6 +16,7 @@ public class MainScreen extends AppCompatActivity {
|
||||
NavigationView navigationView;
|
||||
Toolbar toolbar;
|
||||
|
||||
@SuppressLint("WrongViewCast")
|
||||
@Override
|
||||
protected void onCreate (Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
@@ -25,11 +28,23 @@ public class MainScreen extends AppCompatActivity {
|
||||
toolbar = findViewById(R.id.toolbar);
|
||||
|
||||
/*---Tool Bar---*/
|
||||
setSupportActionBar(toolbar);
|
||||
// setSupportActionBar(toolbar);
|
||||
|
||||
/*---Navigation Drawer Menu---*/
|
||||
ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(this.drawerLayout,toolbar,R.string.navigation_drawer_open,R.string.navigation_drawer_close);
|
||||
navigationView.bringToFront();
|
||||
ActionBarDrawerToggle toggle=new
|
||||
ActionBarDrawerToggle(this,drawerLayout,toolbar,R.string.navigation_drawer_open,R.string.navigation_drawer_close);
|
||||
drawerLayout.addDrawerListener(toggle);
|
||||
toggle.syncState();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBackPressed(){
|
||||
if(drawerLayout.isDrawerOpen(GravityCompat.START)){
|
||||
drawerLayout.closeDrawer(GravityCompat.START);
|
||||
}
|
||||
else
|
||||
{super.onBackPressed();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -25,15 +25,15 @@ public class PowerScreen extends AppCompatActivity {
|
||||
Intent intent = new Intent(PowerScreen.this, BicepVideo.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
openSquatVideo.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(PowerScreen.this, SquatVideo.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
|
||||
openTricepVideo.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(PowerScreen.this, TricepVideo.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
// openSquatVideo.setOnClickListener(v -> {
|
||||
// Intent intent = new Intent(PowerScreen.this, SquatVideo.class);
|
||||
// startActivity(intent);
|
||||
// });
|
||||
//
|
||||
// openTricepVideo.setOnClickListener(v -> {
|
||||
// Intent intent = new Intent(PowerScreen.this, TricepVideo.class);
|
||||
// startActivity(intent);
|
||||
// });
|
||||
|
||||
goToHome.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(PowerScreen.this, MainActivity.class);
|
||||
|
@@ -1,30 +1,25 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/drawer_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".MainActivity"
|
||||
android:fitsSystemWindows="true"
|
||||
tools:context=".MainActivity"
|
||||
tools:openDrawer="start">
|
||||
|
||||
<include
|
||||
android:id="@+id/toolbar"
|
||||
layout="@layout/toolbar"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Hello World"
|
||||
android:layout_centerInParent="true"/>
|
||||
layout="@layout/toolbar" />
|
||||
|
||||
<android.support.design.widget.NavigationView
|
||||
android:id="@+id/nav_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:id="@+id/nav_view"
|
||||
android:layout_gravity="start"
|
||||
app:headerLayout="@layout/header"
|
||||
app:menu="@menu/main_menu"
|
||||
android:layout_gravity="start"/>
|
||||
app:menu="@menu/main_menu" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/menu_switch_btn"
|
||||
@@ -32,17 +27,6 @@
|
||||
android:layout_height="50dp"
|
||||
android:text="Go to Sport Menu"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
/>
|
||||
app:layout_constraintLeft_toLeftOf="parent" />
|
||||
|
||||
<android.support.v7.widget.Toolbar
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="798dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="#00FFFFFF"
|
||||
android:minHeight="?attr/actionBarSize"
|
||||
android:theme="?attr/actionBarTheme"
|
||||
tools:layout_editor_absoluteX="0dp"
|
||||
tools:layout_editor_absoluteY="0dp" />
|
||||
|
||||
</RelativeLayout>
|
||||
</android.support.v4.widget.DrawerLayout>
|
@@ -1,5 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="200dp"
|
||||
@@ -9,17 +10,23 @@
|
||||
android:padding="10dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imageView"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="150dp"
|
||||
android:src="@drawable/robotlogo"/>
|
||||
android:layout_marginStart="10dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:src="@drawable/robotlogo"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="60dp"
|
||||
android:text="FitBot"
|
||||
android:textSize="48sp"
|
||||
tools:layout_editor_absoluteX="160dp"
|
||||
tools:layout_editor_absoluteY="50dp"/>
|
||||
app:layout_constraintStart_toEndOf="@+id/imageView"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
|
||||
</android.support.constraint.ConstraintLayout>
|
@@ -2,8 +2,8 @@
|
||||
<android.support.v7.widget.Toolbar xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/design_default_color_primary"
|
||||
android:background="#00000000"
|
||||
android:elevation="8dp"
|
||||
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar">
|
||||
android:theme="@style/Theme.AppCompat.Light.NoActionBar">
|
||||
|
||||
</android.support.v7.widget.Toolbar>
|
@@ -1,6 +1,6 @@
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
<!-- Base application theme. -->
|
||||
<style name="Theme.Fitbot" parent="Theme.AppCompat.Light.DarkActionBar">
|
||||
<style name="Theme.Fitbot" parent="Theme.AppCompat.Light.NoActionBar">
|
||||
<!-- Primary brand color. -->
|
||||
<item name="colorPrimary">@color/purple_200</item>
|
||||
<item name="colorPrimaryDark">@color/purple_700</item>
|
||||
|
9
code/src/Fitbot/app/src/main/res/values/styles.xml
Normal file
9
code/src/Fitbot/app/src/main/res/values/styles.xml
Normal file
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<!-- Base application theme. -->
|
||||
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
|
||||
<item name="android:statusBarColor">#00000000</item>
|
||||
<item name="windowActionBar">false</item>
|
||||
<item name="windowNoTitle">true</item>
|
||||
</style>
|
||||
</resources>
|
@@ -1,6 +1,6 @@
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
<!-- Base application theme. -->
|
||||
<style name="Theme.Fitbot" parent="Theme.AppCompat.Light.DarkActionBar">
|
||||
<style name="Theme.Fitbot" parent="Theme.AppCompat.Light.NoActionBar">
|
||||
<!-- Primary brand color. -->
|
||||
<item name="colorPrimary">@color/purple_500</item>
|
||||
<item name="colorPrimaryDark">@color/purple_700</item>
|
||||
|
Reference in New Issue
Block a user