private void btnApplyCustomStyle_Click(object sender, RoutedEventArgs e) { #region #ApplyCustomStyle VisualDayViewGroupByResource visualDayViewElement = LayoutHelper.FindElementByType(schedulerControl1, typeof(VisualDayViewGroupByResource)) as VisualDayViewGroupByResource; if (visualDayViewElement != null) { visualDayViewElement.Style = this.Resources.MergedDictionaries[2]["CustomDayViewGroupByResourceStyle"] as System.Windows.Style; } #endregion #ApplyCustomStyle }
private void comb_PopupClosing(object sender, DevExpress.Xpf.Editors.ClosePopupEventArgs e) { ComboBoxEdit comboBoxEdit = sender as ComboBoxEdit; var popup = (sender as ComboBoxEdit).GetPopup(); if (popup != null) { var list = (PopupListBox)LayoutHelper.FindElementByType(popup.PopupContent as FrameworkElement, typeof(PopupListBox)); (sender as ComboBoxEdit).EditValue = list.SelectedItems.Cast <object>().ToList(); } }
void Timer_Tick(object sender, EventArgs e) { lock (BusyIndicator.Locker) { if (ShouldStop) { Close(); } if (!SupportProgress) { return; } TextBlock tb = (TextBlock)LayoutHelper.FindElementByType(this, typeof(TextBlock)); tb.Text = string.Format("Progress: {0} in {1}", Progress, Count); } }
void Timer_Tick(object sender, EventArgs e) { lock (BusyIndicator.Locker) { if (ShouldStop) { Close(); tb = null; return; } if (tb == null) { tb = (TextBlock)LayoutHelper.FindElementByType(this, typeof(TextBlock)); } tb.Text = SupportProgress ? string.Format(Text, Progress, Count) : Text; } }