Skip to content

Instantly share code, notes, and snippets.

View ElfSundae's full-sized avatar
:octocat:
🤔

Elf Sundae ElfSundae

:octocat:
🤔
View GitHub Profile

slidenumber: true autoscale: true

iOS13とmacOS CatalinaのWebSocketサポート

参加してなくてもついていけるもん!

WWDCゴリゴリキャッチアップ会 2019

@omochimetaru


@eugenebokhan
eugenebokhan / CGImage+Resize.swift
Last active April 11, 2024 21:28
UIImage + Resize
import CoreGraphics
import Accelerate
import CoreImage
import UIKit
extension CGImage {
public enum Error: Swift.Error {
case imageResizingFailed
case cgContextCreationFailed
@Orangenhain
Orangenhain / import_minimizer.rb
Created November 28, 2013 12:45
Script that takes a ObjC .m file and tries to find unused (or duplicate) import statements by commenting out each #import line in turn and seeing if the project still compiles. You will have to change BUILD_DIR & BUILD_CMD.
#!/usr/bin/env ruby -w
class String
def starts_with?(prefix)
prefix.respond_to?(:to_str) && self[0, prefix.length] == prefix
end
end
HEADER_REGEX = /^#import\s+["<](.*)[">]/
@heroicyang
heroicyang / ios_resources.json
Created October 9, 2013 02:33
GitHub 上的 iOS 开源项目
var githubList = [
{
name:'系统基础库',
list: [
{name:'Category/Util',
list: [
{name:'sstoolkit', owner:'soffes', desc:'一套Category类型的库,附带很多自定义控件 功能不错~'},
{name:'BlocksKit', owner:'pandamonia', desc:'将Block风格带入UIKit和Founcation'},
{name:'cocoa-helpers', owner:'enormego', desc:'一些Cocoa的扩展 2年前的工程'},
@jan0
jan0 / imessage_decrypt.py
Created June 30, 2012 11:46
Decrypt iMessages
from Crypto.Cipher import AES
from StringIO import StringIO
from bplist import BPlistReader #https://github.com/farcaller/bplist-python
import M2Crypto
import gzip
import struct
def xor_strings(s, key):
res = ""
for i in xrange(len(s)):
@TonnyXu
TonnyXu / Description.md
Created February 3, 2012 10:03
Make the UITableView with group style to round the image.

The point is, the roundCorner is draw by a subview of UITableViewCell, and mean while, it's not a public class, there is no way you can get layer.cornerRadius from any view. So we need to resolve this problem by ourselves.

There are 2 cases.

  1. There is only one cell.

    This case is ease, just use cell.contentView.layer.cornerRadius and cell.contentView.layer.masksToBounds to make it work.

  2. There are more than one cell.

@amcgregor
amcgregor / BDHost.m
Created October 5, 2011 18:35
Useful Objective-C methods, classes, objects, and categories. Basically a snippit collection.
// From: http://www.bdunagan.com/2009/11/28/iphone-tip-no-nshost/
// MIT license
// Remember to add CFNetwork.framework to your project using Add=>Existing Frameworks.
#import "BDHost.h"
#import <CFNetwork/CFNetwork.h>
#import <netinet/in.h>
#import <netdb.h>
#import <ifaddrs.h>