public void SetControls(ProgramView pv, TimeView tv, ScrollViewer hv) { programView = pv; timeView = tv; horizontalViewScroll = hv; programView.ScrollChanged += epgProgramView_ScrollChanged; programView.LeftDoubleClick += (sender, cursorPos) => EpgCmds.ShowDialog.Execute(null, cmdMenu); programView.MouseClick += (sender, cursorPos) => clickPos = cursorPos; programView.RightClick += epgProgramView_RightClick; }
public void SetControls(ProgramView pv, TimeView tv, ScrollViewer hv, Button button_now) { programView = pv; timeView = tv; horizontalViewScroll = hv; programView.ScrollChanged += new ScrollChangedEventHandler(epgProgramView_ScrollChanged); programView.LeftDoubleClick += new ProgramView.PanelViewClickHandler(epgProgramView_LeftDoubleClick); programView.RightClick += new ProgramView.PanelViewClickHandler(epgProgramView_RightClick); nowViewTimer = new DispatcherTimer(DispatcherPriority.Normal); nowViewTimer.Tick += new EventHandler(WaitReDrawNowLine); button_now.Click += new RoutedEventHandler((sender, e) => MoveNowTime()); }
public void SetControls(ProgramView pv, TimeView tv, ScrollViewer hv, Button button_now) { programView = pv; timeView = tv; horizontalViewScroll = hv; programView.ScrollChanged += new ScrollChangedEventHandler(epgProgramView_ScrollChanged); programView.LeftDoubleClick += (sender, cursorPos) => EpgCmds.ShowDialog.Execute(null, cmdMenu); programView.MouseClick += (sender, cursorPos) => clickPos = cursorPos; programView.RightClick += new ProgramView.PanelViewClickHandler(epgProgramView_RightClick); nowViewTimer = new DispatcherTimer(DispatcherPriority.Normal); nowViewTimer.Tick += (sender, e) => ReDrawNowLine(); this.Unloaded += (sender, e) => nowViewTimer.Stop(); button_now.Click += new RoutedEventHandler((sender, e) => MoveNowTime()); }
public void SetControls(ProgramView pv, TimeView tv, ScrollViewer hv, Button button_now) { programView = pv; timeView = tv; horizontalViewScroll = hv; programView.ScrollChanged += new ScrollChangedEventHandler(epgProgramView_ScrollChanged); programView.LeftDoubleClick += new ProgramView.PanelViewClickHandler(epgProgramView_LeftDoubleClick); programView.RightClick += new ProgramView.PanelViewClickHandler(epgProgramView_RightClick); nowViewTimer = new DispatcherTimer(DispatcherPriority.Normal); nowViewTimer.Tick += new EventHandler(WaitReDrawNowLine); button_now.Click += new RoutedEventHandler((sender, e) => MoveNowTime()); timeView.Margin = new Thickness(0, 0, 0, SystemParameters.HorizontalScrollBarHeight); horizontalViewScroll.Margin = new Thickness(0, 0, SystemParameters.VerticalScrollBarWidth, 0); }