/// <summary> /// Handles the Click event of the uxMainMenuViewTextures control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param> private void uxMainMenuViewTextures_Click(object sender, EventArgs e) { using (TextureReferenceBrowser browser = new TextureReferenceBrowser(this.TextureReferences, this.TextureReferenceAdded)) { browser.ShowDialog(); } }
/// <summary> /// Handles the Click event of the uxSelectTexture control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param> private void uxSelectTexture_Click(object sender, EventArgs e) { using (TextureReferenceBrowser browser = new TextureReferenceBrowser(this.TextureReferences, this.TextureReferenceAdded)) { if (browser.ShowDialog() == DialogResult.OK) { EmitterTreeNode node = this.uxEffectTree.SelectedNode as EmitterTreeNode; var args = new TextureReferenceChangedEventArgs(node.Emitter, browser.SelectedReference); this.OnTextureReferenceChanged(args); this.uxPropertyBrowser.Refresh(); } } }