Instead of doing:
$name = !empty($json['name']) ? $json['name'] : null;
just do:
$name = burntCheck($json['name']);
@protocol TFFTagging | |
@property (readonly, nonatomic) NSString *name; | |
@end | |
// Tags in sidebar UI use TFFRecordedTag | |
// Tags in notes UI use TFFAttachableTag | |
// Same interface for what makes a tag, which is its name. |
@mixin searchButtonImage | |
{ | |
background-image: inline-image('infinitylist/svg/search-icon.svg', unquote('image/svg+xml')); | |
background-repeat: no-repeat; | |
} |
http://www.adobe.com/digitalimag/pdfs/phscs2ip_colspace.pdf |
Instead of doing:
$name = !empty($json['name']) ? $json['name'] : null;
just do:
$name = burntCheck($json['name']);
import Swift | |
import Cocoa | |
// Properties you need as an enum - problem of key value coding is it allows you to type *anything*, typos compile fine. | |
enum SyncObjectPropertyName { | |
case Archived | |
case Title | |
} | |
// Protocol shared both for local and server |
// Created by Patrick Smith on 22/04/2015. | |
// Copyright 2015 Patrick Smith. | |
// Released under the MIT License http://opensource.org/licenses/MIT | |
import Cocoa | |
import WebKit | |
extension WKUserContentController { | |
func addBundledUserScript(scriptNameInBundle: String, injectAtStart: Bool = false, injectAtEnd: Bool = false, forMainFrameOnly: Bool = true, sourceReplacements: [String:String]? = nil) { |
internal enum FileInfoIdentifier: String { | |
case DisplayNameAndIcon = "displayNameAndIcon" | |
case DateModified = "dateModified" | |
var sortDescriptor: NSSortDescriptor { | |
switch self { | |
case .DisplayNameAndIcon: | |
return NSSortDescriptor(key:NSURLLocalizedNameKey, ascending:true) | |
case .DateModified: | |
return NSSortDescriptor(key:NSURLContentModificationDateKey, ascending:false) |
protocol ValueStorable { | |
subscript(key: String) -> AnyObject? { get set } | |
} | |
internal protocol ValueStorableUpdater { | |
init?(fromStorable storable: ValueStorable) | |
func updateStorable(inout storable: ValueStorable) | |
} |
//: Property Observing | |
// Swift 1.2 | |
import Cocoa | |
import XCPlayground | |
protocol ObjectListenerType { | |
func objectDidChange<T: AnyObject>(x: T) | |
} |
//: Playground - noun: a place where people can play | |
import Foundation | |
protocol OptionalParasite { | |
typealias WrappedParasite | |
func toArray() -> [WrappedParasite] | |
} |