-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
*.iml | ||
.gradle | ||
/local.properties | ||
/.idea/caches | ||
/.idea/libraries | ||
/.idea/modules.xml | ||
/.idea/workspace.xml | ||
/.idea/navEditor.xml | ||
/.idea/assetWizardSettings.xml | ||
.DS_Store | ||
/build | ||
/captures | ||
.externalNativeBuild | ||
.cxx | ||
local.properties |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/build |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
package bupaljr.com.bottomnavigationdrawer; | ||
|
||
import androidx.annotation.NonNull; | ||
import androidx.appcompat.app.AppCompatActivity; | ||
|
||
import android.content.Intent; | ||
import android.os.Bundle; | ||
import android.view.MenuItem; | ||
|
||
import com.google.android.material.bottomnavigation.BottomNavigationView; | ||
|
||
public class ChatsActivity extends AppCompatActivity { | ||
|
||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
super.onCreate(savedInstanceState); | ||
setContentView(R.layout.activity_chats); | ||
|
||
// Initialize variable | ||
BottomNavigationView bottomNavigationView = findViewById(R.id.bottom_navigation); | ||
|
||
// Set Home Selected | ||
bottomNavigationView.setSelectedItemId(R.id.home); | ||
|
||
//Perform ItemSelectedListener | ||
bottomNavigationView.setOnNavigationItemSelectedListener(new BottomNavigationView.OnNavigationItemSelectedListener() { | ||
@Override | ||
public boolean onNavigationItemSelected(@NonNull MenuItem item) { | ||
switch (item.getItemId()) { | ||
case R.id.search: | ||
startActivity(new Intent(getApplicationContext() | ||
, MainActivity.class)); | ||
overridePendingTransition(0, 0); | ||
return true; | ||
case R.id.jobs: | ||
startActivity(new Intent(getApplicationContext() | ||
, JobsActivity.class)); | ||
overridePendingTransition(0, 0); | ||
return true; | ||
case R.id.chats: | ||
return true; | ||
case R.id.account: | ||
startActivity(new Intent(getApplicationContext() | ||
, ProfileActivity.class)); | ||
overridePendingTransition(0, 0); | ||
return true; | ||
} | ||
return false; | ||
} | ||
}); | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
package bupaljr.com.bottomnavigationdrawer; | ||
|
||
import androidx.annotation.NonNull; | ||
import androidx.appcompat.app.AppCompatActivity; | ||
|
||
import android.content.Intent; | ||
import android.os.Bundle; | ||
import android.view.MenuItem; | ||
|
||
import com.google.android.material.bottomnavigation.BottomNavigationView; | ||
|
||
public class JobsActivity extends AppCompatActivity { | ||
|
||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
super.onCreate(savedInstanceState); | ||
setContentView(R.layout.activity_jobs); | ||
|
||
// Initialize variable | ||
BottomNavigationView bottomNavigationView = findViewById(R.id.bottom_navigation); | ||
|
||
// Set Home Selected | ||
bottomNavigationView.setSelectedItemId(R.id.home); | ||
|
||
//Perform ItemSelectedListener | ||
bottomNavigationView.setOnNavigationItemSelectedListener(new BottomNavigationView.OnNavigationItemSelectedListener() { | ||
@Override | ||
public boolean onNavigationItemSelected(@NonNull MenuItem item) { | ||
switch (item.getItemId()) { | ||
case R.id.search: | ||
startActivity(new Intent(getApplicationContext() | ||
, MainActivity.class)); | ||
overridePendingTransition(0, 0); | ||
return true; | ||
case R.id.jobs: | ||
return true; | ||
case R.id.chats: | ||
startActivity(new Intent(getApplicationContext() | ||
, ChatsActivity.class)); | ||
overridePendingTransition(0, 0); | ||
return true; | ||
case R.id.account: | ||
startActivity(new Intent(getApplicationContext() | ||
, ProfileActivity.class)); | ||
overridePendingTransition(0, 0); | ||
return true; | ||
} | ||
return false; | ||
} | ||
}); | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
package bupaljr.com.bottomnavigationdrawer; | ||
|
||
import android.content.Intent; | ||
import android.os.Bundle; | ||
import android.view.MenuItem; | ||
|
||
import androidx.annotation.NonNull; | ||
import androidx.appcompat.app.AppCompatActivity; | ||
|
||
import com.google.android.material.bottomnavigation.BottomNavigationView; | ||
|
||
public class ProfileActivity extends AppCompatActivity { | ||
|
||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
super.onCreate(savedInstanceState); | ||
setContentView(R.layout.activity_profile); | ||
|
||
// Initialize variable | ||
BottomNavigationView bottomNavigationView = findViewById(R.id.bottom_navigation); | ||
|
||
// Set Home Selected | ||
bottomNavigationView.setSelectedItemId(R.id.home); | ||
|
||
//Perform ItemSelectedListener | ||
bottomNavigationView.setOnNavigationItemSelectedListener(new BottomNavigationView.OnNavigationItemSelectedListener() { | ||
@Override | ||
public boolean onNavigationItemSelected(@NonNull MenuItem item) { | ||
switch (item.getItemId()) { | ||
case R.id.search: | ||
startActivity(new Intent(getApplicationContext() | ||
, MainActivity.class)); | ||
overridePendingTransition(0, 0); | ||
return true; | ||
case R.id.jobs: | ||
startActivity(new Intent(getApplicationContext() | ||
, JobsActivity.class)); | ||
overridePendingTransition(0, 0); | ||
return true; | ||
case R.id.chats: | ||
startActivity(new Intent(getApplicationContext() | ||
, ChatsActivity.class)); | ||
overridePendingTransition(0, 0); | ||
return true; | ||
case R.id.account: | ||
return true; | ||
} | ||
return false; | ||
} | ||
}); | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<RelativeLayout | ||
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="match_parent" | ||
tools:context=".AboutUsActivity"> | ||
|
||
<TextView | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:text="About" | ||
android:textSize="50sp" | ||
android:textStyle="bold" | ||
android:layout_centerInParent="true"/> | ||
|
||
<com.google.android.material.bottomnavigation.BottomNavigationView | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:id="@+id/bottom_navigation" | ||
app:itemBackground="@color/PurpleFik_1" | ||
app:itemTextColor="@drawable/selector" | ||
app:itemIconTint="@drawable/selector" | ||
app:menu="@menu/menu_navigation" | ||
android:layout_alignParentBottom="true"/> | ||
|
||
</RelativeLayout> |