mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-06 14:16:32 +02:00
Fix crash on Sparkle update when binary is replaced.
This commit is contained in:
@@ -22,6 +22,7 @@
|
|||||||
#include "macshortcuthandler.h"
|
#include "macshortcuthandler.h"
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
#include "tomahawkwindow.h"
|
#include "tomahawkwindow.h"
|
||||||
|
#include "audio/audioengine.h"
|
||||||
|
|
||||||
#import <AppKit/NSApplication.h>
|
#import <AppKit/NSApplication.h>
|
||||||
#import <Foundation/NSAutoreleasePool.h>
|
#import <Foundation/NSAutoreleasePool.h>
|
||||||
@@ -54,6 +55,9 @@
|
|||||||
|
|
||||||
- (Tomahawk::PlatformInterface*) application_handler;
|
- (Tomahawk::PlatformInterface*) application_handler;
|
||||||
- (void) setApplicationHandler: (Tomahawk::PlatformInterface*)handler;
|
- (void) setApplicationHandler: (Tomahawk::PlatformInterface*)handler;
|
||||||
|
|
||||||
|
// SUUpdaterDelegate
|
||||||
|
- (void)updater:(SUUpdater *)updater willInstallUpdate:(SUAppcastItem *)update;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
|
||||||
@@ -205,6 +209,13 @@
|
|||||||
[super sendEvent: event];
|
[super sendEvent: event];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (void)updater:(SUUpdater *)updater willInstallUpdate:(SUAppcastItem *)update
|
||||||
|
{
|
||||||
|
tLog() << "NSApp in willInstallUpdate, deleting Phonon objects";
|
||||||
|
AudioEngine::instance()->stop();
|
||||||
|
delete AudioEngine::instance();
|
||||||
|
}
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
void Tomahawk::macMain() {
|
void Tomahawk::macMain() {
|
||||||
|
Reference in New Issue
Block a user