diff --git a/app/src/main/java/nl/jpelgrm/movienotifier/ui/settings/AccountNotificationsFragment.java b/app/src/main/java/nl/jpelgrm/movienotifier/ui/settings/AccountNotificationsFragment.java index 2de925c..18cb49f 100644 --- a/app/src/main/java/nl/jpelgrm/movienotifier/ui/settings/AccountNotificationsFragment.java +++ b/app/src/main/java/nl/jpelgrm/movienotifier/ui/settings/AccountNotificationsFragment.java @@ -37,6 +37,7 @@ public class AccountNotificationsFragment extends Fragment { @BindView(R.id.error) TextView error; @BindView(R.id.types) LinearLayout types; + @BindView(R.id.privacy) LinearLayout privacy; @BindView(R.id.go) Button go; @@ -69,12 +70,9 @@ public void onViewCreated(View view, @Nullable Bundle savedInstanceState) { getTypes(); - go.setOnClickListener(new View.OnClickListener() { - @Override - public void onClick(View view) { - error.setVisibility(View.GONE); - save(); - } + go.setOnClickListener(view1 -> { + error.setVisibility(View.GONE); + save(); }); } @@ -91,9 +89,11 @@ public void onResponse(Call> call, Response> call, Throwable t) { error.setText(ErrorUtil.getErrorMessage(getContext(), null)); error.setVisibility(View.VISIBLE); + privacy.setVisibility(View.GONE); } }); } diff --git a/app/src/main/java/nl/jpelgrm/movienotifier/ui/settings/SettingsAccountOverviewFragment.java b/app/src/main/java/nl/jpelgrm/movienotifier/ui/settings/SettingsAccountOverviewFragment.java index 2b28c1c..57b7922 100644 --- a/app/src/main/java/nl/jpelgrm/movienotifier/ui/settings/SettingsAccountOverviewFragment.java +++ b/app/src/main/java/nl/jpelgrm/movienotifier/ui/settings/SettingsAccountOverviewFragment.java @@ -53,6 +53,7 @@ public class SettingsAccountOverviewFragment extends Fragment { @BindView(R.id.notifications) LinearLayout notificationsWrapper; @BindView(R.id.notificationsEmpty) TextView notificationsEmpty; + @BindView(R.id.notificationsPrivacy) LinearLayout notificationsPrivacy; @BindView(R.id.notificationTypes) LinearLayout notificationsList; private User user; @@ -207,6 +208,7 @@ public void run() { notificationsWrapper.setVisibility(View.VISIBLE); notificationsList.setVisibility(typeList.size() > 0 ? View.VISIBLE : View.GONE); notificationsEmpty.setVisibility(typeList.size() > 0 ? View.GONE : View.VISIBLE); + notificationsPrivacy.setVisibility(typeList.size() > 0 ? View.VISIBLE : View.GONE); } private void editDetail(SettingsAccountUpdateFragment.UpdateMode mode) { @@ -417,6 +419,7 @@ public void onResponse(Call> call, Response> call, Throwable t) { notificationsWrapper.setVisibility(user != null ? View.VISIBLE : View.GONE); notificationsList.setVisibility(View.GONE); notificationsEmpty.setVisibility(View.VISIBLE); + notificationsPrivacy.setVisibility(View.GONE); } }); } diff --git a/app/src/main/res/drawable-night/ic_info.xml b/app/src/main/res/drawable-night/ic_info.xml new file mode 100644 index 0000000..95eeb5e --- /dev/null +++ b/app/src/main/res/drawable-night/ic_info.xml @@ -0,0 +1,9 @@ + + + diff --git a/app/src/main/res/drawable/ic_info.xml b/app/src/main/res/drawable/ic_info.xml new file mode 100644 index 0000000..4bcd749 --- /dev/null +++ b/app/src/main/res/drawable/ic_info.xml @@ -0,0 +1,9 @@ + + + diff --git a/app/src/main/res/layout/fragment_account_add.xml b/app/src/main/res/layout/fragment_account_add.xml index 30d3ce2..1740d0d 100644 --- a/app/src/main/res/layout/fragment_account_add.xml +++ b/app/src/main/res/layout/fragment_account_add.xml @@ -115,6 +115,28 @@ + + + + + + + +