• 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
(hopefully) simple newb question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

(hopefully) simple newb question


  • Subject: (hopefully) simple newb question
  • From: Mike Abdullah <email@hidden>
  • Date: Wed, 18 Jan 2006 14:56:23 +0000

I keep getting a warning message in my code when I compile and I cannot see what I'm doing wrong! However, I'm sure it's fairly easy to solve (although I couldn't find anything when googling), so please forgive me if I've just been really, really stupid here.

I have a pretty standard document based app, although I have subclassed NSWindowController as well as NSDocument.

In my doc window, there is a popup button.

When an item is selected from that popup, the window controller does [[self document] setEventKind: [[sender selectedItem] tag]]. This should call the setEventKind: method in my NSDocument yes?

setEventKind is declared in the NSDocument like this:
- (void)setEventKind:(int)newEventKind

Now as far as I can see that is OK. setEventKind is called by my NSDocument whilst the document is first loading and it works fine, but when I try to call it from the window controller, I keep getting the compiler warning:

"passing argument 1 of setEventKind: makes pointer from integer without a cast"

Why is this a problem from the window controller, but not from the NSDocument?

Thanks,
Mike.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: (hopefully) simple newb question
      • From: Daniel Jalkut <email@hidden>
  • Prev by Date: Re: Bindings don't populate dialog fields?
  • Next by Date: Re: Prevent running in Rosetta
  • Previous by thread: Re: NSAttributedString - determine document type without loading?
  • Next by thread: Re: (hopefully) simple newb question
  • Index(es):
    • Date
    • Thread