Implemented WebView to show description of item
This commit is contained in:
parent
d7e3bfc930
commit
8078e34912
@ -49,4 +49,8 @@
|
|||||||
android:layout_width="0px"
|
android:layout_width="0px"
|
||||||
android:layout_height="wrap_content"/>
|
android:layout_height="wrap_content"/>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
<WebView
|
||||||
|
android:id="@+id/webvDescription"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"/>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
@ -7,6 +7,7 @@ import android.os.Bundle;
|
|||||||
import android.text.format.DateUtils;
|
import android.text.format.DateUtils;
|
||||||
import android.util.Log;
|
import android.util.Log;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
|
import android.webkit.WebView;
|
||||||
import android.widget.Button;
|
import android.widget.Button;
|
||||||
import android.widget.ImageView;
|
import android.widget.ImageView;
|
||||||
import android.widget.TextView;
|
import android.widget.TextView;
|
||||||
@ -38,6 +39,7 @@ public class ItemviewActivity extends SherlockActivity {
|
|||||||
private Button butPlay;
|
private Button butPlay;
|
||||||
private Button butDownload;
|
private Button butDownload;
|
||||||
private Button butRemove;
|
private Button butRemove;
|
||||||
|
private WebView webvDescription;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onCreate(Bundle savedInstanceState) {
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
@ -117,7 +119,7 @@ public class ItemviewActivity extends SherlockActivity {
|
|||||||
butPlay = (Button) findViewById(R.id.butPlay);
|
butPlay = (Button) findViewById(R.id.butPlay);
|
||||||
butDownload = (Button) findViewById(R.id.butDownload);
|
butDownload = (Button) findViewById(R.id.butDownload);
|
||||||
butRemove = (Button) findViewById(R.id.butRemove);
|
butRemove = (Button) findViewById(R.id.butRemove);
|
||||||
|
webvDescription = (WebView) findViewById(R.id.webvDescription);
|
||||||
setTitle(item.getFeed().getTitle());
|
setTitle(item.getFeed().getTitle());
|
||||||
|
|
||||||
txtvPublished.setText(DateUtils.formatSameDayTime(item.getPubDate()
|
txtvPublished.setText(DateUtils.formatSameDayTime(item.getPubDate()
|
||||||
@ -128,6 +130,7 @@ public class ItemviewActivity extends SherlockActivity {
|
|||||||
imgvImage
|
imgvImage
|
||||||
.setImageBitmap(item.getFeed().getImage().getImageBitmap());
|
.setImageBitmap(item.getFeed().getImage().getImageBitmap());
|
||||||
}
|
}
|
||||||
|
webvDescription.loadData(item.getDescription(), "text/html", null);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void getDownloadStatus() {
|
private void getDownloadStatus() {
|
||||||
|
@ -81,7 +81,7 @@ public class NSRSS20 extends Namespace {
|
|||||||
if (second.equals(CHANNEL)) {
|
if (second.equals(CHANNEL)) {
|
||||||
state.getFeed().setDescription(content);
|
state.getFeed().setDescription(content);
|
||||||
} else if (second.equals(ITEM)) {
|
} else if (second.equals(ITEM)) {
|
||||||
state.getFeed().setDescription(content);
|
state.getCurrentItem().setDescription(content);
|
||||||
}
|
}
|
||||||
} else if (top.equals(LINK)) {
|
} else if (top.equals(LINK)) {
|
||||||
if (second.equals(CHANNEL)) {
|
if (second.equals(CHANNEL)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user