• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
accelerometer puzzle
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

accelerometer puzzle


  • Subject: accelerometer puzzle
  • From: David Rowland <email@hidden>
  • Date: Mon, 29 Nov 2010 12:31:14 -0800

I have a class defined like this,


@interface GAppDelegate : NSObject <UIApplicationDelegate, UIAccelerometerDelegate > {



and inside that class I have implemented this,

// UIAccelerometerDelegate method, called when the device accelerates.
- (void)accelerometer:(UIAccelerometer *)accelerometer didAccelerate:(UIAcceleration *)acceleration;


When I build, I get a warning,

 type 'id <UIApplicationDelegate>' does not conform to the 'UIAccelerometerDelegate' protocol


Yet in running, the method is called and behaves as it should. It is the only method in the protocol, and it's optional. How could I fail to conform to the protocol?


David

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: accelerometer puzzle
      • From: David Duncan <email@hidden>
  • Prev by Date: Re: Foundation vs Core Foundation
  • Next by Date: Re: accelerometer puzzle
  • Previous by thread: Re: Foundation vs Core Foundation
  • Next by thread: Re: accelerometer puzzle
  • Index(es):
    • Date
    • Thread