Permalink
Browse files

Added the first of the fragment demos.

  • Loading branch information...
1 parent b072305 commit 32d57e0e6a8b3f88740560bd5bcf31abcab99d61 @kevinmcdonagh kevinmcdonagh committed Feb 18, 2012
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<manifest
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ package="novoda.demo.fragments.list"
+ android:versionCode="55"
+ android:versionName="3.5.1">
+
+ <uses-sdk
+ android:minSdkVersion="4"
+ android:targetSdkVersion="13"/>
+
+ <application
+ android:icon="@drawable/ic_launcher"
+ android:label="@string/application_label"
+ android:theme="@android:style/Theme.NoTitleBar">
+
+ <activity
+ android:name=".activities.List"
+ android:label="@string/application_label">
+
+ <intent-filter>
+ <action android:name="android.intent.action.MAIN" />
+ <category android:name="android.intent.category.LAUNCHER" />
+ </intent-filter>
+ </activity>
+
+ <activity android:name=".activities.Details" />
+
+ </application>
+</manifest>
View
@@ -0,0 +1,13 @@
+ActionBarSherlock Sample: Shakespeare
+=====================================
+
+See [actionbarsherlock.com/samples.html][1] for information on the sample
+contained in this folder.
+
+
+
+
+
+
+
+ [1]: http://actionbarsherlock.com/samples.html
Binary file not shown.
View
@@ -0,0 +1,103 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+
+ <groupId>com.actionbarsherlock</groupId>
+ <artifactId>sample-shakespeare</artifactId>
+ <name>Sample: Shakespeare</name>
+ <packaging>apk</packaging>
+
+ <parent>
+ <groupId>com.actionbarsherlock</groupId>
+ <artifactId>parent-sample</artifactId>
+ <version>3.5.1</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>android</groupId>
+ <artifactId>android</artifactId>
+ <scope>provided</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>com.actionbarsherlock</groupId>
+ <artifactId>library</artifactId>
+ <version>${project.version}</version>
+ <type>apklib</type>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <sourceDirectory>src</sourceDirectory>
+ <finalName>${apk.prefix}-${project.artifactId}-unaligned</finalName>
+
+ <plugins>
+ <plugin>
+ <groupId>com.jayway.maven.plugins.android.generation2</groupId>
+ <artifactId>maven-android-plugin</artifactId>
+ <extensions>true</extensions>
+ </plugin>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <configuration>
+ <skip>true</skip>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <profiles>
+ <profile>
+ <id>release</id>
+ <activation>
+ <property>
+ <name>performRelease</name>
+ <value>true</value>
+ </property>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>com.jayway.maven.plugins.android.generation2</groupId>
+ <artifactId>maven-android-plugin</artifactId>
+ <inherited>true</inherited>
+ <configuration>
+ <zipalign>
+ <inputApk>${project.build.directory}/${project.build.finalName}.apk</inputApk>
+ <outputApk>${project.build.directory}/${apk.prefix}-${project.artifactId}.apk</outputApk>
+ </zipalign>
+ </configuration>
+ <executions>
+ <execution>
+ <id>alignApk</id>
+ <phase>package</phase>
+ <goals>
+ <goal>zipalign</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+
+ <plugin>
+ <groupId>com.jakewharton</groupId>
+ <artifactId>github-deploy-maven-plugin</artifactId>
+ <version>1.0.1</version>
+ <configuration>
+ <types>
+ <type>aligned</type>
+ </types>
+ </configuration>
+ <goals>
+ <goal>deploy</goal>
+ </goals>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+</project>
@@ -0,0 +1,12 @@
+# This file is automatically generated by Android Tools.
+# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
+#
+# This file must be checked in Version Control Systems.
+#
+# To customize properties used by the Ant build system use,
+# "ant.properties", and override values to adapt the script to your
+# project structure.
+
+# Project target.
+target=android-14
+android.library.reference.1=../../library
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2010 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.
+-->
+
+<!-- Top-level content view for the layout fragment sample. This version is
+ for display when in landscape: we can fit both titles and dialog. -->
+
+
+<LinearLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:orientation="horizontal"
+ android:layout_width="fill_parent"
+ android:layout_height="fill_parent">
+
+ <fragment
+ class="novoda.demo.fragments.list.frags.List"
+ android:id="@+id/fragment_titles"
+ android:layout_weight="2"
+ android:layout_width="0px"
+ android:layout_height="fill_parent" />
+
+ <FrameLayout
+ android:id="@+id/frame_details"
+ android:layout_weight="3"
+ android:layout_width="0px"
+ android:layout_height="fill_parent" />
+
+</LinearLayout>
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2010 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.
+-->
+
+<!-- Top-level content view for the layout fragment sample. This version is
+ for display when in landscape: we can fit both titles and dialog. -->
+
+
+<LinearLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:orientation="horizontal"
+ android:layout_width="fill_parent"
+ android:layout_height="fill_parent">
+
+ <fragment
+ class="novoda.demo.fragments.list.frags.List"
+ android:id="@+id/fragment_titles"
+ android:layout_weight="1"
+ android:layout_width="0px"
+ android:layout_height="fill_parent" />
+
+ <FrameLayout
+ android:id="@+id/frame_details"
+ android:layout_weight="3"
+ android:layout_width="0px"
+ android:layout_height="fill_parent" />
+
+</LinearLayout>
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2010 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.
+-->
+
+<!-- Top-level content view for the layout fragment sample. This version is
+ for display when not in landscape: we can only fit the list of titles. -->
+
+
+<FrameLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="fill_parent"
+ android:layout_height="fill_parent">
+
+ <fragment
+ class="novoda.demo.fragments.list.frags.List"
+ android:id="@+id/fragment_titles"
+ android:layout_width="fill_parent"
+ android:layout_height="fill_parent" />
+
+</FrameLayout>
+
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+ <string name="application_label">Demo: Frags List</string>
+</resources>
@@ -0,0 +1,66 @@
+package novoda.demo.fragments.list;
+
+public final class Constants {
+ public static final String[] ITEMS =
+ {
+ "Item 1",
+ "Item 2",
+ "Item 3",
+ "Item 4",
+ };
+
+ public static final String[] DETAILS =
+ {
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1," +
+ "Item 1, Item 1, Item 1, Item 1, Item 1, Item 1,",
+
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2," +
+ "Item 2, Item 2, Item 2, Item 2, Item 2, Item 2,",
+
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3," +
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3," +
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3," +
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3," +
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3," +
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3," +
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3," +
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3," +
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3," +
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3," +
+ "Item 3, Item 3, Item 3, Item 3, Item 3, Item 3,",
+
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4," +
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4," +
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4," +
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4," +
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4," +
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4," +
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4," +
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4," +
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4," +
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4," +
+ "Item 4, Item 4, Item 4, Item 4, Item 4, Item 4,"
+ };
+}
Oops, something went wrong.

0 comments on commit 32d57e0

Please sign in to comment.