• 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
MyShadow was deallocated while key value observers...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

MyShadow was deallocated while key value observers...


  • Subject: MyShadow was deallocated while key value observers...
  • From: Leonardo <email@hidden>
  • Date: Fri, 27 Jun 2014 22:21:36 +0200
  • Thread-topic: MyShadow was deallocated while key value observers...

While the user moves the selection within an NSTextView, I show on the UI
the values of the current textShadow: offsetX, offsetY and blur. In each
textField on IB, I bind, e.g.

   oObjsArrayController.selection.textShadow.offsetX

So, in the textView's method textViewDidChangeSelection I do
   attr = [self.textStorage attributesAtIndex:loc effectiveRange:effRange];
   self.textShadow = [attr objectForKey:MyShadowAttributeName];


textShadow is never retained. It's just a pointer that I set to nil or to
the current selected shadow, as above, just to show the current selected
shadow values. On the header, it looks

   @property (nonatomic, assign) MyShadow      *textShadow;

Sometimes, when I create a new shadow or I release the textView I get this
bug:

   MyShadow was deallocated while key value observers were still registered
   with it...

Why? I can't find a solution to this bug.


Regards
-- Leonardo


_______________________________________________

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: MyShadow was deallocated while key value observers...
      • From: Ken Thomases <email@hidden>
    • Re: MyShadow was deallocated while key value observers...
      • From: Lee Ann Rucker <email@hidden>
  • Prev by Date: Re: Trouble with setWidthTracksTextView YES
  • Next by Date: Re: MyShadow was deallocated while key value observers...
  • Previous by thread: Re: Problems with NSComboBox delegate
  • Next by thread: Re: MyShadow was deallocated while key value observers...
  • Index(es):
    • Date
    • Thread