Skip to content

Instantly share code, notes, and snippets.

View xtreme-daniel-crampton's full-sized avatar

Daniel Crampton xtreme-daniel-crampton

View GitHub Profile
2015-05-19 17:18:19.531 Record[2816:791519] <Debug:0x17069f680 -[SensorConnectViewController addRecorderDataSource] (line 310)> Added workout sensor data source with device UUID: 3FF231D1-AA2F-C4CF-B429-B94F73711A56
2015-05-19 17:18:19.532 Record[2816:791581] <Debug:0x171879140 -[UARecorderCalculator addDataSource:] (line 154)> Primary data sources: {
"energy_expended" = "<UABluetoothDataSource: 0x1706984c0>";
"heart_rate" = "<UABluetoothDataSource: 0x1706984c0>";
steps = "<UABluetoothDataSource: 0x1706984c0>";
willpower = "<UABluetoothDataSource: 0x1706984c0>";
}
2015-05-19 17:18:19.532 Record[2816:791581] <Debug:0x171879200 -[UARecorderCalculator addDataSource:] (line 155)> Current triggers: {
}
2015-05-19 17:18:19.533 Record[2816:791581] <Debug:0x1718793c0 __33-[UARecordProcessor beginPolling]_block_invoke (line 73)> Processed UABlockMessage.
2015-05-19 17:21:22.118 Record[2816:791519] <Debug:0x174297c00 -[SensorConnectViewController addRecorderDataSource] (line 310)> Added workout sensor data source with device UUID: 3FF231D1-AA2F-C4CF-B429-B94F73711A56
2015-05-19 17:21:22.118 Record[2816:791581] <Debug:0x171875680 -[UARecorderCalculator addDataSource:] (line 154)> Primary data sources: {
"energy_expended" = "<UABluetoothDataSource: 0x174297a70>";
"heart_rate" = "<UABluetoothDataSource: 0x174297a70>";
steps = "<UABluetoothDataSource: 0x174297a70>";
willpower = "<UABluetoothDataSource: 0x174297a70>";
}
2015-05-19 17:21:22.118 Record[2816:791519] <Debug:0x17465b270 -[UARecorder addSensorDataSourceObserver:withName:] (line 543)> Observing data source with name 3FF231D1-AA2F-C4CF-B429-B94F73711A56.
2015-05-19 17:21:22.118 Record[2816:791581] <Debug:0x17187c380 -[UARecorderCalculator addDataSource:] (line 155)> Current triggers: {
}
@xtreme-daniel-crampton
xtreme-daniel-crampton / noNilImageNamed
Created February 26, 2015 23:04
+ [UIImage noNilImageNamed:]
//
// UIImage+NoNilImageNamed.m
// UARecord
//
// Created by DX131 on 2/26/15.
// Copyright (c) 2015 Under Armour. All rights reserved.
//
#import "UIImage+NoNilImageNamed.h"
#import <objc/runtime.h>
@xtreme-daniel-crampton
xtreme-daniel-crampton / NSString+AdjustedSize.m
Created March 25, 2014 21:40
Returns a CGSize for a multi-line string.
- (CGSize)adjustedSizeWithFont:(UIFont *)font fromDefaultSize:(CGSize)defaultSize {
CGFloat additionalHeight = 0.0f;
NSDictionary *attributes = @{NSFontAttributeName : font};
CGRect rect = [self boundingRectWithSize:CGSizeMake(defaultSize.width, MAXFLOAT)
options:NSStringDrawingUsesLineFragmentOrigin
attributes:attributes
context:nil];