public void InvokeContentsChanged(EventArgs e) { EventHandler handler = ContentsChanged; if (handler != null) handler(this, e); }