public ColorPickerViewModel()
        {
            StandardColorClickedCommand = new RelayCommandWithParameter((param) => ChangeSelectedColor(param));

            StandardColors = new ObservableCollection <SolidColorBrush>();

            FillStandardColorsList();
        }
Exemple #2
0
        public SearchSectionViewModel()
        {
            SearchCommand = new RelayCommandWithParameter((param) => { Search(IoC.Kernel.Get <CustomRichTextBox>().Document); });

            IoC.Kernel.Get <IEventAggregator>().GetEvent <ToggleSearchSectionVisibilityEvent>().Subscribe(() => IsVisible ^= true);
        }
Exemple #3
0
 public InsertSubmenuViewModel(FlowDocument document, Point popupPlacement, TextSelection selectedText)
 {
     InsertImageCommand = new RelayCommandWithParameter((param) => { InsertImage(document); });
     InsertLinkCommand  = new RelayCommandWithParameter((param) => { InsertLink(selectedText, popupPlacement); });
     InsertFileCommand  = new RelayCommand(() => { IoC.Kernel.Get <AttachmentsSectionViewModel>().InsertFileFromDialog(); });
 }