mirror of
https://github.com/macvim-dev/macvim.git
synced 2026-06-11 15:37:29 +02:00
Explicitly take the address of potentially-missing weak-linked functions.
This commit is contained in:
@@ -2076,7 +2076,7 @@ fsEventCallback(ConstFSEventStreamRef streamRef,
|
||||
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
|
||||
if (fsEventStream)
|
||||
return;
|
||||
if (NULL == FSEventStreamStart)
|
||||
if (NULL == &FSEventStreamStart)
|
||||
return; // FSEvent functions are weakly linked
|
||||
|
||||
NSString *path = [@"~/.vim" stringByExpandingTildeInPath];
|
||||
@@ -2098,7 +2098,7 @@ fsEventCallback(ConstFSEventStreamRef streamRef,
|
||||
- (void)stopWatchingVimDir
|
||||
{
|
||||
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
|
||||
if (NULL == FSEventStreamStop)
|
||||
if (NULL == &FSEventStreamStop)
|
||||
return; // FSEvent functions are weakly linked
|
||||
|
||||
if (fsEventStream) {
|
||||
@@ -2489,7 +2489,7 @@ fsEventCallback(ConstFSEventStreamRef streamRef,
|
||||
{
|
||||
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
|
||||
// The TIS symbols are weakly linked.
|
||||
if (NULL != TISCopyCurrentKeyboardInputSource) {
|
||||
if (NULL != &TISCopyCurrentKeyboardInputSource) {
|
||||
// We get here when compiled on >=10.5 and running on >=10.5.
|
||||
|
||||
id nc = [NSDistributedNotificationCenter defaultCenter];
|
||||
@@ -2507,7 +2507,7 @@ fsEventCallback(ConstFSEventStreamRef streamRef,
|
||||
{
|
||||
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
|
||||
// The TIS symbols are weakly linked.
|
||||
if (NULL != TISCopyCurrentKeyboardInputSource) {
|
||||
if (NULL != &TISCopyCurrentKeyboardInputSource) {
|
||||
// We get here when compiled on >=10.5 and running on >=10.5.
|
||||
|
||||
id nc = [NSDistributedNotificationCenter defaultCenter];
|
||||
|
||||
@@ -130,7 +130,7 @@ KeyboardInputSourcesEqual(TISInputSourceRef a, TISInputSourceRef b)
|
||||
ASLogDebug(@"%@", event);
|
||||
|
||||
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
|
||||
if (NULL == TISCopyCurrentKeyboardInputSource) {
|
||||
if (NULL == &TISCopyCurrentKeyboardInputSource) {
|
||||
#endif
|
||||
|
||||
// NOTE: Check IM state _before_ key has been interpreted or we'll pick
|
||||
@@ -787,7 +787,7 @@ KeyboardInputSourcesEqual(TISInputSourceRef a, TISInputSourceRef b)
|
||||
|
||||
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
|
||||
// The TIS symbols are weakly linked.
|
||||
if (NULL != TISCopyCurrentKeyboardInputSource) {
|
||||
if (NULL != &TISCopyCurrentKeyboardInputSource) {
|
||||
// We get here when compiled on >=10.5 and running on >=10.5.
|
||||
|
||||
if (asciiImSource) {
|
||||
@@ -824,7 +824,7 @@ KeyboardInputSourcesEqual(TISInputSourceRef a, TISInputSourceRef b)
|
||||
|
||||
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
|
||||
// The TIS symbols are weakly linked.
|
||||
if (NULL != TISCopyCurrentKeyboardInputSource) {
|
||||
if (NULL != &TISCopyCurrentKeyboardInputSource) {
|
||||
// We get here when compiled on >=10.5 and running on >=10.5.
|
||||
|
||||
// Enable IM: switch back to input source used when IM was last on
|
||||
@@ -862,7 +862,7 @@ KeyboardInputSourcesEqual(TISInputSourceRef a, TISInputSourceRef b)
|
||||
- (void)checkImState
|
||||
{
|
||||
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
|
||||
if (imControl && NULL != TISCopyCurrentKeyboardInputSource) {
|
||||
if (imControl && NULL != &TISCopyCurrentKeyboardInputSource) {
|
||||
// We get here when compiled on >=10.5 and running on >=10.5.
|
||||
TISInputSourceRef cur = TISCopyCurrentKeyboardInputSource();
|
||||
BOOL state = !KeyboardInputSourcesEqual(asciiImSource, cur);
|
||||
|
||||
Reference in New Issue
Block a user