Fix about layout (do not compile, gradle process diseapears)

This commit is contained in:
jacques 2019-09-18 23:03:08 +02:00
parent e1515086d1
commit 5285f8d070
2 changed files with 7 additions and 5 deletions

View file

@ -1,9 +1,10 @@
package net.foucry.pilldroid;
import android.R;
import net.foucry.pilldroid.R;
import android.graphics.Color;
import android.graphics.drawable.Drawable;
import android.os.Bundle;
import android.support.v4.content.ContextCompat;
import android.support.v7.app.AppCompatActivity;
import android.text.Html;
import android.webkit.WebView;
@ -44,8 +45,9 @@ public class About extends AppCompatActivity{
return null;
}
Drawable d = getResources().getDrawable(id);
// Drawable d = ResourcesCompat.getDrawable(getResources(),id, null);
// Drawable d = getResources().getDrawable(id);
//Drawable d = ResourcesCompatApi21.getDrawable(getResources(),id, null);
Drawable d = ContextCompat.getDrawable(getApplicationContext(),id);
d.setBounds(0, 0, d.getIntrinsicWidth(), d.getIntrinsicHeight());
return d;
}

View file

@ -6,6 +6,6 @@
<WebView
android:id="@+id/aboutHtml"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
android:layout_width="match_parent"
android:layout_height="match_parent" />
</LinearLayout>