10

ハーフページカール機能を実行しようとしています。これは私が使用しているコードです:

#import <QuartzCore/QuartzCore.h>


CATransition *animation = [CATransition animation];
[animation setDelegate:self];
[animation setDuration:1.0f];
[animation setTimingFunction:UIViewAnimationCurveEaseInOut];
[animation setType:(notCurled ? @"mapCurl" : @"mapUnCurl")];
[animation setRemovedOnCompletion:NO];
[animation setFillMode: @"extended"];
[animation setRemovedOnCompletion: NO];
notCurled = !notCurled;

しかし、次のエラーが発生します

Undefined symbols for architecture i386:
  "_OBJC_CLASS_$_CATransition", referenced from:
      objc-class-ref in MyMapViewController.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)


  "_OBJC_CLASS_$_CATransition", referenced from:


      objc-class-ref in SJMapViewController.o


ld: symbol(s) not found for architecture i386


clang: error: linker command failed with exit code 1 (use -v to see invocation)

どうすれば解決できますか?

4

1 に答える 1

23

アプリがCATransitionシンボルが見つからないと文句を言っています。

QuartzCoreフレームワークをアプリに追加しましたか?

追加しない場合:ターゲット設定->ビルドフェーズ->リンクバイナリ-> +ボタンを選択し、QuartzCoreを選択します。

次に、使用する必要がある場所にインポートします。

      #import <QuartzCore/QuartzCore.h>
于 2011-12-12T09:10:48.810 に答える