Skip to content
This repository has been archived by the owner on Oct 16, 2020. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
…ure the CodeSnippet properties cannot be null.
  • Loading branch information
dgrunwald committed Aug 29, 2010
1 parent 2f15071 commit d5fe7a3
Showing 1 changed file with 5 additions and 5 deletions.
Expand Up @@ -25,7 +25,7 @@ namespace ICSharpCode.AvalonEdit.AddIn.Snippets
/// </summary>
public class CodeSnippet : INotifyPropertyChanged, IEquatable<CodeSnippet>
{
string name, description, text, keyword;
string name = string.Empty, description = string.Empty, text = string.Empty, keyword = string.Empty;

public CodeSnippet()
{
Expand All @@ -43,7 +43,7 @@ public CodeSnippet(CodeSnippet copy)
get { return name; }
set {
if (name != value) {
name = value;
name = value ?? string.Empty;
OnPropertyChanged("Name");
}
}
Expand All @@ -53,7 +53,7 @@ public CodeSnippet(CodeSnippet copy)
get { return text; }
set {
if (text != value) {
text = value;
text = value ?? string.Empty;
OnPropertyChanged("Text");
}
}
Expand All @@ -63,7 +63,7 @@ public CodeSnippet(CodeSnippet copy)
get { return description; }
set {
if (description != value) {
description = value;
description = value ?? string.Empty;
OnPropertyChanged("Description");
}
}
Expand All @@ -81,7 +81,7 @@ public CodeSnippet(CodeSnippet copy)
get { return keyword; }
set {
if (keyword != value) {
keyword = value;
keyword = value ?? string.Empty;
OnPropertyChanged("Keyword");
}
}
Expand Down

0 comments on commit d5fe7a3

Please sign in to comment.