Skip to content

Commit

Permalink
Merge pull request #160 from Crazy-Marvin/development
Browse files Browse the repository at this point in the history
To Don't v1.8
  • Loading branch information
CrazyMarvin authored Oct 1, 2022
2 parents ef521ff + 6582460 commit 5be742a
Show file tree
Hide file tree
Showing 46 changed files with 133 additions and 157 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ android {
applicationId "rocks.poopjournal.todont"
minSdkVersion 21
targetSdkVersion 33
versionCode 7
versionName "1.7"
versionCode 8
versionName "1.8"

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
Expand Down
4 changes: 2 additions & 2 deletions app/release/output-metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
"type": "SINGLE",
"filters": [],
"attributes": [],
"versionCode": 6,
"versionName": "1.6",
"versionCode": 7,
"versionName": "1.7",
"outputFile": "app-release.apk"
}
],
Expand Down
3 changes: 2 additions & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
android:icon="@mipmap/ic_store"
android:roundIcon="@mipmap/ic_store"
android:supportsRtl="true"
android:theme="@style/AppTheme">
android:theme="@style/AppTheme"
android:dataExtractionRules="@xml/data_extraction_rules">
<activity android:name=".About"></activity>
<activity android:name=".Settings" />
<activity android:name=".OnBoardingActivity" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
public class AvoidedAdapter extends RecyclerView.Adapter<AvoidedAdapter.RecyclerViewHolder> {
private ArrayList<String> donotTask = new ArrayList<>();
private ArrayList<String> donotCatagory = new ArrayList<>();
private ArrayList<String> updateddonotCatagory = new ArrayList<>();
private final ArrayList<String> updateddonotCatagory = new ArrayList<>();
AvoidedFragment ft;
Context con;
Date c = Calendar.getInstance().getTime();
Expand Down Expand Up @@ -81,7 +81,7 @@ public void onClick(View view) {
R.style.BottomSheetDialogTheme);
final View bottomsheetview = LayoutInflater.from(con.getApplicationContext()).
inflate(R.layout.update_layout_bottom_sheet,
(RelativeLayout) view.findViewById(R.id.bottomsheetContainer));
view.findViewById(R.id.bottomsheetContainer));
final Spinner spinner = bottomsheetview.findViewById(R.id.updatespinner);
Button saveTaskButton = bottomsheetview.findViewById(R.id.updateTaskButton);
final EditText habit = bottomsheetview.findViewById(R.id.updatehabit);
Expand All @@ -100,11 +100,7 @@ public void onClick(View view) {
Helper.labels_array) {
@Override
public boolean isEnabled(int position) {
if (position == 0) {
return false;
} else {
return true;
}
return position != 0;
}
};
spinner.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
public class AvoidedLogAdapter extends RecyclerView.Adapter<AvoidedLogAdapter.RecyclerViewHolder> {
private ArrayList<String> donotTask = new ArrayList<>();
private ArrayList<String> donotCatagory = new ArrayList<>();
private ArrayList<String> updateddonotCatagory = new ArrayList<>();
private final ArrayList<String> updateddonotCatagory = new ArrayList<>();
AvoidedLogFragment ft;
Context con;
Date c = Calendar.getInstance().getTime();
Expand Down Expand Up @@ -82,7 +82,7 @@ public void onClick(View view) {
R.style.BottomSheetDialogTheme);
final View bottomsheetview = LayoutInflater.from(con.getApplicationContext()).
inflate(R.layout.update_layout_bottom_sheet,
(RelativeLayout) view.findViewById(R.id.bottomsheetContainer));
view.findViewById(R.id.bottomsheetContainer));
final Spinner spinner = bottomsheetview.findViewById(R.id.updatespinner);
Button saveTaskButton = bottomsheetview.findViewById(R.id.updateTaskButton);
final EditText habit = bottomsheetview.findViewById(R.id.updatehabit);
Expand All @@ -101,11 +101,7 @@ public void onClick(View view) {
Helper.labels_array) {
@Override
public boolean isEnabled(int position) {
if (position == 0) {
return false;
} else {
return true;
}
return position != 0;
}
};
spinner.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public void onClick(View view) {
R.style.BottomSheetDialogTheme);
final View bottomsheetview = LayoutInflater.from(con.getApplicationContext()).
inflate(R.layout.update_layout_bottom_sheet,
(RelativeLayout) view.findViewById(R.id.bottomsheetContainer));
view.findViewById(R.id.bottomsheetContainer));
final Spinner spinner = bottomsheetview.findViewById(R.id.updatespinner);
Button saveTaskButton = bottomsheetview.findViewById(R.id.updateTaskButton);
final EditText habit = bottomsheetview.findViewById(R.id.updatehabit);
Expand All @@ -98,11 +98,7 @@ public void onClick(View view) {
Helper.labels_array) {
@Override
public boolean isEnabled(int position) {
if (position == 0) {
return false;
} else {
return true;
}
return position != 0;
}

};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public void onClick(View view) {
R.style.BottomSheetDialogTheme);
final View bottomsheetview = LayoutInflater.from(con.getApplicationContext()).
inflate(R.layout.update_layout_bottom_sheet,
(RelativeLayout) view.findViewById(R.id.bottomsheetContainer));
view.findViewById(R.id.bottomsheetContainer));
final Spinner spinner = bottomsheetview.findViewById(R.id.updatespinner);
Button saveTaskButton = bottomsheetview.findViewById(R.id.updateTaskButton);
final EditText habit = bottomsheetview.findViewById(R.id.updatehabit);
Expand All @@ -99,11 +99,7 @@ public void onClick(View view) {
Helper.labels_array) {
@Override
public boolean isEnabled(int position) {
if (position == 0) {
return false;
} else {
return true;
}
return position != 0;
}

};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public void onClick(View view) {
R.style.BottomSheetDialogTheme);
final View bottomsheetview = LayoutInflater.from(con.getApplicationContext()).
inflate(R.layout.update_layout_bottom_sheet,
(RelativeLayout) view.findViewById(R.id.bottomsheetContainer));
view.findViewById(R.id.bottomsheetContainer));
final Spinner spinner = bottomsheetview.findViewById(R.id.updatespinner);
Button saveTaskButton = bottomsheetview.findViewById(R.id.updateTaskButton);
final EditText habit = bottomsheetview.findViewById(R.id.updatehabit);
Expand All @@ -103,11 +103,7 @@ public void onClick(View view) {
Helper.labels_array) {
@Override
public boolean isEnabled(int position) {
if (position == 0) {
return false;
} else {
return true;
}
return position != 0;
}

};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public void onClick(View view) {
R.style.BottomSheetDialogTheme);
final View bottomsheetview = LayoutInflater.from(con.getApplicationContext()).
inflate(R.layout.update_layout_bottom_sheet,
(RelativeLayout) view.findViewById(R.id.bottomsheetContainer));
view.findViewById(R.id.bottomsheetContainer));
final Spinner spinner = bottomsheetview.findViewById(R.id.updatespinner);
Button saveTaskButton = bottomsheetview.findViewById(R.id.updateTaskButton);
final EditText habit = bottomsheetview.findViewById(R.id.updatehabit);
Expand All @@ -99,11 +99,7 @@ public void onClick(View view) {
Helper.labels_array) {
@Override
public boolean isEnabled(int position) {
if (position == 0) {
return false;
} else {
return true;
}
return position != 0;
}

};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ public void funcPieChart(int avoidedPer) {
pieDataSet.setValueTextColor(Color.WHITE);
PieData pieData = new PieData(pieDataSet);
pieChart.setData(pieData);
pieDataSet.setColors(new int[]{Color.parseColor("#FFAF01"), Color.parseColor("#26272c")});
pieDataSet.setColors(Color.parseColor("#FFAF01"), Color.parseColor("#26272c"));
Legend legend = pieChart.getLegend();
legend.setEnabled(false);
Description description = new Description();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ public void onClick(View view) {
}

});
spinner.setAdapter((SpinnerAdapter) arrayAdapter);
spinner.setAdapter(arrayAdapter);
d.show();


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,7 @@ public View onCreateView(LayoutInflater inflater, ViewGroup container,
btnbefore.setEnabled(true);
btnafter.setEnabled(true);
}
if(year.getText().toString().equals(splitteddate[0]) && date.getText().toString().equals(curmonth)){
btnafter.setEnabled(false);
}
else{
btnafter.setEnabled(true);
}
btnafter.setEnabled(!year.getText().toString().equals(splitteddate[0]) || !date.getText().toString().equals(curmonth));

btnbefore.setOnClickListener(new View.OnClickListener() {
@Override
Expand Down Expand Up @@ -365,7 +360,7 @@ public void funcPieChart(int avoidedPer) {
pieDataSet.setValueTextColor(Color.WHITE);
PieData pieData = new PieData(pieDataSet);
pieChart.setData(pieData);
pieDataSet.setColors(new int[]{Color.parseColor("#FFAF01"), Color.parseColor("#26272c")});
pieDataSet.setColors(Color.parseColor("#FFAF01"), Color.parseColor("#26272c"));
Legend legend = pieChart.getLegend();
legend.setEnabled(false);
Description description = new Description();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ public void funcPieChart(int avoidedPer) {
pieDataSet.setValueTextColor(Color.WHITE);
PieData pieData = new PieData(pieDataSet);
pieChart.setData(pieData);
pieDataSet.setColors(new int[]{Color.parseColor("#FFAF01"), Color.parseColor("#26272c")});
pieDataSet.setColors(Color.parseColor("#FFAF01"), Color.parseColor("#26272c"));
Legend legend = pieChart.getLegend();
legend.setEnabled(false);
Description description = new Description();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,7 @@ public View onCreateView(LayoutInflater inflater, ViewGroup container,
btnbefore.setEnabled(true);
btnafter.setEnabled(true);
}
if(year.getText().toString().equals(splitteddate[0])){
btnafter.setEnabled(false);
}
else{
btnafter.setEnabled(true);
}
btnafter.setEnabled(!year.getText().toString().equals(splitteddate[0]));

btnbefore.setOnClickListener(new View.OnClickListener() {
@Override
Expand Down Expand Up @@ -181,7 +176,7 @@ public void funcPieChart(int avoidedPer) {
pieDataSet.setValueTextColor(Color.WHITE);
PieData pieData = new PieData(pieDataSet);
pieChart.setData(pieData);
pieDataSet.setColors(new int[]{Color.parseColor("#FFAF01"), Color.parseColor("#26272c")});
pieDataSet.setColors(Color.parseColor("#FFAF01"), Color.parseColor("#26272c"));
Legend legend = pieChart.getLegend();
legend.setEnabled(false);
Description description = new Description();
Expand Down
10 changes: 5 additions & 5 deletions app/src/main/java/rocks/poopjournal/todont/MainActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ class MainActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
val fragment = FragmentToday();
val fragment = FragmentToday()
db = Db_Controller(applicationContext, "", null, 2)


supportFragmentManager.beginTransaction()
.replace(R.id.container, fragment, fragment.javaClass.getSimpleName())
.replace(R.id.container, fragment, fragment.javaClass.simpleName)
.commit()
toolbartext.setText(R.string.today)
label.visibility = View.VISIBLE
Expand All @@ -43,9 +43,9 @@ class MainActivity : AppCompatActivity() {
when (item.itemId) {
R.id.navigation_today -> {
val fragment =
FragmentToday();
FragmentToday()
supportFragmentManager.beginTransaction()
.replace(R.id.container, fragment, fragment.javaClass.getSimpleName())
.replace(R.id.container, fragment, fragment.javaClass.simpleName)
.commit()
toolbartext.setText(R.string.today)
label.visibility = View.VISIBLE
Expand All @@ -57,7 +57,7 @@ class MainActivity : AppCompatActivity() {
val fragment =
FragmentLog()
supportFragmentManager.beginTransaction()
.replace(R.id.container, fragment, fragment.javaClass.getSimpleName())
.replace(R.id.container, fragment, fragment.javaClass.simpleName)
.commit()
toolbartext.setText(R.string.log)
label.visibility = View.INVISIBLE
Expand Down
6 changes: 4 additions & 2 deletions app/src/main/res/layout/dialogbox_floatingbutton.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@
android:hint="@string/addtask"
android:textColorHint="@android:color/darker_gray"
android:textColor="@color/textcolor"
android:textAppearance="@style/TextAppearance.AppCompat.Medium" />
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:autofillHints="" />

<EditText
android:id="@+id/detail"
Expand All @@ -34,7 +35,8 @@
android:hint="@string/note"
android:textColorHint="@android:color/darker_gray"
android:textColor="@color/textcolor"
android:textAppearance="@style/TextAppearance.AppCompat.Medium" />
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:autofillHints="" />

<TextView
android:id="@+id/txt"
Expand Down
3 changes: 2 additions & 1 deletion app/src/main/res/layout/dialogbox_labels.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:textColor="@color/textcolor"
android:textColorHint="@android:color/darker_gray"
android:textSize="16sp" />
android:textSize="16sp"
android:autofillHints="" />


<Button
Expand Down
3 changes: 2 additions & 1 deletion app/src/main/res/layout/labels_bottom_sheet.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
android:layout_height="wrap_content"
android:textSize="16sp"
android:hint="@string/addnewlabel"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"/>
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:autofillHints="" />


<Button
Expand Down
3 changes: 2 additions & 1 deletion app/src/main/res/layout/labels_bottom_sheet_night.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
android:hint="@string/addnewlabel"
android:textColorHint="#7C7A72"
android:textColor="@android:color/white"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"/>
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:autofillHints="" />


<Button
Expand Down
6 changes: 4 additions & 2 deletions app/src/main/res/layout/layout_bottom_sheet.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
android:layout_height="wrap_content"
android:hint="@string/addtask"
android:textColor="@color/textcolor"
android:textAppearance="@style/TextAppearance.AppCompat.Medium" />
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:autofillHints="" />

<EditText
android:id="@+id/detail"
Expand All @@ -21,7 +22,8 @@
android:layout_below="@id/habit"
android:hint="@string/note"
android:textColor="@color/textcolor"
android:textAppearance="@style/TextAppearance.AppCompat.Medium" />
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:autofillHints="" />

<TextView
android:id="@+id/txt"
Expand Down
6 changes: 4 additions & 2 deletions app/src/main/res/layout/layout_bottom_sheet_nightmode.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
android:hint="@string/addtask"
android:textColorHint="#7C7A72"
android:textColor="@android:color/white"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"/>
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:autofillHints="" />

<EditText
android:id="@+id/detail"
Expand All @@ -23,7 +24,8 @@
android:textColorHint="#7C7A72"
android:textColor="@android:color/white"
android:layout_below="@id/habit"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"/>
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:autofillHints="" />
<!-- <View-->
<!-- android:layout_width="match_parent"-->
<!-- android:layout_height="1dp"-->
Expand Down
Loading

0 comments on commit 5be742a

Please sign in to comment.