Skip to content

Commit

Permalink
Prep for runtime translation decisions.
Browse files Browse the repository at this point in the history
  • Loading branch information
Keflon committed Feb 25, 2024
1 parent 7e24d8f commit e9ca518
Showing 1 changed file with 20 additions and 1 deletion.
21 changes: 20 additions & 1 deletion SampleApp/MauiProgram.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
using FunctionZero.Maui.Controls;
using FunctionZero.ExpressionParserZero.Binding;
using FunctionZero.ExpressionParserZero.Evaluator;
using FunctionZero.ExpressionParserZero.Parser;
using FunctionZero.Maui.Controls;
using FunctionZero.Maui.MvvmZero;
using FunctionZero.Maui.Services;
using SampleApp.Mvvm.Pages;
Expand Down Expand Up @@ -121,6 +124,22 @@ private static LangService GetConfiguredLanguageService(IServiceProvider provide
private static string[] GetEnglish() => new string[] { "Hello", "World", "Welcome to the Moasure Playground!" };
private static string[] GetGerman() => new string[] { "Hallo", "Welt", "Willkommen auf dem Moasure Spielplatz!" };

//private static List<(ExpressionTree, string)> GetEnglish2()
//{
// var retval = new List<(ExpressionTree, string)>();

// var parser = ExpressionParserFactory.GetExpressionParser();

// retval.Add((parser.Parse("NumBananas == 0"), "There are no bananas!"));

// retval.Add((parser.Parse("NumBananas == 1"), "There is one banana!"));
// retval.Add((parser.Parse("NumBananas == 2"), "There are two bananas!"));
// retval.Add((parser.Parse("NumBananas < 10"), "There are {NumBananas} bananas!")); // TODO: {NumBananas}
// retval.Add((parser.Parse("true"), "There are loads of bananas!"));

// return retval;
//}

#endregion
}
}

0 comments on commit e9ca518

Please sign in to comment.