mirror of
https://github.com/Kunzisoft/KeePassDX.git
synced 2025-12-04 15:49:33 +01:00
Fix visual issues in education screens
This commit is contained in:
@@ -230,6 +230,7 @@ public class EntryActivity extends LockingHideActivity {
|
||||
} else if (!PreferencesUtil.isEducationEntryEditPerformed(this)) {
|
||||
|
||||
try {
|
||||
// TODO add a link on reference https://keepass.info/help/base/fieldrefs.html
|
||||
TapTargetView.showFor(this,
|
||||
TapTarget.forToolbarMenuItem(toolbar, R.id.menu_edit,
|
||||
getString(R.string.education_entry_edit_title),
|
||||
|
||||
@@ -218,9 +218,8 @@ public class FileSelectActivity extends StylishActivity implements
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// For the first time show the tuto
|
||||
checkAndPerformedEducation(savedInstanceState);
|
||||
// For the first time show education
|
||||
checkAndPerformedEducation();
|
||||
}
|
||||
|
||||
private void launchPasswordActivityWithPath(String path) {
|
||||
@@ -264,7 +263,7 @@ public class FileSelectActivity extends StylishActivity implements
|
||||
mAdapter.notifyDataSetChanged();
|
||||
}
|
||||
|
||||
private void checkAndPerformedEducation(Bundle savedInstanceState) {
|
||||
private void checkAndPerformedEducation() {
|
||||
|
||||
// If no recent files
|
||||
if ( !fileHistory.hasRecentFiles() ) {
|
||||
@@ -289,46 +288,59 @@ public class FileSelectActivity extends StylishActivity implements
|
||||
public void onTargetCancel(TapTargetView view) {
|
||||
super.onTargetCancel(view);
|
||||
// But if the user cancel, it can also select a database
|
||||
checkAndPerformedEducationForSelection();
|
||||
}
|
||||
});
|
||||
PreferencesUtil.saveEducationPreference(FileSelectActivity.this,
|
||||
R.string.education_create_db_key);
|
||||
}
|
||||
}
|
||||
else
|
||||
checkAndPerformedEducationForSelection();
|
||||
}
|
||||
|
||||
private void checkAndPerformedEducationForSelection() {
|
||||
|
||||
if (!PreferencesUtil.isEducationSelectDatabasePerformed(this)) {
|
||||
|
||||
TapTargetView.showFor(FileSelectActivity.this,
|
||||
TapTarget.forView(browseButtonView,
|
||||
getString(R.string.education_select_database_title),
|
||||
getString(R.string.education_select_database_summary))
|
||||
.tintTarget(false)
|
||||
.cancelable(true),
|
||||
new TapTargetView.Listener() {
|
||||
@Override
|
||||
public void onTargetClick(TapTargetView view) {
|
||||
super.onTargetClick(view);
|
||||
keyFileHelper.getOpenFileOnClickViewListener().onClick(view);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onTargetCancel(TapTargetView view) {
|
||||
super.onTargetCancel(view);
|
||||
|
||||
if (!PreferencesUtil.isEducationOpenLinkDatabasePerformed(FileSelectActivity.this)) {
|
||||
TapTargetView.showFor(FileSelectActivity.this,
|
||||
TapTarget.forView(browseButtonView,
|
||||
getString(R.string.education_select_database_title),
|
||||
getString(R.string.education_select_database_summary))
|
||||
TapTarget.forView(openButtonView,
|
||||
getString(R.string.education_open_link_database_title),
|
||||
getString(R.string.education_open_link_database_summary))
|
||||
.tintTarget(false)
|
||||
.cancelable(true),
|
||||
new TapTargetView.Listener() {
|
||||
@Override
|
||||
public void onTargetClick(TapTargetView view) {
|
||||
super.onTargetClick(view);
|
||||
keyFileHelper.getOpenFileOnClickViewListener().onClick(view);
|
||||
// Do nothing here
|
||||
}
|
||||
});
|
||||
PreferencesUtil.saveEducationPreference(FileSelectActivity.this,
|
||||
R.string.education_select_db_key);
|
||||
R.string.education_open_link_db_key);
|
||||
}
|
||||
});
|
||||
PreferencesUtil.saveEducationPreference(FileSelectActivity.this,
|
||||
R.string.education_create_db_key);
|
||||
}
|
||||
} else {
|
||||
|
||||
if (!PreferencesUtil.isEducationOpenLinkDatabasePerformed(this) ) {
|
||||
|
||||
TapTargetView.showFor(FileSelectActivity.this,
|
||||
TapTarget.forView(openButtonView,
|
||||
getString(R.string.education_open_link_database_title),
|
||||
getString(R.string.education_open_link_database_summary))
|
||||
.tintTarget(false)
|
||||
.cancelable(true),
|
||||
new TapTargetView.Listener() {
|
||||
@Override
|
||||
public void onTargetClick(TapTargetView view) {
|
||||
super.onTargetClick(view);
|
||||
// Do nothing here
|
||||
}
|
||||
});
|
||||
PreferencesUtil.saveEducationPreference(FileSelectActivity.this,
|
||||
R.string.education_open_link_db_key);
|
||||
}
|
||||
}
|
||||
});
|
||||
PreferencesUtil.saveEducationPreference(FileSelectActivity.this,
|
||||
R.string.education_select_db_key);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -277,7 +277,7 @@
|
||||
<string name="education_field_copy_title">Copiez un champ</string>
|
||||
<string name="education_field_copy_summary">Copiez un champ facilement dans le presse-papiers pour le coller où vous voulez.</string>
|
||||
<string name="education_lock_title">Vérouillez la base de données</string>
|
||||
<string name="education_lock_summary">Verrouillez votre base de données rapidement, vous pouvez paramétrer l\'application pour qu\'elle se verrouille après un certain temps et lorsqu\'un écran est éteint.</string>
|
||||
<string name="education_lock_summary">Verrouillez votre base de données rapidement, vous pouvez paramétrer l\'application pour qu\'elle se verrouille après un certain temps et lorsque l\'écran s\'éteint.</string>
|
||||
<string name="education_sort_title">Triez les éléments</string>
|
||||
<string name="education_sort_summary">Triez les entrées et les groupes en fonction de paramètres spécifiques.</string>
|
||||
<string name="education_donation_title">Participez</string>
|
||||
|
||||
@@ -281,7 +281,7 @@
|
||||
<string name="education_field_copy_title">Copy a field</string>
|
||||
<string name="education_field_copy_summary">Copy a field easily into the clipboard to paste it where you want.</string>
|
||||
<string name="education_lock_title">Lock the database</string>
|
||||
<string name="education_lock_summary">Lock your database quickly, you can parameter the application to lock it after a while and when a screen is off.</string>
|
||||
<string name="education_lock_summary">Lock your database quickly, you can parameter the application to lock it after a while and when the screen goes off.</string>
|
||||
<string name="education_sort_title">Sort items</string>
|
||||
<string name="education_sort_summary">Sort entries and groups according to specific parameters.</string>
|
||||
<string name="education_donation_title">Participate</string>
|
||||
|
||||
Reference in New Issue
Block a user