/// <summary> /// Handles the button lock/unlock clicks. /// </summary> /// <param name="sender">The <see cref="Button"/> sender.</param> /// <param name="e">The <see cref="RoutedEventArgs"/> instance containing the event data.</param> private void BtnUnlock_Click(object sender, RoutedEventArgs e) { if (((ToggleButton)sender).IsChecked.Value) { setListDisplay = FindSetListDisplay(); if (setListDisplay != null) { setListDisplay.Hide(); } setListWindow = new SetListWindow(); setListWindow.Activate(); } else { setListDisplay = FindSetListDisplay(); if (setListWindow != null && setListDisplay != null) { Settings.Default.SetlistTop = setListWindow.Top; Settings.Default.SetlistLeft = setListWindow.Left; Canvas.SetTop(setListDisplay, Settings.Default.SetlistTop); Canvas.SetLeft(setListDisplay, Settings.Default.SetlistLeft); setListWindow.Close(); } } }
/// <summary> /// Called when [mouse off]. /// </summary> private void OnMouseOff() { setListDisplay.Hide(); }