mirror of
https://github.com/moparisthebest/Yaaic
synced 2024-12-01 05:12:18 -05:00
MessageListView: Set transcript mode to normal (Only automatically scroll if the last item is visible). Fixes #119.
This commit is contained in:
parent
dbdc731965
commit
81b7fe798c
@ -51,15 +51,13 @@ public class MessageListView extends ListView
|
|||||||
setVerticalFadingEdgeEnabled(false);
|
setVerticalFadingEdgeEnabled(false);
|
||||||
setBackgroundResource(R.layout.conversation_background);
|
setBackgroundResource(R.layout.conversation_background);
|
||||||
setScrollBarStyle(SCROLLBARS_OUTSIDE_INSET);
|
setScrollBarStyle(SCROLLBARS_OUTSIDE_INSET);
|
||||||
setTranscriptMode(TRANSCRIPT_MODE_ALWAYS_SCROLL);
|
|
||||||
|
|
||||||
// Scale padding by screen density
|
// Scale padding by screen density
|
||||||
float density = context.getResources().getDisplayMetrics().density;
|
float density = context.getResources().getDisplayMetrics().density;
|
||||||
int padding = (int) (5 * density);
|
int padding = (int) (5 * density);
|
||||||
setPadding(padding, padding, padding, padding);
|
setPadding(padding, padding, padding, padding);
|
||||||
|
|
||||||
// XXX: This should be dynamically
|
setTranscriptMode(TRANSCRIPT_MODE_NORMAL);
|
||||||
setTranscriptMode(TRANSCRIPT_MODE_ALWAYS_SCROLL);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user