• 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: Disappearing accessory view
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Disappearing accessory view


  • Subject: Re: Disappearing accessory view
  • From: Michael McLaughlin <email@hidden>
  • Date: Wed, 17 May 2017 16:39:05 -0400

As was probably obvious to everyone but me, I discovered that I did not need to save the NSSavePanel even though it is required to change the filetype and extension.

The solution was to utilize the window in which the accessory panel is embedded.  That is, with sender as the radio button array in the accessory view,

- (IBAction)setSaveType:(id)sender
{
   NSSavePanel  *sp = (NSSavePanel*)[sender window];
   NSInteger col = [saveTypes selectedColumn];
   isPDF = (col == 0) ? YES : NO;
   
   NSString *fname = filename;
   if (isPDF)
      fname = [fname stringByAppendingString:@".pdf"];
   else
      fname = [fname stringByAppendingString:@".png"];
   
   [sp setNameFieldStringValue:fname];
}

--
Michael McLaughlin
email@hidden





 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Disappearing accessory view
      • From: Quincey Morris <email@hidden>
  • Prev by Date: Re: Disappearing accessory view
  • Next by Date: Novice Struggling With Wrangling a Project Template Into Shape
  • Previous by thread: Re: Disappearing accessory view
  • Next by thread: Re: Disappearing accessory view
  • Index(es):
    • Date
    • Thread