Don't crash under XP in the taskbar button sample.

Refuse to run if the taskbar button API is not available.

This wouldn't make much sense anyhow and is the simplest thing to do.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77703 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin 2014-09-14 23:58:14 +00:00
parent 938f19b739
commit 4c1a2a51ef

View File

@ -193,6 +193,12 @@ bool MyApp::OnInit()
}
MyFrame *frame = new MyFrame("wxTaskBarButton App");
if ( !frame->MSWGetTaskBarButton() )
{
wxLogError("Task bar button API is not available on this system, sorry.");
return false;
}
frame->Show(true);
return true;