void HandleRollButtonTouchUpInside(object sender, EventArgs e) { ObservableCollection <Character> oldList = new ObservableCollection <Character>(CombatState.CombatList); CombatState.RollInitiative(); CombatState.SortCombatList(); ReloadList(oldList); MainUI.SaveCombatState(); }
public void LoadStuff() { int count = Monster.Monsters.Count; MainUI.LoadCombatState(); if (count > 0) { InvokeOnMainThread(LoadUI); } }
void HandlePrevButtonTouchUpInside(object sender, EventArgs e) { int index1 = ActiveCharacterIndex; CombatState.MovePrevious(); int index2 = ActiveCharacterIndex; ReloadListRows(new List <int> { index1, index2 }); MainUI.SaveCombatState(); }
public void LoadUI() { uiLoaded = true; ui = new MainUI(); RectangleF rect = View.Frame; rect = View.ConvertRectFromView(rect, View.Superview); rect.X = 0; rect.Y = 0; ui.Frame = rect; View.AddSubview(ui); LayoutView(); }
public MainUI() { _MainView = this; BackgroundColor = CMUIColors.PrimaryColorLight; toolbar = new ToolbarView(); toolbar.BackgroundColor = CMUIColors.PrimaryColorLight; currentTab = new CombatTab(_CombatState); AddSubview(toolbar); AddSubview(currentTab); }
public void LoadUI() { uiLoaded = true; ui = new MainUI(); ui.StartupUrl = StartupUrl; CGRect rect = View.Frame; rect = View.ConvertRectFromView(rect, View.Superview); rect.X = 0; rect.Y = 0; ui.Frame = rect; View.AddSubview(ui); LayoutView(); if (MobileSettings.Instance.RunLocalService) { RunLocalService(); } MobileSettings.Instance.PropertyChanged += MobileSettingsPropertyChanged; }