mirror of
https://github.com/FossifyOrg/Notes.git
synced 2026-01-04 05:29:45 -05:00
display a dialog at leaving with unsaved changes
This commit is contained in:
@@ -37,4 +37,12 @@ public class Config {
|
||||
public void setIsAutosaveEnabled(boolean enabled) {
|
||||
mPrefs.edit().putBoolean(Constants.AUTOSAVE, enabled).apply();
|
||||
}
|
||||
|
||||
public boolean getShouldPromptAutosave() {
|
||||
return mPrefs.getBoolean(Constants.PROMPT_AUTOSAVE, true);
|
||||
}
|
||||
|
||||
public void setShouldPromptAutosave(boolean prompt) {
|
||||
mPrefs.edit().putBoolean(Constants.PROMPT_AUTOSAVE, prompt).apply();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user