Merge pull request #524 from sigmabeta/android-banner-scaling
Fix banner scaling using a different method.
This commit is contained in:
commit
4d39076d04
|
@ -7,8 +7,8 @@
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/ListItemIcon"
|
android:id="@+id/ListItemIcon"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="100dp"
|
||||||
android:layout_height="fill_parent"
|
android:layout_height="wrap_content"
|
||||||
|
|
||||||
tools:src="@drawable/ic_launcher"
|
tools:src="@drawable/ic_launcher"
|
||||||
|
|
||||||
|
|
|
@ -65,8 +65,6 @@ public final class GameListAdapter extends ArrayAdapter<GameListItem>
|
||||||
if (icon != null)
|
if (icon != null)
|
||||||
{
|
{
|
||||||
icon.setImageBitmap(item.getImage());
|
icon.setImageBitmap(item.getImage());
|
||||||
icon.getLayoutParams().width = (int) ((860 / context.getResources().getDisplayMetrics().density) + 0.5);
|
|
||||||
icon.getLayoutParams().height = (int)((340 / context.getResources().getDisplayMetrics().density) + 0.5);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue