Compare commits
1 Commits
c52a74c7e3
...
f8bd760f7a
| Author | SHA1 | Date | |
|---|---|---|---|
| f8bd760f7a |
@@ -78,7 +78,7 @@ class MainActivity : AppCompatActivity() {
|
||||
progressIndicator = findViewById(R.id.progress_indicator)
|
||||
buttonsContainer = findViewById(R.id.buttons_container)
|
||||
recyclerView = findViewById(R.id.list_events)
|
||||
recyclerView.setLayoutManager(LinearLayoutManager(this))
|
||||
recyclerView.setLayoutManager(LinearLayoutManager(applicationContext))
|
||||
|
||||
// Set listeners
|
||||
findViewById<View>(R.id.logbooks_add_button).setOnClickListener {
|
||||
@@ -637,8 +637,8 @@ class MainActivity : AppCompatActivity() {
|
||||
val previousTextView = dialogView.findViewById<TextView>(R.id.dialog_event_previous)
|
||||
val previousEvent = getPreviousSameEvent(event, allEvents)
|
||||
if (previousEvent != null) {
|
||||
val emoji = previousEvent.getTypeEmoji(this)
|
||||
val time = DateUtils.formatTimeDuration(this, event.time - previousEvent.time)
|
||||
val emoji = previousEvent.getTypeEmoji(applicationContext)
|
||||
val time = DateUtils.formatTimeDuration(applicationContext, event.time - previousEvent.time)
|
||||
previousTextView.text = String.format("⬅️ %s %s", emoji, time)
|
||||
previousTextView.setOnClickListener {
|
||||
alertDialog.cancel()
|
||||
@@ -652,8 +652,8 @@ class MainActivity : AppCompatActivity() {
|
||||
val nextTextView = dialogView.findViewById<TextView>(R.id.dialog_event_next)
|
||||
val nextEvent = getNextSameEvent(event, allEvents)
|
||||
if (nextEvent != null) {
|
||||
val emoji = nextEvent.getTypeEmoji(this)
|
||||
val time = DateUtils.formatTimeDuration(this, nextEvent.time - event.time)
|
||||
val emoji = nextEvent.getTypeEmoji(applicationContext)
|
||||
val time = DateUtils.formatTimeDuration(applicationContext, nextEvent.time - event.time)
|
||||
nextTextView.text = String.format("%s %s ➡️", time, emoji)
|
||||
nextTextView.setOnClickListener {
|
||||
alertDialog.cancel()
|
||||
|
||||
Reference in New Issue
Block a user