Migrate Bitsy to MaterialComponets theme.

This commit is contained in:
Severiano Jaramillo 2018-11-21 13:13:07 -06:00
parent 196e2f2144
commit fb1d6b89fa
6 changed files with 19 additions and 56 deletions

View file

@ -18,6 +18,9 @@ android {
minifyEnabled false minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
} }
debug {
resValue("string", "PORT_NUMBER", "8082")
}
} }
} }
@ -28,7 +31,7 @@ dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar']) implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation project(':graphenejlib:graphenej') implementation project(':graphenejlib:graphenej')
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'androidx.appcompat:appcompat:1.0.0' implementation 'androidx.appcompat:appcompat:1.0.2'
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-alpha2' implementation 'androidx.constraintlayout:constraintlayout:2.0.0-alpha2'
implementation 'com.google.android.material:material:1.0.0' implementation 'com.google.android.material:material:1.0.0'
implementation 'androidx.legacy:legacy-support-v4:1.0.0' implementation 'androidx.legacy:legacy-support-v4:1.0.0'
@ -41,6 +44,9 @@ dependencies {
implementation "androidx.room:room-runtime:$room_version" implementation "androidx.room:room-runtime:$room_version"
kapt "androidx.room:room-compiler:$room_version" kapt "androidx.room:room-compiler:$room_version"
// Android Debug Database
debugImplementation 'com.amitshekhar.android:debug-db:1.0.4'
// TODO enable and make proper testing // TODO enable and make proper testing
// testImplementation 'junit:junit:4.12' // testImplementation 'junit:junit:4.12'
// testImplementation "androidx.arch.core:core-testing:$lifecycle_version" // testImplementation "androidx.arch.core:core-testing:$lifecycle_version"

View file

@ -9,12 +9,12 @@
android:label="@string/app_name" android:label="@string/app_name"
android:roundIcon="@drawable/bts_logo" android:roundIcon="@drawable/bts_logo"
android:supportsRtl="true" android:supportsRtl="true"
android:theme="@style/AppTheme" android:theme="@style/Theme.Bitsy"
tools:ignore="GoogleAppIndexingWarning"> tools:ignore="GoogleAppIndexingWarning">
<activity <activity
android:name=".activities.MainActivity" android:name=".activities.MainActivity"
android:label="@string/app_name" android:label="@string/app_name"
android:theme="@style/AppTheme.NoActionBar"> android:theme="@style/Theme.Bitsy.NoActionBar">
<intent-filter> <intent-filter>
<action android:name="android.intent.action.MAIN"/> <action android:name="android.intent.action.MAIN"/>
@ -29,16 +29,6 @@
</activity> </activity>
<activity android:name=".activities.ReceiveTransactionActivity"> <activity android:name=".activities.ReceiveTransactionActivity">
</activity> </activity>
<!--<activity
android:name="de.bitshares_munich.smartcoinswallet.ReceiveActivity"
android:screenOrientation="portrait"
android:theme="@style/AppTheme" />-->
<activity
android:name=".activities.RequestActivity"
android:screenOrientation="portrait"
android:theme="@style/AppTheme" />
</application> </application>
</manifest> </manifest>

View file

@ -21,7 +21,7 @@ class SettingsActivity : AppCompatActivity() {
if (PreferenceManager.getDefaultSharedPreferences(this) if (PreferenceManager.getDefaultSharedPreferences(this)
.getBoolean(Constants.KEY_NIGHT_MODE_ACTIVATED, false) .getBoolean(Constants.KEY_NIGHT_MODE_ACTIVATED, false)
) { ) {
setTheme(R.style.AppTheme_Dark) setTheme(R.style.Theme_Bitsy_Dark)
} }
setContentView(R.layout.activity_settings) setContentView(R.layout.activity_settings)

View file

@ -14,7 +14,7 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:paddingTop="@dimen/appbar_padding_top" android:paddingTop="@dimen/appbar_padding_top"
android:theme="@style/AppTheme.AppBarOverlay"> android:theme="@style/Theme.Bitsy.AppBarOverlay">
<!--<android.support.v7.widget.Toolbar--> <!--<android.support.v7.widget.Toolbar-->
<!--android:id="@+id/toolbar"--> <!--android:id="@+id/toolbar"-->

View file

@ -3,37 +3,6 @@
<color name="colorPrimary">#0099d6</color> <color name="colorPrimary">#0099d6</color>
<color name="colorPrimaryDark">#0099d6</color> <color name="colorPrimaryDark">#0099d6</color>
<color name="colorAccent">#669900</color> <color name="colorAccent">#669900</color>
<color name="gray">#d3d3d3</color>
<color name="darkGray">#686767</color>
<color name="white">#ffffff</color>
<color name="pink">#f0006b</color>
<color name="green">#147b00</color> <color name="black">#000</color>
<color name="black">#000000</color>
<color name="skyblue">#BFD1FF</color>
<color name="light_blue">#f2f6ff</color>
<color name="greencolor">#70882E</color>
<color name="red">#ff0000</color>
<color name="pinkColor">#FF4081</color>
<color name="redcolor">#DD4739</color>
<color name="textColorPrimary">#FFFFFF</color>
<color name="windowBackground">#FFFFFF</color>
<color name="navigationBarColor">#000000</color>
<color name="bottomBarColor">#dddddd</color>
<color name="blackColor">#000000</color>
<color name="whiteColor">#ffffff</color>
<color name="receive_amount">#669900</color>
<color name="receive_amount_light">#c5e1a5</color>
<color name="send_amount">#DC473A</color>
<color name="send_amount_light">#ef9a9a</color>
<color name="transactionsHeader">#BFE5F5</color>
<color name="transactionsseparator">#CCCCCC</color>
<color name="color_preloader_start">#000000</color>
<color name="color_preloader_center">#000000</color>
<color name="color_preloader_end">#ff56a9c7</color>
</resources> </resources>

View file

@ -1,33 +1,31 @@
<resources> <resources>
<!-- Base application light theme. --> <!-- Base application light theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"> <style name="Theme.Bitsy" parent="Theme.MaterialComponents.Light.DarkActionBar">
<!-- Customize your theme here. --> <!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item> <item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item> <item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item> <item name="colorAccent">@color/colorAccent</item>
</style> </style>
<style name="AppTheme.NoActionBar"> <style name="Theme.Bitsy.NoActionBar">
<item name="windowActionBar">false</item> <item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item> <item name="windowNoTitle">true</item>
</style> </style>
<style name="AppTheme.AppBarOverlay" parent="ThemeOverlay.AppCompat.Dark.ActionBar"/> <style name="Theme.Bitsy.AppBarOverlay" parent="ThemeOverlay.MaterialComponents.Dark.ActionBar"/>
<!-- Base application dark theme. --> <!-- Base application dark theme. -->
<style name="AppTheme.Dark" parent="Theme.AppCompat"> <style name="Theme.Bitsy.Dark" parent="Theme.MaterialComponents">
<!-- Customize your theme here. --> <!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item> <item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item> <item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item> <item name="colorAccent">@color/colorAccent</item>
</style> </style>
<style name="AppTheme.Dark.NoActionBar"> <style name="Theme.Bitsy.Dark.NoActionBar">
<item name="windowActionBar">false</item> <item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item> <item name="windowNoTitle">true</item>
</style> </style>
<!-- Text styles --> <!-- Text styles -->
<style name="TextAppearance.Body1" parent="TextAppearance.AppCompat.Body1" > <style name="TextAppearance.Body1" parent="TextAppearance.MaterialComponents.Body1" />
<item name="android:textSize">16sp</item> <style name="TextAppearance.Body2" parent="TextAppearance.MaterialComponents.Body2" />
</style>
<style name="TextAppearance.Body2" parent="Base.TextAppearance.AppCompat.Body2" />
</resources> </resources>