diff options
Diffstat (limited to 'samples/NotePad')
| -rw-r--r-- | samples/NotePad/AndroidManifest.xml | 2 | ||||
| -rw-r--r-- | samples/NotePad/res/layout/note_editor.xml | 1 | ||||
| -rw-r--r-- | samples/NotePad/src/com/google/provider/NotePad.java | 65 | ||||
| -rw-r--r-- | samples/NotePad/tests/AndroidManifest.xml | 2 | ||||
| -rw-r--r-- | samples/NotePad/tests/src/com/example/android/notepad/NotePadTest.java (renamed from samples/NotePad/tests/src/com/android/notepad/NotePadTest.java) | 2 |
5 files changed, 70 insertions, 2 deletions
diff --git a/samples/NotePad/AndroidManifest.xml b/samples/NotePad/AndroidManifest.xml index 2dd675b51..84e87dd85 100644 --- a/samples/NotePad/AndroidManifest.xml +++ b/samples/NotePad/AndroidManifest.xml @@ -51,6 +51,8 @@ <activity android:name="NoteEditor" android:theme="@android:style/Theme.Light" android:label="@string/title_note" + android:screenOrientation="sensor" + android:configChanges="keyboardHidden|orientation" > <!-- This filter says that we can view or edit the data of a single note --> diff --git a/samples/NotePad/res/layout/note_editor.xml b/samples/NotePad/res/layout/note_editor.xml index dba55a1e9..c54a96308 100644 --- a/samples/NotePad/res/layout/note_editor.xml +++ b/samples/NotePad/res/layout/note_editor.xml @@ -24,5 +24,6 @@ android:scrollbars="vertical" android:fadingEdge="vertical" android:gravity="top" + android:textSize="22sp" android:capitalize="sentences" /> diff --git a/samples/NotePad/src/com/google/provider/NotePad.java b/samples/NotePad/src/com/google/provider/NotePad.java new file mode 100644 index 000000000..f8de69b6b --- /dev/null +++ b/samples/NotePad/src/com/google/provider/NotePad.java @@ -0,0 +1,65 @@ +/* + * Copyright (C) 2007 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.google.provider; + +import android.net.Uri; +import android.provider.BaseColumns; + +/** + * Convenience definitions for NotePadProvider + */ +public final class NotePad { + /** + * Notes table + */ + public static final class Notes implements BaseColumns { + /** + * The content:// style URL for this table + */ + public static final Uri CONTENT_URI + = Uri.parse("content://com.google.provider.NotePad/notes"); + + /** + * The default sort order for this table + */ + public static final String DEFAULT_SORT_ORDER = "modified DESC"; + + /** + * The title of the note + * <P>Type: TEXT</P> + */ + public static final String TITLE = "title"; + + /** + * The note itself + * <P>Type: TEXT</P> + */ + public static final String NOTE = "note"; + + /** + * The timestamp for when the note was created + * <P>Type: INTEGER (long)</P> + */ + public static final String CREATED_DATE = "created"; + + /** + * The timestamp for when the note was last modified + * <P>Type: INTEGER (long)</P> + */ + public static final String MODIFIED_DATE = "modified"; + } +} diff --git a/samples/NotePad/tests/AndroidManifest.xml b/samples/NotePad/tests/AndroidManifest.xml index fc6c1cd7c..afd502b5a 100644 --- a/samples/NotePad/tests/AndroidManifest.xml +++ b/samples/NotePad/tests/AndroidManifest.xml @@ -15,7 +15,7 @@ --> <manifest xmlns:android="http://schemas.android.com/apk/res/android" - package="com.android.notepad.tests"> + package="com.example.android.notepad.tests"> <!-- We add an application tag here just so that we can indicate that this package needs to link against the android.test library, diff --git a/samples/NotePad/tests/src/com/android/notepad/NotePadTest.java b/samples/NotePad/tests/src/com/example/android/notepad/NotePadTest.java index 48fc26434..452c5991c 100644 --- a/samples/NotePad/tests/src/com/android/notepad/NotePadTest.java +++ b/samples/NotePad/tests/src/com/example/android/notepad/NotePadTest.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package com.android.notepad; +package com.example.android.notepad; import android.test.ActivityInstrumentationTestCase; |
