public UserImage() { InitializeComponent(); GwupeClientAppContext _appContext = GwupeClientAppContext.CurrentAppContext.UIManager.GetAppcontext(); ChatWindow chatWindow = new ChatWindow(); DataContext = new ChatWindowDataContext(_appContext); }
public UserImageOthers() { InitializeComponent(); GwupeClientAppContext appContext = GwupeClientAppContext.CurrentAppContext.UIManager.GetAppcontext(); Engagement engagement = null;//GwupeClientAppContext.CurrentAppContext.UIManager.GetSourceObject(); DataContext = new ChatWindowDataContext(appContext,engagement); }
public UserImageOthers() { InitializeComponent(); GwupeClientAppContext appContext = GwupeClientAppContext.CurrentAppContext.UIManager.GetAppcontext(); Engagement engagement = null;//GwupeClientAppContext.CurrentAppContext.UIManager.GetSourceObject(); DataContext = new ChatWindowDataContext(appContext, engagement); }
public ChatWindow(GwupeClientAppContext appContext, EngagementWindow engagementWindow) { this.InitializeComponent(); _appContext = appContext; _engagementWindow = engagementWindow; Chat = _engagementWindow.Engagement.Functions["Chat"] as Function; Chat.NewActivity += ChatOnNewMessage; ChatPanelViewer.ScrollToBottom(); DataContext = new ChatWindowDataContext(_appContext, this); // need to do this here, because we get weird errors if its part of the data context. ChatPanel.ItemsSource = new DispatchingCollection <ObservableCollection <IChatMessage>, IChatMessage>(Chat.Conversation.Exchange, Dispatcher); }
public ChatWindow(GwupeClientAppContext appContext, EngagementWindow engagementWindow) { this.InitializeComponent(); _appContext = appContext; _engagementWindow = engagementWindow; Chat = _engagementWindow.Engagement.Functions["Chat"] as Function; Chat.NewActivity += ChatOnNewMessage; ChatPanelViewer.ScrollToBottom(); DataContext = new ChatWindowDataContext(_appContext, this); // need to do this here, because we get weird errors if its part of the data context. ChatPanel.ItemsSource = new DispatchingCollection<ObservableCollection<IChatMessage>, IChatMessage>(Chat.Conversation.Exchange, Dispatcher); }