Make sure not to try to set empty text to clipboard

This commit is contained in:
baldurk
2015-04-25 13:19:48 +02:00
parent 7339be3c00
commit 23404656ce
3 changed files with 8 additions and 4 deletions
+4 -2
View File
@@ -275,7 +275,8 @@ namespace renderdocui.Windows
text += string.Format("{0,-5} {1}" + Environment.NewLine, n[0].ToString(), n[1].ToString());
}
Clipboard.SetText(text);
if (text.Length > 0)
Clipboard.SetText(text);
}
}
@@ -291,7 +292,8 @@ namespace renderdocui.Windows
text += n.ToString() + Environment.NewLine;
}
Clipboard.SetText(text);
if (text.Length > 0)
Clipboard.SetText(text);
}
}
@@ -280,7 +280,8 @@ namespace renderdocui.Controls
text += string.Format(fmt, n[0], n[1], n[2]);
}
Clipboard.SetText(text);
if (text.Length > 0)
Clipboard.SetText(text);
}
}
+2 -1
View File
@@ -670,7 +670,8 @@ namespace renderdocui.Windows
}
text += Environment.NewLine;
Clipboard.SetText(text);
if (text.Length > 0)
Clipboard.SetText(text);
}
}
}