Пример #1
0
 private void UserControl_IsVisibleChanged(object sender, DependencyPropertyChangedEventArgs e)
 {
     if (e.NewValue as bool? == true)
     {
         if (String.IsNullOrWhiteSpace(Properties.Settings.Default.PrefDownloadDir))
         {
             TextBoxHelper.SetWatermark(tbDirectory, ReceiveFilesManager.GetDefaultDownloadDirectory(false));
         }
     }
 }
Пример #2
0
 private void TbDirectory_SourceUpdated(object sender, DataTransferEventArgs e)
 {
     if (sender is TextBox textBox)
     {
         if (String.IsNullOrWhiteSpace(Properties.Settings.Default.PrefDownloadDir))
         {
             TextBoxHelper.SetWatermark(textBox, ReceiveFilesManager.GetDefaultDownloadDirectory(false));
         }
         else
         {
             TextBoxHelper.SetWatermark(textBox, null);
         }
     }
 }