Skip to content

Commit

Permalink
Merge pull request #189 from jianzhaojohn/develop
Browse files Browse the repository at this point in the history
Official Release
  • Loading branch information
jianzhaojohn authored May 4, 2018
2 parents 44a7658 + 2678ae0 commit 5cf9e12
Show file tree
Hide file tree
Showing 90 changed files with 1,346 additions and 717 deletions.
4 changes: 2 additions & 2 deletions .idea/assetWizardSettings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file modified .idea/caches/build_file_checksums.ser
Binary file not shown.
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@
## Landing Page
https://habit-rabbit.000webhostapp.com/

## Beta Release
https://youtu.be/Xox4mv7I9XQ

## Official Release
https://youtu.be/j23T9routSI

## Project Description:

Expand Down Expand Up @@ -83,3 +82,6 @@ https://youtu.be/g607Lzud3Ss
## Alpha Release
https://youtu.be/jdsvigK7bPs

## Beta Release
https://youtu.be/Xox4mv7I9XQ

50 changes: 25 additions & 25 deletions app/.idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 6 additions & 6 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,17 @@ android {

dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'com.android.support:appcompat-v7:27.1.0'
implementation 'com.android.support:design:27.1.0'
implementation 'com.android.support:support-v4:27.1.0'
implementation 'com.android.support:recyclerview-v7:27.1.0'
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support:design:27.1.1'
implementation 'com.android.support:support-v4:27.1.1'
implementation 'com.android.support:recyclerview-v7:27.1.1'
implementation 'com.squareup:android-times-square:1.6.5@aar'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.1'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
implementation 'com.android.support.constraint:constraint-layout:1.0.2'
implementation 'com.android.support.constraint:constraint-layout:1.1.0'
implementation 'de.hdodenhof:circleimageview:2.2.0'
implementation 'com.android.volley:volley:1.1.0'
implementation 'com.android.support:cardview-v7:27.1.0'
implementation 'com.android.support:cardview-v7:27.1.1'
implementation 'com.google.code.gson:gson:2.8.2'
}
4 changes: 2 additions & 2 deletions app/local.properties
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@
# Location of the SDK. This is only used by Gradle.
# For customization when using a Version Control System, please read the
# header note.
#Mon Mar 12 08:20:23 EDT 2018
sdk.dir=C\:\\Users\\SunnyD\\AppData\\Local\\Android\\Sdk
#Mon Apr 30 11:43:07 EDT 2018
sdk.dir=C\:\\Users\\john\\AppData\\Local\\Android\\Sdk
23 changes: 19 additions & 4 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@
android:name="android.support.PARENT_ACTIVITY"
android:value="comjianzhaojohnhabit_rabbit.httpsgithub.habit_rabbit.MainActivity" />
</activity>
<activity android:name=".ProfileActivity"
<activity
android:name=".ProfileActivity"
android:label="@string/app_name"
android:parentActivityName=".MainActivity">
<meta-data
Expand All @@ -68,7 +69,9 @@
android:name="android.support.PARENT_ACTIVITY"
android:value="comjianzhaojohnhabit_rabbit.httpsgithub.habit_rabbit.MainActivity" />
</activity>
<activity android:name=".RegisterActivity" />
<activity
android:name=".RegisterActivity"
android:parentActivityName=".MainActivity" />
<activity
android:name=".SettingsActivity"
android:label="@string/title_activity_settings"
Expand All @@ -89,16 +92,28 @@
android:name=".DeadRabbitActivity"
android:configChanges="orientation|keyboardHidden|screenSize"
android:label="@string/app_name"
android:theme="@style/FullscreenTheme"
android:parentActivityName=".MainActivity"
android:theme="@style/FullscreenTheme">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="comjianzhaojohnhabit_rabbit.httpsgithub.habit_rabbit.MainActivity" />
</activity>


<activity
android:name=".AboutusActivity"
android:label="About Us"
android:parentActivityName=".MainActivity">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="comjianzhaojohnhabit_rabbit.httpsgithub.habit_rabbit.MainActivity" />
</activity>

<receiver
android:name=".HabitCheckReciever"
android:enabled="true"
android:exported="true" />

</application>

</manifest>
</manifest>
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
package comjianzhaojohnhabit_rabbit.httpsgithub.habit_rabbit;

import android.content.Intent;
import android.net.Uri;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;

import java.io.File;

public class AboutusActivity extends AppCompatActivity {

@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_aboutus2);
}
public void github(View view) {
Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("https://github.com/jianzhaojohn/Habit-Rabbit"));
startActivity(browserIntent);
}
@Override
public boolean onCreateOptionsMenu(Menu menu) {
// Inflate the menu; this adds items to the action bar if it is present.
getMenuInflater().inflate(R.menu.navigation_menu, menu);
return true;
}

/**
* This hook is called whenever an item in your options menu is selected.
*
* @param item-The menu item that was selected.
* @return boolean Return false to allow normal menu processing to proceed, true to consume it here.
*/
@Override
public boolean onOptionsItemSelected(MenuItem item) {

switch (item.getItemId()) {

case R.id.nav_Profile:
startActivity(new Intent(AboutusActivity.this, ProfileActivity.class));
break;
case R.id.nav_agenda:
startActivity(new Intent(AboutusActivity.this, CalendarActivity.class));
break;
case R.id.nav_habits:
startActivity(new Intent(AboutusActivity.this, HabitListActivity.class));
break;

case R.id.nav_logout:
try {
// getApplicationContext().deleteFile("autionloginfile");
File autologin = getApplicationContext().getFileStreamPath("autionloginfile");
autologin.delete();
// clear and delete data file, then logout
SharedPref.clearAll(AboutusActivity.this);
String fileName = SharedPref.FILE_NAME;
File file = new File(this.getFilesDir().getParent() + "/shared_prefs/" + fileName + ".xml");
file.delete();

Intent intent = new Intent(this, LoginActivity.class);
intent.setFlags(intent.FLAG_ACTIVITY_NEW_TASK | intent.FLAG_ACTIVITY_CLEAR_TOP | intent.FLAG_ACTIVITY_CLEAR_TASK);
startActivity(intent);
} catch (Exception e) {
}
break;

default:
}
return super.onOptionsItemSelected(item);
}

}

Loading

0 comments on commit 5cf9e12

Please sign in to comment.