public MainWindowViewModel() { KernelService.MainWindowViewModel = this; this._columnOwnerViewModel = new ColumnOwnerViewModel(this); this._notifierViewModel = new NotifierViewModel(this); this._notifyBlockViewModel = new NotifyBlockViewModel(this); // Input block dependents ColumnOwnerViewModel this._inputBlockViewModel = new InputBlockViewModel(this); this._userSelectionViewModel = new UserSelectionViewModel(); this._userSelectionViewModel.Finished += () => { this._isVisibleUserSelection = false; RaisePropertyChanged(() => IsVisibleUserSelection); RaisePropertyChanged(() => IsActivateMain); }; ViewModelHelper.BindNotification(Setting.SettingValueChangedEvent, this, (o, e) => { RaisePropertyChanged(() => IsNotifierBarBottom); RaisePropertyChanged(() => NotifierBarColumn); RaisePropertyChanged(() => IsInputBlockBottom); RaisePropertyChanged(() => InputBlockColumn); RaisePropertyChanged(() => FontFamily); RaisePropertyChanged(() => FontSize); }); }
public IEnumerable <TweetWorker> ReadyUpdate(InputBlockViewModel ibvm, IEnumerable <string> bindTags, IEnumerable <AccountInfo> infos) { var containsTags = RegularExpressions.HashRegex.Matches(InputText) .Cast <Match>().Select(m => m.Value).ToArray(); var excepteds = bindTags.Except(containsTags).Distinct(); return(infos .Where(i => i != null) .Select(i => new TweetWorker(ibvm, i, InputText, InReplyToId, AttachedImage, excepteds.ToArray()))); }
public TweetWorker(InputBlockViewModel parent, AccountInfo info, string body, long inReplyToId, string attachedImage, string[] tag) { this.parent = parent; this.TweetSummary = info.ScreenName + ": " + body; this.accountInfo = info; this.body = body; this.inReplyToId = inReplyToId; this.attachImagePath = attachedImage; this.tags = tag; }
public TweetWorker(InputBlockViewModel parent, AccountInfo info, string body, long inReplyToId, string attachedImage, string[] tag) { isImageAttached = false; isBodyStandby = false; if (info == null) throw new ArgumentNullException("info"); this.parent = parent; this.TweetSummary = info.ScreenName + ": " + body; this.accountInfo = info; this.body = body; this.inReplyToId = inReplyToId; this.attachImagePath = attachedImage; this.tags = tag; }
public TweetWorker(InputBlockViewModel parent, AccountInfo info, string body, long inReplyToId, string attachedImage, string[] tag) { isImageAttached = false; isBodyStandby = false; if (info == null) { throw new ArgumentNullException("info"); } this.parent = parent; this.TweetSummary = info.ScreenName + ": " + body; this.accountInfo = info; this.body = body; this.inReplyToId = inReplyToId; this.attachImagePath = attachedImage; this.tags = tag; }
public IEnumerable<TweetWorker> ReadyUpdate(InputBlockViewModel ibvm, IEnumerable<string> bindTags, IEnumerable<AccountInfo> infos) { var containsTags = RegularExpressions.HashRegex.Matches(InputText) .Cast<Match>().Select(m => m.Value).ToArray(); var excepteds = bindTags.Except(containsTags).Distinct(); return infos.Select(i => new TweetWorker(ibvm, i, InputText, InReplyToId, AttachedImage, excepteds.ToArray())); }