-
-
Notifications
You must be signed in to change notification settings - Fork 1
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 #15 from elimu-ai/14-Rename-from-org.literacyapp-t…
…o-elimu.ai 14 rename from org.literacyapp to elimu.ai
- Loading branch information
Showing
13 changed files
with
125 additions
and
161 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,3 +16,4 @@ android: | |
|
||
notifications: | ||
email: false | ||
slack: elimu-ai:5hNcmHPFkAETjJZjrkBlNTxr |
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
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,29 @@ | ||
package ai.elimu.storybooks; | ||
|
||
import android.content.Intent; | ||
import android.os.Bundle; | ||
import android.support.v7.app.AppCompatActivity; | ||
import android.util.Log; | ||
|
||
public class MainActivity extends AppCompatActivity { | ||
|
||
private static final int PERMISSION_REQUEST_READ_EXTERNAL_STORAGE = 0; | ||
|
||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
Log.i(getClass().getName(), "onCreate"); | ||
super.onCreate(savedInstanceState); | ||
setContentView(R.layout.activity_main); | ||
} | ||
|
||
@Override | ||
protected void onStart() { | ||
Log.i(getClass().getName(), "onStart"); | ||
super.onStart(); | ||
|
||
Intent intent = new Intent(this, StoryBooksActivity.class); | ||
startActivity(intent); | ||
|
||
finish(); | ||
} | ||
} |
79 changes: 79 additions & 0 deletions
79
app/src/main/java/ai/elimu/storybooks/StoryBooksActivity.java
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,79 @@ | ||
package ai.elimu.storybooks; | ||
|
||
import android.content.Intent; | ||
import android.graphics.Bitmap; | ||
import android.graphics.BitmapFactory; | ||
import android.os.Bundle; | ||
import android.support.v7.app.AppCompatActivity; | ||
import android.support.v7.widget.GridLayout; | ||
import android.util.Log; | ||
import android.view.LayoutInflater; | ||
import android.view.View; | ||
import android.widget.ImageView; | ||
import android.widget.TextView; | ||
|
||
//import ai.elimu.analytics.eventtracker.EventTracker; | ||
//import ai.elimu.contentprovider.ContentProvider; | ||
//import ai.elimu.contentprovider.model.content.StoryBook; | ||
//import ai.elimu.contentprovider.util.MultimediaHelper; | ||
//import ai.elimu.model.enums.GradeLevel; | ||
|
||
import java.io.File; | ||
import java.util.List; | ||
|
||
public class StoryBooksActivity extends AppCompatActivity { | ||
|
||
private GridLayout storyBooksGridLayout; | ||
|
||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
Log.i(getClass().getName(), "onCreate"); | ||
super.onCreate(savedInstanceState); | ||
setContentView(R.layout.activity_storybooks); | ||
|
||
storyBooksGridLayout = (GridLayout) findViewById(R.id.storyBookGridLayout); | ||
|
||
// List<StoryBook> storyBooks = ContentProvider.getAllStoryBooks(GradeLevel.LEVEL1); | ||
// Log.i(getClass().getName(), "storyBooks.size(): " + storyBooks.size()); | ||
// | ||
// for (final StoryBook storyBook : storyBooks) { | ||
// View storyBookView = LayoutInflater.from(this).inflate(R.layout.activity_storybooks_cover_view, storyBooksGridLayout, false); | ||
// | ||
// File storyBookCoverFile = MultimediaHelper.getFile(storyBook.getCoverImage()); | ||
// Log.i(getClass().getName(), "storyBookCoverFile: " + storyBookCoverFile); | ||
// if (storyBookCoverFile.exists()) { | ||
// ImageView storyBookImageView = (ImageView) storyBookView.findViewById(R.id.storyBookCoverImageView); | ||
// Bitmap bitmap = BitmapFactory.decodeFile(storyBookCoverFile.getAbsolutePath()); | ||
// storyBookImageView.setImageBitmap(bitmap); | ||
// } | ||
// | ||
// TextView storyBookCoverTitleTextView = (TextView) storyBookView.findViewById(R.id.storyBookCoverTitleTextView); | ||
// storyBookCoverTitleTextView.setText(storyBook.getTitle()); | ||
// | ||
// storyBookView.setOnClickListener(new View.OnClickListener() { | ||
// @Override | ||
// public void onClick(View v) { | ||
// Log.i(getClass().getName(), "onClick"); | ||
// | ||
// Log.i(getClass().getName(), "storyBook.getId(): " + storyBook.getId()); | ||
// Log.i(getClass().getName(), "storyBook.getTitle(): " + storyBook.getTitle()); | ||
// | ||
// EventTracker.reportStoryBookLearningEvent(getApplicationContext(), storyBook.getId()); | ||
// | ||
//// Intent intent = new Intent(getApplicationContext(), StoryBookActivity.class); | ||
// Intent intent = new Intent(getApplicationContext(), TabbedActivity.class); | ||
// intent.putExtra(TabbedActivity.EXTRA_KEY_STORYBOOK_ID, storyBook.getId()); | ||
// startActivity(intent); | ||
// } | ||
// }); | ||
// | ||
// storyBooksGridLayout.addView(storyBookView); | ||
// } | ||
} | ||
|
||
@Override | ||
protected void onStart() { | ||
Log.i(getClass().getName(), "onStart"); | ||
super.onStart(); | ||
} | ||
} |
2 changes: 1 addition & 1 deletion
2
...iteracyapp/storybooks/TabbedActivity.java → ...a/ai/elimu/storybooks/TabbedActivity.java
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
62 changes: 0 additions & 62 deletions
62
app/src/main/java/org/literacyapp/storybooks/MainActivity.java
This file was deleted.
Oops, something went wrong.
79 changes: 0 additions & 79 deletions
79
app/src/main/java/org/literacyapp/storybooks/StoryBooksActivity.java
This file was deleted.
Oops, something went wrong.
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
2 changes: 1 addition & 1 deletion
2
...teracyapp/storybooks/ExampleUnitTest.java → .../ai/elimu/storybooks/ExampleUnitTest.java
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,4 +1,4 @@ | ||
package org.literacyapp.storybooks; | ||
package ai.elimu.storybooks; | ||
|
||
import org.junit.Test; | ||
|
||
|