Rerun scripts weren't working for script menu items
parent
d7dc7f19d1
commit
89065a4005
|
@ -7,9 +7,8 @@
|
|||
//
|
||||
|
||||
#import "ScriptsController.h"
|
||||
#import "CelestiaAppCore.h"
|
||||
#import "CelestiaController.h"
|
||||
#import "NSString_ObjCPlusPlus.h"
|
||||
#import "celestiacore.h"
|
||||
#import "scriptmenu.h"
|
||||
|
||||
#define CEL_SCRIPTS_FOLDER @"scripts"
|
||||
|
@ -104,11 +103,11 @@
|
|||
{
|
||||
if (aSender && [aSender respondsToSelector: @selector(representedObject)])
|
||||
{
|
||||
CelestiaCore *appCore = (CelestiaCore*) [[CelestiaAppCore sharedAppCore] appCore];
|
||||
CelestiaController *controller = [CelestiaController shared];
|
||||
id filename = [aSender representedObject];
|
||||
if (filename)
|
||||
{
|
||||
appCore->runScript([(NSString *)filename stdString]);
|
||||
[controller runScript: filename];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue