Camino only - Bug 505601: Remove SharedMenusCocoa source from the tree. sr=pink
git-svn-id: svn://10.0.0.236/branches/CAMINO_2_0_BRANCH@257766 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
Binary file not shown.
@@ -1,24 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>English</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>SharedMenusCocoa</string>
|
||||
<key>CFBundleIconFile</key>
|
||||
<string></string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string></string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>FMWK</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>0.0.3</string>
|
||||
<key>NSPrincipalClass</key>
|
||||
<string></string>
|
||||
</dict>
|
||||
</plist>
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,145 +0,0 @@
|
||||
/*
|
||||
Copyright (c) 1991-2000 UserLand Software, Inc.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a
|
||||
copy of this software and associated documentation files (the
|
||||
"Software"), to deal in the Software without restriction, including
|
||||
without limitation the rights to use, copy, modify, merge, publish,
|
||||
distribute, sublicense, and/or sell copies of the Software, and to
|
||||
permit persons to whom the Software is furnished to do so, subject to the
|
||||
following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
||||
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
||||
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
||||
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef __APPLEEVENTS__
|
||||
|
||||
#include <AppleEvents.h>
|
||||
|
||||
#endif
|
||||
|
||||
#ifndef __COMPONENTS__
|
||||
|
||||
#include <Components.h> /*3.0*/
|
||||
|
||||
#endif
|
||||
|
||||
#ifndef __MENUS__
|
||||
|
||||
#include <Menus.h> /*3.0*/
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
#define __MENUSHARING__ /*so other modules can tell that we've been included*/
|
||||
|
||||
// RMS 960614
|
||||
#if !TARGET_API_MAC_CARBON
|
||||
#if PRAGMA_ALIGN_SUPPORTED
|
||||
#pragma options align=mac68k
|
||||
#endif //PRAGMA_ALIGN_SUPPORTED
|
||||
#endif //TARGET_API_MAC_CARBON
|
||||
|
||||
typedef struct tysharedmenurecord { /*must match scripting system record structure*/
|
||||
|
||||
short idmenu; /*the resource id of the menu*/
|
||||
|
||||
short flhierarchic: 1; /*if true it's a hiearchic menu*/
|
||||
|
||||
short flinserted: 1; /*if true the menu has been inserted in the menu bar*/
|
||||
|
||||
MenuHandle hmenu; /*a handle to the Mac Menu Manager's data structure*/
|
||||
} tysharedmenurecord;
|
||||
|
||||
|
||||
typedef tysharedmenurecord tymenuarray [1];
|
||||
|
||||
typedef tymenuarray **hdlmenuarray;
|
||||
|
||||
typedef pascal void (*tyMSerrordialog) (Str255);
|
||||
|
||||
typedef pascal void (*tyMSeventfilter) (EventRecord *);
|
||||
|
||||
typedef pascal void (*tyMSmenusinstaller) (hdlmenuarray);
|
||||
|
||||
|
||||
|
||||
typedef struct tyMSglobals { /*Menu Sharing globals, all in one struct*/
|
||||
|
||||
OSType serverid; /*identifier for shared menu server*/
|
||||
|
||||
OSType clientid; /*id of this application*/
|
||||
|
||||
hdlmenuarray hsharedmenus; /*data structure that holds shared menus*/
|
||||
|
||||
Boolean fldirtysharedmenus; /*if true, menus are reloaded next time app comes to front*/
|
||||
|
||||
Boolean flscriptcancelled; /*set true by calling CancelSharedScript*/
|
||||
|
||||
Boolean flscriptrunning; /*true if a script is currently running*/
|
||||
|
||||
Boolean flinitialized; /*true if InitSharedMenus was successful*/
|
||||
|
||||
long idscript; /*the server's id for the currently running script, makes it easy to kill it*/
|
||||
|
||||
ComponentInstance menuserver; /*3.0*/
|
||||
|
||||
long serverversion; /*4.1*/
|
||||
|
||||
tyMSerrordialog scripterrorcallback; /*3.0*/
|
||||
|
||||
tyMSeventfilter eventfiltercallback; /*3.0*/
|
||||
|
||||
tyMSmenusinstaller menusinsertercallback; /*4.1*/
|
||||
|
||||
tyMSmenusinstaller menusremovercallback; /*4.1*/
|
||||
} tyMSglobals;
|
||||
|
||||
|
||||
extern tyMSglobals MSglobals; /*menu sharing globals*/
|
||||
|
||||
|
||||
/*basic Menu Sharing routines*/
|
||||
|
||||
pascal Boolean InitSharedMenus (tyMSerrordialog, tyMSeventfilter);
|
||||
|
||||
pascal Boolean SharedMenuHit (short, short);
|
||||
|
||||
pascal Boolean SharedScriptRunning (void);
|
||||
|
||||
pascal Boolean CancelSharedScript (void);
|
||||
|
||||
pascal Boolean CheckSharedMenus (short);
|
||||
|
||||
pascal Boolean SharedScriptCancelled (AppleEvent *, AppleEvent *);
|
||||
|
||||
|
||||
/*special-purpose routines*/
|
||||
|
||||
pascal Boolean DisposeSharedMenus (void);
|
||||
|
||||
pascal Boolean IsSharedMenu (short);
|
||||
|
||||
pascal Boolean EnableSharedMenus (Boolean);
|
||||
|
||||
pascal Boolean RunSharedMenuItem (short, short);
|
||||
|
||||
pascal Boolean SetMenusInserterCallback (tyMSmenusinstaller);
|
||||
|
||||
pascal Boolean SetMenusRemoverCallback (tyMSmenusinstaller);
|
||||
|
||||
// RMS 960614
|
||||
#if !TARGET_API_MAC_CARBON
|
||||
#if PRAGMA_ALIGN_SUPPORTED
|
||||
#pragma options align=reset
|
||||
#endif //PRAGMA_ALIGN_SUPPORTED
|
||||
#endif //TARGET_API_MAC_CARBON
|
||||
@@ -1,34 +0,0 @@
|
||||
SharedMenusCocoa provides menu sharing for integration with URL Manager Pro.
|
||||
It is available under an MIT license. The contents of this directory,
|
||||
excluding this README, come from the source of the SharedMenusCocoa framework:
|
||||
|
||||
ftp://ftp.url-manager.com/pub/SharedMenusCocoa.dmg.bin
|
||||
|
||||
The source was downloaded on 2008-01-24, at which time SharedMenusCocoa.dmg.bin
|
||||
had a modification date of 2003-01-23. Everything included from that disk
|
||||
image is included here, except:
|
||||
- The "build" directory has been omitted. In the disk image, the "build"
|
||||
directory contained a prebuilt framework for PowerPC.
|
||||
- The Project Builder-based SharedMenusCocoa.pbproj project has been
|
||||
upgraded to an Xcode-based SharedMenusCocoa.xcodeproj project. This was
|
||||
done to allow the use of a native Xcode target, for which Xcode provides
|
||||
superior support. Within the project:
|
||||
+ The legacy jam-based SharedMenusCocoa target has been upgraded
|
||||
to an Xcode-based native framework target. The legacy target has
|
||||
been removed and the upgraded target has been renamed appropriately.
|
||||
The accompanying Info.plist generated by the upgrade process is also
|
||||
included, renamed from the ugly name given by the upgrade process. It
|
||||
is placed in the Resouces source group in the project.
|
||||
+ The unnecessary Default build configuration created by the upgrade has
|
||||
been removed.
|
||||
+ The empty Build Resource Manager Resources phase has been deleted.
|
||||
+ The following build settings were deleted, as the defaults are suitable:
|
||||
OTHER_LDFLAGS SECTORDER_FLAGS ZERO_LINK FRAMEWORK_VERSION
|
||||
WRAPPER_EXTENSION FRAMEWORK_SEARCH_PATHS HEADER_SEARCH_PATHS
|
||||
LIBRARY_SEARCH_PATHS GCC_GENERATE_DEBUGGING_SYMBOLS GCC_DYNAMIC_NO_PIC
|
||||
GCC_SYMBOLS_PRIVATE_EXTERN OTHER_CFLAGS
|
||||
+ In the Deployment target, the setting for GCC_ENABLE_FIX_AND_CONTINUE
|
||||
has been deleted, as the default is suitable.
|
||||
+ INFOPLIST_FILE has been set properly.
|
||||
+ PREBINDING has been turned off, as it is no longer desirable.
|
||||
+ DEBUG_INFORMATION_FORMAT has been set to dwarf-with-dsym for Deployment (and GCC_ENABLE_SYMBOL_SEPARATION set to NO).
|
||||
@@ -1,283 +0,0 @@
|
||||
// !$*UTF8*$!
|
||||
{
|
||||
archiveVersion = 1;
|
||||
classes = {
|
||||
};
|
||||
objectVersion = 42;
|
||||
objects = {
|
||||
|
||||
/* Begin PBXBuildFile section */
|
||||
7B0B54DF0D4A459E003BC853 /* SharedMenusObj.h in Headers */ = {isa = PBXBuildFile; fileRef = F5AD4DF30341B12B01A80002 /* SharedMenusObj.h */; settings = {ATTRIBUTES = (Public, ); }; };
|
||||
7B0B54E00D4A459E003BC853 /* MenuSharing.h in Headers */ = {isa = PBXBuildFile; fileRef = F5AD4DF70341B14B01A80002 /* MenuSharing.h */; settings = {ATTRIBUTES = (Public, ); }; };
|
||||
7B0B54E20D4A459E003BC853 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C1666FE841158C02AAC07 /* InfoPlist.strings */; };
|
||||
7B0B54E40D4A459E003BC853 /* SharedMenusObj.m in Sources */ = {isa = PBXBuildFile; fileRef = F5AD4DF50341B13401A80002 /* SharedMenusObj.m */; };
|
||||
7B0B54E50D4A459E003BC853 /* MenuSharing.c in Sources */ = {isa = PBXBuildFile; fileRef = F5AD4DF90341B15601A80002 /* MenuSharing.c */; };
|
||||
7B0B54E70D4A459E003BC853 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7B1FEA5585E11CA2CBB /* Cocoa.framework */; };
|
||||
7B0B54E80D4A459E003BC853 /* Carbon.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F5ACCBD4033DF40901A80002 /* Carbon.framework */; };
|
||||
/* End PBXBuildFile section */
|
||||
|
||||
/* Begin PBXFileReference section */
|
||||
0867D69BFE84028FC02AAC07 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = "<absolute>"; };
|
||||
0867D6A5FE840307C02AAC07 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = "<absolute>"; };
|
||||
089C1667FE841158C02AAC07 /* English */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = English; path = English.lproj/InfoPlist.strings; sourceTree = "<group>"; };
|
||||
1058C7B1FEA5585E11CA2CBB /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = /System/Library/Frameworks/Cocoa.framework; sourceTree = "<absolute>"; };
|
||||
7B0B54EE0D4A459E003BC853 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
|
||||
7B0B54EF0D4A459E003BC853 /* SharedMenusCocoa.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = SharedMenusCocoa.framework; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
F5ACCBD4033DF40901A80002 /* Carbon.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Carbon.framework; path = /System/Library/Frameworks/Carbon.framework; sourceTree = "<absolute>"; };
|
||||
F5AD4DF30341B12B01A80002 /* SharedMenusObj.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SharedMenusObj.h; sourceTree = "<group>"; };
|
||||
F5AD4DF50341B13401A80002 /* SharedMenusObj.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SharedMenusObj.m; sourceTree = "<group>"; };
|
||||
F5AD4DF70341B14B01A80002 /* MenuSharing.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MenuSharing.h; sourceTree = "<group>"; };
|
||||
F5AD4DF90341B15601A80002 /* MenuSharing.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = MenuSharing.c; sourceTree = "<group>"; };
|
||||
/* End PBXFileReference section */
|
||||
|
||||
/* Begin PBXFrameworksBuildPhase section */
|
||||
7B0B54E60D4A459E003BC853 /* Frameworks */ = {
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
7B0B54E70D4A459E003BC853 /* Cocoa.framework in Frameworks */,
|
||||
7B0B54E80D4A459E003BC853 /* Carbon.framework in Frameworks */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXFrameworksBuildPhase section */
|
||||
|
||||
/* Begin PBXGroup section */
|
||||
034768DFFF38A50411DB9C8B /* Products */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
7B0B54EF0D4A459E003BC853 /* SharedMenusCocoa.framework */,
|
||||
);
|
||||
name = Products;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
0867D691FE84028FC02AAC07 /* SharedMenusCocoa */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
08FB77AEFE84172EC02AAC07 /* Classes */,
|
||||
F5ACCBCF033DF33101A80002 /* Sources */,
|
||||
089C1665FE841158C02AAC07 /* Resources */,
|
||||
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */,
|
||||
034768DFFF38A50411DB9C8B /* Products */,
|
||||
);
|
||||
name = SharedMenusCocoa;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
1058C7B0FEA5585E11CA2CBB /* Linked Frameworks */,
|
||||
1058C7B2FEA5585E11CA2CBB /* Other Frameworks */,
|
||||
);
|
||||
name = "External Frameworks and Libraries";
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
089C1665FE841158C02AAC07 /* Resources */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
7B0B54EE0D4A459E003BC853 /* Info.plist */,
|
||||
089C1666FE841158C02AAC07 /* InfoPlist.strings */,
|
||||
);
|
||||
name = Resources;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
08FB77AEFE84172EC02AAC07 /* Classes */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
F5AD4DF30341B12B01A80002 /* SharedMenusObj.h */,
|
||||
F5AD4DF50341B13401A80002 /* SharedMenusObj.m */,
|
||||
);
|
||||
name = Classes;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
1058C7B0FEA5585E11CA2CBB /* Linked Frameworks */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
1058C7B1FEA5585E11CA2CBB /* Cocoa.framework */,
|
||||
F5ACCBD4033DF40901A80002 /* Carbon.framework */,
|
||||
);
|
||||
name = "Linked Frameworks";
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
1058C7B2FEA5585E11CA2CBB /* Other Frameworks */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
0867D69BFE84028FC02AAC07 /* Foundation.framework */,
|
||||
0867D6A5FE840307C02AAC07 /* AppKit.framework */,
|
||||
);
|
||||
name = "Other Frameworks";
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
F5ACCBCF033DF33101A80002 /* Sources */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
F5AD4DF70341B14B01A80002 /* MenuSharing.h */,
|
||||
F5AD4DF90341B15601A80002 /* MenuSharing.c */,
|
||||
);
|
||||
name = Sources;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
/* End PBXGroup section */
|
||||
|
||||
/* Begin PBXHeadersBuildPhase section */
|
||||
7B0B54DE0D4A459E003BC853 /* Headers */ = {
|
||||
isa = PBXHeadersBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
7B0B54DF0D4A459E003BC853 /* SharedMenusObj.h in Headers */,
|
||||
7B0B54E00D4A459E003BC853 /* MenuSharing.h in Headers */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXHeadersBuildPhase section */
|
||||
|
||||
/* Begin PBXNativeTarget section */
|
||||
7B0B54DD0D4A459E003BC853 /* SharedMenusCocoa */ = {
|
||||
isa = PBXNativeTarget;
|
||||
buildConfigurationList = 7B0B54EA0D4A459E003BC853 /* Build configuration list for PBXNativeTarget "SharedMenusCocoa" */;
|
||||
buildPhases = (
|
||||
7B0B54DE0D4A459E003BC853 /* Headers */,
|
||||
7B0B54E10D4A459E003BC853 /* Resources */,
|
||||
7B0B54E30D4A459E003BC853 /* Sources */,
|
||||
7B0B54E60D4A459E003BC853 /* Frameworks */,
|
||||
);
|
||||
buildRules = (
|
||||
);
|
||||
dependencies = (
|
||||
);
|
||||
name = SharedMenusCocoa;
|
||||
productInstallPath = "$(HOME)/Library/Frameworks";
|
||||
productName = SharedMenusCocoa;
|
||||
productReference = 7B0B54EF0D4A459E003BC853 /* SharedMenusCocoa.framework */;
|
||||
productType = "com.apple.product-type.framework";
|
||||
};
|
||||
/* End PBXNativeTarget section */
|
||||
|
||||
/* Begin PBXProject section */
|
||||
0867D690FE84028FC02AAC07 /* Project object */ = {
|
||||
isa = PBXProject;
|
||||
buildConfigurationList = 7B0B54D60D4A4574003BC853 /* Build configuration list for PBXProject "SharedMenusCocoa" */;
|
||||
compatibilityVersion = "Xcode 2.4";
|
||||
hasScannedForEncodings = 0;
|
||||
mainGroup = 0867D691FE84028FC02AAC07 /* SharedMenusCocoa */;
|
||||
productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
|
||||
projectDirPath = "";
|
||||
projectRoot = "";
|
||||
targets = (
|
||||
7B0B54DD0D4A459E003BC853 /* SharedMenusCocoa */,
|
||||
);
|
||||
};
|
||||
/* End PBXProject section */
|
||||
|
||||
/* Begin PBXResourcesBuildPhase section */
|
||||
7B0B54E10D4A459E003BC853 /* Resources */ = {
|
||||
isa = PBXResourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
7B0B54E20D4A459E003BC853 /* InfoPlist.strings in Resources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXResourcesBuildPhase section */
|
||||
|
||||
/* Begin PBXSourcesBuildPhase section */
|
||||
7B0B54E30D4A459E003BC853 /* Sources */ = {
|
||||
isa = PBXSourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
7B0B54E40D4A459E003BC853 /* SharedMenusObj.m in Sources */,
|
||||
7B0B54E50D4A459E003BC853 /* MenuSharing.c in Sources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXSourcesBuildPhase section */
|
||||
|
||||
/* Begin PBXVariantGroup section */
|
||||
089C1666FE841158C02AAC07 /* InfoPlist.strings */ = {
|
||||
isa = PBXVariantGroup;
|
||||
children = (
|
||||
089C1667FE841158C02AAC07 /* English */,
|
||||
);
|
||||
name = InfoPlist.strings;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
/* End PBXVariantGroup section */
|
||||
|
||||
/* Begin XCBuildConfiguration section */
|
||||
7B0B54D00D4A4573003BC853 /* Development */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
};
|
||||
name = Development;
|
||||
};
|
||||
7B0B54D10D4A4573003BC853 /* Deployment */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
};
|
||||
name = Deployment;
|
||||
};
|
||||
7B0B54EB0D4A459E003BC853 /* Development */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
COPY_PHASE_STRIP = NO;
|
||||
DYLIB_COMPATIBILITY_VERSION = 1;
|
||||
DYLIB_CURRENT_VERSION = 1;
|
||||
GCC_ENABLE_FIX_AND_CONTINUE = YES;
|
||||
GCC_OPTIMIZATION_LEVEL = 0;
|
||||
INFOPLIST_FILE = Info.plist;
|
||||
INSTALL_PATH = "@executable_path/../Frameworks";
|
||||
PREBINDING = NO;
|
||||
PRODUCT_NAME = SharedMenusCocoa;
|
||||
WARNING_CFLAGS = (
|
||||
"-Wmost",
|
||||
"-Wno-four-char-constants",
|
||||
"-Wno-unknown-pragmas",
|
||||
);
|
||||
};
|
||||
name = Development;
|
||||
};
|
||||
7B0B54EC0D4A459E003BC853 /* Deployment */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
COPY_PHASE_STRIP = YES;
|
||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
||||
DYLIB_COMPATIBILITY_VERSION = 1;
|
||||
DYLIB_CURRENT_VERSION = 1;
|
||||
GCC_ENABLE_SYMBOL_SEPARATION = NO;
|
||||
INFOPLIST_FILE = Info.plist;
|
||||
INSTALL_PATH = "@executable_path/../Frameworks";
|
||||
PREBINDING = NO;
|
||||
PRODUCT_NAME = SharedMenusCocoa;
|
||||
WARNING_CFLAGS = (
|
||||
"-Wmost",
|
||||
"-Wno-four-char-constants",
|
||||
"-Wno-unknown-pragmas",
|
||||
);
|
||||
};
|
||||
name = Deployment;
|
||||
};
|
||||
/* End XCBuildConfiguration section */
|
||||
|
||||
/* Begin XCConfigurationList section */
|
||||
7B0B54D60D4A4574003BC853 /* Build configuration list for PBXProject "SharedMenusCocoa" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
7B0B54D00D4A4573003BC853 /* Development */,
|
||||
7B0B54D10D4A4573003BC853 /* Deployment */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Development;
|
||||
};
|
||||
7B0B54EA0D4A459E003BC853 /* Build configuration list for PBXNativeTarget "SharedMenusCocoa" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
7B0B54EB0D4A459E003BC853 /* Development */,
|
||||
7B0B54EC0D4A459E003BC853 /* Deployment */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Development;
|
||||
};
|
||||
/* End XCConfigurationList section */
|
||||
};
|
||||
rootObject = 0867D690FE84028FC02AAC07 /* Project object */;
|
||||
}
|
||||
@@ -1,64 +0,0 @@
|
||||
/* SharedMenusObj */
|
||||
|
||||
/* More Info - please contact Alco Blom at : alco@url-manager.com */
|
||||
|
||||
/* Object to use to support Shared Menus in Cocoa applications
|
||||
|
||||
makes use of source code Copyright (c) 1991-2000 UserLand Software, Inc.,
|
||||
see included file 'MenuSharing.h'
|
||||
|
||||
Description:
|
||||
this object makes your application a Menu Sharing Client
|
||||
|
||||
How to use in your code:
|
||||
on application launch time:
|
||||
sharedMenusObj = [[SharedMenusObj alloc] init];
|
||||
|
||||
on application quit time:
|
||||
[sharedMenusObj dealloc];
|
||||
|
||||
Note:
|
||||
when no Menu Server is present in the user's system, this object
|
||||
does essentially nothing.
|
||||
|
||||
How to use in your project:
|
||||
a) add the SharedMenusCocoa.framework to your project
|
||||
b) make sure you add the framework to the Copy Files section
|
||||
(in the end the framework should be in your bundle in /Contents/Frameworks)
|
||||
c) BTW: the SharedMenusCocoa.framework is in the build folder of this project
|
||||
|
||||
Pitfalls:
|
||||
the SharedMenusObj install a Carbon Event Handler for:
|
||||
|
||||
EventTypeSpec commandSpec = {kEventClassCommand, kEventCommandProcess};
|
||||
|
||||
if your application already has an event handler installed for this
|
||||
event type, you can still use SharedMenus, but you need to adapt
|
||||
this source code. In that case, you must not install the Carbon event
|
||||
handler in SharedMenusObj and just act on command ID == 'SHMN'
|
||||
in your event handler and call SharedMenuHit right there;
|
||||
|
||||
Extra:
|
||||
if you have the time, it would be nice to have a preference in your
|
||||
application named 'At Startup Disable Shared Menus'. Default should be: OFF.
|
||||
when it is ON, however, you should not create the sharedMenusObj.
|
||||
|
||||
FTP: source of project (a ProjectBuilder project):
|
||||
ftp://ftp.url-manager.com/pub/SharedMenusCocoa.sit.bin
|
||||
|
||||
*/
|
||||
|
||||
#import <Cocoa/Cocoa.h>
|
||||
|
||||
@interface SharedMenusObj : NSObject
|
||||
{
|
||||
NSTimer *timer;
|
||||
BOOL existsMenuServer;
|
||||
BOOL installedCommandHandler;
|
||||
}
|
||||
- (void)myStartSharedMenusTimer;
|
||||
- (void)myStopSharedMenusTimer;
|
||||
- (void)myCheckSharedMenus:(id)sender;
|
||||
- (void)myInitSharedMenus;
|
||||
- (void)myDisposeSharedMenus;
|
||||
@end
|
||||
@@ -1,88 +0,0 @@
|
||||
#import "SharedMenusObj.h"
|
||||
|
||||
extern pascal Boolean CheckSharedMenus (short);
|
||||
extern pascal Boolean InitSharedMenusSimple (void);
|
||||
extern pascal Boolean DisposeSharedMenus (void);
|
||||
|
||||
extern OSStatus InstallCarbonSharedMenusHandler();
|
||||
extern void RemoveCarbonSharedMenusHandler();
|
||||
|
||||
@implementation SharedMenusObj
|
||||
|
||||
/*
|
||||
GetWebPageName is a utility function to get the window title of
|
||||
the front browser window. It is used by the Add Bookmark dialog
|
||||
of URL Manager Pro
|
||||
*/
|
||||
|
||||
NSString* GetWebPageName() {
|
||||
NSWindow* windowRef = [NSApp mainWindow];
|
||||
if (windowRef != nil) {
|
||||
return [windowRef title];
|
||||
}
|
||||
|
||||
return nil;
|
||||
}
|
||||
|
||||
-(id)init
|
||||
{
|
||||
if (self = [super init]) {
|
||||
|
||||
existsMenuServer = NO;
|
||||
installedCommandHandler = NO;
|
||||
|
||||
[self myInitSharedMenus];
|
||||
|
||||
if (existsMenuServer)
|
||||
[self myStartSharedMenusTimer];
|
||||
|
||||
}
|
||||
return self;
|
||||
}
|
||||
|
||||
- (void)myInitSharedMenus
|
||||
{
|
||||
existsMenuServer = InitSharedMenusSimple();
|
||||
}
|
||||
|
||||
- (void)myStartSharedMenusTimer
|
||||
{
|
||||
OSStatus err;
|
||||
|
||||
timer = [[NSTimer scheduledTimerWithTimeInterval:1 target:self selector:@selector(myCheckSharedMenus:)
|
||||
userInfo:nil repeats:YES] retain];
|
||||
|
||||
err = InstallCarbonSharedMenusHandler();
|
||||
if (err == noErr)
|
||||
installedCommandHandler = YES;
|
||||
}
|
||||
|
||||
- (void)myStopSharedMenusTimer
|
||||
{
|
||||
if (installedCommandHandler)
|
||||
RemoveCarbonSharedMenusHandler();
|
||||
|
||||
[timer invalidate];
|
||||
[timer release];
|
||||
}
|
||||
|
||||
- (void)myCheckSharedMenus:(id)sender
|
||||
{
|
||||
CheckSharedMenus (0);
|
||||
}
|
||||
|
||||
- (void)myDisposeSharedMenus
|
||||
{
|
||||
DisposeSharedMenus();
|
||||
}
|
||||
|
||||
- (void)dealloc
|
||||
{
|
||||
if (existsMenuServer) {
|
||||
[self myStopSharedMenusTimer];
|
||||
[self myDisposeSharedMenus];
|
||||
}
|
||||
|
||||
[super dealloc];
|
||||
}
|
||||
@end
|
||||
Reference in New Issue
Block a user