private void OnCommand(object o)
{
switch (o as MenuCommand?)
{
case MenuCommand.ShowSequences:
m_sequencewindow = m_sequencewindow ?? new SequenceWindow();
m_sequencewindow.Show();
m_sequencewindow.Activate();
break;
case MenuCommand.ShowOptions:
m_optionswindow = m_optionswindow ?? new SettingsWindow();
m_optionswindow.Show();
m_optionswindow.Activate();
break;
case MenuCommand.DebugWindow:
m_debugwindow = m_debugwindow ?? new DebugWindow();
m_debugwindow.Show();
m_debugwindow.Activate();
break;
case MenuCommand.About:
m_about_box = m_about_box ?? new AboutBox();
m_about_box.Show();
m_about_box.Activate();
break;
case MenuCommand.Download:
var url = Utils.IsInstalled ? Updater.Get("Installer")
: Updater.Get("Portable");
Process.Start(url);
break;
case MenuCommand.VisitWebsite:
Process.Start("http://wincompose.info/");
break;
case MenuCommand.DonationPage:
Process.Start("http://wincompose.info/donate/");
break;
case MenuCommand.Exit:
Application.Current.Shutdown();
break;
}
}