package com.icecondor.nest;

import android.app.ListActivity;
import android.database.sqlite.SQLiteDatabase;
import android.os.Bundle;
import android.widget.ListAdapter;
import android.widget.SimpleCursorAdapter;

public class GeoRssList extends ListActivity {
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
        
		GeoRssSqlite rssdb = new GeoRssSqlite(this, "georss", null, 1);
		SQLiteDatabase db = rssdb.getWritableDatabase();
        ListAdapter adapter = new SimpleCursorAdapter(
                this, // Context
                android.R.layout.two_line_list_item,  // Specify the row template to use (here, two columns bound to the two retrieved cursor rows)
                db.query("urls",null, null, null, null, null, null),  // Pass in the cursor to bind to.
                new String[] {GeoRssSqlite.NAME, GeoRssSqlite.URL}, // Array of cursor columns to bind to.
                new int[] {R.id.text1, R.id.text2});      // Parallel array of which template objects to bind to those columns.

        // Bind to our new adapter.
        setListAdapter(adapter);


	}
}

@@ -469,16 +469,99 @@
 base();%0A
+%09%09//db.execSQL(%22insert into urls values (null, 'service', 'https://service.com'%22);%0A
         
@@ -1026,16 +1026,24 @@
  int%5B%5D %7B
+android.
 R.id.tex
@@ -1046,16 +1046,24 @@
 .text1, 
+android.
 R.id.tex
@@ -1214,14 +1214,13 @@
 pter);%0A%0A
-%0A
 %09%7D%0A%7D%0A

use the pre-made list stylings