Skip to content

Commit

Permalink
refactor(PreviewlessMedia): move margin value to layout file
Browse files Browse the repository at this point in the history
  • Loading branch information
LucasGGamerM committed Sep 17, 2023
1 parent f69ae5e commit 5cda112
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,9 @@ public Holder(Activity activity, ViewGroup parent){
super(new FrameLayoutThatOnlyMeasuresFirstChild(activity));
wrapper=(FrameLayout)itemView;
layout= new LinearLayout(activity);
layout.setOrientation(LinearLayout.VERTICAL);
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
params.setMargins(V.dp(16), 0, V.dp(16), 0);
layout.setLayoutParams(params);
layout.setOrientation(LinearLayout.VERTICAL);
wrapper.addView(layout);
wrapper.setClipToPadding(false);

Expand Down
2 changes: 1 addition & 1 deletion mastodon/src/main/res/layout/display_item_file.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_marginHorizontal="16dp"
android:layout_height="wrap_content">

<org.joinmastodon.android.ui.views.MaxWidthFrameLayout
android:id="@+id/inner"
android:layout_marginBottom="16dp"
android:layout_marginHorizontal="16dp"
android:background="@drawable/bg_search_field"
android:layout_width="match_parent"
android:layout_height="wrap_content"
Expand Down

0 comments on commit 5cda112

Please sign in to comment.