mirror of
https://github.com/bloxstraplabs/bloxstrap.git
synced 2025-04-21 18:11:27 -07:00
37 lines
941 B
C#
37 lines
941 B
C#
using System.Windows;
|
|
using System.Windows.Input;
|
|
|
|
using Bloxstrap.UI.ViewModels.Menu;
|
|
|
|
namespace Bloxstrap.UI.Elements.Menu.Pages
|
|
{
|
|
/// <summary>
|
|
/// Interaction logic for FastFlagsPage.xaml
|
|
/// </summary>
|
|
public partial class FastFlagsPage
|
|
{
|
|
bool _initialLoad = false;
|
|
|
|
public FastFlagsPage()
|
|
{
|
|
DataContext = new FastFlagsViewModel(this);
|
|
InitializeComponent();
|
|
}
|
|
|
|
private void Page_Loaded(object sender, RoutedEventArgs e)
|
|
{
|
|
// refresh datacontext on page load to synchronize with editor page
|
|
|
|
if (!_initialLoad)
|
|
{
|
|
_initialLoad = true;
|
|
return;
|
|
}
|
|
|
|
DataContext = new FastFlagsViewModel(this);
|
|
}
|
|
|
|
private void ValidateInt32(object sender, TextCompositionEventArgs e) => e.Handled = !Int32.TryParse(e.Text, out int _);
|
|
}
|
|
}
|