• 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
Re: One IBAction, multiple results from multiple methods
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: One IBAction, multiple results from multiple methods


  • Subject: Re: One IBAction, multiple results from multiple methods
  • From: "Paul Sanders" <email@hidden>
  • Date: Thu, 26 Feb 2009 16:24:42 -0000

>>> What IB should do, of course, is let you type in symbolic names for
>>> your
>>> tags and generate an include file containing a set of unique
>>> #defines.
>>> That's what I'm used to on a certain other OS, anyway.
>>
>>  Absolutely agree. File a request. :-)
>>
>> --
>> I.S.

> What you have there, if I'm not mistaken, then, is essentially the
> concept of a represented object that's a string, yes?

> Cheers,
> Andrew

No, it's an object (or, if you like, an action) represented by a symbol:

// Generated by IB
#define IDC_CUT      1
#define IDC_COPY     2
#define IDC_PASTE    3

// Coded by Joe Soap
switch (tag)
{
    case IDC_CUT:
        ...
    case IDC_COPY:
        ...
    case IDC_PASTE:
        ...
}

It frees you from worrying about what the numerical values actually are.  IB
should [be free to] assign those, although there might be issues if you want
values to be unique across more than one NIB (Visual Studio handles this by
allowing you to set a 'starting value', per resource file, e.g. 1000, 2000,
...).

_______________________________________________

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: One IBAction, multiple results from multiple methods
      • From: Graham Lee <email@hidden>
References: 
 >One IBAction, multiple results from multiple methods (From: Walker Argendeli <email@hidden>)
 >Re: One IBAction, multiple results from multiple methods (From: "I. Savant" <email@hidden>)
 >Re: One IBAction, multiple results from multiple methods (From: Klaus Backert <email@hidden>)
 >Re: One IBAction, multiple results from multiple methods (From: "I. Savant" <email@hidden>)
 >Re: One IBAction, multiple results from multiple methods (From: "Peter Ilberg" <email@hidden>)
 >Re: One IBAction, multiple results from multiple methods (From: "I. Savant" <email@hidden>)
 >Re: One IBAction, multiple results from multiple methods (From: "Paul Sanders" <email@hidden>)
 >Re: One IBAction, multiple results from multiple methods (From: "I. Savant" <email@hidden>)
 >Re: One IBAction, multiple results from multiple methods (From: Andrew Merenbach <email@hidden>)

  • Prev by Date: Re: One IBAction, multiple results from multiple methods
  • Next by Date: Re: One IBAction, multiple results from multiple methods
  • Previous by thread: Re: One IBAction, multiple results from multiple methods
  • Next by thread: Re: One IBAction, multiple results from multiple methods
  • Index(es):
    • Date
    • Thread