Fix AccountTypeListActivity title

This commit is contained in:
Shinokuni 2019-08-24 19:36:59 +02:00
parent e43636f943
commit c147752370
3 changed files with 4 additions and 6 deletions

View File

@ -41,15 +41,13 @@ public class AccountTypeListActivity extends AppCompatActivity {
binding = DataBindingUtil.setContentView(this, R.layout.activity_account_type_list);
viewModel = ViewModelProviders.of(this).get(AccountViewModel.class);
setTitle(R.string.new_account);
binding.accountTypeRecyclerview.setLayoutManager(new LinearLayoutManager(this));
binding.accountTypeRecyclerview.addItemDecoration(new DividerItemDecoration(this, LinearLayout.VERTICAL));
fromMainActivity = getIntent().getBooleanExtra("fromMainActivity", false);
if (fromMainActivity)
setTitle(R.string.add_account);
else
setTitle(R.string.create_account);
adapter = new AccountTypeListAdapter(accountType -> {
if (!(accountType == AccountType.LOCAL)) {

View File

@ -73,6 +73,6 @@
<string name="filter_newest">Du plus récent au plus ancien</string>
<string name="filter_oldest">Du plus ancien au plus récent</string>
<string name="login_failed">La connexion a échoué. Veuillez vérifier vos identifiants</string>
<string name="create_account">Créer un compte</string>
<string name="new_account">Nouveau compte</string>
</resources>

View File

@ -79,5 +79,5 @@
<string name="filter_newest">Newest to oldest</string>
<string name="filter_oldest">Oldest to newsest</string>
<string name="login_failed">Login failed. Please check your credentials</string>
<string name="create_account">Create account</string>
<string name="new_account">New account</string>
</resources>