protected override void OnMouseUp(MouseEventArgs e) { if (fsbar.Visible) { fsbar.Focus(); } else { Focus(); } if (fItemOver != -1 && ItemClick != null) { if (GetSoundArea(e.Location, AyaList[fItemOver].DrawArea)) { if (e.Location.Y <= fHeaderTop + fLineHeight) { if (SouraSoundClick != null) { SouraSoundClick(cnSoura); } } else { if (AyaSoundClick != null) { AyaSoundClick(AyaList[fItemOver]); } } return; } if (fItemSelected != -1) //Invalidate Old Selection { InvalidateAya(fItemSelected); } fItemSelected = fItemOver; InvalidateAya(fItemOver); // don't raise events for soura header, for now if (fItemSelected > 0) { ItemClick(fItemOver.ToString()); } } base.OnMouseUp(e); }
private void PopInfo_MouseEnter(object sender, EventArgs e) { if (!ContainsFocus) { return; } VScrollBar1.Focus(); }
/// <summary> /// Performs initialization. /// </summary> protected override void OnLoad(EventArgs e) { base.OnLoad(e); Size = new Size(760, 587); InitParams(); SetTextBoxes(); scrollBar.Focus(); return; }
public MapWriteScroll(HScrollBar hScroll, VScrollBar vScroll, MapWriteScene mws, Size mapSize, int mapChipSize) : base(hScroll, vScroll) { this.mws = mws; SetScrollDelta(mapChipSize); SetScrollMaximum(mapSize, mapChipSize); //スクロールバーの値が更新されたら、mwsの位置を更新する処理を呼ぶ ValueChenged += UpdateValue; //スクロールバーがスクロールされたら、 //フォーカスを当てるようにしてmouseホイールしやすくする hScroll.Scroll += (o, e) => hScroll.Focus(); vScroll.Scroll += (o, e) => vScroll.Focus(); }
private void Panel1OnGotFocus(object sender, EventArgs e) { VScrollBar1.Focus(); }
void pInfo_MouseEnter(object sender, EventArgs e) { VScrollBar1.Focus(); }
private void hexView_MouseClick(object sender, MouseEventArgs e) { scrollPosition.Focus(); }