refactor: circular deps part 13

This commit is contained in:
Nathan Walker
2025-07-09 20:07:56 -07:00
parent ee03774ec0
commit 579a25d583
31 changed files with 552 additions and 387 deletions

View File

@@ -1,10 +1,10 @@
import * as common from './application-settings-common';
import { Application } from '../application';
import { getNativeApp } from '../application/helpers-common';
let sharedPreferences: android.content.SharedPreferences;
function ensureSharedPreferences() {
if (!sharedPreferences) {
sharedPreferences = Application.android.getNativeApplication().getApplicationContext().getSharedPreferences('prefs.db', 0);
sharedPreferences = (getNativeApp() as android.app.Application).getApplicationContext().getSharedPreferences('prefs.db', 0);
}
}