20
questions
1
vote
1
answer
67
views
How to programmatically put an NSObjectController into entity mode?
I'm instantiating an NSTreeController programmatically and want to put it into entity mode, but regardless of what I do it sticks to class mode.
The following code fragment doesn't work:
...
1
vote
1
answer
538
views
How to use NSObjectController and Managed Object Context using Cocoa Bindings
Searched entire Internet but couldn’t find the modern solution for my problem.
I want to use NSObjectController in pair with Core Data through Cocoa Bindings and struggle to set it up properly. Worth ...
0
votes
1
answer
102
views
NSObjectController in object mode in Swift
How do I configure an NSObjectController in object mode in Swift?
Let's say I have a class A:
class A {}
Here's what I have tried:
let oc = NSObjectController()
oc.objectClass = A.self
oc....
0
votes
1
answer
184
views
Why NSObjectController does not update the model property it is bound to?
I configure bindings like this:
@property (nonatomic, copy) NSString *name;
@property (nonatomic, strong) NSObjectController *controller;
...
self.controller = [[NSObjectController alloc] ...
0
votes
3
answers
70
views
trouble with inheritance in Objective C
I am very new to Objective C, and working on a project and I am struggling with the pass-by-reference, among other things which is likely obvious in my code. If someone could break it down for me in ...
1
vote
1
answer
69
views
How to use keyDown in NSObjectController
I'm developing an ap for MacOSX with Xcode5
my initial window is NSObjectController based, and I'm trying to capture keyboard events by using the common method I used on NSWindowControllers called
-(...
0
votes
2
answers
190
views
error NSObjectController invalid reference to NSManagedObjectContext addObject
Question:
I seem to have bindings set without design time or build errors, but at run-time an instance of a an NSManagedObject (an Account entity) isn't found. What is my configuration mistake?
...
1
vote
1
answer
182
views
How to be notified of any binding changes to an NSObjectController
I have an NSView which in which all the controls have been bound to a model object using an NSObjectController in Interface Builder.
This works correctly. Now I would like my NSViewController to be ...
3
votes
1
answer
1k
views
How to use NSObjectController with Core Data?
I have spent more than a day on trying to find a simple example of how to use an NSObjectController for binding along with core data. All examples are of NSArrayControllers with NSTableView bindings.
...
0
votes
2
answers
94
views
protocol and delegate not accessing method
I am trying to pass some data back to my UIView, its abit of a complicated situation I will try to explain it.
I have my
mainViewController // request is made to RequestClass
requestClass // ...
5
votes
1
answer
2k
views
KVO: +keyPathsForValuesAffecting<Key> doesn't work with (subclass of) NSObjectController
I have a KVO-able class (call it Observee), which affectedValue dynamic property is affected by affectingValue property. The dependency between the properties is defined by implementing +...
2
votes
0
answers
213
views
Binding a number to NSTextField with an NSObjectController, but cannot display
I am pretty new for cocoa programming.
I am learning binding, trying to make a simple binding code as:
- (void)awakeFromNib
{
self.aValue = [[Model alloc] init];
NSString *...
1
vote
2
answers
131
views
When is a NSManagedObject really accessible?
I have a problem.
I have an NSObjectController called "mapController" and I want to put some defaults when the object is created. I do this inside the windowControllerDidLoadNib method of my document,...
5
votes
1
answer
4k
views
How do I bind an NSTextField's value to an NSObjectController's content without errors?
I have a pretty simple set up here, and Xcode is giving me a comment-less red "!" mark in the interface builder.
Started from a Core Data-based document template. The document xib has an ...
0
votes
1
answer
252
views
Changing value of instance variable declared as property in model class, via app delegate class
I am doing following things in my sample application:
I made a model class and declared an array as property in it.
@interface MyModel : NSObject
@property (strong, readwrite) NSArray *...