public VideoPlaybackPanel() { InitializeComponent(); _timer = new CoolTimer(); _timer.RenderFrame += new EventHandler<FrameEventArgs>(RenderUpdate); previewPanel1.LeftClicked += previewPanel1_LeftClicked; previewPanel1.RightClicked += previewPanel1_RightClicked; }
public void Search(string searchText) { if (_timer != null) { _timer.Cancel(); } _timer = new CoolTimer((x) => { this.SearchResults = _localDbService.GetStations((string)x); _timer = null; }, searchText, 500); }
public ModelEditControl() { InitializeComponent(); leftPanel._mainWindow = this; rightPanel.pnlKeyframes._mainWindow = rightPanel.pnlBones._mainWindow = srt0Editor._mainWindow = shp0Editor._mainWindow = pat0Editor._mainWindow = vis0Editor._mainWindow = scn0Editor._mainWindow = clr0Editor._mainWindow = weightEditor._mainWindow = vertexEditor._mainWindow = pnlPlayback._mainWindow = chr0Editor._mainWindow = this; animEditors.HorizontalScroll.Enabled = addedHeight = (!(animEditors.Width - animCtrlPnl.Width >= pnlPlayback.MinimumSize.Width)); if (pnlPlayback.Width <= pnlPlayback.MinimumSize.Width) { pnlPlayback.Dock = DockStyle.Left; pnlPlayback.Width = pnlPlayback.MinimumSize.Width; } else pnlPlayback.Dock = DockStyle.Fill; _interpolationEditor = new Forms.InterpolationEditor(this); leftPanel.fileType.DataSource = _editableAnimTypes; TargetAnimType = AnimType.CHR; m_DelegateOpenFile = new DelegateOpenFile(OpenFile); ScreenCapBgLocText.Text = Application.StartupPath + "\\ScreenCaptures"; _timer = new CoolTimer(); _timer.RenderFrame += _timer_RenderFrame; modelPanel.PreRender += (EventPreRender = new System.Windows.Forms.GLRenderEventHandler(this.modelPanel1_PreRender)); modelPanel.PostRender += (EventPostRender = new System.Windows.Forms.GLRenderEventHandler(this.modelPanel1_PostRender)); modelPanel.MouseDown += (EventMouseDown = new System.Windows.Forms.MouseEventHandler(this.modelPanel1_MouseDown)); modelPanel.MouseMove += (EventMouseMove = new System.Windows.Forms.MouseEventHandler(this.modelPanel1_MouseMove)); modelPanel.MouseUp += (EventMouseUp = new System.Windows.Forms.MouseEventHandler(this.modelPanel1_MouseUp)); KeyframePanel.visEditor.EntryChanged += new EventHandler(this.VISEntryChanged); KeyframePanel.visEditor.IndexChanged += new EventHandler(this.VISIndexChanged); }
public override async void Start() { base.Start(); await ExecuteRefreshCommand(); _coolTimer = new CoolTimer(DataCallBack, null, REFRESH_DELAY, -1); }
public void DataCallBack(object state) { Task.Run(new Func<Task>(ExecuteRefreshCommand)); _coolTimer = new CoolTimer( DataCallBack, null, REFRESH_DELAY, -1 ); }