I'm trying to cross every 't' and dot every 'i' for my atomic store subclass as
I try to find the source of my "save as" problems, and in doing so, I have
implemented the identifier and setIdentifier methods I mentioned below (even
though the documentation seems to imply that there are default i
Folks;
I have a dozen or so strings that I use over and over in various classes.
So here's what I've done
I have a CommonStrings.txt file added to the project. It looks like this:
NSString *gLeftBracket =@"<";
NSString *gRightBracket =@">";
If I #include this file somewhere in
On Mar 13, 2010, at 19:48, Marx Bievor wrote:
> - (void)awakeFromNib{
> cont = [[Controller alloc] init];
> polygon = [[PolygonShape alloc] initWithNumberOfSides:5
> minimumNumberOfSides:3 maximumNumberOfSides:12];
> numberOfSidesLabel.text=[NSString stringWithF
Hi,
I would like to populate a TableView with data from a web service.
I would also like to send requests back and fourth depening on what
the user does on an iPhone.
Does anyone have an example or info on a simular application?
Best Regards,
Nick
_
On Mar 13, 2010, at 10:23 PM, Quincey Morris wrote:
> On Mar 13, 2010, at 19:33, Alexander Bokovikov wrote:
>
>> I have a time-consuming procedure, and I'd like to show its progress. I
>> can't use multi-threading for some technical reason.
>> I'm looking for a way to update a progress indicator
On Mar 13, 2010, at 19:33, Alexander Bokovikov wrote:
> I have a time-consuming procedure, and I'd like to show its progress. I can't
> use multi-threading for some technical reason.
> I'm looking for a way to update a progress indicator from this procedure,
> As far as I understand my task is to
Hi all,
I have two functions increase and decrease which control the number of sides of
a polygon. I want to call a - (void)function that disables the buttons if the
current number of sides are equal to the maximum number of sides.
1) One problem is that "button.enabled=YES/NO" does not get cal
On Mar 13, 2010, at 8:33 PM, Alexander Bokovikov wrote:
> Hi, All,
>
> I have a time-consuming procedure, and I'd like to show its progress. I can't
> use multi-threading for some technical reason.
> I'm looking for a way to update a progress indicator from this procedure,
> As far as I underst
Hi, All,
I have a time-consuming procedure, and I'd like to show its progress.
I can't use multi-threading for some technical reason.
I'm looking for a way to update a progress indicator from this procedure,
As far as I understand my task is to cause message loop processing.
And my question is
Hi guys,
I've got a few *nix libs to flesh out with some Cocoa UI goodness and
would welcome suggestions for a good way to do a bunch of controls:
Control 1: A long colour bar with a sliding window over it (mouse
controls the position of the window) -
++
|]|[|||
Hi Paul,
You said 'an object you don't manage' -- If I alloc/init an instance
of NSTimer I am responsible for this object, in my opinion. That's why
I tried to do everything properly.
You see I am actually really just trying to prevent memory leaks and I
see lots of leaks in sample code I a
This is almost always caused by releasing an object earlier than you
expected to, and then trying to release it again later (similar to "double
free"). Look around in your class's code for a place where you autorelease
an ivar, but don't add it to a collection, or where you release an ivar but
don'
I don't understand all the confusion on this issue. The NSTimer
documentation makes the life-cycle of this object very clear.
Until it goes away, it is probably retained by the runloop.
As Joar says, you often can't make any concrete predictions
about when an object you don't manage yourself m
I haven't followed this whole thread, but my experience is that an NSTimer
(especially a repetitive one) is an easy thing to leak, even in a GC
environment (which I use). To prevent it, you have to make sure you keep a
reference to the timer so that you can actually invalidate it, taking it out
of
I am running into a weird error and I don't know why it's happening. I
am adding an image that comes from a Quartz Composer composition to a
dictionary. The dictionary is archived, and when that happens I see
the following message in the console:
-[QCNSBitmapImageRep encodeWithCoder
Hi Joar,
Thanks a lot for taking the time to respond to this request! Let me
explain what made me write to this cocoa list and think NSTimer's got
a memory leak:
When reading through all the class documentations from Apple I often
see some notes in the discussion group that say something
For the benefit of the OP, according to the docs (and this fits in with my own
experience), calling [NSTimer invalidate] will release the timer at some future
point in the run loop and is in fact the only way to get rid of it. So there
is really nothing to worrry about. Trust in Papa Cocoa, al
Am 13.03.2010 um 18:54 schrieb Joanna Carter:
>> Actually this is how nibs were designed and intended to be used: to be
>> fragments of the object graph loaded at runtime. It is a *very* recent
>> trend to have them exist so independently of File's Owner, and to use
>> the public API to hook up t
>> Recycled objects can appear as leaks, making it hard to distinguish
>> between a bug and normal behavior.
>
> I don't think that's true (it doesn't fit with the algorithm used for
> identifying leaks), but if it is, please file a bug report:
I didn't mean to imply the Leaks instrument. Using t
You are right, id is the standard.
But the question was how to get a delegate that is not visible in IB and does
not produce compiler warnings.
atze
Am 13.03.2010 um 18:55 schrieb Kevin Cathey:
> Not necessarily true. While you are free to specify a delegate as NSObject
> , it is not
On 13 mar 2010, at 09.08, Tobias Jordan wrote:
> Yes, don't get me wrong, I trust the Apple docs, of course but I also know
> it's possible they are doing something wrong. I don't remember all cases but
> it always starts like this: I see something's not being freed, I try to free
> it, it doe
Not necessarily true. While you are free to specify a delegate as NSObject
, it is not standard convention. The convention for delegates is:
id.
Kevin
On 13 Mar 2010, at 07:39, Alexander Spohr wrote:
>
> Am 13.03.2010 um 16:25 schrieb Joanna Carter:
>
>> My reason for using id is because I
Hi Ken,
the problem was solved by checking bitsPerPixel and changed the pixel format
to GL_RGB, GL_UNSIGNED_BYTE
but, if the best combination of format / type is GL_BGRA,
GL_UNSIGNED_INT_8_8_8_8_REV so does it means we need to convert RGB / RGBA
to BGRA?
sorry for posting in cocoa list
2010/3/1
Hi Kyle
> Actually this is how nibs were designed and intended to be used: to be
> fragments of the object graph loaded at runtime. It is a *very* recent
> trend to have them exist so independently of File's Owner, and to use
> the public API to hook up their connections.
So I gather. Which was o
I have some code that is throwing EXC_BAD_ACCESS. It does so when an object is
deallocating, in its -dealloc method on a call to [super dealloc]. The object's
class's superclass is NSObject. Here's the (relevant part of the) stack trace:
#0 0x7fff872e016d in _class_hasCxxStructorsNoSuper
#1
On 13 mar 2010, at 07.36, Tobias Jordan wrote:
> I've always been having problems with Foundation's NSTimer Class when it
> comes to Memory-Management. After activating the static analyzer in Xcode
> (very useful!), it immediately reminds me of autoreleasing my instance of
> NSTimer and I thou
On Sat, Mar 13, 2010 at 7:20 AM, Joanna Carter
wrote:
>> If my class is files owner the whole nib is owned by it - hence the name.
>> Therefore I absolutely want IB to be able to set even the private ivars. The
>> nib is just another way of setting up my class’ objects.
>
> If I may say so, to s
On 13 Mar 2010, at 16:41, Alexander Spohr wrote:
>
> Am 13.03.2010 um 17:03 schrieb Thomas Davie:
>
>> On 13 Mar 2010, at 11:59, Alexander Spohr wrote:
>>
>>> This is not really a Cocoa question...
>>>
>>> - If you want your application in the store you need Company.
>>
>> This is not true,
Yes, don't get me wrong, I trust the Apple docs, of course but I also
know it's possible they are doing something wrong. I don't remember
all cases but it always starts like this: I see something's not being
freed, I try to free it, it doesn't work, I do a search on it and
notice there are
On 13 mar 2010, at 08.57, Dave Keck wrote:
> Recycled objects can appear as leaks, making it hard to distinguish
> between a bug and normal behavior.
I don't think that's true (it doesn't fit with the algorithm used for
identifying leaks), but if it is, please file a bug report:
> Please explain this.
>
> If you stick to the memory rules you’re fine.
Recycled objects can appear as leaks, making it hard to distinguish
between a bug and normal behavior.
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not post ad
Am 13.03.2010 um 17:41 schrieb Tobias Jordan:
> I want to know what's going on inside my app and I've got enough experience
> in coding to know that just trusting the Apple docs (especially when it's
> about memory management) is not reliable.
Please explain this.
If you stick to the memory r
Hi Mani,
Thanks a lot, sounds good although I am not really happy with the fact
that Apple doesn't mention it somewhere. I know a lot of developers
who don't care about Instruments and memory leaks'n'stuff that's why
their software will be always buggy.
I want to know what's going on inside
Am 13.03.2010 um 17:03 schrieb Thomas Davie:
> On 13 Mar 2010, at 11:59, Alexander Spohr wrote:
>
>> This is not really a Cocoa question...
>>
>> - If you want your application in the store you need Company.
>
> This is not true, I currently have two applications in the store, and do not
> ha
Martin Wierschin wrote:
> > I have a custom NSTextAttachmentCell that does its work by adding
> > subviews to the NSTextView (e.g. NSButtons). This works fine.
> >
> > What I can't get to work is cursor handling; I always get an arrow
> > cursor when the mouse is over my views. I overwrite resetC
On 13 Mar 2010, at 11:59, Alexander Spohr wrote:
> This is not really a Cocoa question...
>
> - If you want your application in the store you need Company.
This is not true, I currently have two applications in the store, and do not
have a company account.
The important difference is that if
Hi Alexander
> Yes your idea is wrong.
> You are free to specify NSObject *delegate;
Great. I've learnt so much but there is still so much more to learn :-)
Joanna
--
Joanna Carter
Carter Consulting
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.
> I sent an -invalidate to my instance of NSTimer in -fire: but Instruments
> told me the object was still alive. This is really confusing, I think the
> instance should be released when sending an invalidate so mem-management is
> clean and fine as it is in every other Apple ObjC class.
This i
Am 13.03.2010 um 16:25 schrieb Joanna Carter:
> My reason for using id is because I want to hold a delegate and call methods
> on it without compiler warnings. Or have I got the wrong idea there?
Yes your idea is wrong.
You are free to specify NSObject *delegate;
atze
___
Hey Devs,
I've always been having problems with Foundation's NSTimer Class when
it comes to Memory-Management. After activating the static analyzer in
Xcode (very useful!), it immediately reminds me of autoreleasing my
instance of NSTimer and I thought like why is the NSTimer never being
Hi Roland
Le 13 mars 2010 à 12:13, Roland King a écrit :
> I don't know if Joanna was suggesting you couldn't make anything available to
> IB by making it an IBOutlet, I took it that she was saying the old
> 'compatibility mode' of having any variable of type 'id', even if not an
> IBOutlet, b
Hi Paul
Le 13 mars 2010 à 12:12, Paul Sanders a écrit :
> Try:
>
> #define PRIVATE_ID id
>
> ...
>
> PRIVATE_ID myPrivateiVar;
Hmmm, messy. I much prefer the developer tools to respect the visibility
specifier. :-)
Joanna
--
Joanna Carter
Carter Consulting
Hi Alexander
> If my class is files owner the whole nib is owned by it - hence the name.
> Therefore I absolutely want IB to be able to set even the private ivars. The
> nib is just another way of setting up my class’ objects.
If I may say so, to say this is to misunderstand object oriented des
On Mar 12, 2010, at 1:17 PM, David Blanton wrote:
> How does one get a views acceptsFirstResponder method called without having
> to click on the view?
You may be looking for -makeFirstResponder: in the NSWindow class.
-acceptsFirstResponder should be called automatically...
If not, you'll ne
I don't know if Joanna was suggesting you couldn't make anything available to
IB by making it an IBOutlet, I took it that she was saying the old
'compatibility mode' of having any variable of type 'id', even if not an
IBOutlet, be visible in IB would not be broken if you restricted it to those
Try:
#define PRIVATE_ID id
...
PRIVATE_ID myPrivateiVar;
Paul Sanders.
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.
Am 13.03.2010 um 10:32 schrieb Joanna Carter:
> All that is needed is to detect whether the ivar is @private and to respect
> that visibility. If an ivar is private, it should not be visible in the IB
> designer, regardless of whether it is of type id or not.
I’d say no to this.
If my class i
This is not really a Cocoa question...
- If you want your application in the store you need Company.
- If you want to distribute in a big company (1000 employees) without using the
store you want the enterprise.
The account is for the whole company. But the one who pays owns the account.
So you
Am 12.03.2010 um 03:13 schrieb Mazen M. Abdel-Rahman:
> For the calendar grid I was creating an NSTrackingArea for each cell - in my
> case (the calendar is for 7 days with 15 minutes per cell) there was 672
> NSTrackingAreas.
>
> I will have to look at alternative solutions to all these NSTra
Yes, that's what I mean. But it worked fine on Leopard and
Tiger... It's all academic now anyway, I rewrote it around my
own, STL-based collection classes. I just thought I'd mention
it in case it bit anybody else. I didn't keep a copy of the
code, sorry.
And I know about the difference be
> As people often seem to do with such things, I was
> misinterpreting what it [Instruments] was telling me.
A really really simple way of getting a handle on where a
program is spending its time is to take a few samples in
Activity Monitor while it is busy. You'd be amazed at how well
this w
> In practice it probably won't because I believe the Cocoa typesetter
> always produces more glyphs than characters (eg: inserting null glyphs
> as padding).
I'm not sure that's true - sometimes, multiple characters get replaced by a
single glyph (i.c.o. ligatures). In other words: It can c
Hi Thomas
> Which is something some people at Apple encourage not to do. The leading
> underscore is seen as "Library implementors naming space" (also and
> especially for method signatures) so your code might break when you use that
> coding pattern.
>
> OTOH, enforcing would break many peop
Am 04.03.2010 um 19:58 schrieb Joanna Carter:
> I have no problem with this concept of default behaviour, if it is for legacy
> purposes but, with the new visibility specifiers, these should take
> precedence of the older legacy rules.
>
> Never mind, as long as you prepend the private ivar wi
Final follow up:
I got this to work with NSPredicateEditor, and it was actually surprisingly
easy (I got the entire thing put in in a couple of hours this evening). The
expression dependency was easy enough to get around. For example, with the
"Stop evaluating rules" option, I just made the l
55 matches
Mail list logo