Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
General
GeneralPortable MacsHardwareNetworking
Applications
Mac ApplicationsEudoraFirefox / MozillaInternet ExplorerOutlook ExpressMS OfficeEntourageExcelPowerPointWordVirtual PCMedia PlayerOther MS Products
Programming
Mac ProgrammingCodeWarriorPerl
Country Specific
Australian Mac GroupUK Mac Group

Mac Forum / Programming / Mac Programming / September 2005



Tip: Looking for answers? Try searching our database.

Navigation services popup menu

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Phil Taylor - 21 Sep 2005 21:09 GMT
I want to use NavPutFile in a Carbon port of an old program.  I know
it's obsolete, but I don't want the hassle of dealing with FsRefs and
CFStrings etc, and I don't care about Long/Unicode filenames.

The program originally used CustomPutFile, with a popup menu to select
which of 9 different file types to create.

Now I can see how to populate the popup menu in NavPutFile, but what I
can't see is how to retrieve the user's choice of filetype after the OK
button has been pressed.

Can anyone enlighten me?

Phil Taylor
Phil Taylor - 23 Sep 2005 10:48 GMT
> Now I can see how to populate the popup menu in NavPutFile, but what I
> can't see is how to retrieve the user's choice of filetype after the OK
> button has been pressed.

To answer my own question (in case anybody's interested), it's done in
the eventproc.  Look for a callBackSelector of type
kNavCBPopupMenuSelect.  Then look at the what and when fields of the
eventrecord obtained from
callBackParms^.eventData.eventDataParms.event^.  These contain the type
and creator OSTypes from the list which you supplied in the
popupExtension of NavDialogOptions.

Doncha just love Navigation Services?

Phil Taylor
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.