Commit 7f83041b authored by Nihar Thakkar's avatar Nihar Thakkar
Browse files

Show categories screen when app category is clicked

parent 43999e36
......@@ -28,6 +28,7 @@ import foundation.e.apps.application.model.data.FullData
import foundation.e.apps.applicationmanager.ApplicationManager
import foundation.e.apps.applicationmanager.ApplicationManagerServiceConnection
import foundation.e.apps.applicationmanager.ApplicationManagerServiceConnectionCallback
import foundation.e.apps.categories.category.CategoryActivity
import foundation.e.apps.utils.Common
import foundation.e.apps.utils.Common.toMiB
import foundation.e.apps.utils.Constants
......@@ -180,6 +181,11 @@ class ApplicationActivity : AppCompatActivity(), ApplicationStateListener,
// Set the app category
if (fullData.category.getTitle().isNotEmpty()) {
app_category.text = fullData.category.getTitle()
app_category.setOnClickListener {
startActivity(Intent(this, CategoryActivity::class.java).apply {
putExtra(Constants.CATEGORY_KEY, fullData.category)
})
}
} else {
app_category.visibility = View.GONE
}
......
......@@ -84,6 +84,7 @@
android:layout_marginTop="@dimen/layout_margin_medium"
android:background="@drawable/app_category_border"
android:ellipsize="end"
android:foreground="?android:selectableItemBackground"
android:maxLines="1"
android:textSize="@dimen/text_size_medium"
tools:text="App category" />
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment