mirror of
https://github.com/iSoron/uhabits.git
synced 2025-12-06 09:08:52 -06:00
now allowing blank for description
squash! now allowing blank for description
This commit is contained in:
@@ -76,7 +76,7 @@ public class NameDescriptionPanel extends FrameLayout
|
||||
tvName.setTextColor(PaletteUtils.getColor(getContext(), color));
|
||||
}
|
||||
|
||||
@Nullable
|
||||
@NonNull
|
||||
public String getDescription()
|
||||
{
|
||||
return tvDescription.getRealText().trim();
|
||||
@@ -105,10 +105,7 @@ public class NameDescriptionPanel extends FrameLayout
|
||||
setColor(habit.getColor());
|
||||
tvName.setText(habit.getName());
|
||||
tvQuestion.setRealText(habit.getQuestion());
|
||||
final String description = habit.getDescription();
|
||||
if(description != null) {
|
||||
tvDescription.setRealText(description);
|
||||
}
|
||||
tvDescription.setRealText(habit.getDescription());
|
||||
}
|
||||
|
||||
public boolean validate()
|
||||
|
||||
@@ -142,7 +142,7 @@ public class Habit
|
||||
data.color = color;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
@NonNull
|
||||
public synchronized String getDescription()
|
||||
{
|
||||
return data.description;
|
||||
@@ -368,7 +368,7 @@ public class Habit
|
||||
@NonNull
|
||||
public String name;
|
||||
|
||||
@Nullable
|
||||
@NonNull
|
||||
public String description;
|
||||
|
||||
@NonNull
|
||||
@@ -402,7 +402,7 @@ public class Habit
|
||||
this.frequency = new Frequency(3, 7);
|
||||
this.type = YES_NO_HABIT;
|
||||
this.name = "";
|
||||
this.description = null;
|
||||
this.description = "";
|
||||
this.question = "";
|
||||
this.targetType = AT_LEAST;
|
||||
this.targetValue = 100;
|
||||
|
||||
Reference in New Issue
Block a user