Skip to content

Commit

Permalink
Fixing issues in missing libraries
Browse files Browse the repository at this point in the history
  • Loading branch information
britto committed Apr 16, 2020
1 parent e62091a commit 7d8d5ba
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 10 deletions.
3 changes: 0 additions & 3 deletions .idea/gradle.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions androidboilerplate/build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-kapt'
apply plugin: 'kotlin-android-extensions'
apply plugin: 'kotlin-android'

android {
compileSdkVersion 28
Expand Down Expand Up @@ -36,4 +40,9 @@ dependencies {
implementation 'com.android.support:design:28.0.0'
implementation 'com.android.support:support-annotations:28.0.0'
testImplementation 'junit:junit:4.12'
implementation "androidx.core:core-ktx:+"
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
}
repositories {
mavenCentral()
}
1 change: 1 addition & 0 deletions androidboilerplate/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

package="com.androidboilerplate">

<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />

<application
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,18 @@
package com.androidboilerplate;

import android.annotation.SuppressLint;
import android.app.Dialog;
import android.os.Bundle;
import android.support.annotation.Nullable;

import android.support.design.widget.BottomSheetBehavior;
import android.support.design.widget.BottomSheetDialogFragment;
import android.support.design.widget.CoordinatorLayout;
import android.view.View;
import android.view.ViewTreeObserver;

import androidx.annotation.Nullable;
import androidx.coordinatorlayout.widget.CoordinatorLayout;

import com.google.android.material.bottomsheet.BottomSheetBehavior;
import com.google.android.material.bottomsheet.BottomSheetDialogFragment;

public class ModalBottomSheetWithCustomLayout extends BottomSheetDialogFragment {

private static View inflateView = null;
Expand Down Expand Up @@ -37,6 +40,7 @@ public void setupDialog(Dialog dialog, int style) {

private void setPeekHeightOfBottomSheet(){
inflateView.getViewTreeObserver().addOnGlobalLayoutListener(new ViewTreeObserver.OnGlobalLayoutListener() {
@SuppressLint("NewApi")
@Override
public void onGlobalLayout() {
inflateView.getViewTreeObserver().removeOnGlobalLayoutListener(this);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
package com.androidboilerplatesample;

import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;

import com.androidboilerplate.R;
import com.androidboilerplate.utils.StringUtil;
import androidx.appcompat.app.AppCompatActivity;


public class LibraryActivity extends AppCompatActivity {

Expand Down
2 changes: 2 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
ext.kotlin_version = '1.3.72'
repositories {
jcenter()
google()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.5.3'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
Expand Down

0 comments on commit 7d8d5ba

Please sign in to comment.