“Setter methods on queue-based managed object contexts are thread-safe. You can
invoke these methods directly on any thread”
https://developer.apple.com/library/mac/documentation/Cocoa/Reference/CoreDataFramework/Classes/NSManagedObjectContext_Class/index.html
> On Jul 28, 2015, at 11:49 PM, Tr
>
>> On 28 Jul 2015, at 9:12 pm, Trygve Inda wrote:
>>
>> I gather that when using NSPrivateQueueConcurrencyType, all operations (a
>> fetch for example) have to be done within a performBlock call.
>>
>
> ...
>
>> Then later, this context is used outside a performBlock:
>>
>>
>> NSArray *ma
On Jul 28, 2015, at 18:07 , Rick Mann wrote:
>
>dynamic var thumbnailURL: NSURL?
>dynamic var numFiles: NSNumber?
>dynamic var filesDownloaded : NSNumber?
>dynamic var downloadState : NSNumber? =
> DownloadState.notDownloaded.rawV
I'm trying to get an NSURL into PHAsset form, but I keep coming up with null.
PHAsset fetchAssetsWithALAssetURLs: takes an NSArray of NSURLs: "An array of
NSURL objects, each an asset URL previously retrieved from an ALAsset object."
Apparently, this is not a simple array of NSURL objects. How c
> On Jul 28, 2015, at 8:57 PM, Charles Srstka wrote:
>
> func valueForKey(key: String) -> AnyObject? {
>
> func setValue(value: AnyObject?, forKey key: String) {
D’oh — I forgot to put “override” in front of these. Old Objective-C habits die
hard. Sorry about that.
Charles
_
> On Jul 28, 2015, at 8:07 PM, Rick Mann wrote:
>
> I'd like to have a Swift enum that lays out a set of states, and a property
> of that type on an object that is KVObservable (i.e. dynamic). I don't think
> this is possible. What I settled on was this:
>
> class
> Model : MPObject
> {
>e
I'd like to have a Swift enum that lays out a set of states, and a property of
that type on an object that is KVObservable (i.e. dynamic). I don't think this
is possible. What I settled on was this:
class
Model : MPObject
{
enum
DownloadState : NSNumber
{
case notDownloaded
I’m not 100% sure if it’s related, but one user sent this to me which appeared
to coincide with the launch failure:
7/28/15 4:41:01.467 PM CoreServicesUIAgent[8607]: Error -60005 creating
authorization
7/28/15 4:41:11.624 PM CoreServicesUIAgent[8607]: An uncaught exception was
raised
7/28/15 4
>>
>
> performBlockAndWait might work. In my completion handler I have basically:
>
> Context = [self createPrivateContect];
>
> For (I = 1; I < something ; i++)
> {
>...do stuff with completetion data from URL...
>
>...do stuff with the context...
>
> }
>
> So I need to make sure th
>
>> On Jul 28, 2015, at 10:14 AM, Trygve Inda wrote:
>>
On 28 Jul 2015, at 9:12 pm, Trygve Inda wrote:
I gather that when using NSPrivateQueueConcurrencyType, all operations (a
fetch for example) have to be done within a performBlock call.
>>>
>>> ...
>>>
>>>
Yes, thanks. I ended up with this (yes, I like to use Void):
func keyboardWillShow(notification:NSNotification) -> Void
{
let userInfo = notification.userInfo!
let keyboardEndFrame = (userInfo[UIKeyboardFrameEndUserInfoKey] as!
NSValue).CGRectValue()
let animDuratio
Also FYI, it’s a lot simpler to serve content to a WebView by implementing an
NSURLProtocol, than by embedding an entire web server. (And it doesn’t open any
sockets, so you avoid this problem.) I’m sure there’s sample code somewhere
showing how to do this, but I don’t have any pointers to it.
> Le 28 juil. 2015 à 16:03, Eric E. Dolecki a écrit :
>
> The more I stretch to Swift goals, the more I learn. However I've come upon
> a little thing where I am translating code into Swift and quickly stumbled.
>
> *Obj-C:*
> NSValue *keyboardEndFrameValue = [[notification userInfo]
> objectFo
The more I stretch to Swift goals, the more I learn. However I've come upon
a little thing where I am translating code into Swift and quickly stumbled.
*Obj-C:*
NSValue *keyboardEndFrameValue = [[notification userInfo]
objectForKey:UIKeyboardFrameEndUserInfoKey];
*Swift (the closest I've come):*
> On 28 Jul 2015, at 10:14 pm, Trygve Inda wrote:
>
>>
>>> On 28 Jul 2015, at 9:12 pm, Trygve Inda wrote:
>>>
>>> I gather that when using NSPrivateQueueConcurrencyType, all operations (a
>>> fetch for example) have to be done within a performBlock call.
>>>
>>
>> ...
>>
>>> Then later, th
Depending on what you are doing, you could either put doSomething and
doSomethingElse inside the performBlock, or you could use performBlockAndWait
> On Jul 28, 2015, at 10:14 AM, Trygve Inda wrote:
>
>
> If I do use performBlock and have to do several things:
>
> This code is sitting inside
> On Jul 28, 2015, at 10:14 AM, Trygve Inda wrote:
>
>>>
>>> On 28 Jul 2015, at 9:12 pm, Trygve Inda wrote:
>>>
>>> I gather that when using NSPrivateQueueConcurrencyType, all operations (a
>>> fetch for example) have to be done within a performBlock call.
>>>
>>
>> ...
>>
>>> Then later,
>
>> On 28 Jul 2015, at 9:12 pm, Trygve Inda wrote:
>>
>> I gather that when using NSPrivateQueueConcurrencyType, all operations (a
>> fetch for example) have to be done within a performBlock call.
>>
>
> ...
>
>> Then later, this context is used outside a performBlock:
>>
>>
>> NSArray *ma
> On Jul 28, 2015, at 10:01 AM, Roland King wrote:
>
>
>> On 28 Jul 2015, at 9:12 pm, Trygve Inda wrote:
>>
>> I gather that when using NSPrivateQueueConcurrencyType, all operations (a
>> fetch for example) have to be done within a performBlock call.
>>
>
> ...
>
>> Then later, this contex
> On 28 Jul 2015, at 9:12 pm, Trygve Inda wrote:
>
> I gather that when using NSPrivateQueueConcurrencyType, all operations (a
> fetch for example) have to be done within a performBlock call.
>
...
> Then later, this context is used outside a performBlock:
>
>
> NSArray *matchingQuakes = [t
I gather that when using NSPrivateQueueConcurrencyType, all operations (a
fetch for example) have to be done within a performBlock call.
Apple has sample code here:
https://developer.apple.com/library/mac/samplecode/Earthquakes/History/Histo
ry.html#//apple_ref/doc/uid/TP40014547-RevisionHistory-
Dear list,
I am working on an iOS app that uses a UISplitViewController.
As per the client’s requirements, a UIViewController should be loaded before
the UISplitViewController loads.
This “preceding” UIViewController - let’s call it the Home Screen - allows the
user to select from a small numb
22 matches
Mail list logo