fixed build and crash in YACReader MacOSX

This commit is contained in:
Luis Ángel San Martín
2014-11-06 19:22:34 +01:00
parent 877f68fd98
commit dd8a1eb417
2 changed files with 4 additions and 1 deletions

View File

@ -162,6 +162,7 @@ YACReaderMacOSXToolbar::YACReaderMacOSXToolbar(QObject *parent)
((MyToolbarDelegate *)delegate)->mytoolbar = this;
[nativeToolBar setDelegate:(MyToolbarDelegate *)delegate];
#ifdef YACREADER_LIBRARY
NSWindow *nswindow = (NSWindow*) qApp->platformNativeInterface()->nativeResourceForWindow("nswindow", ((QMainWindow*)parent)->windowHandle());
if([nswindow respondsToSelector:@selector(setTitleVisibility:)])
{
@ -169,6 +170,8 @@ YACReaderMacOSXToolbar::YACReaderMacOSXToolbar(QObject *parent)
[nswindow setTitleVisibility:1];
}else
yosemite = false;
#endif
yosemite = false;
}
void YACReaderMacOSXToolbar::addAction(QAction *action)