Skip to content

Commit

Permalink
code refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
vamsii777 committed Sep 14, 2020
1 parent 5d59792 commit 04f2df5
Show file tree
Hide file tree
Showing 31 changed files with 1,277 additions and 41 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,5 @@
/captures
.externalNativeBuild
.cxx
*.json
/download/crossally/apps/hizkiyyah/utils/SharedObjects.java
20 changes: 18 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ android {
applicationId "download.crossally.apps.hizkiyyah"
minSdkVersion 21
targetSdkVersion 30
versionCode 15
versionCode 16
multiDexEnabled true
versionName "1.1.15"
versionName "1.2.16"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
}
Expand All @@ -40,6 +40,10 @@ android {
generateStubs = true
}

kotlinOptions {
jvmTarget = JavaVersion.VERSION_1_8.toString()
}

}

dependencies {
Expand All @@ -58,6 +62,7 @@ dependencies {
implementation 'com.facebook.stetho:stetho-js-rhino:1.5.1'
implementation 'com.squareup.retrofit2:converter-gson:2.9.0'
implementation 'com.jakewharton:butterknife:10.2.1'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
kapt 'com.jakewharton:butterknife-compiler:10.2.1'
implementation 'io.github.inflationx:calligraphy3:3.1.1'
implementation 'io.github.inflationx:viewpump:2.0.3'
Expand All @@ -66,12 +71,21 @@ dependencies {
implementation 'com.squareup.picasso:picasso:2.71828'
implementation 'com.android.support:multidex:1.0.3'
implementation 'com.google.firebase:firebase-crashlytics:17.2.1'
// Jetpack Navigation
def nav_version = "2.3.0"
implementation "androidx.navigation:navigation-fragment-ktx:$nav_version"
implementation "androidx.navigation:navigation-ui-ktx:$nav_version"
// FirebaseUI for Real-time database
implementation 'com.firebaseui:firebase-ui-database:6.2.0'
// Paging Library (For Pagination Only)
implementation 'android.arch.paging:runtime:1.0.1'
// Recommended: Add the Firebase SDK for Google Analytics.
implementation 'com.google.firebase:firebase-analytics-ktx:17.5.0'
implementation 'com.google.firebase:firebase-analytics:17.5.0'
// Add the Firebase Crashlytics SDK.
implementation 'com.google.firebase:firebase-crashlytics-ktx:17.2.1'
// debugImplementation because LeakCanary should only run in debug builds.
implementation 'com.squareup.picasso:picasso:2.71828' // picasso library
debugImplementation 'com.squareup.leakcanary:leakcanary-android:2.4'
implementation('org.jitsi.react:jitsi-meet-sdk:2.9.3') { transitive = true }
implementation 'com.daimajia.swipelayout:library:1.2.0@aar'
Expand All @@ -83,6 +97,8 @@ dependencies {
implementation 'com.vungle:publisher-sdk-android:6.7.0'
implementation 'com.google.ads.mediation:vungle:6.7.0.0'
implementation 'com.google.ads.mediation:mopub:5.13.1.0'
implementation 'com.github.HamidrezaAmz:MagicalExoPlayer:1.0.15'
implementation 'com.github.halilozercan:BetterVideoPlayer:kotlin-SNAPSHOT'
implementation 'com.google.ads.mediation:facebook:5.11.0.0'
implementation 'com.google.ads.mediation:adcolony:4.1.4.1'
// Add the dependency for the Performance Monitoring library
Expand Down
Binary file modified app/release/app-release.aab
Binary file not shown.
61 changes: 31 additions & 30 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,40 +1,48 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:installLocation="auto"
package="download.crossally.apps.hizkiyyah">
package="download.crossally.apps.hizkiyyah"
android:installLocation="auto">

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.READ_CALENDAR"/>
<uses-permission android:name="android.permission.WRITE_CALENDAR"/>
<uses-permission android:name="android.permission.READ_CALENDAR" />
<uses-permission android:name="android.permission.WRITE_CALENDAR" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />

<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />

<application
android:usesCleartextTraffic="true"
tools:replace="android:allowBackup"
android:name="download.crossally.apps.hizkiyyah.utils.SharedObjects"
android:allowBackup="false"
android:name=".utils.SharedObjects"
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:requestLegacyExternalStorage="true"
android:roundIcon="@mipmap/ic_launcher"
android:supportsRtl="true"
android:theme="@style/AppTheme"
tools:ignore="UnusedAttribute">
android:usesCleartextTraffic="true"
tools:ignore="UnusedAttribute"
tools:replace="android:allowBackup">
<activity
android:name=".videoplay.VideoPlayFullscreenActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenSize|screenLayout|smallestScreenSize|uiMode"
android:label="@string/title_activity_video_play_fullscreen"
android:screenOrientation="landscape"
android:theme="@style/FullscreenTheme">
</activity>

<meta-data
android:name="firebase_performance_logcat_enabled"
android:value="true" />
<meta-data
android:name="com.google.android.gms.ads.APPLICATION_ID"
android:value="@string/app_id"/>
android:value="@string/app_id" />
<meta-data
android:name="com.bugsnag.android.API_KEY"
android:value="1c5c00cec04e3f7aaca2ee68956ea883"/>
android:value="1c5c00cec04e3f7aaca2ee68956ea883" />

<activity
android:name=".SplashActivity"
android:configChanges="orientation|screenSize"
Expand All @@ -48,63 +56,56 @@
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>

<activity
android:name="download.crossally.apps.hizkiyyah.IntroActivity"
android:name=".IntroActivity"
android:configChanges="orientation|screenSize"
android:label="@string/app_name"
android:noHistory="true"
android:screenOrientation="sensorPortrait"
android:theme="@style/AppTheme.NoActionBar" />
<activity
android:name="download.crossally.apps.hizkiyyah.RegisterActivity"
android:name=".RegisterActivity"
android:configChanges="orientation|screenSize"
android:label="@string/app_name"
android:screenOrientation="sensorPortrait"
android:theme="@style/AppTheme.NoActionBar"
android:windowSoftInputMode="adjustPan" />

<activity
android:name="download.crossally.apps.hizkiyyah.EmailVerificationActivity"
android:name=".EmailVerificationActivity"
android:configChanges="orientation|screenSize"
android:label="@string/app_name"
android:screenOrientation="sensorPortrait"
android:theme="@style/AppTheme.NoActionBar"
android:windowSoftInputMode="adjustPan" />

<activity
android:name="download.crossally.apps.hizkiyyah.LoginActivity"
android:name=".LoginActivity"
android:configChanges="orientation|screenSize"
android:label="@string/app_name"
android:screenOrientation="sensorPortrait"
android:theme="@style/AppTheme.NoActionBar"
android:windowSoftInputMode="adjustPan" />

<activity
android:name="download.crossally.apps.hizkiyyah.MainActivity"
android:name=".MainActivity"
android:configChanges="orientation|screenSize"
android:label="@string/app_name"
android:screenOrientation="sensorPortrait"
android:theme="@style/AppTheme.NoActionBar"
android:windowSoftInputMode="adjustPan"/>

android:windowSoftInputMode="adjustPan" />
<activity
android:name=".meeting.MeetingActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|screenSize|smallestScreenSize"
android:name="download.crossally.apps.hizkiyyah.meeting.MeetingActivity"
android:label="@string/app_name"
android:launchMode="singleTask"
android:resizeableActivity="true"
android:supportsPictureInPicture="true"
android:label="@string/app_name"/>

android:supportsPictureInPicture="true" />
<activity
android:name="download.crossally.apps.hizkiyyah.profile.ProfileActivity"
android:name=".profile.ProfileActivity"
android:configChanges="orientation|screenSize"
android:label="@string/app_name"
android:screenOrientation="sensorPortrait"
android:theme="@style/AppTheme.NoActionBar" />

<activity
android:name="download.crossally.apps.hizkiyyah.schedule.ScheduleMeetingActivity"
android:name=".schedule.ScheduleMeetingActivity"
android:configChanges="orientation|screenSize"
android:label="@string/app_name"
android:screenOrientation="sensorPortrait"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@ import android.os.Bundle
import android.os.Handler
import android.util.Log
import android.view.MenuItem
import android.view.View
import android.widget.Toast
import androidx.appcompat.app.AppCompatActivity
import androidx.coordinatorlayout.widget.CoordinatorLayout
import androidx.fragment.app.Fragment
import androidx.fragment.app.FragmentTransaction
import butterknife.BindView
Expand All @@ -24,6 +26,7 @@ import com.google.firebase.database.DatabaseReference
import com.google.firebase.database.FirebaseDatabase
import com.google.gson.Gson
import download.crossally.apps.hizkiyyah.IntroActivity
import download.crossally.apps.hizkiyyah.explore.ExploreFragment
import download.crossally.apps.hizkiyyah.firebase.DatabaseManager
import download.crossally.apps.hizkiyyah.firebase.DatabaseManager.OnUserListener
import download.crossally.apps.hizkiyyah.home.HomeFragment
Expand Down Expand Up @@ -100,6 +103,10 @@ class MainActivity : AppCompatActivity() {
})
appUpdaterUtils.start()
}
val content: CoordinatorLayout = findViewById(R.id.container)
content.systemUiVisibility = View.SYSTEM_UI_FLAG_LAYOUT_STABLE or
View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN or
View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
}

private fun launchUpdateDialog(onlineVersion: String) {
Expand Down Expand Up @@ -149,6 +156,16 @@ class MainActivity : AppCompatActivity() {
}
return@OnNavigationItemSelectedListener true
}
R.id.nav_explore -> {
fragmentClass = ExploreFragment::class.java
try {
fragment = fragmentClass.newInstance() as Fragment
loadFragment(fragment, menuItem)
} catch (e: Exception) {
e.printStackTrace()
}
return@OnNavigationItemSelectedListener true
}
R.id.nav_meeting_history -> {
fragmentClass = MeetingHistoryFragment::class.java
try {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,13 @@ import android.content.Context
import android.content.Intent
import android.os.Bundle
import android.os.Handler
import android.view.View
import android.view.WindowManager
import android.widget.RelativeLayout
import android.widget.TextView
import androidx.appcompat.app.AppCompatActivity
import androidx.appcompat.app.AppCompatDelegate
import androidx.coordinatorlayout.widget.CoordinatorLayout
import butterknife.BindView
import butterknife.ButterKnife
import com.google.firebase.auth.FirebaseAuth
Expand Down Expand Up @@ -35,6 +38,10 @@ class SplashActivity : AppCompatActivity() {
sharedObjects = SharedObjects(this@SplashActivity)
ButterKnife.bind(this)
txtVersionName!!.text = getString(R.string.version, SharedObjects.getVersion(this@SplashActivity))
val content: RelativeLayout = findViewById(R.id.contSplash)
content.systemUiVisibility = View.SYSTEM_UI_FLAG_LAYOUT_STABLE or
View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN or
View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
Handler().postDelayed({
val intentLogin: Intent
if (firebaseAuth!!.currentUser != null) {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
package download.crossally.apps.hizkiyyah.bean;

import java.io.Serializable;

public class VideoList implements Serializable {

String id;
String title;

public String getId() {
return id;
}

public void setId(String id) {
this.id = id;
}

public String getTitle() {
return title;
}

public void setTitle(String title) {
this.title = title;
}

public String getDescription() {
return description;
}

public void setDescription(String description) {
this.description = description;
}

public String getImageurl() {
return imageurl;
}

public void setImageurl(String imageurl) {
this.imageurl = imageurl;
}

public String getVideourl() {
return videourl;
}

public void setVideourl(String videourl) {
this.videourl = videourl;
}

String description;
String imageurl;
String videourl;

public Long getTimestamp() {
return timestamp;
}

public void setTimestamp(Long timestamp) {
this.timestamp = timestamp;
}

Long timestamp;

}
Loading

0 comments on commit 04f2df5

Please sign in to comment.