use the proper style when listing events
This commit is contained in:
parent
b8959259c8
commit
631fe89f3b
2 changed files with 2 additions and 21 deletions
|
@ -27,14 +27,6 @@ class DayActivity : SimpleActivity(), NavigationListener, DBHelper.DBOperationsL
|
||||||
val DELETED_ID = "deleted_id"
|
val DELETED_ID = "deleted_id"
|
||||||
}
|
}
|
||||||
|
|
||||||
/*@BindView(R.id.month_value) internal var mDateTV: TextView? = null
|
|
||||||
@BindView(R.id.day_events) internal var mEventsList: ListView? = null
|
|
||||||
@BindView(R.id.day_coordinator) internal var mCoordinatorLayout: CoordinatorLayout? = null
|
|
||||||
@BindView(R.id.top_left_arrow) internal var mLeftArrow: ImageView? = null
|
|
||||||
@BindView(R.id.top_right_arrow) internal var mRightArrow: ImageView? = null
|
|
||||||
|
|
||||||
@BindDimen(R.dimen.activity_margin) internal var mActivityMargin: Int = 0*/
|
|
||||||
|
|
||||||
override fun onCreate(savedInstanceState: Bundle?) {
|
override fun onCreate(savedInstanceState: Bundle?) {
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
setContentView(R.layout.activity_day)
|
setContentView(R.layout.activity_day)
|
||||||
|
@ -52,18 +44,7 @@ class DayActivity : SimpleActivity(), NavigationListener, DBHelper.DBOperationsL
|
||||||
startActivity(eventIntent)
|
startActivity(eventIntent)
|
||||||
}
|
}
|
||||||
|
|
||||||
/*mToBeDeleted = ArrayList<Int>()
|
//mToBeDeleted = ArrayList<Int>()
|
||||||
|
|
||||||
val baseColor = if (mConfig.isDarkTheme) Color.WHITE else Color.BLACK
|
|
||||||
val textColor = Utils.adjustAlpha(baseColor, Constants.HIGH_ALPHA)
|
|
||||||
mLeftArrow!!.drawable.mutate().setColorFilter(textColor, PorterDuff.Mode.SRC_ATOP)
|
|
||||||
mRightArrow!!.drawable.mutate().setColorFilter(textColor, PorterDuff.Mode.SRC_ATOP)
|
|
||||||
|
|
||||||
var params = mLeftArrow!!.layoutParams as RelativeLayout.LayoutParams
|
|
||||||
params.setMargins(mActivityMargin, params.topMargin, params.rightMargin, params.bottomMargin)
|
|
||||||
|
|
||||||
params = mRightArrow!!.layoutParams as RelativeLayout.LayoutParams
|
|
||||||
params.setMargins(params.leftMargin, params.topMargin, mActivityMargin, params.bottomMargin)*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onResume() {
|
override fun onResume() {
|
||||||
|
|
|
@ -114,7 +114,7 @@ class DayFragment : Fragment(), DBHelper.DBOperationsListener, AdapterView.OnIte
|
||||||
private fun updateEvents(events: MutableList<Event>) {
|
private fun updateEvents(events: MutableList<Event>) {
|
||||||
mEvents = ArrayList(events)
|
mEvents = ArrayList(events)
|
||||||
val eventsToShow = getEventsToShow(events)
|
val eventsToShow = getEventsToShow(events)
|
||||||
val eventsAdapter = EventsAdapter(activity.applicationContext, eventsToShow)
|
val eventsAdapter = EventsAdapter(activity.baseContext, eventsToShow)
|
||||||
mHolder.day_events.apply {
|
mHolder.day_events.apply {
|
||||||
adapter = eventsAdapter
|
adapter = eventsAdapter
|
||||||
onItemClickListener = this@DayFragment
|
onItemClickListener = this@DayFragment
|
||||||
|
|
Loading…
Reference in a new issue