How to change background in webview
<p>I have created two themes for my activity; Bright/Dark. But when i trigger change in theme, color of webpage loaded in the webview doesn't change.</p>

<p>I have tried this <code>myWebView.setBackgroundColor(Color.TRANSPARENT);</code>
but it doesn't make any difference. So, how would i go about this?</p>

<p>Here is my layout please have a look;</p>

<pre><code>&lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:ads="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:orientation="vertical"&gt;   

    &lt;LinearLayout
        xmlns:night="http://schemas.android.com/apk/res-auto"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
        android:orientation="vertical"
        android:background="@color/ColorPrimary"
        night:night_background="@color/colorPrimary_n"
        tools:ignore="MissingPrefix"&gt;

        &lt;ProgressBar
            android:id="@+id/progressBar3"
            style="?android:attr/progressBarStyleHorizontal"
            android:layout_width="fill_parent"
            android:layout_height="3dp"
            android:max="100"
            android:progressDrawable="@drawable/greenprogress"
            /&gt;

        &lt;android.support.v4.widget.SwipeRefreshLayout
            xmlns:android="http://schemas.android.com/apk/res/android"
            android:id="@+id/swiperefresh"
            android:layout_width="match_parent"
            android:layout_height="match_parent"&gt;
            &lt;WebView
                xmlns:android="http://schemas.android.com/apk/res/android"
                android:id="@+id/webViewTop"
                android:layout_width="fill_parent"
                android:layout_height="fill_parent"
                night:night_background="@color/colorPrimary_n"
                android:layout_below="@id/progressBar3"/&gt;

        &lt;/android.support.v4.widget.SwipeRefreshLayout&gt;

    &lt;/LinearLayout&gt;
    &lt;com.google.android.gms.ads.AdView
        android:id="@+id/adView"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerHorizontal="true"
        android:layout_alignParentBottom="true"
        ads:adSize="BANNER"
        ads:adUnitId="@string/banner_ad_unit_id"&gt;
    &lt;/com.google.android.gms.ads.AdView&gt;
&lt;/RelativeLayout&gt;
</code></pre>