Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 16 additions & 12 deletions app/build.gradle
Original file line number Diff line number Diff line change
@@ -1,31 +1,35 @@
apply plugin: 'com.android.application'

android {
compileSdkVersion 23
buildToolsVersion "24.0.2"
namespace "com.example.akarshan.drivelert"
compileSdk 34

defaultConfig {
applicationId "com.drivelert.akarshan.drivelert"
minSdkVersion 16
targetSdkVersion 23
minSdk 21
targetSdk 34
versionCode 5
versionName "1.3"
multiDexEnabled true
}
buildTypes {2
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:23.4.0'
compile 'com.android.support:design:23.4.0'
compile 'com.github.bloder:magic:1.1'
compile 'com.google.android.gms:play-services:9.4.0'
compile 'com.android.support:multidex:1.0.0'
implementation fileTree(dir: 'libs', include: ['*.jar'])
testImplementation 'junit:junit:4.13.2'
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'com.google.android.material:material:1.10.0'
implementation 'com.github.bloder:magic:1.1'
implementation 'com.google.android.gms:play-services-vision:20.1.3'
implementation 'androidx.multidex:multidex:2.0.1'
}
2 changes: 1 addition & 1 deletion app/src/androidTest/java/layout/BlankFragment.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import android.content.Context;
import android.net.Uri;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import androidx.fragment.app.Fragment;
import android.view.LayoutInflater;
import android.view.MotionEvent;
import android.view.View;
Expand Down
2 changes: 1 addition & 1 deletion app/src/androidTest/java/layout/page_1.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import android.content.Context;
import android.net.Uri;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import androidx.fragment.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
Expand Down
2 changes: 1 addition & 1 deletion app/src/androidTest/java/layout/page_2.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import android.content.Context;
import android.net.Uri;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import androidx.fragment.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
Expand Down
2 changes: 1 addition & 1 deletion app/src/androidTest/java/layout/page_3.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import android.content.Context;
import android.net.Uri;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import androidx.fragment.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
Expand Down
8 changes: 4 additions & 4 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
android:versionCode="2">

<uses-sdk
android:minSdkVersion="9"
android:targetSdkVersion="22" />
android:minSdkVersion="21"
android:targetSdkVersion="34" />

<uses-feature android:name="android.hardware.camera" />
<uses-permission android:name="android.permission.CAMERA" />
Expand All @@ -14,7 +14,7 @@
<application
android:allowBackup="true"
android:largeHeap="true"
android:name="android.support.multidex.MultiDexApplication"
android:name="androidx.multidex.MultiDexApplication"
android:icon="@drawable/l"
android:label="@string/app_name"
android:supportsRtl="true"
Expand Down Expand Up @@ -42,4 +42,4 @@
<activity android:name=".contactus" />
</application>

</manifest>
</manifest>
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
import android.media.AudioManager;
import android.media.MediaPlayer;
import android.os.Bundle;
import android.support.design.widget.Snackbar;
import android.support.v4.app.ActivityCompat;
import android.support.v7.app.AppCompatActivity;
import com.google.android.material.snackbar.Snackbar;
import androidx.core.app.ActivityCompat;
import androidx.appcompat.app.AppCompatActivity;
import android.util.Log;
import android.view.KeyEvent;
import android.view.MotionEvent;
Expand Down
21 changes: 10 additions & 11 deletions app/src/main/java/com/example/akarshan/drivelert/MainActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,18 @@
import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.support.design.widget.FloatingActionButton;
import android.support.design.widget.Snackbar;
import android.support.multidex.MultiDex;
import android.support.v4.app.FragmentActivity;
import android.support.v7.app.AlertDialog;
import com.google.android.material.floatingactionbutton.FloatingActionButton;
import com.google.android.material.snackbar.Snackbar;
import androidx.multidex.MultiDex;
import androidx.fragment.app.FragmentActivity;
import androidx.appcompat.app.AlertDialog;
import android.view.MotionEvent;
import android.view.View;
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.support.v7.widget.Toolbar;
import com.google.android.material.navigation.NavigationView;
import androidx.core.view.GravityCompat;
import androidx.drawerlayout.widget.DrawerLayout;
import androidx.appcompat.app.ActionBarDrawerToggle;
import androidx.appcompat.widget.Toolbar;
import android.view.Menu;
import android.view.MenuItem;
import android.widget.Button;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package com.example.akarshan.drivelert;

import android.support.v4.app.Fragment;
import android.support.v7.app.AppCompatActivity;
import androidx.fragment.app.Fragment;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/java/com/example/akarshan/drivelert/end.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.example.akarshan.drivelert;

import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
import android.view.MotionEvent;
import android.view.View;
Expand Down
12 changes: 6 additions & 6 deletions app/src/main/java/com/example/akarshan/drivelert/help.java
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package com.example.akarshan.drivelert;

import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;
import android.support.v4.view.ViewPager;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import androidx.fragment.app.Fragment;
import androidx.fragment.app.FragmentManager;
import androidx.fragment.app.FragmentPagerAdapter;
import androidx.viewpager.widget.ViewPager;
import androidx.appcompat.app.AppCompatActivity;
import androidx.appcompat.widget.Toolbar;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuItem;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
package com.example.akarshan.drivelert;

import android.content.Intent;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentActivity;
import android.support.v7.app.AppCompatActivity;
import androidx.fragment.app.Fragment;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
Expand Down
12 changes: 5 additions & 7 deletions app/src/main/res/layout/activity_help.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
<androidx.coordinatorlayout.widget.CoordinatorLayout 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/main_content"
Expand All @@ -8,21 +8,19 @@
android:fitsSystemWindows="true"
tools:context="com.example.akarshan.drivelert.help">

<android.support.design.widget.AppBarLayout
<com.google.android.material.appbar.AppBarLayout
android:id="@+id/appbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/AppTheme.AppBarOverlay">


</com.google.android.material.appbar.AppBarLayout>


</android.support.design.widget.AppBarLayout>

<android.support.v4.view.ViewPager
<androidx.viewpager.widget.ViewPager
android:id="@+id/container"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior" />

</android.support.design.widget.CoordinatorLayout>
</androidx.coordinatorlayout.widget.CoordinatorLayout>
6 changes: 3 additions & 3 deletions app/src/main/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
<androidx.drawerlayout.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"
Expand All @@ -13,7 +13,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent" />

<android.support.design.widget.NavigationView
<com.google.android.material.navigation.NavigationView
android:id="@+id/nav_view"
android:layout_width="wrap_content"
android:layout_height="match_parent"
Expand All @@ -23,4 +23,4 @@
app:menu="@menu/activity_main_drawer" />


</android.support.v4.widget.DrawerLayout>
</androidx.drawerlayout.widget.DrawerLayout>
10 changes: 5 additions & 5 deletions app/src/main/res/layout/app_bar_main.xml
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
<androidx.coordinatorlayout.widget.CoordinatorLayout 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"
android:fitsSystemWindows="true"
tools:context="com.example.akarshan.drivelert.MainActivity">

<android.support.design.widget.AppBarLayout
<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/AppTheme.AppBarOverlay">

<android.support.v7.widget.Toolbar
<androidx.appcompat.widget.Toolbar
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:background="?attr/colorPrimary"
app:popupTheme="@style/AppTheme.PopupOverlay" />

</android.support.design.widget.AppBarLayout>
</com.google.android.material.appbar.AppBarLayout>

<include layout="@layout/content_main" />



</android.support.design.widget.CoordinatorLayout>
</androidx.coordinatorlayout.widget.CoordinatorLayout>
13 changes: 5 additions & 8 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,21 +1,18 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
repositories {
jcenter()
google()
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.1.2'


// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
classpath 'com.android.tools.build:gradle:8.2.2'
}
}

allprojects {
repositories {
jcenter()
google()
Comment on lines 3 to +14
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[P1] Add repository for com.github.bloder:magic dependency

The top-level repositories list was reduced to only google() and mavenCentral(), but the module still declares implementation 'com.github.bloder:magic:1.1'. That artifact is distributed via JCenter/JitPack and is not available from Google or Maven Central, so removing JCenter causes Gradle to fail when resolving the dependency and the project no longer builds. An additional repository (e.g., JitPack) or an alternative artifact is needed.

Useful? React with 👍 / 👎.

mavenCentral()
}
}

Expand Down
5 changes: 4 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,7 @@
# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
# org.gradle.parallel=true

android.useAndroidX=true
android.enableJetifier=true
5 changes: 3 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#Mon Dec 28 10:00:20 PST 2015
# Updated Gradle wrapper properties
# Generated by migration script
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2.1-bin.zip
Empty file modified gradlew
100644 → 100755
Empty file.