Skip to content

Commit

Permalink
Created release v2.0
Browse files Browse the repository at this point in the history
general improvements
  • Loading branch information
mannprerak2 committed Jun 4, 2018
1 parent bdb853c commit 8b41a9f
Show file tree
Hide file tree
Showing 14 changed files with 44 additions and 34 deletions.
Binary file modified .idea/caches/build_file_checksums.ser
Binary file not shown.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ android {
applicationId "com.pkmnapps.activitydo"
minSdkVersion 19
targetSdkVersion 27
versionCode 1
versionName "1.0"
versionCode 2
versionName "2.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true

Expand Down
Binary file modified app/release/app-release.apk
Binary file not shown.
2 changes: 1 addition & 1 deletion app/release/output.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":1,"versionName":"1.0","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}]
[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":2,"versionName":"2.0","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}]
2 changes: 1 addition & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
<activity
android:name=".ActivityChoser"
android:label="@string/title_activity_choser"
android:theme="@style/AppTheme.NoActionBar"></activity>
android:theme="@style/AppTheme.NoActionBar"/>
</application>

</manifest>
9 changes: 5 additions & 4 deletions app/src/main/java/com/pkmnapps/activitydo/HomeFragment.java
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ public void onMoved(RecyclerView recyclerView, RecyclerView.ViewHolder viewHolde

@Override
public int getMovementFlags(RecyclerView recyclerView, RecyclerView.ViewHolder viewHolder) {
return makeFlag(ItemTouchHelper.ACTION_STATE_SWIPE,ItemTouchHelper.RIGHT);
return makeFlag(ItemTouchHelper.ACTION_STATE_SWIPE,ItemTouchHelper.LEFT);

}

Expand Down Expand Up @@ -296,7 +296,7 @@ public void onClick(DialogInterface dialog, int which) {
//add to database
dbHelper.updateActivity(activityData);
//update UI
activityAdapter.notifyDataSetChanged();
activityAdapter.notifyItemChanged(activityDataList.indexOf(activityData));
}
}
});
Expand All @@ -321,16 +321,17 @@ public void onClick(DialogInterface dialog, int which) {
//delete from database
new DBHelper(getContext()).deleteActivity(activityData.getId());
//delete from list
int x = activityDataList.indexOf(activityData);
activityDataList.remove(activityData);
activityAdapter.notifyDataSetChanged();
activityAdapter.notifyItemRemoved(x);
//also remove from pinned menu if it exists
updatePinnedMenu();
}
});
builder.setOnCancelListener(new DialogInterface.OnCancelListener() {
@Override
public void onCancel(DialogInterface dialog) {
activityAdapter.notifyDataSetChanged();
activityAdapter.notifyItemChanged(activityDataList.indexOf(activityData));
}
});
builder.show();
Expand Down
16 changes: 15 additions & 1 deletion app/src/main/java/com/pkmnapps/activitydo/MainActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,21 @@ public boolean onNavigationItemSelected(MenuItem item) {
fragmentTransaction.replace(R.id.fragment_parent_main,new TabFragment()).commit();
}
else if(id == R.id.nav_share){

try {
Intent i = new Intent(Intent.ACTION_SEND);
i.setType("text/plain");
i.putExtra(Intent.EXTRA_SUBJECT, "Activity Do");
String sAux = "\nTry this app 'Activity Do' to note down stuff, organise, plan stuff in your life as Activities\n\n";
sAux = sAux + "https://play.google.com/store/apps/details?id=com.pkmnapps.activitydo\n\n";
i.putExtra(Intent.EXTRA_TEXT, sAux);
startActivity(Intent.createChooser(i, "choose one"));
} catch(Exception ignored) {
}
}
else if(id==R.id.nav_rate){
Intent intent = new Intent(Intent.ACTION_VIEW);
intent.setData(Uri.parse("market://details?id=com.pkmnapps.activitydo"));
startActivity(intent);
}

DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer_layout);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -600,8 +600,9 @@ public void deleteWidget(final Widget widget){
@Override
public void onClick(DialogInterface dialog, int which) {
//delete from list
int x = widgets.indexOf(widget);
widgets.remove(widget);
activityContentAdapter.notifyDataSetChanged();
activityContentAdapter.notifyItemRemoved(x);
dbHelperWidgets.updateAllWidgetSortOrders(widgets);
//delete rom database
switch (widget.getType()){
Expand All @@ -622,7 +623,7 @@ public void onClick(DialogInterface dialog, int which) {
builder.setOnCancelListener(new DialogInterface.OnCancelListener() {
@Override
public void onCancel(DialogInterface dialog) {
activityContentAdapter.notifyDataSetChanged();
activityContentAdapter.notifyItemChanged(widgets.indexOf(widget));
}
});
builder.show();
Expand Down
7 changes: 4 additions & 3 deletions app/src/main/java/com/pkmnapps/activitydo/TaskActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ private void setUpJumpControls(){
takeNote.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
createList();
createNote();
}
});
ImageButton more = (ImageButton)findViewById(R.id.more_button);
Expand Down Expand Up @@ -581,8 +581,9 @@ public void deleteWidget(final Widget widget){
@Override
public void onClick(DialogInterface dialog, int which) {
//delete from list
int x = widgets.indexOf(widget);
widgets.remove(widget);
activityContentAdapter.notifyDataSetChanged();
activityContentAdapter.notifyItemRemoved(x);
dbHelperWidgets.updateAllWidgetSortOrders(widgets);
//delete rom database
switch (widget.getType()){
Expand All @@ -603,7 +604,7 @@ public void onClick(DialogInterface dialog, int which) {
builder.setOnCancelListener(new DialogInterface.OnCancelListener() {
@Override
public void onCancel(DialogInterface dialog) {
activityContentAdapter.notifyDataSetChanged();
activityContentAdapter.notifyItemChanged(widgets.indexOf(widget));
}
});
builder.show();
Expand Down
1 change: 0 additions & 1 deletion app/src/main/res/layout/activity_image_view_fullscreen.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom|center_horizontal"
android:background="@color/black_overlay"
android:orientation="horizontal"
tools:ignore="UselessParent">

Expand Down
3 changes: 1 addition & 2 deletions app/src/main/res/layout/activity_task.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:background="?attr/colorPrimary"
app:popupTheme="@style/AppTheme.PopupOverlay"
app:layout_scrollFlags="scroll|enterAlwaysCollapsed" />
app:popupTheme="@style/AppTheme.PopupOverlay" />

</android.support.design.widget.AppBarLayout>

Expand Down
19 changes: 7 additions & 12 deletions app/src/main/res/layout/content_main.xml
Original file line number Diff line number Diff line change
@@ -1,17 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:orientation="vertical"

<FrameLayout android:id="@+id/fragment_parent_main"
app:layout_behavior="android.support.design.widget.AppBarLayout$ScrollingViewBehavior"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="android.support.design.widget.AppBarLayout$ScrollingViewBehavior"
tools:context=".MainActivity"
tools:showIn="@layout/app_bar_main">
<FrameLayout
android:id="@+id/fragment_parent_main"
android:layout_width="match_parent"
android:layout_height="match_parent"
>
tools:showIn="@layout/app_bar_main"
xmlns:tools="http://schemas.android.com/tools"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto">
</FrameLayout>
</LinearLayout>
2 changes: 1 addition & 1 deletion app/src/main/res/layout/fragment_home.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@
android:id="@+id/addNewButton"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#d7d7d7"
android:text="@string/add_new_activity"
android:textStyle="bold"
android:textColor="@color/colorAccent" />

</LinearLayout>
8 changes: 4 additions & 4 deletions app/src/main/res/menu/activity_main_drawer.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@
<menu>
<item
android:id="@+id/nav_share"
android:icon="@drawable/ic_menu_share"
android:icon="@drawable/ic_share_black_24dp"
android:title="Share" />
<item
android:id="@+id/nav_send"
android:icon="@drawable/ic_menu_send"
android:title="Send" />
android:id="@+id/nav_rate"
android:icon="@drawable/ic_star_black_24dp"
android:title="Rate" />
</menu>
</item>

Expand Down

0 comments on commit 8b41a9f

Please sign in to comment.