diff --git a/app/build.gradle b/app/build.gradle index 29a8030..bb0ba6c 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -1,7 +1,5 @@ apply plugin: 'com.android.application' - apply plugin: 'kotlin-android' - apply plugin: 'kotlin-android-extensions' android { @@ -32,4 +30,4 @@ dependencies { androidTestImplementation 'androidx.test:runner:1.1.1' androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1' implementation project(':cravecalculator') -} +} \ No newline at end of file diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index f30236b..e54706f 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -5,7 +5,7 @@ diff --git a/build.gradle b/build.gradle index 61dfae1..2f12d88 100644 --- a/build.gradle +++ b/build.gradle @@ -1,5 +1,3 @@ -// Top-level build file where you can add configuration options common to all sub-projects/modules. - buildscript { ext.kotlin_version = '1.3.21' repositories { @@ -8,10 +6,8 @@ buildscript { } dependencies { - classpath 'com.android.tools.build:gradle:3.3.1' + classpath 'com.android.tools.build:gradle:3.3.2' 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 } } @@ -25,4 +21,4 @@ allprojects { task clean(type: Delete) { delete rootProject.buildDir -} +} \ No newline at end of file diff --git a/cravecalculator/build.gradle b/cravecalculator/build.gradle index 17bc3d1..daed752 100644 --- a/cravecalculator/build.gradle +++ b/cravecalculator/build.gradle @@ -4,31 +4,23 @@ apply plugin: 'kotlin-android-extensions' android { compileSdkVersion 28 - - - defaultConfig { minSdkVersion 21 targetSdkVersion 28 versionCode 1 versionName "1.0" - testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" - } - buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' } } - } dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) - implementation 'com.android.support:appcompat-v7:28.0.0' implementation 'androidx.legacy:legacy-support-v4:1.0.0' implementation 'androidx.lifecycle:lifecycle-extensions:2.0.0' diff --git a/cravecalculator/src/main/java/com/cravefood/cravecalculator/CalculatorFragment.kt b/cravecalculator/src/main/java/com/cravefood/cravecalculator/CalculatorFragment.kt index 72c5551..5f5b9fa 100644 --- a/cravecalculator/src/main/java/com/cravefood/cravecalculator/CalculatorFragment.kt +++ b/cravecalculator/src/main/java/com/cravefood/cravecalculator/CalculatorFragment.kt @@ -9,7 +9,7 @@ import android.widget.Toast import androidx.fragment.app.Fragment import androidx.lifecycle.Observer import androidx.lifecycle.ViewModelProviders -import kotlinx.android.synthetic.main.calculator_fragment.* +import kotlinx.android.synthetic.main.c_calc_fragment.* class CalculatorFragment : Fragment() { @@ -19,7 +19,7 @@ class CalculatorFragment : Fragment() { private var onConfirmListener: ((Double) -> Unit)? = null override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View? { - return inflater.inflate(R.layout.calculator_fragment, container, false) + return inflater.inflate(R.layout.c_calc_fragment, container, false) } override fun onActivityCreated(savedInstanceState: Bundle?) { diff --git a/cravecalculator/src/main/res/drawable/ic_divide.xml b/cravecalculator/src/main/res/drawable/c_calc_ic_divide.xml similarity index 100% rename from cravecalculator/src/main/res/drawable/ic_divide.xml rename to cravecalculator/src/main/res/drawable/c_calc_ic_divide.xml diff --git a/cravecalculator/src/main/res/drawable/ic_equal.xml b/cravecalculator/src/main/res/drawable/c_calc_ic_equal.xml similarity index 100% rename from cravecalculator/src/main/res/drawable/ic_equal.xml rename to cravecalculator/src/main/res/drawable/c_calc_ic_equal.xml diff --git a/cravecalculator/src/main/res/drawable/ic_minus.xml b/cravecalculator/src/main/res/drawable/c_calc_ic_minus.xml similarity index 100% rename from cravecalculator/src/main/res/drawable/ic_minus.xml rename to cravecalculator/src/main/res/drawable/c_calc_ic_minus.xml diff --git a/cravecalculator/src/main/res/drawable/ic_plus.xml b/cravecalculator/src/main/res/drawable/c_calc_ic_plus.xml similarity index 100% rename from cravecalculator/src/main/res/drawable/ic_plus.xml rename to cravecalculator/src/main/res/drawable/c_calc_ic_plus.xml diff --git a/cravecalculator/src/main/res/drawable/ic_times.xml b/cravecalculator/src/main/res/drawable/c_calc_ic_times.xml similarity index 100% rename from cravecalculator/src/main/res/drawable/ic_times.xml rename to cravecalculator/src/main/res/drawable/c_calc_ic_times.xml diff --git a/cravecalculator/src/main/res/drawable/ripple_cancel_button.xml b/cravecalculator/src/main/res/drawable/c_calc_ripple_cancel_button.xml similarity index 76% rename from cravecalculator/src/main/res/drawable/ripple_cancel_button.xml rename to cravecalculator/src/main/res/drawable/c_calc_ripple_cancel_button.xml index ada42fa..26848a8 100644 --- a/cravecalculator/src/main/res/drawable/ripple_cancel_button.xml +++ b/cravecalculator/src/main/res/drawable/c_calc_ripple_cancel_button.xml @@ -2,5 +2,5 @@ + android:drawable="@drawable/c_calc_shape_cancel_button"/> \ No newline at end of file diff --git a/cravecalculator/src/main/res/drawable/ripple_confirm_button.xml b/cravecalculator/src/main/res/drawable/c_calc_ripple_confirm_button.xml similarity index 71% rename from cravecalculator/src/main/res/drawable/ripple_confirm_button.xml rename to cravecalculator/src/main/res/drawable/c_calc_ripple_confirm_button.xml index 9fa823d..9e14ade 100644 --- a/cravecalculator/src/main/res/drawable/ripple_confirm_button.xml +++ b/cravecalculator/src/main/res/drawable/c_calc_ripple_confirm_button.xml @@ -1,5 +1,5 @@ - + \ No newline at end of file diff --git a/cravecalculator/src/main/res/drawable/c_calc_ripple_equal_button.xml b/cravecalculator/src/main/res/drawable/c_calc_ripple_equal_button.xml new file mode 100644 index 0000000..b1d3258 --- /dev/null +++ b/cravecalculator/src/main/res/drawable/c_calc_ripple_equal_button.xml @@ -0,0 +1,5 @@ + + + + \ No newline at end of file diff --git a/cravecalculator/src/main/res/drawable/ripple_numbers_button.xml b/cravecalculator/src/main/res/drawable/c_calc_ripple_numbers_button.xml similarity index 75% rename from cravecalculator/src/main/res/drawable/ripple_numbers_button.xml rename to cravecalculator/src/main/res/drawable/c_calc_ripple_numbers_button.xml index 9bd85d9..050a4b8 100644 --- a/cravecalculator/src/main/res/drawable/ripple_numbers_button.xml +++ b/cravecalculator/src/main/res/drawable/c_calc_ripple_numbers_button.xml @@ -2,5 +2,5 @@ + android:drawable="@drawable/c_calc_shape_numbers_button"/> \ No newline at end of file diff --git a/cravecalculator/src/main/res/drawable/c_calc_ripple_operations_button.xml b/cravecalculator/src/main/res/drawable/c_calc_ripple_operations_button.xml new file mode 100644 index 0000000..432e79d --- /dev/null +++ b/cravecalculator/src/main/res/drawable/c_calc_ripple_operations_button.xml @@ -0,0 +1,5 @@ + + + + \ No newline at end of file diff --git a/cravecalculator/src/main/res/drawable/selector_confirm_button.xml b/cravecalculator/src/main/res/drawable/c_calc_selector_confirm_button.xml similarity index 62% rename from cravecalculator/src/main/res/drawable/selector_confirm_button.xml rename to cravecalculator/src/main/res/drawable/c_calc_selector_confirm_button.xml index 8ceab66..fbfbea2 100644 --- a/cravecalculator/src/main/res/drawable/selector_confirm_button.xml +++ b/cravecalculator/src/main/res/drawable/c_calc_selector_confirm_button.xml @@ -1,5 +1,5 @@ - - + + \ No newline at end of file diff --git a/cravecalculator/src/main/res/drawable/shape_cancel_button.xml b/cravecalculator/src/main/res/drawable/c_calc_shape_cancel_button.xml similarity index 82% rename from cravecalculator/src/main/res/drawable/shape_cancel_button.xml rename to cravecalculator/src/main/res/drawable/c_calc_shape_cancel_button.xml index 2b4af96..9ce0c58 100644 --- a/cravecalculator/src/main/res/drawable/shape_cancel_button.xml +++ b/cravecalculator/src/main/res/drawable/c_calc_shape_cancel_button.xml @@ -1,7 +1,7 @@ - + - + - + - + - + - + - - - \ No newline at end of file diff --git a/cravecalculator/src/main/res/drawable/ripple_operations_button.xml b/cravecalculator/src/main/res/drawable/ripple_operations_button.xml deleted file mode 100644 index 906756d..0000000 --- a/cravecalculator/src/main/res/drawable/ripple_operations_button.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - \ No newline at end of file diff --git a/cravecalculator/src/main/res/font/lato_regular.ttf b/cravecalculator/src/main/res/font/c_calc_lato_regular.ttf similarity index 100% rename from cravecalculator/src/main/res/font/lato_regular.ttf rename to cravecalculator/src/main/res/font/c_calc_lato_regular.ttf diff --git a/cravecalculator/src/main/res/font/lato_semibold.ttf b/cravecalculator/src/main/res/font/c_calc_lato_semibold.ttf similarity index 100% rename from cravecalculator/src/main/res/font/lato_semibold.ttf rename to cravecalculator/src/main/res/font/c_calc_lato_semibold.ttf diff --git a/cravecalculator/src/main/res/layout/calculator_fragment.xml b/cravecalculator/src/main/res/layout/c_calc_fragment.xml similarity index 84% rename from cravecalculator/src/main/res/layout/calculator_fragment.xml rename to cravecalculator/src/main/res/layout/c_calc_fragment.xml index acbcc76..56b0a54 100644 --- a/cravecalculator/src/main/res/layout/calculator_fragment.xml +++ b/cravecalculator/src/main/res/layout/c_calc_fragment.xml @@ -35,7 +35,7 @@ + style="@style/CCalcTextViewOperation"/> + style="@style/CCalcTextViewPreview"/>