git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@52378
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
// because the code must use Objective-C features.
return wxCocoaLaunchDefaultBrowser(url, flags);
#elif defined(__WXMAC__)
// because the code must use Objective-C features.
return wxCocoaLaunchDefaultBrowser(url, flags);
#elif defined(__WXMAC__)
- OSStatus err;
- ICInstance inst;
- long int startSel;
- long int endSel;
+ wxCFRef< CFURLRef > curl( CFURLCreateWithString( kCFAllocatorDefault,
+ wxCFStringRef( url ), NULL ) );
+ OSStatus err = LSOpenCFURLRef( curl , NULL );
- err = ICStart(&inst, 'STKA'); // put your app creator code here
- if (err == noErr)
- {
- ConstStr255Param hint = 0;
- startSel = 0;
- endSel = url.length();
- err = ICLaunchURL(inst, hint, url.fn_str(), endSel, &startSel, &endSel);
- if (err != noErr)
- wxLogDebug(wxT("ICLaunchURL error %d"), (int) err);
- }
- ICStop(inst);
- wxLogDebug(wxT("ICStart error %d"), (int) err);
+ wxLogDebug(wxT("Browser Launch error %d"), (int) err);