From 0e6b88f993e034f1e3083bf26f08bc1dfd5ccf2e Mon Sep 17 00:00:00 2001 From: Damien Plisson Date: Mon, 1 Feb 2010 09:11:18 +0000 Subject: Cocoa : implement opening .blend file by double-clicking on it in OSX Finder When the user double-clicks on a document file in the Finder, OSX doesn't simply give the filename as a command-line argument when calling Blender, as it is done in other OSes. Instead, it launches the app if needed, and then sends an "openFile" event. The user can also open a document file by dropping its icon on the app dock icon. But as this is not real Drag'n'drop, I've renamed the Ghost event to a less confusing "GHOST_kEventOpenMainFile" name. DND Ghost wiki page updated : http://wiki.blender.org/index.php/BlenderDev/Blender2.5/DragnDrop --- intern/ghost/GHOST_Types.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'intern/ghost/GHOST_Types.h') diff --git a/intern/ghost/GHOST_Types.h b/intern/ghost/GHOST_Types.h index 9bb8def00d0..ff60aaf9c03 100644 --- a/intern/ghost/GHOST_Types.h +++ b/intern/ghost/GHOST_Types.h @@ -173,7 +173,8 @@ typedef enum { GHOST_kEventDraggingUpdated, GHOST_kEventDraggingExited, GHOST_kEventDraggingDropDone, - GHOST_kEventDraggingDropOnIcon, + + GHOST_kEventOpenMainFile, // Needed for Cocoa to open double-clicked .blend file at startup GHOST_kEventTimer, -- cgit v1.2.3