This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version='1.0' encoding='UTF-8' standalone='yes'?> | |
<assembly xmlns='urn:schemas-microsoft-com:asm.v1' manifestVersion='1.0'> | |
<application xmlns="urn:schemas-microsoft-com:asm.v3"> | |
<windowsSettings> | |
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true</dpiAware> | |
</windowsSettings> | |
</application> | |
</assembly> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Restart Bluetooth Module on Mac OS X | |
# | |
# Requires Blueutil to be installed: http://brewformulas.org/blueutil | |
BT="/usr/local/bin/blueutil" | |
log() { | |
echo "$@" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// SpinlockTestTests.swift | |
// SpinlockTestTests | |
// | |
// Created by Peter Steinberger on 04/10/2016. | |
// Copyright © 2016 PSPDFKit GmbH. All rights reserved. | |
// | |
import XCTest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var readline = require('readline'), | |
fs = require('fs'); | |
var LinkMap = function(filePath) { | |
this.files = [] | |
this.filePath = filePath | |
} | |
LinkMap.prototype = { | |
start: function(cb) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ffmpeg -i input.mov -vcodec libwebp -lossless 1 -q:60 -preset default -loop 0 -an -vsync 0 output.webp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifndef TTD_CATEGORY_PROPERTY | |
#define TTD_CATEGORY_PROPERTY | |
#import <objc/runtime.h> | |
#define TTD_GET_PROPERTY(property) objc_getAssociatedObject(self, @selector(property)); | |
#define TTD_SET_STRONG(property) objc_setAssociatedObject(self, @selector(property), property, OBJC_ASSOCIATION_RETAIN_NONATOMIC); | |
#define TTD_SET_COPY(property) objc_setAssociatedObject(self, @selector(property), property, OBJC_ASSOCIATION_COPY_NONATOMIC); | |
#define TTD_SET_UNSAFE_UNRETAINED(property) objc_setAssociatedObject(self, @selector(property), property, OBJC_ASSOCIATION_ASSIGN); | |
#define TTD_SET_ASSIGN(property, value) objc_setAssociatedObject(self, @selector(property), value, OBJC_ASSOCIATION_RETAIN_NONATOMIC); | |
#define TTD_SET_WEAK(property) id __weak __weak_object = property; \ | |
id (^__weak_block)() = ^{ return __weak_object; }; \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifndef TTD_SWITCH_STRING | |
#define TTD_SWITCH_STRING | |
#define TTD_CASE(str) if ([__s__ isEqualToString:(str)]) | |
#define TTD_SWITCH(s) for (NSString *__s__ = (s); ; ) | |
#define TTD_DEFAULT | |
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifndef dispatch_main_sync_safe | |
#define dispatch_main_sync_safe(block)\ | |
if ([NSThread isMainThread]) {\ | |
block();\ | |
} else {\ | |
dispatch_sync(dispatch_get_main_queue(), block);\ | |
} | |
#endif | |
#ifndef dispatch_main_async_safe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// PSPDFFastEnumeration.h | |
// PSPDFFoundation | |
// | |
// PSPDFKit is the leading cross-platform solution for integrating PDFs into your apps: https://pspdfkit.com. | |
// Try it today using our free PDF Viewer app: https://pdfviewer.io/ | |
// | |
// This file is MIT licensed. | |
@protocol PSPDFFastEnumeration <NSFastEnumeration> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (UIView *)hitTest:(CGPoint)point withEvent:(UIEvent *)event { | |
if (!self.isUserInteractionEnabled || self.isHidden || self.alpha <= 0.01) { | |
return nil; | |
} | |
if ([self pointInside:point withEvent:event]) { | |
for (UIView *subview in [self.subviews reverseObjectEnumerator]) { | |
CGPoint convertedPoint = [subview convertPoint:point fromView:self]; | |
UIView *hitTestView = [subview hitTest:convertedPoint withEvent:event]; | |
if (hitTestView) { | |
return hitTestView; |