Fresh new change for:
  Add Live Folder support to NotePad sample, and add new icons for the app and Live Folder (separate for Donut and Eclair).

Previous change 33290 was screwed up.

Xav, please pardon a repo newbie!
diff --git a/samples/NotePad/AndroidManifest.xml b/samples/NotePad/AndroidManifest.xml
index 5c56daf..04f4dbe 100644
--- a/samples/NotePad/AndroidManifest.xml
+++ b/samples/NotePad/AndroidManifest.xml
@@ -4,9 +4,9 @@
      Licensed under the Apache License, Version 2.0 (the "License");
      you may not use this file except in compliance with the License.
      You may obtain a copy of the License at
-  
+
           http://www.apache.org/licenses/LICENSE-2.0
-  
+
      Unless required by applicable law or agreed to in writing, software
      distributed under the License is distributed on an "AS IS" BASIS,
      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -47,7 +47,7 @@
                 <data android:mimeType="vnd.android.cursor.item/vnd.google.note" />
             </intent-filter>
         </activity>
-        
+
         <activity android:name="NoteEditor"
             android:theme="@android:style/Theme.Light"
             android:label="@string/title_note"
@@ -73,10 +73,11 @@
             </intent-filter>
 
         </activity>
-        
-		<activity android:name="TitleEditor" android:label="@string/title_edit_title"
-				android:theme="@android:style/Theme.Dialog"
-                android:windowSoftInputMode="stateVisible">
+
+        <activity android:name="TitleEditor"
+            android:label="@string/title_edit_title"
+            android:theme="@android:style/Theme.Dialog"
+            android:windowSoftInputMode="stateVisible">
             <!-- This activity implements an alternative action that can be
                  performed on notes: editing their title.  It can be used as
                  a default operation if the user invokes this action, and is
@@ -98,7 +99,17 @@
                 <data android:mimeType="vnd.android.cursor.item/vnd.google.note" />
             </intent-filter>
         </activity>
-        
+
+        <activity android:name="NotesLiveFolder" android:label="@string/live_folder_name"
+            android:icon="@drawable/live_folder_notes">
+            <intent-filter>
+                <action android:name="android.intent.action.CREATE_LIVE_FOLDER" />
+                <category android:name="android.intent.category.DEFAULT" />
+            </intent-filter>
+        </activity>
+
     </application>
+
+    <uses-sdk android:targetSdkVersion="4" android:minSdkVersion="3"/>
 </manifest>
 
diff --git a/samples/NotePad/_index.html b/samples/NotePad/_index.html
index 093022b..8f680ef 100644
--- a/samples/NotePad/_index.html
+++ b/samples/NotePad/_index.html
@@ -5,6 +5,7 @@
 <li>Accessing a database</li>
 <li>Using an intent to open a new window</li>
 <li>Managing activity lifecycle</li>
+<li>Creating <a href="../../../reference/android/provider/LiveFolders.html">Live Folders</a></li>
 <li>And more...</li>
 </ul>
 
diff --git a/samples/NotePad/res/drawable-hdpi-v6/app_notes.png b/samples/NotePad/res/drawable-hdpi-v6/app_notes.png
new file mode 100644
index 0000000..3491823
--- /dev/null
+++ b/samples/NotePad/res/drawable-hdpi-v6/app_notes.png
Binary files differ
diff --git a/samples/NotePad/res/drawable-hdpi-v6/live_folder_notes.png b/samples/NotePad/res/drawable-hdpi-v6/live_folder_notes.png
new file mode 100644
index 0000000..c6d26f5
--- /dev/null
+++ b/samples/NotePad/res/drawable-hdpi-v6/live_folder_notes.png
Binary files differ
diff --git a/samples/NotePad/res/drawable-ldpi-v6/app_notes.png b/samples/NotePad/res/drawable-ldpi-v6/app_notes.png
new file mode 100644
index 0000000..8432ce6
--- /dev/null
+++ b/samples/NotePad/res/drawable-ldpi-v6/app_notes.png
Binary files differ
diff --git a/samples/NotePad/res/drawable-ldpi-v6/live_folder_notes.png b/samples/NotePad/res/drawable-ldpi-v6/live_folder_notes.png
new file mode 100644
index 0000000..d547cbf
--- /dev/null
+++ b/samples/NotePad/res/drawable-ldpi-v6/live_folder_notes.png
Binary files differ
diff --git a/samples/NotePad/res/drawable-mdpi-v6/app_notes.png b/samples/NotePad/res/drawable-mdpi-v6/app_notes.png
new file mode 100644
index 0000000..81d1c22
--- /dev/null
+++ b/samples/NotePad/res/drawable-mdpi-v6/app_notes.png
Binary files differ
diff --git a/samples/NotePad/res/drawable-mdpi-v6/live_folder_notes.png b/samples/NotePad/res/drawable-mdpi-v6/live_folder_notes.png
new file mode 100644
index 0000000..c565cd0
--- /dev/null
+++ b/samples/NotePad/res/drawable-mdpi-v6/live_folder_notes.png
Binary files differ
diff --git a/samples/NotePad/res/drawable-mdpi/live_folder_notes.png b/samples/NotePad/res/drawable-mdpi/live_folder_notes.png
new file mode 100644
index 0000000..ac54a49
--- /dev/null
+++ b/samples/NotePad/res/drawable-mdpi/live_folder_notes.png
Binary files differ
diff --git a/samples/NotePad/res/values/strings.xml b/samples/NotePad/res/values/strings.xml
index b4bf671..168db92 100644
--- a/samples/NotePad/res/values/strings.xml
+++ b/samples/NotePad/res/values/strings.xml
@@ -30,6 +30,7 @@
 	<string name="title_edit_title">Note title:</string>  
 	
 	<string name="app_name">Note Pad</string>  
+	<string name="live_folder_name">Notes</string>
 	
 	<string name="button_ok">OK</string>  
 	
diff --git a/samples/NotePad/src/com/example/android/notepad/NotePadProvider.java b/samples/NotePad/src/com/example/android/notepad/NotePadProvider.java
index f1d3fdc..58cdc8f 100644
--- a/samples/NotePad/src/com/example/android/notepad/NotePadProvider.java
+++ b/samples/NotePad/src/com/example/android/notepad/NotePadProvider.java
@@ -30,6 +30,7 @@
 import android.database.sqlite.SQLiteOpenHelper;
 import android.database.sqlite.SQLiteQueryBuilder;
 import android.net.Uri;
+import android.provider.LiveFolders;
 import android.text.TextUtils;
 import android.util.Log;
 
@@ -48,9 +49,11 @@
     private static final String NOTES_TABLE_NAME = "notes";
 
     private static HashMap<String, String> sNotesProjectionMap;
+    private static HashMap<String, String> sLiveFolderProjectionMap;
 
     private static final int NOTES = 1;
     private static final int NOTE_ID = 2;
+    private static final int LIVE_FOLDER_NOTES = 3;
 
     private static final UriMatcher sUriMatcher;
 
@@ -95,19 +98,22 @@
     public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs,
             String sortOrder) {
         SQLiteQueryBuilder qb = new SQLiteQueryBuilder();
+        qb.setTables(NOTES_TABLE_NAME);
 
         switch (sUriMatcher.match(uri)) {
         case NOTES:
-            qb.setTables(NOTES_TABLE_NAME);
             qb.setProjectionMap(sNotesProjectionMap);
             break;
 
         case NOTE_ID:
-            qb.setTables(NOTES_TABLE_NAME);
             qb.setProjectionMap(sNotesProjectionMap);
             qb.appendWhere(Notes._ID + "=" + uri.getPathSegments().get(1));
             break;
 
+        case LIVE_FOLDER_NOTES:
+            qb.setProjectionMap(sLiveFolderProjectionMap);
+            break;
+
         default:
             throw new IllegalArgumentException("Unknown URI " + uri);
         }
@@ -133,6 +139,7 @@
     public String getType(Uri uri) {
         switch (sUriMatcher.match(uri)) {
         case NOTES:
+        case LIVE_FOLDER_NOTES:
             return Notes.CONTENT_TYPE;
 
         case NOTE_ID:
@@ -238,6 +245,7 @@
         sUriMatcher = new UriMatcher(UriMatcher.NO_MATCH);
         sUriMatcher.addURI(NotePad.AUTHORITY, "notes", NOTES);
         sUriMatcher.addURI(NotePad.AUTHORITY, "notes/#", NOTE_ID);
+        sUriMatcher.addURI(NotePad.AUTHORITY, "live_folders/notes", LIVE_FOLDER_NOTES);
 
         sNotesProjectionMap = new HashMap<String, String>();
         sNotesProjectionMap.put(Notes._ID, Notes._ID);
@@ -245,5 +253,13 @@
         sNotesProjectionMap.put(Notes.NOTE, Notes.NOTE);
         sNotesProjectionMap.put(Notes.CREATED_DATE, Notes.CREATED_DATE);
         sNotesProjectionMap.put(Notes.MODIFIED_DATE, Notes.MODIFIED_DATE);
+
+        // Support for Live Folders.
+        sLiveFolderProjectionMap = new HashMap<String, String>();
+        sLiveFolderProjectionMap.put(LiveFolders._ID, Notes._ID + " AS " +
+                LiveFolders._ID);
+        sLiveFolderProjectionMap.put(LiveFolders.NAME, Notes.TITLE + " AS " +
+                LiveFolders.NAME);
+        // Add more columns here for more robust Live Folders.
     }
 }
diff --git a/samples/NotePad/src/com/example/android/notepad/NotesLiveFolder.java b/samples/NotePad/src/com/example/android/notepad/NotesLiveFolder.java
new file mode 100644
index 0000000..00eb314
--- /dev/null
+++ b/samples/NotePad/src/com/example/android/notepad/NotesLiveFolder.java
@@ -0,0 +1,65 @@
+/*
+ * Copyright (C) 2009 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.example.android.notepad;
+
+import android.app.Activity;
+import android.content.Intent;
+import android.net.Uri;
+import android.os.Bundle;
+import android.provider.LiveFolders;
+
+public class NotesLiveFolder extends Activity {
+    /**
+     * The URI for the Notes Live Folder content provider.
+     */
+    public static final Uri CONTENT_URI = Uri.parse("content://"
+            + NotePad.AUTHORITY + "/live_folders/notes");
+
+    public static final Uri NOTE_URI = Uri.parse("content://"
+            + NotePad.AUTHORITY + "/notes/#");
+
+    @Override
+    protected void onCreate(Bundle savedInstanceState) {
+        super.onCreate(savedInstanceState);
+
+        final Intent intent = getIntent();
+        final String action = intent.getAction();
+
+        if (LiveFolders.ACTION_CREATE_LIVE_FOLDER.equals(action)) {
+            // Build the live folder intent.
+            final Intent liveFolderIntent = new Intent();
+
+            liveFolderIntent.setData(CONTENT_URI);
+            liveFolderIntent.putExtra(LiveFolders.EXTRA_LIVE_FOLDER_NAME,
+                    getString(R.string.live_folder_name));
+            liveFolderIntent.putExtra(LiveFolders.EXTRA_LIVE_FOLDER_ICON,
+                    Intent.ShortcutIconResource.fromContext(this,
+                            R.drawable.live_folder_notes));
+            liveFolderIntent.putExtra(LiveFolders.EXTRA_LIVE_FOLDER_DISPLAY_MODE,
+                    LiveFolders.DISPLAY_MODE_LIST);
+            liveFolderIntent.putExtra(LiveFolders.EXTRA_LIVE_FOLDER_BASE_INTENT,
+                    new Intent(Intent.ACTION_EDIT, NOTE_URI));
+
+            // The result of this activity should be a live folder intent.
+            setResult(RESULT_OK, liveFolderIntent);
+        } else {
+            setResult(RESULT_CANCELED);
+        }
+
+        finish();
+    }
+}