private void GetCurrentBG1_Click(object sender, RoutedEventArgs e) { if (((Button)sender).CommandParameter.ToString().Equals("GetCurrentBG1")) { pathOrig1 = deskBGHandler.GetBackground(); ShowPreview(pathOrig1, 1); } if (((Button)sender).CommandParameter.ToString().Equals("GetCurrentBG2")) { pathOrig2 = deskBGHandler.GetBackground(); ShowPreview(pathOrig2, 2); } }
private void GetCurrentBG1_Click(object sender, RoutedEventArgs e) { if (((Button)sender).CommandParameter.ToString().Equals("GetCurrentBG1")) { pathOrig1 = deskBGHandler.GetBackground(); ShowPreview(pathOrig1, 1); PictureText1.Text = ""; picture1 = true; } if (((Button)sender).CommandParameter.ToString().Equals("GetCurrentBG2")) { pathOrig2 = deskBGHandler.GetBackground(); ShowPreview(pathOrig2, 2); PictureText2.Text = ""; picture2 = true; } EnableSaveButton(); }