In my app there is a white bar at the bottom. I've looked at other questions and they told me to make sure I have everything set to match_parent. I did that and nothing worked.
Picture:
http://i.imgur.com/G3FlTij.png
Any help would be appreciated.
fragment_main.xml
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:id="#+id/container_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<android.support.v4.widget.SwipeRefreshLayout
android:id="#+id/container_swipe_refresh"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1">
<WebView
android:id="#+id/fragment_main_webview"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#color/global_bg_front" />
</android.support.v4.widget.SwipeRefreshLayout>
<com.google.android.gms.ads.AdView
android:id="#+id/fragment_main_adview"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
app:adUnitId="#string/admob_unit_id"
app:adSize="BANNER" />
</LinearLayout>
<include
layout="#layout/placeholder_progress"
android:id="#+id/container_progress"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone" />
<include
layout="#layout/placeholder_offline"
android:id="#+id/container_offline"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone" />
<include
layout="#layout/placeholder_empty"
android:id="#+id/container_empty"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone" />
activity_main.xml
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<include layout="#layout/toolbar" />
<android.support.v4.widget.DrawerLayout
android:id="#+id/activity_main_layout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<FrameLayout
android:id="#+id/activity_main_container"
android:layout_width="match_parent"
android:layout_height="match_parent" />
<ListView
android:id="#+id/activity_main_drawer"
android:layout_width="#dimen/drawer_width"
android:layout_height="match_parent"
android:layout_gravity="start"
android:choiceMode="singleChoice"
android:drawSelectorOnTop="true"
android:fastScrollEnabled="false"
android:listSelector="#drawable/selector_clickable_item_bg"
android:background="#color/global_bg_front" />
</android.support.v4.widget.DrawerLayout>
Isn't this bar because of wrongly displayed ads in layout? Did you try to remove it? If bar disappear, it means that there is a problem with displaying ads.
<com.google.android.gms.ads.AdView
android:id="#+id/fragment_main_adview"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
app:adUnitId="#string/admob_unit_id"
app:adSize="BANNER" />
Related
How can I make layouts/views that have a lower z-index in a RelativeLayout response to any gesture, even if the view/layout above them covers the entire screen?
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#drawable/purplebgscaled"
tools:context="com.xxx.xxx.MainActivity">
<!-- This is the layout I want to interact with -->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="top|center"
android:orientation="vertical"
android:translationY="20dp">
<androidx.fragment.app.FragmentContainerView
android:id="#+id/brightness_controls"
android:name="com.xxx.xxx.BrightnessControls"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingHorizontal="50dp"
android:paddingTop="25dp" />
<androidx.fragment.app.FragmentContainerView
android:id="#+id/fragment_container_view"
android:name="com.xxx.xxx.Clock"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingTop="20dp" />
</LinearLayout>
<!-- It needs to be behind this drawer -->
<androidx.drawerlayout.widget.DrawerLayout
android:id="#+id/drawer"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="com.xxx.xxx.MainActivity"
tools:openDrawer="start">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:orientation="vertical"
android:translationY="250dp">
<androidx.recyclerview.widget.RecyclerView
android:id="#+id/appHome_recylerView"
android:layout_width="wrap_content"
android:layout_height="match_parent" />
</LinearLayout>
<com.google.android.material.navigation.NavigationView
android:id="#+id/navigation_view"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_gravity="start"
android:clipToPadding="false"
app:menu="#menu/main_menu" />
</androidx.drawerlayout.widget.DrawerLayout>
<ImageView
android:id="#+id/icon_drawer"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_centerInParent="true"
android:layout_marginBottom="20dp"
android:contentDescription="#string/background_image"
android:src="#drawable/ic_apps" />
</RelativeLayout>
Action Bar is going out of the screen when keyboard is in use on Edit text.
I have tried using some parameters of windowSoftInputMode on activity tag in Manifest as adjustresize, adjustPan but none of the above worked.
My xml is
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:background="#ffffff"
android:fitsSystemWindows="true"
android:orientation="vertical"
tools:context=".MainActivity">
<include
layout="#layout/toolbar"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:layout_gravity="top"
/>
<ScrollView
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight=".9"
android:id="#+id/scrollView"
android:paddingBottom="#dimen/margin_toolbar"
android:paddingLeft="#dimen/margin_toolbar"
android:paddingRight="#dimen/margin_toolbar"
android:paddingTop="#dimen/margin_toolbar">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="#+id/layout2"
android:layout_width="match_parent"
android:layout_height="match_parent"
>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:id="#+id/layout1">
</LinearLayout>
</RelativeLayout>
</LinearLayout>
</ScrollView>
<include
layout="#layout/bottom_chat"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight=".1"
android:layout_gravity="bottom"
/>
</LinearLayout>
I am not able to resolve the problem
I need to show a header above a RecyclerView but with the code below, the header is not fixed and gets scrolled with the recycler view.
Does anyone has a solution for his problem?
fragment_history_detail.xml
[[First Try]]
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?android:attr/colorBackground">
<RelativeLayout
android:id="#+id/header_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentTop="true">
<include
layout="#layout/view_header_history_detail"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</RelativeLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="#id/header_container">
<android.support.v7.widget.RecyclerView
android:id="#+id/recyclerView_history_list"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
app:layoutManager="LinearLayoutManager"
tools:listitem="#layout/fragment_history_detail_item_self" />
</RelativeLayout>
</RelativeLayout>
[[Second Try]]
I also tried using LinearLayout like below. But it doesn't help.
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?android:attr/colorBackground"
android:orientation="vertical">
<include
layout="#layout/view_header_history_detail"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
<android.support.v7.widget.RecyclerView
android:id="#+id/recyclerView_history_list"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
app:layoutManager="LinearLayoutManager"
tools:listitem="#layout/fragment_history_detail_item_self" />
</LinearLayout>
[[Third Try]]
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?android:attr/colorBackground"
android:orientation="vertical">
<include
layout="#layout/view_header_history_detail"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
<RelativeLayout xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?android:attr/colorBackground">
<android.support.v7.widget.RecyclerView
android:id="#+id/recyclerView_history_list"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
app:layoutManager="LinearLayoutManager"
tools:listitem="#layout/fragment_history_detail_item_self" />
</RelativeLayout>
</LinearLayout>
view_header_history_detail.xml
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal">
<ImageView
android:id="#+id/imageView_back"
android:layout_width="60dp"
android:layout_height="#dimen/title_height"
android:background="?attr/colorPrimaryDark"
app:srcCompat="#drawable/vector_expand_left" />
<TextView
android:id="#+id/textview_title"
android:layout_width="match_parent"
android:layout_height="#dimen/title_height"
android:background="?attr/colorPrimaryDark"
android:gravity="center_vertical"
android:text="History Detail"
android:textAllCaps="true"
android:textColor="?attr/colorHeaderText"
android:textSize="16sp" />
</LinearLayout>
Use LinearLayout instead of RelativeLayout. And ser Orientation to vertical. So that the layout place top to bottom.
So, Your parent layout should be link this ->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?android:attr/colorBackground">
<!--Your child layouts goes here-->
</LinearLayout>
Copy below code and put in your xml file
<RelativeLayout
android:id="#+id/header_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentTop="true">
<include
layout="#layout/view_header_history_detail"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</RelativeLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="#id/header_container">
<android.support.v7.widget.RecyclerView
android:id="#+id/recyclerView_history_list"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
app:layoutManager="LinearLayoutManager"
tools:listitem="#layout/fragment_history_detail_item_self" />
</RelativeLayout>
remove above relative layout or you can paste ralative layout content
<RelativeLayout
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?android:attr/colorBackground">
<android.support.v7.widget.RecyclerView
android:id="#+id/recyclerView_history_list"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
app:layoutManager="LinearLayoutManager"
tools:listitem="#layout/fragment_history_detail_item_self" />
</RelativeLayout>
if you want to fix the layout then u can do one thing as i m thinking....
look the code below....
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?android:attr/colorBackground"
android:orientation="vertical">
<include
layout="#layout/view_header_history_detail"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
<RelativeLayout xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?android:attr/colorBackground"/>
<android.support.v7.widget.RecyclerView
android:id="#+id/recyclerView_history_list"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
app:layoutManager="LinearLayoutManager"
tools:listitem="#layout/fragment_history_detail_item_self" /></LinearLayout>
Try below code. it works for me.
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<include layout="#layout/view_header_history_detail" />
<android.support.v7.widget.RecyclerView
android:id="#+id/recyclerChat"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1" />
</LinearLayout>
In my home screen I want to add the search box with navigation drawer but I am not able to set the non scrollable edittext over scrollview.
Here is my Code
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="#+id/drawer"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true"
android:background="#ecedf1">
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fillViewport="true">
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<android.support.v4.view.ViewPager xmlns:android="http://schemas.android.com/apk/res/android"
android:id="#+id/viewpager"
android:layout_width="match_parent"
android:layout_height="#dimen/_200sdp" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="#dimen/_200sdp"
>
<EditText
android:layout_width="#dimen/_280sdp"
android:layout_centerHorizontal="true"
android:layout_marginTop="#dimen/_10sdp"
android:layout_height="#dimen/_40sdp"
android:text="fdgsdfhsfhsfghhsfhsfhf"
android:background="#drawable/customedittext"/>
</RelativeLayout>
<RelativeLayout
android:id="#+id/viewPagerIndicator"
android:layout_width="match_parent"
android:layout_height="25dp"
android:layout_marginTop="#dimen/_180sdp"
android:gravity="center">
<LinearLayout
android:id="#+id/viewPagerCountDots"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_centerHorizontal="true"
android:gravity="center"
android:orientation="horizontal" />
</RelativeLayout>
<com.information.aanjana.aanjanainformation.NonScrollGridView
android:id="#+id/gv_android"
android:layout_width="#dimen/_299sdp"
android:layout_height="match_parent"
android:horizontalSpacing="8dp"
android:layout_centerHorizontal="true"
android:numColumns="2"
android:paddingLeft="#dimen/_4sdp"
android:paddingRight="#dimen/_4sdp"
android:layout_marginTop="#dimen/_220sdp"
android:verticalSpacing="8dp"/>
</RelativeLayout>
</ScrollView>
<android.support.design.widget.NavigationView
android:id="#+id/navigation_view"
android:layout_height="match_parent"
android:layout_width="#dimen/_170sdp"
android:layout_gravity="start"
app:menu="#menu/drawer"
/>
</android.support.v4.widget.DrawerLayout>
I want a edittext with navigation drawer which should be sticky and do not scroll with rest of the layout. How can I achive it.
What I want is explained in screenshot below:
Try my below code:
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="#+id/drawer"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true"
android:background="#ecedf1">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fillViewport="true">
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<android.support.v4.view.ViewPager xmlns:android="http://schemas.android.com/apk/res/android"
android:id="#+id/viewpager"
android:layout_width="match_parent"
android:layout_height="#dimen/_200sdp" />
<RelativeLayout
android:id="#+id/viewPagerIndicator"
android:layout_width="match_parent"
android:layout_height="25dp"
android:layout_marginTop="#dimen/_180sdp"
android:gravity="center">
<LinearLayout
android:id="#+id/viewPagerCountDots"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_centerHorizontal="true"
android:gravity="center"
android:orientation="horizontal" />
</RelativeLayout>
<com.information.aanjana.aanjanainformation.NonScrollGridView
android:id="#+id/gv_android"
android:layout_width="#dimen/_299sdp"
android:layout_height="match_parent"
android:horizontalSpacing="8dp"
android:layout_centerHorizontal="true"
android:numColumns="2"
android:paddingLeft="#dimen/_4sdp"
android:paddingRight="#dimen/_4sdp"
android:layout_marginTop="#dimen/_220sdp"
android:verticalSpacing="8dp"/>
</RelativeLayout>
</ScrollView>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="#dimen/_200sdp"
android:layout_alignParentTop="true"
>
<EditText
android:layout_width="#dimen/_280sdp"
android:layout_centerHorizontal="true"
android:layout_marginTop="#dimen/_10sdp"
android:layout_height="#dimen/_40sdp"
android:text="fdgsdfhsfhsfghhsfhsfhf"
android:background="#drawable/customedittext"/>
</RelativeLayout>
</RelativeLayout>
<android.support.design.widget.NavigationView
android:id="#+id/navigation_view"
android:layout_height="match_parent"
android:layout_width="#dimen/_170sdp"
android:layout_gravity="start"
app:menu="#menu/drawer"
/>
</android.support.v4.widget.DrawerLayout>
Here Only thing which I have changed is kept the editText outside the scrollView.
Why don't you try to put it out outside the ScrollView. Then just overlay it with a RelativeLayout and the gravity set to top. I can't run it now but in xml should look like something like this
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="#+id/drawer"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true"
android:background="#ecedf1">
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fillViewport="true">
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<android.support.v4.view.ViewPager xmlns:android="http://schemas.android.com/apk/res/android"
android:id="#+id/viewpager"
android:layout_width="match_parent"
android:layout_height="#dimen/_200sdp" />
<RelativeLayout
android:id="#+id/viewPagerIndicator"
android:layout_width="match_parent"
android:layout_height="25dp"
android:layout_marginTop="#dimen/_180sdp"
android:gravity="center">
<LinearLayout
android:id="#+id/viewPagerCountDots"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_centerHorizontal="true"
android:gravity="center"
android:orientation="horizontal" />
</RelativeLayout>
<com.information.aanjana.aanjanainformation.NonScrollGridView
android:id="#+id/gv_android"
android:layout_width="#dimen/_299sdp"
android:layout_height="match_parent"
android:horizontalSpacing="8dp"
android:layout_centerHorizontal="true"
android:numColumns="2"
android:paddingLeft="#dimen/_4sdp"
android:paddingRight="#dimen/_4sdp"
android:layout_marginTop="#dimen/_220sdp"
android:verticalSpacing="8dp"/>
</RelativeLayout>
</ScrollView>
<!-- Here we add the layout outside the ScrollView -->
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="#dimen/_200sdp"
android:gravity="top"> <!-- GRAVITY ADJUST -->
<EditText
android:layout_width="#dimen/_280sdp"
android:layout_centerHorizontal="true"
android:layout_marginTop="#dimen/_10sdp"
android:layout_height="#dimen/_40sdp"
android:text="fdgsdfhsfhsfghhsfhsfhf"
android:background="#drawable/customedittext"/>
</RelativeLayout>
<android.support.design.widget.NavigationView
android:id="#+id/navigation_view"
android:layout_height="match_parent"
android:layout_width="#dimen/_170sdp"
android:layout_gravity="start"
app:menu="#menu/drawer"
/>
</android.support.v4.widget.DrawerLayout>
Hopefully, it runs smoothly and turns out helpful.
I crated an Android app with webview. In Android simulator I can scroll out the website, till it match perfekt the webview. But at a real Android device, I'm not able to scroll out till the website content matches the webwiew, it is to large. What co do I have to put/change to get the website match the webview?
I hope you understand my issue und can help me!?
this.mWebView.getSettings().setJavaScriptEnabled(true);
this.mWebView.getSettings().setUseWideViewPort(true);
this.mWebView.getSettings().setLoadWithOverviewMode(true);
this.mWebView.getSettings().setRenderPriority(RenderPriority.HIGH);
if you mention above settings ,webview can render your website properly.
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:webviewapp="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:id="#+id/container_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<android.support.v4.widget.SwipeRefreshLayout
android:id="#+id/container_swipe_refresh"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1">
<WebView
android:id="#+id/fragment_main_webview"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#color/global_bg_front" />
</android.support.v4.widget.SwipeRefreshLayout>
<com.google.android.gms.ads.AdView
android:id="#+id/fragment_main_adview"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
webviewapp:adUnitId="#string/admob_unit_id"
webviewapp:adSize="BANNER" />
</LinearLayout>
<include layout="#layout/placeholder_progress"
android:id="#+id/container_progress"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone" />
<include layout="#layout/placeholder_offline"
android:id="#+id/container_offline"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone" />
<include layout="#layout/placeholder_empty"
android:id="#+id/container_empty"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone" />
</FrameLayout>
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:webviewapp="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:id="#+id/container_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<android.support.v4.widget.SwipeRefreshLayout
android:id="#+id/container_swipe_refresh"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1">
<WebView
android:id="#+id/fragment_main_webview"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#color/global_bg_front" />
</android.support.v4.widget.SwipeRefreshLayout>
<com.google.android.gms.ads.AdView
android:id="#+id/fragment_main_adview"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
webviewapp:adUnitId="#string/admob_unit_id"
webviewapp:adSize="BANNER" />
</LinearLayout>
<include layout="#layout/placeholder_progress"
android:id="#+id/container_progress"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone" />
<include layout="#layout/placeholder_offline"
android:id="#+id/container_offline"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone" />
<include layout="#layout/placeholder_empty"
android:id="#+id/container_empty"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone" />
</FrameLayout>
<?xml version="1.0" encoding="utf-8"?>
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="#+id/activity_main_layout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<FrameLayout
android:id="#+id/activity_main_container"
android:layout_width="match_parent"
android:layout_height="match_parent" />
<ListView
android:id="#+id/activity_main_drawer"
android:layout_width="#dimen/drawer_width"
android:layout_height="match_parent"
android:layout_gravity="start"
android:choiceMode="singleChoice"
android:drawSelectorOnTop="false"
android:fastScrollEnabled="false"
android:dividerHeight="#dimen/drawer_item_divider"
android:divider="#color/drawer_item_divider"
android:cacheColorHint="#android:color/transparent"
android:listSelector="#android:color/transparent"
android:background="#color/drawer_bg" />
</android.support.v4.widget.DrawerLayout>