Skip to content

Instantly share code, notes, and snippets.

View martinwinter's full-sized avatar

Martin Winter martinwinter

View GitHub Profile
@martinwinter
martinwinter / MWCGPath.h
Created March 18, 2014 18:49
A thin object wrapper around CGPath, mainly for the purpose of serializing paths. (Not yet converted to ARC, sorry.)
//
// MWCGPath.h
//
// Created by Martin Winter on 14.01.11.
// Copyright 2011 Martin Winter. All rights reserved.
//
// Provides an NSObject wrapper around CGPathRef.
//
#if TARGET_OS_IPHONE
@martinwinter
martinwinter / Open Safari tabs in Google Chrome
Last active November 20, 2020 11:33
Opens all Safari windows and tabs in Google Chrome.
tell application "Safari"
repeat with theSafariWindow in windows
tell application "Google Chrome" to set theChromeWindow to make new window
repeat with theSafariTab in theSafariWindow's tabs
set theURL to URL of theSafariTab
tell application "Google Chrome"
set theChromeTab to make new tab at end of tabs of theChromeWindow
set URL of theChromeTab to theURL
end tell
end repeat