Advertisement
solodroid

gnt_small_template_view.xml

Jan 16th, 2021
1,059
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 9.37 KB | None | 0 0
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <merge xmlns:android="http://schemas.android.com/apk/res/android"
  3.    xmlns:app="http://schemas.android.com/apk/res-auto"
  4.    xmlns:card_view="http://schemas.android.com/apk/res-auto">
  5.  
  6.     <com.google.android.gms.ads.formats.UnifiedNativeAdView
  7.        android:id="@+id/native_ad_view"
  8.        android:layout_width="match_parent"
  9.        android:layout_height="wrap_content">
  10.  
  11.         <androidx.constraintlayout.widget.ConstraintLayout
  12.            android:id="@+id/background"
  13.            android:layout_width="wrap_content"
  14.            android:layout_height="match_parent">
  15.  
  16.             <RelativeLayout
  17.                android:layout_width="match_parent"
  18.                android:layout_height="wrap_content"
  19.                app:layout_constraintBottom_toBottomOf="parent"
  20.                app:layout_constraintEnd_toEndOf="parent"
  21.                app:layout_constraintTop_toTopOf="parent">
  22.  
  23.                 <LinearLayout
  24.                    android:id="@+id/lyt_ad"
  25.                    android:layout_width="match_parent"
  26.                    android:layout_height="wrap_content"
  27.                    android:gravity="center_vertical"
  28.                    android:minHeight="?attr/actionBarSize"
  29.                    android:orientation="horizontal"
  30.                    android:padding="3dp">
  31.  
  32.                     <View
  33.                        android:layout_width="@dimen/row_spacing"
  34.                        android:layout_height="0dp" />
  35.  
  36.                     <RelativeLayout
  37.                        android:layout_width="@dimen/img_compact_width"
  38.                        android:layout_height="@dimen/img_compact_width"
  39.                        android:layout_marginTop="@dimen/row_spacing"
  40.                        android:layout_marginBottom="@dimen/row_spacing">
  41.  
  42.                         <com.makeramen.roundedimageview.RoundedImageView
  43.                            android:id="@+id/icon"
  44.                            android:layout_width="@dimen/img_compact_width"
  45.                            android:layout_height="@dimen/img_compact_height"
  46.                            android:scaleType="centerCrop"
  47.                            android:visibility="gone"
  48.                            app:riv_corner_radius="8dip" />
  49.  
  50.                         <androidx.cardview.widget.CardView
  51.                            android:id="@+id/card_media_view"
  52.                            android:layout_width="match_parent"
  53.                            android:layout_height="wrap_content"
  54.                            card_view:cardCornerRadius="8dp"
  55.                            card_view:cardElevation="0dp">
  56.  
  57.                             <com.google.android.gms.ads.formats.MediaView
  58.                                android:id="@+id/media_view"
  59.                                android:layout_width="@dimen/img_compact_width"
  60.                                android:layout_height="@dimen/img_compact_height" />
  61.  
  62.                         </androidx.cardview.widget.CardView>
  63.  
  64.                     </RelativeLayout>
  65.  
  66.                     <View
  67.                        android:layout_width="@dimen/row_spacing"
  68.                        android:layout_height="0dp" />
  69.  
  70.                     <RelativeLayout
  71.                        android:layout_width="match_parent"
  72.                        android:layout_height="match_parent"
  73.                        android:layout_marginStart="4dp"
  74.                        android:layout_marginLeft="4dp"
  75.                        android:orientation="vertical">
  76.  
  77.                         <LinearLayout
  78.                            android:layout_width="match_parent"
  79.                            android:layout_height="wrap_content"
  80.                            android:layout_centerVertical="true"
  81.                            android:gravity="center_vertical"
  82.                            android:orientation="horizontal">
  83.  
  84.                             <LinearLayout
  85.                                android:layout_width="0dp"
  86.                                android:layout_height="wrap_content"
  87.                                android:layout_weight="1"
  88.                                android:orientation="vertical">
  89.  
  90.                                 <TextView
  91.                                    android:id="@+id/primary"
  92.                                    android:layout_width="match_parent"
  93.                                    android:layout_height="wrap_content"
  94.                                    android:ellipsize="end"
  95.                                    android:lines="1"
  96.                                    android:text="Head"
  97.                                    android:textAppearance="@style/Base.TextAppearance.AppCompat.Body2"
  98.                                    android:textSize="@dimen/text_title_size" />
  99.  
  100.                                 <LinearLayout
  101.                                    android:id="@+id/row_two"
  102.                                    android:layout_width="match_parent"
  103.                                    android:layout_height="wrap_content"
  104.                                    android:layout_marginTop="3dp"
  105.                                    android:orientation="horizontal">
  106.  
  107.                                     <TextView
  108.                                        android:id="@+id/ad_notification_view"
  109.                                        android:layout_width="@dimen/gnt_ad_indicator_width"
  110.                                        android:layout_height="@dimen/gnt_ad_indicator_height"
  111.                                        android:layout_marginStart="@dimen/gnt_no_margin"
  112.                                        android:layout_marginLeft="@dimen/gnt_no_margin"
  113.                                        android:layout_marginTop="@dimen/gnt_ad_indicator_top_margin"
  114.                                        android:layout_marginEnd="@dimen/gnt_no_margin"
  115.                                        android:layout_marginRight="@dimen/gnt_no_margin"
  116.                                        android:background="@drawable/gnt_rounded_corners_shape"
  117.                                        android:gravity="center"
  118.                                        android:text="Ad"
  119.                                        android:textColor="@color/gnt_ad_green"
  120.                                        android:textSize="@dimen/gnt_ad_indicator_text_size"
  121.                                        android:textStyle="bold" />
  122.                                        
  123.                                     <LinearLayout
  124.                                         android:id="@+id/lyt_rating_bar"
  125.                                         android:layout_width="match_parent"
  126.                                         android:layout_height="wrap_content"
  127.                                         android:visibility="gone"
  128.                                         android:orientation="vertical">
  129.  
  130.                                         <RatingBar
  131.                                             android:id="@+id/rating_bar"
  132.                                             android:layout_width="match_parent"
  133.                                             android:layout_height="wrap_content"
  134.                                             android:layout_marginStart="@dimen/gnt_no_margin"
  135.                                             android:layout_marginTop="@dimen/gnt_no_margin"
  136.                                             android:layout_marginEnd="@dimen/gnt_no_margin"
  137.                                             android:layout_marginBottom="@dimen/gnt_no_margin"
  138.                                             android:lines="1"
  139.                                             android:numStars="0"
  140.                                             android:textColor="@color/gnt_gray"
  141.                                             android:textSize="@dimen/gnt_text_size_small"
  142.                                             android:visibility="gone">
  143.  
  144.                                         </RatingBar>
  145.                                    
  146.                                     </LinearLayout>
  147.  
  148.                                     <TextView
  149.                                        android:id="@+id/secondary"
  150.                                        android:layout_width="match_parent"
  151.                                        android:layout_height="match_parent"
  152.                                        android:layout_marginStart="@dimen/gnt_no_margin"
  153.                                        android:layout_marginTop="@dimen/gnt_no_margin"
  154.                                        android:layout_marginEnd="@dimen/gnt_no_margin"
  155.                                        android:layout_marginBottom="@dimen/gnt_no_margin"
  156.                                        android:gravity="top"
  157.                                        android:lines="1"
  158.                                        android:text="sub title"
  159.                                        android:textSize="@dimen/text_sub_title_size" />
  160.  
  161.                                 </LinearLayout>
  162.  
  163.                                 <Button
  164.                                    android:id="@+id/cta"
  165.                                    android:layout_width="match_parent"
  166.                                    android:layout_height="30dp"
  167.                                    android:background="@drawable/bg_button_primary"
  168.                                    android:lines="1"
  169.                                    android:textColor="@color/gnt_white"
  170.                                    android:visibility="gone" />
  171.  
  172.                             </LinearLayout>
  173.  
  174.                             <View
  175.                                android:layout_width="@dimen/row_spacing"
  176.                                android:layout_height="0dp" />
  177.  
  178.                             <View
  179.                                android:layout_width="10dp"
  180.                                android:layout_height="0dp" />
  181.  
  182.                         </LinearLayout>
  183.  
  184.                     </RelativeLayout>
  185.  
  186.                 </LinearLayout>
  187.  
  188.             </RelativeLayout>
  189.  
  190.         </androidx.constraintlayout.widget.ConstraintLayout>
  191.  
  192.     </com.google.android.gms.ads.formats.UnifiedNativeAdView>
  193.  
  194. </merge>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement