How do i add a click event handler to a button

Building and customizing Audacity from the source code.
Forum rules
If you require help using Audacity, please post on the forum board relevant to your operating system:
Windows
Mac OS X
GNU/Linux and Unix-like
Post Reply
murtaza19
Posts: 6
Joined: Tue Nov 06, 2012 7:22 am
Operating System: Please select

How do i add a click event handler to a button

Post by murtaza19 » Fri Nov 09, 2012 5:46 am

How do i add a click event handler to a button, which i am adding using this command

wxDialog dlg(this, wxID_ANY, wxString(_("Image Display Settings")));

ShuttleGui S(&dlg, eIsCreating);


wxButton *btnBrowse;

btnBrowse = S.AddButton(_("Select Directory..."),false);

Any help will be great and if i need to post a new question plz let me know as well.

Thanks

Edgar
Forum Crew
Posts: 2043
Joined: Thu Sep 03, 2009 9:13 pm
Operating System: Windows 10

Re: How do i add a click event handler to a button

Post by Edgar » Fri Nov 09, 2012 7:17 pm

Not really enough info for me to help you. What I would suggest is that you either create a patch against SVN HEAD and paste it into a code block here; or post the affected files (in a code block here). Try to limit your changes to just enough to show what you are working on. Post mock-ups of GUI changes--it makes it easier to see what you are doing. Try to tell us more about what you are trying to do with the button and handler.

I think adding an event handler to a button will require some knowledge of wxWidgets.

Post Reply