forked from douglascraigschmidt/POSA-15
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from douglascraigschmidt/master
Update from original
- Loading branch information
Showing
49 changed files
with
1,904 additions
and
1,586 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,62 +1,55 @@ | ||
<html> | ||
|
||
<title>Downloaded Image Viewer (P1 - Assignment 1)</title> | ||
<title>Downloaded Image Viewer (P2 - Assignment 1)</title> | ||
|
||
<body text = "#000000" | ||
link="#000fff" | ||
vlink="#ff0f0f" | ||
bgcolor="#ffffff"> | ||
|
||
<hr> | ||
<h3>Downloaded Image Viewer (P1 - Assignment 1)</h3> | ||
<h3>Downloaded Image Viewer (P2 - Assignment 1)</h3> | ||
|
||
<hr width=50% align=left> | ||
<h4>Overview of the Downloaded Image Viewer Assignment</h4> | ||
|
||
<p> | ||
|
||
The purpose of this assignment is to give you experience using | ||
Android to develop an app that contains a MainActivity that | ||
prompts the user for a URL to an image and then uses Intents and | ||
the DownloadImageActivity to download the image and view it via | ||
the Gallery app. The DownloadImageActivity should use the Android | ||
"HaMeR" concurrency framework, which is covered in <A | ||
HREF="https://www.youtube.com/watch?v=6cV54pxU6bc&list=PLZ9NgFYEMxp4tbiFYip6tDNIEBRUDyPQK&index=28">this | ||
video</a>. <P> | ||
|
||
<p> In addition to the lectures on Android we'll present in | ||
class during Weeks 1 and 2, the following resources may be helpful | ||
in completing portions of this assignment: </p> | ||
|
||
<ul> | ||
<li> <A HREF="https://www.youtube.com/watch?v=GtqZrzBuers&list=PLZ9NgFYEMxp4tbiFYip6tDNIEBRUDyPQK&index=7">Introduction to Android Concurrency</A> | ||
<li> <A HREF="https://www.youtube.com/watch?v=x8TTL_u0dNU&list=PLZ9NgFYEMxp4tbiFYip6tDNIEBRUDyPQK&index=9">Motivations for Concurrency</A> | ||
</ul> | ||
Android Services by developing an app containing a main Activity | ||
that prompts the user for URLs of images to download concurrently | ||
via the DownloadImageService and then view via the | ||
DisPlayImagesActivity. The DownloadImageService should use the | ||
Android <A | ||
HREF="http://developer.android.com/reference/android/app/IntentService.html">IntentService</a> | ||
framework, which is covered in <A | ||
HREF="https://www.youtube.com/watch?v=N9tx9sRmn48&list=PLZ9NgFYEMxp4tbiFYip6tDNIEBRUDyPQK&index=39">this | ||
video</a>. Material presented in lectures during Week 1 and 2 of | ||
this class are also relevant to this assignment. </p> | ||
|
||
<hr width=50% align=left> | ||
<h4>Skeleton Code</h4> | ||
|
||
<p> Skeleton code for this assignment is available <a | ||
href="https://github.com/douglascraigschmidt/POSA-15/tree/master/assignments/assignment1">here</a>. | ||
href="https://github.com/douglascraigschmidt/POSA-15/tree/master/assignments/assignment1"">here</a>. | ||
Pull the appropriate skeleton code in your repository, read it | ||
carefully, and complete the "TODO" markers. </p> | ||
|
||
<p> Note that there are no automated unit tests for this | ||
assignment. Instead, you'll know the program is working when you can | ||
successfully download and view an image. Make sure that your | ||
program works properly for both valid and invalid URLs entered by | ||
the user. | ||
successfully download and view an image. However, make sure your | ||
program works for both valid and invalid URL input. | ||
|
||
</p> | ||
|
||
<hr width=50% align=left> | ||
<h4>Concluding Remarks</h4> | ||
<p> | ||
|
||
This assignment is designed to help you get familiar with concurrent | ||
programming Android in Java. Make sure you start early and come to | ||
Virtual Office Hours if you have questions or run into problems. | ||
</p> | ||
This assignment is designed to further your understanding with | ||
programming Android Started Services and the IntentService framework | ||
in Java. Start early and come to Virtual Office Hours if you have | ||
questions or run into problems. </p> | ||
|
||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
K 25 | ||
svn:wc:ra_dav:version-url | ||
V 104 | ||
/aporter/AndroidShortCourse/svn/!svn/ver/46/SourceCodeExamples/MapLocationFromContacts/res/drawable-hdpi | ||
END |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
9 | ||
|
||
dir | ||
133 | ||
https://free1.projectlocker.com/aporter/AndroidShortCourse/svn/SourceCodeExamples/MapLocationFromContacts/res/drawable-hdpi | ||
https://free1.projectlocker.com/aporter/AndroidShortCourse/svn | ||
|
||
|
||
|
||
2011-05-26T22:47:42.839519Z | ||
46 | ||
[email protected] | ||
|
||
|
||
svn:special svn:externals svn:needs-lock | ||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
e45d3413-d4ad-49ab-8bcb-92a513df27ac | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
9 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
K 25 | ||
svn:wc:ra_dav:version-url | ||
V 104 | ||
/aporter/AndroidShortCourse/svn/!svn/ver/46/SourceCodeExamples/MapLocationFromContacts/res/drawable-ldpi | ||
END |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
9 | ||
|
||
dir | ||
133 | ||
https://free1.projectlocker.com/aporter/AndroidShortCourse/svn/SourceCodeExamples/MapLocationFromContacts/res/drawable-ldpi | ||
https://free1.projectlocker.com/aporter/AndroidShortCourse/svn | ||
|
||
|
||
|
||
2011-05-26T22:47:42.839519Z | ||
46 | ||
[email protected] | ||
|
||
|
||
svn:special svn:externals svn:needs-lock | ||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
e45d3413-d4ad-49ab-8bcb-92a513df27ac | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
9 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
K 25 | ||
svn:wc:ra_dav:version-url | ||
V 104 | ||
/aporter/AndroidShortCourse/svn/!svn/ver/46/SourceCodeExamples/MapLocationFromContacts/res/drawable-mdpi | ||
END |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
9 | ||
|
||
dir | ||
133 | ||
https://free1.projectlocker.com/aporter/AndroidShortCourse/svn/SourceCodeExamples/MapLocationFromContacts/res/drawable-mdpi | ||
https://free1.projectlocker.com/aporter/AndroidShortCourse/svn | ||
|
||
|
||
|
||
2011-05-26T22:47:42.839519Z | ||
46 | ||
[email protected] | ||
|
||
|
||
svn:special svn:externals svn:needs-lock | ||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
e45d3413-d4ad-49ab-8bcb-92a513df27ac | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
9 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | ||
android:id="@+id/resultLayout" | ||
android:layout_width="match_parent" | ||
android:layout_height="match_parent" | ||
android:orientation="vertical" > | ||
|
||
<HorizontalScrollView | ||
android:id="@+id/scrollView" | ||
android:layout_width="wrap_content" | ||
android:layout_height="0dp" | ||
android:layout_weight="1" > | ||
|
||
<LinearLayout | ||
android:id="@+id/buttonList" | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:orientation="horizontal" | ||
android:gravity="left" /> | ||
|
||
</HorizontalScrollView> | ||
|
||
<GridView | ||
android:id="@+id/imageGrid" | ||
android:layout_width="match_parent" | ||
android:layout_height="0dp" | ||
android:layout_weight="8" | ||
android:stretchMode="columnWidth" | ||
android:gravity="center" /> | ||
|
||
</LinearLayout> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,59 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | ||
android:orientation="vertical" | ||
android:layout_height="match_parent" | ||
android:layout_width="match_parent"> | ||
|
||
<TextView | ||
android:id="@+id/textView1" | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:layout_marginStart="14dp" | ||
android:text="@string/defaultURL" /> | ||
android:layout_width="match_parent" | ||
android:layout_height="match_parent" | ||
android:orientation="vertical" > | ||
|
||
<EditText | ||
android:id="@+id/url" | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:layout_marginTop="20dp" | ||
android:inputType="text|textMultiLine|textUri" | ||
android:ems="10" | ||
android:hint="@string/enter_url" | ||
android:ems="10" > | ||
android:inputType="text|textMultiLine|textUri" > | ||
</EditText> | ||
|
||
<Button | ||
android:id="@+id/button2" | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:onClick="addUrl" | ||
android:text="@string/add_url" /> | ||
|
||
<LinearLayout | ||
android:id="@+id/linearLayout" | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:layout_weight="0.84" | ||
android:orientation="vertical"> | ||
</LinearLayout> | ||
|
||
<ProgressBar | ||
android:id="@+id/progressBar_loading" | ||
style="@android:style/Widget.ProgressBar.Large" | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:layout_above="@+id/button1" | ||
android:visibility="invisible" | ||
android:layout_centerHorizontal="true" | ||
android:layout_centerVertical="true"/> | ||
|
||
<Button | ||
android:id="@+id/button1" | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:layout_alignLeft="@+id/url" | ||
android:layout_below="@+id/url" | ||
android:layout_marginTop="18dp" | ||
android:onClick="downloadImage" | ||
android:text="@string/download_image" /> | ||
android:onClick="downloadImages" | ||
android:text="@string/download_and_display_image" /> | ||
|
||
<Button | ||
android:id="@+id/button3" | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:onClick="deleteDownloadedImages" | ||
android:text="@string/clear_directory" /> | ||
|
||
</LinearLayout> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Button xmlns:android="http://schemas.android.com/apk/res/android" | ||
android:id="@+id/resultButton" | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
style="?android:attr/borderlessButtonStyle" > | ||
</Button> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
<resources> | ||
<string name="app_name">DownloadImageViewer</string> | ||
<string name="download_image_activity">DownLoadImageActivity</string> | ||
<string name="download_image">Download Image</string> | ||
<string name="defaultURL">http://www.dre.vanderbilt.edu/~schmidt/robot.png</string> | ||
<string name="download_and_display_image">Download and Display Image(s)</string> | ||
<string name="add_url">Add URL</string> | ||
<string name="enter_url">Enter URL</string> | ||
<string name="clear_directory">Delete Downloaded Image(s)</string> | ||
<string name="defaultURL">http://www.dre.vanderbilt.edu/~schmidt/robot.png;http://www.dre.vanderbilt.edu/~schmidt/ka.png</string> | ||
</resources> |
Oops, something went wrong.