diff options
author | Scott Jackson <daneren2005@gmail.com> | 2015-01-17 15:34:27 -0800 |
---|---|---|
committer | Scott Jackson <daneren2005@gmail.com> | 2015-01-17 15:34:27 -0800 |
commit | 73b0497234ade5fd061b6d226737a27c8ac5bf61 (patch) | |
tree | 06ce38e54c3e3e9cd6115628edf3d1e833e25d99 /src | |
parent | 59612891378b0799595ec7d4875da37af14cc423 (diff) | |
download | dsub-73b0497234ade5fd061b6d226737a27c8ac5bf61.tar.gz dsub-73b0497234ade5fd061b6d226737a27c8ac5bf61.tar.bz2 dsub-73b0497234ade5fd061b6d226737a27c8ac5bf61.zip |
Increase the number of description lines on tablets
Diffstat (limited to 'src')
-rw-r--r-- | src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java b/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java index d13d9fa5..6d94327c 100644 --- a/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java +++ b/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java @@ -1385,7 +1385,8 @@ public class SelectDirectoryFragment extends SubsonicFragment implements Adapter }
artistView.setText(spanned);
artistView.setSingleLine(false);
- artistView.setLines(5);
+ final int minLines = context.getResources().getInteger(R.integer.TextDescriptionLength);
+ artistView.setLines(minLines);
artistView.setTextAppearance(context, android.R.style.TextAppearance_Small);
final Spanned spannedText = spanned;
@@ -1393,7 +1394,7 @@ public class SelectDirectoryFragment extends SubsonicFragment implements Adapter @TargetApi(Build.VERSION_CODES.JELLY_BEAN)
@Override
public void onClick(View v) {
- if(artistView.getMaxLines() == 5) {
+ if(artistView.getMaxLines() == minLines) {
// Use LeadingMarginSpan2 to try to make text flow around image
Display display = context.getWindowManager().getDefaultDisplay();
View coverArtView = header.findViewById(R.id.select_album_art);
@@ -1424,7 +1425,7 @@ public class SelectDirectoryFragment extends SubsonicFragment implements Adapter vlp = (ViewGroup.MarginLayoutParams) titleView.getLayoutParams();
vlp.leftMargin = width;
} else {
- artistView.setMaxLines(5);
+ artistView.setMaxLines(minLines);
if(albumList instanceof HeaderGridView) {
HeaderGridView headerGridView = (HeaderGridView) albumList;
|