diff --git a/lib/pangea/controllers/language_controller.dart b/lib/pangea/controllers/language_controller.dart index 2a34b1fb4..5b007339f 100644 --- a/lib/pangea/controllers/language_controller.dart +++ b/lib/pangea/controllers/language_controller.dart @@ -13,9 +13,9 @@ class LanguageController { _pangeaController = pangeaController; } //show diloag when user does not have languages selected - showDialogOnEmptyLanguage(BuildContext dialogContext, Function callback) { + showDialogOnEmptyLanguage(BuildContext context, Function callback) { if (!languagesSet) { - pLanguageDialog(dialogContext, callback); + pLanguageDialog(context, callback); } } diff --git a/lib/pangea/widgets/user_settings/p_language_dialog.dart b/lib/pangea/widgets/user_settings/p_language_dialog.dart index 34e30b4c1..bc93f0c63 100644 --- a/lib/pangea/widgets/user_settings/p_language_dialog.dart +++ b/lib/pangea/widgets/user_settings/p_language_dialog.dart @@ -49,14 +49,14 @@ Future pLanguageDialog( return Scaffold( backgroundColor: Colors.transparent, body: AlertDialog( - title: Text(L10n.of(parentContext).updateLanguage), + title: Text(L10n.of(context).updateLanguage), content: SizedBox( width: FluffyThemes.columnWidth, child: Column( mainAxisSize: MainAxisSize.min, children: [ PQuestionContainer( - title: L10n.of(parentContext).whatIsYourBaseLanguage, + title: L10n.of(context).whatIsYourBaseLanguage, ), PLanguageDropdown( onChange: (p0) => @@ -66,7 +66,7 @@ Future pLanguageDialog( isL2List: false, ), PQuestionContainer( - title: L10n.of(parentContext).whatLanguageYouWantToLearn, + title: L10n.of(context).whatLanguageYouWantToLearn, ), PLanguageDropdown( onChange: (p0) => @@ -80,7 +80,7 @@ Future pLanguageDialog( ), actions: [ TextButton( - child: Text(L10n.of(parentContext).cancel), + child: Text(L10n.of(context).cancel), onPressed: () { Navigator.pop(context); }, @@ -117,14 +117,14 @@ Future pLanguageDialog( : ScaffoldMessenger.of(context).showSnackBar( SnackBar( content: Text( - L10n.of(parentContext).noIdenticalLanguages, + L10n.of(context).noIdenticalLanguages, ), backgroundColor: Theme.of(context).colorScheme.primary, ), ); }, - child: Text(L10n.of(parentContext).saveChanges), + child: Text(L10n.of(context).saveChanges), ), ], ),