• 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: How refresh window title -- SOLVED
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How refresh window title -- SOLVED


  • Subject: Re: How refresh window title -- SOLVED
  • From: "McLaughlin, Michael P." <email@hidden>
  • Date: Tue, 4 Aug 2009 11:07:34 -0400
  • Acceptlanguage: en-US
  • Thread-topic: How refresh window title -- SOLVED

Found the problem.  It did not reside in the code below.

Sorry for the waste of bandwidth :-(

*****

I know this is supposed to be trivial but none of the permutations I've
tried have worked [Xcode 3.1.3].  My current incarnation is as follows:

-(void)doShowHide:(BOOL)show time:(short)t
{
   NSWindow *dispWindow = [dispDoc windowForSheet];
   NSString *suffix = [NSString stringWithFormat:@": t = %hd", t];
   NSString *fullTitle = [title stringByAppendingString:suffix];

   if (show == YES) {
      [dispWindow setTitle:fullTitle];
      [dispWindow makeKeyAndOrderFront:self];
      [dispWindow setViewsNeedDisplay:YES];
      [dispWindow display];
   }
   else
      [dispWindow orderOut:self];
}

This function is called periodically via the Event Loop.  There is one
custom view in the window and it *does* redraw as desired.  However, the
title draws only the first time, giving t = 0 in the title and never
changing.

I would like the title to update with time.

Can anyone point out what I am missing?  [Note: The NSString, title, is a
class member.]

Thanks.

--
Mike McLaughlin

_______________________________________________

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

  • Prev by Date: Re: [iPhone] networking-is it crippled on the simulator?
  • Next by Date: [OT] Re: [iPhone] networking-is it crippled on the simulator?
  • Previous by thread: Re: How refresh window title
  • Next by thread: [iphone] split an image
  • Index(es):
    • Date
    • Thread