├── .gitignore ├── LICENSE ├── LauncherApplication ├── AppDelegate.swift ├── Assets.xcassets │ └── AppIcon.appiconset │ │ └── Contents.json ├── Base.lproj │ └── Main.storyboard ├── Info.plist └── LauncherApplication.entitlements ├── Podfile ├── Podfile.lock ├── Pods ├── MASShortcut │ ├── Framework │ │ ├── MASDictionaryTransformer.h │ │ ├── MASDictionaryTransformer.m │ │ ├── MASHotKey.h │ │ ├── MASHotKey.m │ │ ├── MASKeyCodes.h │ │ ├── MASKeyMasks.h │ │ ├── MASLocalization.h │ │ ├── MASLocalization.m │ │ ├── MASShortcut.h │ │ ├── MASShortcut.m │ │ ├── MASShortcut.modulemap │ │ ├── MASShortcutBinder.h │ │ ├── MASShortcutBinder.m │ │ ├── MASShortcutMonitor.h │ │ ├── MASShortcutMonitor.m │ │ ├── MASShortcutValidator.h │ │ ├── MASShortcutValidator.m │ │ ├── MASShortcutView+Bindings.h │ │ ├── MASShortcutView+Bindings.m │ │ ├── MASShortcutView.h │ │ ├── MASShortcutView.m │ │ └── Shortcut.h │ ├── LICENSE │ ├── README.md │ ├── cs.lproj │ │ └── Localizable.strings │ ├── de.lproj │ │ └── Localizable.strings │ ├── en.lproj │ │ └── Localizable.strings │ ├── es.lproj │ │ └── Localizable.strings │ ├── fr.lproj │ │ └── Localizable.strings │ ├── it.lproj │ │ └── Localizable.strings │ ├── ja.lproj │ │ └── Localizable.strings │ ├── ko.lproj │ │ └── Localizable.strings │ ├── nl.lproj │ │ └── Localizable.strings │ ├── pl.lproj │ │ └── Localizable.strings │ ├── ru.lproj │ │ └── Localizable.strings │ ├── zh-Hans.lproj │ │ └── Localizable.strings │ └── zh-Hant.lproj │ │ └── Localizable.strings ├── Manifest.lock ├── Pods.xcodeproj │ ├── project.pbxproj │ └── xcuserdata │ │ ├── buddax2.xcuserdatad │ │ └── xcschemes │ │ │ ├── MASShortcut-MASShortcut.xcscheme │ │ │ ├── MASShortcut.xcscheme │ │ │ ├── Pods-tmpNote.xcscheme │ │ │ └── xcschememanagement.plist │ │ └── oyakub.xcuserdatad │ │ └── xcschemes │ │ ├── MASShortcut-MASShortcut.xcscheme │ │ ├── MASShortcut.xcscheme │ │ ├── Pods-tmpNote.xcscheme │ │ ├── SwiftyMarkdown.xcscheme │ │ └── xcschememanagement.plist ├── SwiftyMarkdown │ ├── LICENSE │ ├── README.md │ └── Sources │ │ └── SwiftyMarkdown │ │ ├── CharacterRule.swift │ │ ├── PerfomanceLog.swift │ │ ├── String+SwiftyMarkdown.swift │ │ ├── SwiftyLineProcessor.swift │ │ ├── SwiftyMarkdown+iOS.swift │ │ ├── SwiftyMarkdown+macOS.swift │ │ ├── SwiftyMarkdown.swift │ │ ├── SwiftyScanner.swift │ │ ├── SwiftyTokeniser.swift │ │ └── Token.swift └── Target Support Files │ ├── MASShortcut │ ├── Info.plist │ ├── MASShortcut-Info.plist │ ├── MASShortcut-dummy.m │ ├── MASShortcut-prefix.pch │ ├── MASShortcut-umbrella.h │ ├── MASShortcut.debug.xcconfig │ ├── MASShortcut.modulemap │ ├── MASShortcut.release.xcconfig │ ├── MASShortcut.xcconfig │ ├── ResourceBundle-MASShortcut-Info.plist │ └── ResourceBundle-MASShortcut-MASShortcut-Info.plist │ ├── Pods-tmpNote │ ├── Info.plist │ ├── Pods-tmpNote-Info.plist │ ├── Pods-tmpNote-acknowledgements.markdown │ ├── Pods-tmpNote-acknowledgements.plist │ ├── Pods-tmpNote-dummy.m │ ├── Pods-tmpNote-frameworks.sh │ ├── Pods-tmpNote-resources.sh │ ├── Pods-tmpNote-umbrella.h │ ├── Pods-tmpNote.debug.xcconfig │ ├── Pods-tmpNote.modulemap │ └── Pods-tmpNote.release.xcconfig │ └── SwiftyMarkdown │ ├── SwiftyMarkdown-Info.plist │ ├── SwiftyMarkdown-dummy.m │ ├── SwiftyMarkdown-prefix.pch │ ├── SwiftyMarkdown-umbrella.h │ ├── SwiftyMarkdown.debug.xcconfig │ ├── SwiftyMarkdown.modulemap │ └── SwiftyMarkdown.release.xcconfig ├── README.md ├── Resources ├── screenshot_new.png ├── tmpNote.dmg └── tmpNote2.dmg ├── tmpNote.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ └── contents.xcworkspacedata └── xcuserdata │ └── buddax2.xcuserdatad │ └── xcschemes │ ├── tmpNote.xcscheme │ └── xcschememanagement.plist ├── tmpNote.xcworkspace ├── contents.xcworkspacedata ├── xcshareddata │ └── IDEWorkspaceChecks.plist └── xcuserdata │ └── buddax2.xcuserdatad │ └── xcdebugger │ └── Breakpoints_v2.xcbkptlist └── tmpNote ├── AppDelegate.swift ├── Assets.xcassets ├── AppIcon.appiconset │ ├── Contents.json │ ├── icon_128x128.png │ ├── icon_128x128@2x.png │ ├── icon_16x16.png │ ├── icon_16x16@2x.png │ ├── icon_256x256.png │ ├── icon_256x256@2x.png │ ├── icon_32x32.png │ ├── icon_32x32@2x.png │ ├── icon_512x512.png │ └── icon_512x512@2x.png ├── Compose.imageset │ ├── Compose.pdf │ └── Contents.json ├── Compose_bg3.imageset │ ├── Compose_bg3.pdf │ └── Contents.json ├── Compose_bg_template.imageset │ ├── Compose_bg_template.pdf │ └── Contents.json ├── Compose_empty.imageset │ ├── Compose_empty.pdf │ └── Contents.json ├── Contents.json ├── big_A.imageset │ ├── Contents.json │ └── big_A.pdf ├── clear.imageset │ ├── Contents.json │ └── clear.png ├── copy.imageset │ ├── Contents.json │ └── copy.pdf ├── draw_empty.imageset │ ├── Contents.json │ └── draw_empty.png ├── draw_filled.imageset │ ├── Contents.json │ └── draw_filled.png ├── menu.imageset │ ├── Contents.json │ └── menu2.pdf ├── page_indicator.imageset │ ├── Contents.json │ └── page_indicator.pdf ├── page_indicator_active.imageset │ ├── Contents.json │ └── page_indicator_active2.pdf ├── settings.imageset │ ├── Contents.json │ └── settings2.pdf └── small_A.imageset │ ├── Contents.json │ └── small_A.pdf ├── Base.lproj └── Main.storyboard ├── Datasource.swift ├── DrawingScene.sks ├── DrawingScene.swift ├── EventMonitor.swift ├── Extensions.swift ├── HeaderView.swift ├── Info.plist ├── PreferencesWindow.swift ├── Resources └── example.gif ├── TmpNoteViewController.swift └── tmpNote.entitlements /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | *.xcbkptlist 3 | *.xcuserstate 4 | Pods/Pods.xcodeproj/xcuserdata/bx2.xcuserdatad/xcschemes/xcschememanagement.plist 5 | tmpNote.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist 6 | tmpNote.xcodeproj/xcuserdata/bx2.xcuserdatad/xcschemes/xcschememanagement.plist 7 | .DS_Store 8 | *.xcbkptlist 9 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 buddax2 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /LauncherApplication/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.swift 3 | // LauncherApplication 4 | // 5 | // Created by BUDDAx2 on 9/25/17. 6 | // Copyright © 2017 BUDDAx2. All rights reserved. 7 | // 8 | 9 | import Cocoa 10 | 11 | @NSApplicationMain 12 | class AppDelegate: NSObject, NSApplicationDelegate { 13 | 14 | 15 | 16 | func applicationDidFinishLaunching(_ aNotification: Notification) { 17 | // Insert code here to initialize your application 18 | NSLog("launched tmpNote launcher") 19 | 20 | let mainAppIdentifier = Bundle.main.bundleIdentifier!.replacingOccurrences(of: ".LauncherApplication", with: "") 21 | let runningApps = NSWorkspace.shared.runningApplications 22 | var alreadyRunning = false 23 | 24 | for app in runningApps { 25 | if app.bundleIdentifier == mainAppIdentifier { 26 | alreadyRunning = true 27 | break 28 | } 29 | } 30 | 31 | if alreadyRunning == false { 32 | DistributedNotificationCenter.default().addObserver(self, selector: #selector(terminate), name: Notification.Name(rawValue: "killme"), object: mainAppIdentifier) 33 | 34 | let path = Bundle.main.bundlePath as NSString 35 | var components = path.pathComponents 36 | components.removeLast() 37 | components.removeLast() 38 | components.removeLast() 39 | components.append("MacOS") 40 | components.append("tmpNote") 41 | let newPath = NSString.path(withComponents: components) 42 | NSWorkspace.shared.launchApplication(newPath) 43 | } 44 | else { 45 | terminate() 46 | } 47 | 48 | } 49 | 50 | func applicationWillTerminate(_ aNotification: Notification) { 51 | // Insert code here to tear down your application 52 | } 53 | 54 | @objc func terminate() { 55 | NSApp.terminate(self) 56 | } 57 | 58 | } 59 | 60 | -------------------------------------------------------------------------------- /LauncherApplication/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "mac", 5 | "size" : "16x16", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "mac", 10 | "size" : "16x16", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "mac", 15 | "size" : "32x32", 16 | "scale" : "1x" 17 | }, 18 | { 19 | "idiom" : "mac", 20 | "size" : "32x32", 21 | "scale" : "2x" 22 | }, 23 | { 24 | "idiom" : "mac", 25 | "size" : "128x128", 26 | "scale" : "1x" 27 | }, 28 | { 29 | "idiom" : "mac", 30 | "size" : "128x128", 31 | "scale" : "2x" 32 | }, 33 | { 34 | "idiom" : "mac", 35 | "size" : "256x256", 36 | "scale" : "1x" 37 | }, 38 | { 39 | "idiom" : "mac", 40 | "size" : "256x256", 41 | "scale" : "2x" 42 | }, 43 | { 44 | "idiom" : "mac", 45 | "size" : "512x512", 46 | "scale" : "1x" 47 | }, 48 | { 49 | "idiom" : "mac", 50 | "size" : "512x512", 51 | "scale" : "2x" 52 | } 53 | ], 54 | "info" : { 55 | "version" : 1, 56 | "author" : "xcode" 57 | } 58 | } -------------------------------------------------------------------------------- /LauncherApplication/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIconFile 10 | 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleVersion 22 | 1 23 | LSBackgroundOnly 24 | 25 | LSMinimumSystemVersion 26 | $(MACOSX_DEPLOYMENT_TARGET) 27 | NSHumanReadableCopyright 28 | Copyright © 2017 BUDDAx2. All rights reserved. 29 | NSMainStoryboardFile 30 | Main 31 | NSPrincipalClass 32 | NSApplication 33 | 34 | 35 | -------------------------------------------------------------------------------- /LauncherApplication/LauncherApplication.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | com.apple.security.files.user-selected.read-only 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /Podfile: -------------------------------------------------------------------------------- 1 | use_frameworks! 2 | 3 | target 'tmpNote' do 4 | pod 'MASShortcut' 5 | pod 'SwiftyMarkdown' 6 | end 7 | -------------------------------------------------------------------------------- /Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - MASShortcut (2.3.6) 3 | - SwiftyMarkdown (1.2.2) 4 | 5 | DEPENDENCIES: 6 | - MASShortcut 7 | - SwiftyMarkdown 8 | 9 | SPEC REPOS: 10 | https://github.com/CocoaPods/Specs.git: 11 | - MASShortcut 12 | trunk: 13 | - SwiftyMarkdown 14 | 15 | SPEC CHECKSUMS: 16 | MASShortcut: 9c215e8a8a78f3d01ce56da48e2730ab66b538fa 17 | SwiftyMarkdown: 716936bd2031df713a8d22d166b9408f4884cab3 18 | 19 | PODFILE CHECKSUM: 15de64ce7c892b1c0f643628afa329d8277efe00 20 | 21 | COCOAPODS: 1.9.1 22 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASDictionaryTransformer.h: -------------------------------------------------------------------------------- 1 | extern NSString *const MASDictionaryTransformerName; 2 | 3 | /** 4 | Converts shortcuts for storage in user defaults. 5 | 6 | User defaults can’t stored custom types directly, they have to 7 | be serialized to `NSData` or some other supported type like an 8 | `NSDictionary`. In Cocoa Bindings, the conversion can be done 9 | using value transformers like this one. 10 | 11 | There’s a built-in transformer (`NSKeyedUnarchiveFromDataTransformerName`) 12 | that converts any `NSCoding` types to `NSData`, but with shortcuts 13 | it makes sense to use a dictionary instead – the defaults look better 14 | when inspected with the `defaults` command-line utility and the 15 | format is compatible with an older sortcut library called Shortcut 16 | Recorder. 17 | */ 18 | @interface MASDictionaryTransformer : NSValueTransformer 19 | @end 20 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASDictionaryTransformer.m: -------------------------------------------------------------------------------- 1 | #import "MASDictionaryTransformer.h" 2 | #import "MASShortcut.h" 3 | 4 | NSString *const MASDictionaryTransformerName = @"MASDictionaryTransformer"; 5 | 6 | static NSString *const MASKeyCodeKey = @"keyCode"; 7 | static NSString *const MASModifierFlagsKey = @"modifierFlags"; 8 | 9 | @implementation MASDictionaryTransformer 10 | 11 | + (BOOL) allowsReverseTransformation 12 | { 13 | return YES; 14 | } 15 | 16 | // Storing nil values as an empty dictionary lets us differ between 17 | // “not available, use default value” and “explicitly set to none”. 18 | // See http://stackoverflow.com/questions/5540760 for details. 19 | - (NSDictionary*) reverseTransformedValue: (MASShortcut*) shortcut 20 | { 21 | if (shortcut == nil) { 22 | return [NSDictionary dictionary]; 23 | } else { 24 | return @{ 25 | MASKeyCodeKey: @([shortcut keyCode]), 26 | MASModifierFlagsKey: @([shortcut modifierFlags]) 27 | }; 28 | } 29 | } 30 | 31 | - (MASShortcut*) transformedValue: (NSDictionary*) dictionary 32 | { 33 | // We have to be defensive here as the value may come from user defaults. 34 | if (![dictionary isKindOfClass:[NSDictionary class]]) { 35 | return nil; 36 | } 37 | 38 | id keyCodeBox = [dictionary objectForKey:MASKeyCodeKey]; 39 | id modifierFlagsBox = [dictionary objectForKey:MASModifierFlagsKey]; 40 | 41 | SEL integerValue = @selector(integerValue); 42 | if (![keyCodeBox respondsToSelector:integerValue] || ![modifierFlagsBox respondsToSelector:integerValue]) { 43 | return nil; 44 | } 45 | 46 | return [MASShortcut 47 | shortcutWithKeyCode:[keyCodeBox integerValue] 48 | modifierFlags:[modifierFlagsBox integerValue]]; 49 | } 50 | 51 | @end 52 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASHotKey.h: -------------------------------------------------------------------------------- 1 | #import "MASShortcut.h" 2 | 3 | extern FourCharCode const MASHotKeySignature; 4 | 5 | @interface MASHotKey : NSObject 6 | 7 | @property(readonly) UInt32 carbonID; 8 | @property(copy) dispatch_block_t action; 9 | 10 | + (instancetype) registeredHotKeyWithShortcut: (MASShortcut*) shortcut; 11 | 12 | @end 13 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASHotKey.m: -------------------------------------------------------------------------------- 1 | #import "MASHotKey.h" 2 | 3 | FourCharCode const MASHotKeySignature = 'MASS'; 4 | 5 | @interface MASHotKey () 6 | @property(assign) EventHotKeyRef hotKeyRef; 7 | @property(assign) UInt32 carbonID; 8 | @end 9 | 10 | @implementation MASHotKey 11 | 12 | - (instancetype) initWithShortcut: (MASShortcut*) shortcut 13 | { 14 | self = [super init]; 15 | 16 | static UInt32 CarbonHotKeyID = 0; 17 | 18 | _carbonID = ++CarbonHotKeyID; 19 | EventHotKeyID hotKeyID = { .signature = MASHotKeySignature, .id = _carbonID }; 20 | 21 | OSStatus status = RegisterEventHotKey([shortcut carbonKeyCode], [shortcut carbonFlags], 22 | hotKeyID, GetEventDispatcherTarget(), 0, &_hotKeyRef); 23 | 24 | if (status != noErr) { 25 | return nil; 26 | } 27 | 28 | return self; 29 | } 30 | 31 | + (instancetype) registeredHotKeyWithShortcut: (MASShortcut*) shortcut 32 | { 33 | return [[self alloc] initWithShortcut:shortcut]; 34 | } 35 | 36 | - (void) dealloc 37 | { 38 | if (_hotKeyRef) { 39 | UnregisterEventHotKey(_hotKeyRef); 40 | _hotKeyRef = NULL; 41 | } 42 | } 43 | 44 | @end 45 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASKeyCodes.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | #import "MASKeyMasks.h" 4 | 5 | // These glyphs are missed in Carbon.h 6 | enum { 7 | kMASShortcutGlyphEject = 0x23CF, 8 | kMASShortcutGlyphClear = 0x2715, 9 | kMASShortcutGlyphDeleteLeft = 0x232B, 10 | kMASShortcutGlyphDeleteRight = 0x2326, 11 | kMASShortcutGlyphLeftArrow = 0x2190, 12 | kMASShortcutGlyphRightArrow = 0x2192, 13 | kMASShortcutGlyphUpArrow = 0x2191, 14 | kMASShortcutGlyphDownArrow = 0x2193, 15 | kMASShortcutGlyphEscape = 0x238B, 16 | kMASShortcutGlyphHelp = 0x003F, 17 | kMASShortcutGlyphPageDown = 0x21DF, 18 | kMASShortcutGlyphPageUp = 0x21DE, 19 | kMASShortcutGlyphTabRight = 0x21E5, 20 | kMASShortcutGlyphReturn = 0x2305, 21 | kMASShortcutGlyphReturnR2L = 0x21A9, 22 | kMASShortcutGlyphPadClear = 0x2327, 23 | kMASShortcutGlyphNorthwestArrow = 0x2196, 24 | kMASShortcutGlyphSoutheastArrow = 0x2198, 25 | }; 26 | 27 | NS_INLINE NSString* NSStringFromMASKeyCode(unsigned short ch) 28 | { 29 | return [NSString stringWithFormat:@"%C", ch]; 30 | } 31 | 32 | NS_INLINE NSUInteger MASPickCocoaModifiers(NSUInteger flags) 33 | { 34 | return (flags & (NSEventModifierFlagControl | NSEventModifierFlagShift | NSEventModifierFlagOption | NSEventModifierFlagCommand)); 35 | } 36 | 37 | NS_INLINE UInt32 MASCarbonModifiersFromCocoaModifiers(NSUInteger cocoaFlags) 38 | { 39 | return 40 | (cocoaFlags & NSEventModifierFlagCommand ? cmdKey : 0) 41 | | (cocoaFlags & NSEventModifierFlagOption ? optionKey : 0) 42 | | (cocoaFlags & NSEventModifierFlagControl ? controlKey : 0) 43 | | (cocoaFlags & NSEventModifierFlagShift ? shiftKey : 0); 44 | } 45 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASKeyMasks.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | // https://github.com/shpakovski/MASShortcut/issues/99 4 | // 5 | // Long story short: NSControlKeyMask and friends were replaced with NSEventModifierFlagControl 6 | // and similar in macOS Sierra. The project builds fine & clean, but including MASShortcut in 7 | // a project with deployment target set to 10.12 results in several deprecation warnings because 8 | // of the control masks. Simply replacing the old symbols with the new ones isn’t an option, 9 | // since it breaks the build on older SDKs – in Travis, for example. 10 | // 11 | // It should be safe to remove this whole thing once the 10.12 SDK is ubiquitous. 12 | 13 | #if __MAC_OS_X_VERSION_MAX_ALLOWED < 101200 14 | #define NSEventModifierFlagCommand NSCommandKeyMask 15 | #define NSEventModifierFlagControl NSControlKeyMask 16 | #define NSEventModifierFlagOption NSAlternateKeyMask 17 | #define NSEventModifierFlagShift NSShiftKeyMask 18 | #endif 19 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASLocalization.h: -------------------------------------------------------------------------------- 1 | /** 2 | Reads a localized string from the framework’s bundle. 3 | 4 | Normally you would use NSLocalizedString to read the localized 5 | strings, but that’s just a shortcut for loading the strings from 6 | the main bundle. And once the framework ends up in an app, the 7 | main bundle will be the app’s bundle and won’t contain our strings. 8 | So we introduced this helper function that makes sure to load the 9 | strings from the framework’s bundle. Please avoid using 10 | NSLocalizedString throughout the framework, it wouldn’t work 11 | properly. 12 | */ 13 | NSString *MASLocalizedString(NSString *key, NSString *comment); -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASLocalization.m: -------------------------------------------------------------------------------- 1 | #import "MASLocalization.h" 2 | #import "MASShortcut.h" 3 | 4 | static NSString *const MASLocalizationTableName = @"Localizable"; 5 | static NSString *const MASPlaceholderLocalizationString = @"XXX"; 6 | 7 | // The CocoaPods trickery here is needed because when the code 8 | // is built as a part of CocoaPods, it won’t make a separate framework 9 | // and the Localized.strings file won’t be bundled correctly. 10 | // See https://github.com/shpakovski/MASShortcut/issues/74 11 | NSString *MASLocalizedString(NSString *key, NSString *comment) { 12 | static NSBundle *localizationBundle = nil; 13 | static dispatch_once_t onceToken; 14 | dispatch_once(&onceToken, ^{ 15 | NSBundle *frameworkBundle = [NSBundle bundleForClass:[MASShortcut class]]; 16 | // first we'll check if resources bundle was copied to MASShortcut framework bundle when !use_frameworks option is active 17 | NSURL *cocoaPodsBundleURL = [frameworkBundle URLForResource:@"MASShortcut" withExtension:@"bundle"]; 18 | if (cocoaPodsBundleURL) { 19 | localizationBundle = [NSBundle bundleWithURL: cocoaPodsBundleURL]; 20 | } else { 21 | // trying to fetch cocoapods bundle from main bundle 22 | cocoaPodsBundleURL = [[NSBundle mainBundle] URLForResource: @"MASShortcut" withExtension:@"bundle"]; 23 | if (cocoaPodsBundleURL) { 24 | localizationBundle = [NSBundle bundleWithURL: cocoaPodsBundleURL]; 25 | } else { 26 | // fallback to framework bundle 27 | localizationBundle = frameworkBundle; 28 | } 29 | } 30 | }); 31 | return [localizationBundle localizedStringForKey:key 32 | value:MASPlaceholderLocalizationString 33 | table:MASLocalizationTableName]; 34 | } 35 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcut.h: -------------------------------------------------------------------------------- 1 | #import "MASKeyCodes.h" 2 | 3 | /** 4 | A model class to hold a key combination. 5 | 6 | This class just represents a combination of keys. It does not care if 7 | the combination is valid or can be used as a hotkey, it doesn’t watch 8 | the input system for the shortcut appearance, nor it does access user 9 | defaults. 10 | */ 11 | @interface MASShortcut : NSObject 12 | 13 | /** 14 | The virtual key code for the keyboard key. 15 | 16 | Hardware independent, same as in `NSEvent`. See `Events.h` in the HIToolbox 17 | framework for a complete list, or Command-click this symbol: `kVK_ANSI_A`. 18 | */ 19 | @property (nonatomic, readonly) NSUInteger keyCode; 20 | 21 | /** 22 | Cocoa keyboard modifier flags. 23 | 24 | Same as in `NSEvent`: `NSCommandKeyMask`, `NSAlternateKeyMask`, etc. 25 | */ 26 | @property (nonatomic, readonly) NSUInteger modifierFlags; 27 | 28 | /** 29 | Same as `keyCode`, just a different type. 30 | */ 31 | @property (nonatomic, readonly) UInt32 carbonKeyCode; 32 | 33 | /** 34 | Carbon modifier flags. 35 | 36 | A bit sum of `cmdKey`, `optionKey`, etc. 37 | */ 38 | @property (nonatomic, readonly) UInt32 carbonFlags; 39 | 40 | /** 41 | A string representing the “key” part of a shortcut, like the `5` in `⌘5`. 42 | 43 | @warning The value may change depending on the active keyboard layout. 44 | For example for the `^2` keyboard shortcut (`kVK_ANSI_2+NSControlKeyMask` 45 | to be precise) the `keyCodeString` is `2` on the US keyboard, but `ě` when 46 | the Czech keyboard layout is active. See the spec for details. 47 | */ 48 | @property (nonatomic, readonly) NSString *keyCodeString; 49 | 50 | /** 51 | A key-code string used in key equivalent matching. 52 | 53 | For precise meaning of “key equivalents” see the `keyEquivalent` 54 | property of `NSMenuItem`. Here the string is used to support shortcut 55 | validation (“is the shortcut already taken in this menu?”) and 56 | for display in `NSMenu`. 57 | 58 | The value of this property may differ from `keyCodeString`. For example 59 | the Russian keyboard has a `Г` (Ge) Cyrillic character in place of the 60 | latin `U` key. This means you can create a `^Г` shortcut, but in menus 61 | that’s always displayed as `^U`. So the `keyCodeString` returns `Г` 62 | and `keyCodeStringForKeyEquivalent` returns `U`. 63 | */ 64 | @property (nonatomic, readonly) NSString *keyCodeStringForKeyEquivalent; 65 | 66 | /** 67 | A string representing the shortcut modifiers, like the `⌘` in `⌘5`. 68 | */ 69 | @property (nonatomic, readonly) NSString *modifierFlagsString; 70 | 71 | - (instancetype)initWithKeyCode:(NSUInteger)code modifierFlags:(NSUInteger)flags; 72 | + (instancetype)shortcutWithKeyCode:(NSUInteger)code modifierFlags:(NSUInteger)flags; 73 | 74 | /** 75 | Creates a new shortcut from an `NSEvent` object. 76 | 77 | This is just a convenience initializer that reads the key code and modifiers from an `NSEvent`. 78 | */ 79 | + (instancetype)shortcutWithEvent:(NSEvent *)anEvent; 80 | 81 | @end 82 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcut.modulemap: -------------------------------------------------------------------------------- 1 | framework module MASShortcut { 2 | umbrella header "Shortcut.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcutBinder.h: -------------------------------------------------------------------------------- 1 | #import "MASShortcutMonitor.h" 2 | 3 | /** 4 | Binds actions to user defaults keys. 5 | 6 | If you store shortcuts in user defaults (for example by binding 7 | a `MASShortcutView` to user defaults), you can use this class to 8 | connect an action directly to a user defaults key. If the shortcut 9 | stored under the key changes, the action will get automatically 10 | updated to the new one. 11 | 12 | This class is mostly a wrapper around a `MASShortcutMonitor`. It 13 | watches the changes in user defaults and updates the shortcut monitor 14 | accordingly with the new shortcuts. 15 | */ 16 | @interface MASShortcutBinder : NSObject 17 | 18 | /** 19 | A convenience shared instance. 20 | 21 | You may use it so that you don’t have to manage an instance by hand, 22 | but it’s perfectly fine to allocate and use a separate instance instead. 23 | */ 24 | + (instancetype) sharedBinder; 25 | 26 | /** 27 | The underlying shortcut monitor. 28 | */ 29 | @property(strong) MASShortcutMonitor *shortcutMonitor; 30 | 31 | /** 32 | Binding options customizing the access to user defaults. 33 | 34 | As an example, you can use `NSValueTransformerNameBindingOption` to customize 35 | the storage format used for the shortcuts. By default the shortcuts are converted 36 | from `NSData` (`NSKeyedUnarchiveFromDataTransformerName`). Note that if the 37 | binder is to work with `MASShortcutView`, both object have to use the same storage 38 | format. 39 | */ 40 | @property(copy) NSDictionary *bindingOptions; 41 | 42 | /** 43 | Binds given action to a shortcut stored under the given defaults key. 44 | 45 | In other words, no matter what shortcut you store under the given key, 46 | pressing it will always trigger the given action. 47 | */ 48 | - (void) bindShortcutWithDefaultsKey: (NSString*) defaultsKeyName toAction: (dispatch_block_t) action; 49 | 50 | /** 51 | Disconnect the binding between user defaults and action. 52 | 53 | In other words, the shortcut stored under the given key will no longer trigger an action. 54 | */ 55 | - (void) breakBindingWithDefaultsKey: (NSString*) defaultsKeyName; 56 | 57 | /** 58 | Register default shortcuts in user defaults. 59 | 60 | This is a convenience frontent to `[NSUserDefaults registerDefaults]`. 61 | The dictionary should contain a map of user defaults’ keys to appropriate 62 | keyboard shortcuts. The shortcuts will be transformed according to 63 | `bindingOptions` and registered using `registerDefaults`. 64 | */ 65 | - (void) registerDefaultShortcuts: (NSDictionary*) defaultShortcuts; 66 | 67 | @end 68 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcutBinder.m: -------------------------------------------------------------------------------- 1 | #import "MASShortcutBinder.h" 2 | #import "MASShortcut.h" 3 | 4 | @interface MASShortcutBinder () 5 | @property(strong) NSMutableDictionary *actions; 6 | @property(strong) NSMutableDictionary *shortcuts; 7 | @end 8 | 9 | @implementation MASShortcutBinder 10 | 11 | #pragma mark Initialization 12 | 13 | - (id) init 14 | { 15 | self = [super init]; 16 | [self setActions:[NSMutableDictionary dictionary]]; 17 | [self setShortcuts:[NSMutableDictionary dictionary]]; 18 | [self setShortcutMonitor:[MASShortcutMonitor sharedMonitor]]; 19 | [self setBindingOptions:@{NSValueTransformerNameBindingOption: NSKeyedUnarchiveFromDataTransformerName}]; 20 | return self; 21 | } 22 | 23 | - (void) dealloc 24 | { 25 | for (NSString *bindingName in [_actions allKeys]) { 26 | [self unbind:bindingName]; 27 | } 28 | } 29 | 30 | + (instancetype) sharedBinder 31 | { 32 | static dispatch_once_t once; 33 | static MASShortcutBinder *sharedInstance; 34 | dispatch_once(&once, ^{ 35 | sharedInstance = [[self alloc] init]; 36 | }); 37 | return sharedInstance; 38 | } 39 | 40 | #pragma mark Registration 41 | 42 | - (void) bindShortcutWithDefaultsKey: (NSString*) defaultsKeyName toAction: (dispatch_block_t) action 43 | { 44 | NSAssert([defaultsKeyName rangeOfString:@"."].location == NSNotFound, 45 | @"Illegal character in binding name (“.”), please see http://git.io/x5YS."); 46 | NSAssert([defaultsKeyName rangeOfString:@" "].location == NSNotFound, 47 | @"Illegal character in binding name (“ ”), please see http://git.io/x5YS."); 48 | [_actions setObject:[action copy] forKey:defaultsKeyName]; 49 | [self bind:defaultsKeyName 50 | toObject:[NSUserDefaultsController sharedUserDefaultsController] 51 | withKeyPath:[@"values." stringByAppendingString:defaultsKeyName] 52 | options:_bindingOptions]; 53 | } 54 | 55 | - (void) breakBindingWithDefaultsKey: (NSString*) defaultsKeyName 56 | { 57 | [_shortcutMonitor unregisterShortcut:[_shortcuts objectForKey:defaultsKeyName]]; 58 | [_shortcuts removeObjectForKey:defaultsKeyName]; 59 | [_actions removeObjectForKey:defaultsKeyName]; 60 | [self unbind:defaultsKeyName]; 61 | } 62 | 63 | - (void) registerDefaultShortcuts: (NSDictionary*) defaultShortcuts 64 | { 65 | NSValueTransformer *transformer = [_bindingOptions valueForKey:NSValueTransformerBindingOption]; 66 | if (transformer == nil) { 67 | NSString *transformerName = [_bindingOptions valueForKey:NSValueTransformerNameBindingOption]; 68 | if (transformerName) { 69 | transformer = [NSValueTransformer valueTransformerForName:transformerName]; 70 | } 71 | } 72 | 73 | NSAssert(transformer != nil, @"Can’t register default shortcuts without a transformer."); 74 | 75 | [defaultShortcuts enumerateKeysAndObjectsUsingBlock:^(NSString *defaultsKey, MASShortcut *shortcut, BOOL *stop) { 76 | id value = [transformer reverseTransformedValue:shortcut]; 77 | [[NSUserDefaults standardUserDefaults] registerDefaults:@{defaultsKey:value}]; 78 | }]; 79 | } 80 | 81 | #pragma mark Bindings 82 | 83 | - (BOOL) isRegisteredAction: (NSString*) name 84 | { 85 | return !![_actions objectForKey:name]; 86 | } 87 | 88 | - (id) valueForUndefinedKey: (NSString*) key 89 | { 90 | return [self isRegisteredAction:key] ? 91 | [_shortcuts objectForKey:key] : 92 | [super valueForUndefinedKey:key]; 93 | } 94 | 95 | - (void) setValue: (id) value forUndefinedKey: (NSString*) key 96 | { 97 | if (![self isRegisteredAction:key]) { 98 | [super setValue:value forUndefinedKey:key]; 99 | return; 100 | } 101 | 102 | MASShortcut *newShortcut = value; 103 | MASShortcut *currentShortcut = [_shortcuts objectForKey:key]; 104 | 105 | // Unbind previous shortcut if any 106 | if (currentShortcut != nil) { 107 | [_shortcutMonitor unregisterShortcut:currentShortcut]; 108 | } 109 | 110 | // Just deleting the old shortcut 111 | if (newShortcut == nil) { 112 | [_shortcuts removeObjectForKey:key]; 113 | return; 114 | } 115 | 116 | // Bind new shortcut 117 | [_shortcuts setObject:newShortcut forKey:key]; 118 | [_shortcutMonitor registerShortcut:newShortcut withAction:[_actions objectForKey:key]]; 119 | } 120 | 121 | @end 122 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcutMonitor.h: -------------------------------------------------------------------------------- 1 | #import "MASShortcut.h" 2 | 3 | /** 4 | Executes action when a shortcut is pressed. 5 | 6 | There can only be one instance of this class, otherwise things 7 | will probably not work. (There’s a Carbon event handler inside 8 | and there can only be one Carbon event handler of a given type.) 9 | */ 10 | @interface MASShortcutMonitor : NSObject 11 | 12 | - (instancetype) init __unavailable; 13 | + (instancetype) sharedMonitor; 14 | 15 | /** 16 | Register a shortcut along with an action. 17 | 18 | Attempting to insert an already registered shortcut probably won’t work. 19 | It may burn your house or cut your fingers. You have been warned. 20 | */ 21 | - (BOOL) registerShortcut: (MASShortcut*) shortcut withAction: (dispatch_block_t) action; 22 | - (BOOL) isShortcutRegistered: (MASShortcut*) shortcut; 23 | 24 | - (void) unregisterShortcut: (MASShortcut*) shortcut; 25 | - (void) unregisterAllShortcuts; 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcutMonitor.m: -------------------------------------------------------------------------------- 1 | #import "MASShortcutMonitor.h" 2 | #import "MASHotKey.h" 3 | 4 | @interface MASShortcutMonitor () 5 | @property(assign) EventHandlerRef eventHandlerRef; 6 | @property(strong) NSMutableDictionary *hotKeys; 7 | @end 8 | 9 | static OSStatus MASCarbonEventCallback(EventHandlerCallRef, EventRef, void*); 10 | 11 | @implementation MASShortcutMonitor 12 | 13 | #pragma mark Initialization 14 | 15 | - (instancetype) init 16 | { 17 | self = [super init]; 18 | [self setHotKeys:[NSMutableDictionary dictionary]]; 19 | EventTypeSpec hotKeyPressedSpec = { .eventClass = kEventClassKeyboard, .eventKind = kEventHotKeyPressed }; 20 | OSStatus status = InstallEventHandler(GetEventDispatcherTarget(), MASCarbonEventCallback, 21 | 1, &hotKeyPressedSpec, (__bridge void*)self, &_eventHandlerRef); 22 | if (status != noErr) { 23 | return nil; 24 | } 25 | return self; 26 | } 27 | 28 | - (void) dealloc 29 | { 30 | if (_eventHandlerRef) { 31 | RemoveEventHandler(_eventHandlerRef); 32 | _eventHandlerRef = NULL; 33 | } 34 | } 35 | 36 | + (instancetype) sharedMonitor 37 | { 38 | static dispatch_once_t once; 39 | static MASShortcutMonitor *sharedInstance; 40 | dispatch_once(&once, ^{ 41 | sharedInstance = [[self alloc] init]; 42 | }); 43 | return sharedInstance; 44 | } 45 | 46 | #pragma mark Registration 47 | 48 | - (BOOL) registerShortcut: (MASShortcut*) shortcut withAction: (dispatch_block_t) action 49 | { 50 | MASHotKey *hotKey = [MASHotKey registeredHotKeyWithShortcut:shortcut]; 51 | if (hotKey) { 52 | [hotKey setAction:action]; 53 | [_hotKeys setObject:hotKey forKey:shortcut]; 54 | return YES; 55 | } else { 56 | return NO; 57 | } 58 | } 59 | 60 | - (void) unregisterShortcut: (MASShortcut*) shortcut 61 | { 62 | if (shortcut) { 63 | [_hotKeys removeObjectForKey:shortcut]; 64 | } 65 | } 66 | 67 | - (void) unregisterAllShortcuts 68 | { 69 | [_hotKeys removeAllObjects]; 70 | } 71 | 72 | - (BOOL) isShortcutRegistered: (MASShortcut*) shortcut 73 | { 74 | return !![_hotKeys objectForKey:shortcut]; 75 | } 76 | 77 | #pragma mark Event Handling 78 | 79 | - (void) handleEvent: (EventRef) event 80 | { 81 | if (GetEventClass(event) != kEventClassKeyboard) { 82 | return; 83 | } 84 | 85 | EventHotKeyID hotKeyID; 86 | OSStatus status = GetEventParameter(event, kEventParamDirectObject, typeEventHotKeyID, NULL, sizeof(hotKeyID), NULL, &hotKeyID); 87 | if (status != noErr || hotKeyID.signature != MASHotKeySignature) { 88 | return; 89 | } 90 | 91 | [_hotKeys enumerateKeysAndObjectsUsingBlock:^(MASShortcut *shortcut, MASHotKey *hotKey, BOOL *stop) { 92 | if (hotKeyID.id == [hotKey carbonID]) { 93 | if ([hotKey action]) { 94 | dispatch_async(dispatch_get_main_queue(), [hotKey action]); 95 | } 96 | *stop = YES; 97 | } 98 | }]; 99 | } 100 | 101 | @end 102 | 103 | static OSStatus MASCarbonEventCallback(EventHandlerCallRef _, EventRef event, void *context) 104 | { 105 | MASShortcutMonitor *dispatcher = (__bridge id)context; 106 | [dispatcher handleEvent:event]; 107 | return noErr; 108 | } 109 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcutValidator.h: -------------------------------------------------------------------------------- 1 | #import "MASShortcut.h" 2 | 3 | /** 4 | This class is used by the recording control to tell which shortcuts are acceptable. 5 | 6 | There are two kinds of shortcuts that are not considered acceptable: shortcuts that 7 | are too simple (like single letter keys) and shortcuts that are already used by the 8 | operating system. 9 | */ 10 | @interface MASShortcutValidator : NSObject 11 | 12 | /** 13 | Set to `YES` if you want to accept Option-something shortcuts. 14 | 15 | `NO` by default, since Option-something shortcuts are often used by system, 16 | for example Option-G will type the © sign. This also applies to Option-Shift 17 | shortcuts – in other words, shortcut recorder will not accept shortcuts like 18 | Option-Shift-K by default. (Again, since Option-Shift-K inserts the Apple 19 | logo sign by default.) 20 | */ 21 | @property(assign) BOOL allowAnyShortcutWithOptionModifier; 22 | 23 | + (instancetype) sharedValidator; 24 | 25 | - (BOOL) isShortcutValid: (MASShortcut*) shortcut; 26 | - (BOOL) isShortcut: (MASShortcut*) shortcut alreadyTakenInMenu: (NSMenu*) menu explanation: (NSString**) explanation; 27 | - (BOOL) isShortcutAlreadyTakenBySystem: (MASShortcut*) shortcut explanation: (NSString**) explanation; 28 | 29 | @end 30 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcutValidator.m: -------------------------------------------------------------------------------- 1 | #import "MASShortcutValidator.h" 2 | #import "MASLocalization.h" 3 | 4 | @implementation MASShortcutValidator 5 | 6 | + (instancetype) sharedValidator 7 | { 8 | static dispatch_once_t once; 9 | static MASShortcutValidator *sharedInstance; 10 | dispatch_once(&once, ^{ 11 | sharedInstance = [[self alloc] init]; 12 | }); 13 | return sharedInstance; 14 | } 15 | 16 | - (BOOL) isShortcutValid: (MASShortcut*) shortcut 17 | { 18 | NSUInteger keyCode = [shortcut keyCode]; 19 | NSUInteger modifiers = [shortcut modifierFlags]; 20 | 21 | // Allow any function key with any combination of modifiers 22 | BOOL includesFunctionKey = ((keyCode == kVK_F1) || (keyCode == kVK_F2) || (keyCode == kVK_F3) || (keyCode == kVK_F4) || 23 | (keyCode == kVK_F5) || (keyCode == kVK_F6) || (keyCode == kVK_F7) || (keyCode == kVK_F8) || 24 | (keyCode == kVK_F9) || (keyCode == kVK_F10) || (keyCode == kVK_F11) || (keyCode == kVK_F12) || 25 | (keyCode == kVK_F13) || (keyCode == kVK_F14) || (keyCode == kVK_F15) || (keyCode == kVK_F16) || 26 | (keyCode == kVK_F17) || (keyCode == kVK_F18) || (keyCode == kVK_F19) || (keyCode == kVK_F20)); 27 | if (includesFunctionKey) return YES; 28 | 29 | // Do not allow any other key without modifiers 30 | BOOL hasModifierFlags = (modifiers > 0); 31 | if (!hasModifierFlags) return NO; 32 | 33 | // Allow any hotkey containing Control or Command modifier 34 | BOOL includesCommand = ((modifiers & NSCommandKeyMask) > 0); 35 | BOOL includesControl = ((modifiers & NSControlKeyMask) > 0); 36 | if (includesCommand || includesControl) return YES; 37 | 38 | // Allow Option key only in selected cases 39 | BOOL includesOption = ((modifiers & NSAlternateKeyMask) > 0); 40 | if (includesOption) { 41 | 42 | // Always allow Option-Space and Option-Escape because they do not have any bind system commands 43 | if ((keyCode == kVK_Space) || (keyCode == kVK_Escape)) return YES; 44 | 45 | // Allow Option modifier with any key even if it will break the system binding 46 | if (_allowAnyShortcutWithOptionModifier) return YES; 47 | } 48 | 49 | // The hotkey does not have any modifiers or violates system bindings 50 | return NO; 51 | } 52 | 53 | - (BOOL) isShortcut: (MASShortcut*) shortcut alreadyTakenInMenu: (NSMenu*) menu explanation: (NSString**) explanation 54 | { 55 | NSString *keyEquivalent = [shortcut keyCodeStringForKeyEquivalent]; 56 | NSUInteger flags = [shortcut modifierFlags]; 57 | 58 | for (NSMenuItem *menuItem in menu.itemArray) { 59 | if (menuItem.hasSubmenu && [self isShortcut:shortcut alreadyTakenInMenu:[menuItem submenu] explanation:explanation]) return YES; 60 | 61 | BOOL equalFlags = (MASPickCocoaModifiers(menuItem.keyEquivalentModifierMask) == flags); 62 | BOOL equalHotkeyLowercase = [menuItem.keyEquivalent.lowercaseString isEqualToString:keyEquivalent]; 63 | 64 | // Check if the cases are different, we know ours is lower and that shift is included in our modifiers 65 | // If theirs is capitol, we need to add shift to their modifiers 66 | if (equalHotkeyLowercase && ![menuItem.keyEquivalent isEqualToString:keyEquivalent]) { 67 | equalFlags = (MASPickCocoaModifiers(menuItem.keyEquivalentModifierMask | NSShiftKeyMask) == flags); 68 | } 69 | 70 | if (equalFlags && equalHotkeyLowercase) { 71 | if (explanation) { 72 | *explanation = MASLocalizedString(@"This shortcut cannot be used because it is already used by the menu item ‘%@’.", 73 | @"Message for alert when shortcut is already used"); 74 | *explanation = [NSString stringWithFormat:*explanation, menuItem.title]; 75 | } 76 | return YES; 77 | } 78 | } 79 | return NO; 80 | } 81 | 82 | - (BOOL) isShortcutAlreadyTakenBySystem: (MASShortcut*) shortcut explanation: (NSString**) explanation 83 | { 84 | CFArrayRef globalHotKeys; 85 | if (CopySymbolicHotKeys(&globalHotKeys) == noErr) { 86 | 87 | // Enumerate all global hotkeys and check if any of them matches current shortcut 88 | for (CFIndex i = 0, count = CFArrayGetCount(globalHotKeys); i < count; i++) { 89 | CFDictionaryRef hotKeyInfo = CFArrayGetValueAtIndex(globalHotKeys, i); 90 | CFNumberRef code = CFDictionaryGetValue(hotKeyInfo, kHISymbolicHotKeyCode); 91 | CFNumberRef flags = CFDictionaryGetValue(hotKeyInfo, kHISymbolicHotKeyModifiers); 92 | CFNumberRef enabled = CFDictionaryGetValue(hotKeyInfo, kHISymbolicHotKeyEnabled); 93 | 94 | if (([(__bridge NSNumber *)code unsignedIntegerValue] == [shortcut keyCode]) && 95 | ([(__bridge NSNumber *)flags unsignedIntegerValue] == [shortcut carbonFlags]) && 96 | ([(__bridge NSNumber *)enabled boolValue])) { 97 | 98 | if (explanation) { 99 | *explanation = MASLocalizedString(@"This combination cannot be used because it is already used by a system-wide " 100 | @"keyboard shortcut.\nIf you really want to use this key combination, most shortcuts " 101 | @"can be changed in the Keyboard & Mouse panel in System Preferences.", 102 | @"Message for alert when shortcut is already used by the system"); 103 | } 104 | return YES; 105 | } 106 | } 107 | CFRelease(globalHotKeys); 108 | } 109 | return [self isShortcut:shortcut alreadyTakenInMenu:[NSApp mainMenu] explanation:explanation]; 110 | } 111 | 112 | @end 113 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcutView+Bindings.h: -------------------------------------------------------------------------------- 1 | #import "MASShortcutView.h" 2 | 3 | /** 4 | A simplified interface to bind the recorder value to user defaults. 5 | 6 | You can bind the `shortcutValue` to user defaults using the standard 7 | `bind:toObject:withKeyPath:options:` call, but since that’s a lot to type 8 | and read, here’s a simpler option. 9 | 10 | Setting the `associatedUserDefaultsKey` binds the view’s shortcut value 11 | to the given user defaults key. You can supply a value transformer to convert 12 | values between user defaults and `MASShortcut`. If you don’t supply 13 | a transformer, the `NSUnarchiveFromDataTransformerName` will be used 14 | automatically. 15 | 16 | Set `associatedUserDefaultsKey` to `nil` to disconnect the binding. 17 | */ 18 | @interface MASShortcutView (Bindings) 19 | 20 | @property(copy) NSString *associatedUserDefaultsKey; 21 | 22 | - (void) setAssociatedUserDefaultsKey: (NSString*) newKey withTransformer: (NSValueTransformer*) transformer; 23 | - (void) setAssociatedUserDefaultsKey: (NSString*) newKey withTransformerName: (NSString*) transformerName; 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcutView+Bindings.m: -------------------------------------------------------------------------------- 1 | #import "MASShortcutView+Bindings.h" 2 | 3 | @implementation MASShortcutView (Bindings) 4 | 5 | - (NSString*) associatedUserDefaultsKey 6 | { 7 | NSDictionary* bindingInfo = [self infoForBinding:MASShortcutBinding]; 8 | if (bindingInfo != nil) { 9 | NSString *keyPath = [bindingInfo objectForKey:NSObservedKeyPathKey]; 10 | NSString *key = [keyPath stringByReplacingOccurrencesOfString:@"values." withString:@""]; 11 | return key; 12 | } else { 13 | return nil; 14 | } 15 | } 16 | 17 | - (void) setAssociatedUserDefaultsKey: (NSString*) newKey withTransformer: (NSValueTransformer*) transformer 18 | { 19 | // Break previous binding if any 20 | NSString *currentKey = [self associatedUserDefaultsKey]; 21 | if (currentKey != nil) { 22 | [self unbind:currentKey]; 23 | } 24 | 25 | // Stop if the new binding is nil 26 | if (newKey == nil) { 27 | return; 28 | } 29 | 30 | NSDictionary *options = transformer ? 31 | @{NSValueTransformerBindingOption:transformer} : 32 | nil; 33 | 34 | [self bind:MASShortcutBinding 35 | toObject:[NSUserDefaultsController sharedUserDefaultsController] 36 | withKeyPath:[@"values." stringByAppendingString:newKey] 37 | options:options]; 38 | } 39 | 40 | - (void) setAssociatedUserDefaultsKey: (NSString*) newKey withTransformerName: (NSString*) transformerName 41 | { 42 | [self setAssociatedUserDefaultsKey:newKey withTransformer:[NSValueTransformer valueTransformerForName:transformerName]]; 43 | } 44 | 45 | - (void) setAssociatedUserDefaultsKey: (NSString*) newKey 46 | { 47 | [self setAssociatedUserDefaultsKey:newKey withTransformerName:NSKeyedUnarchiveFromDataTransformerName]; 48 | } 49 | 50 | @end 51 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/MASShortcutView.h: -------------------------------------------------------------------------------- 1 | @class MASShortcut, MASShortcutValidator; 2 | 3 | extern NSString *const MASShortcutBinding; 4 | 5 | typedef enum { 6 | MASShortcutViewStyleDefault = 0, // Height = 19 px 7 | MASShortcutViewStyleTexturedRect, // Height = 25 px 8 | MASShortcutViewStyleRounded, // Height = 43 px 9 | MASShortcutViewStyleFlat 10 | } MASShortcutViewStyle; 11 | 12 | @interface MASShortcutView : NSView 13 | 14 | @property (nonatomic, strong) MASShortcut *shortcutValue; 15 | @property (nonatomic, strong) MASShortcutValidator *shortcutValidator; 16 | @property (nonatomic, getter = isRecording) BOOL recording; 17 | @property (nonatomic, getter = isEnabled) BOOL enabled; 18 | @property (nonatomic, copy) void (^shortcutValueChange)(MASShortcutView *sender); 19 | @property (nonatomic, assign) MASShortcutViewStyle style; 20 | 21 | /// Returns custom class for drawing control. 22 | + (Class)shortcutCellClass; 23 | 24 | - (void)setAcceptsFirstResponder:(BOOL)value; 25 | 26 | @end 27 | -------------------------------------------------------------------------------- /Pods/MASShortcut/Framework/Shortcut.h: -------------------------------------------------------------------------------- 1 | #import "MASKeyMasks.h" 2 | #import "MASShortcut.h" 3 | #import "MASShortcutValidator.h" 4 | #import "MASShortcutMonitor.h" 5 | #import "MASShortcutBinder.h" 6 | #import "MASDictionaryTransformer.h" 7 | #import "MASShortcutView.h" 8 | #import "MASShortcutView+Bindings.h" 9 | -------------------------------------------------------------------------------- /Pods/MASShortcut/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2012-2013, Vadim Shpakovski 2 | All rights reserved. 3 | 4 | Redistribution and use in source and binary forms, with or without 5 | modification, are permitted provided that the following conditions are met: 6 | 7 | 1. Redistributions of source code must retain the above copyright notice, this 8 | list of conditions and the following disclaimer. 9 | 2. Redistributions in binary form must reproduce the above copyright notice, 10 | this list of conditions and the following disclaimer in the documentation 11 | and/or other materials provided with the distribution. 12 | 13 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 14 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 15 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 16 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 17 | ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 18 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 19 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 20 | ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 21 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 22 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 23 | -------------------------------------------------------------------------------- /Pods/MASShortcut/README.md: -------------------------------------------------------------------------------- 1 | [![Build Status](https://travis-ci.org/shpakovski/MASShortcut.svg?branch=master)](https://travis-ci.org/shpakovski/MASShortcut) 2 | [![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage) 3 | 4 | # Intro 5 | 6 | Some time ago Cocoa developers used a brilliant framework [ShortcutRecorder](http://wafflesoftware.net/shortcut/) for managing keyboard shortcuts in application preferences. However, it became incompatible with the new plugin architecture of Xcode 4. 7 | 8 | The MASShortcut project introduces a modern API and user interface for recording, storing and using system-wide keyboard shortcuts. 9 | 10 | ![Screenshot of the demo project](https://raw.githubusercontent.com/shpakovski/MASShortcut/master/Demo/screenshot.png "This is how the demo looks like") 11 | 12 | Features: 13 | 14 | * Record and display keyboard shortcuts 15 | * Watch for shortcuts and execute actions, system-wide 16 | * A nice, [documented API](http://cocoadocs.org/docsets/MASShortcut/) 17 | * Can be configured to be compatible with Shortcut Recorder 18 | * Can be installed both through CocoaPods and as a Git submodule 19 | * Mac App Store friendly 20 | * Works on OS X 10.6 and up 21 | * Hacking-friendly codebase covered with tests 22 | 23 | Partially done: 24 | 25 | * Accessibility support. There’s some basic accessibility code, testers and feedback welcome. 26 | * Localisation. The English and Czech localization should be complete, there’s basic support for German, French, Spanish, Italian, and Japanese. If you’re a native speaker in one of the mentioned languages, please test the localization and report issues or add missing strings. 27 | 28 | Pull requests welcome :) 29 | 30 | # Installation 31 | 32 | You can use [CocoaPods](http://cocoapods.org/), adding the following line to your Podfile: 33 | 34 | pod 'MASShortcut' 35 | 36 | If you want to stick to the 1.x branch, you can use the version smart match operator: 37 | 38 | pod 'MASShortcut', '~> 1' 39 | 40 | You can also install via [Carthage](https://github.com/Carthage/Carthage), or you can use Git submodules and link against the MASShortcut framework manually. 41 | 42 | To build from the command line, type 'make release'. The framework will be created in a temporary directory and revealed in Finder when the build is complete. 43 | 44 | # Usage 45 | 46 | I hope, it is really easy: 47 | 48 | ```objective-c 49 | #import 50 | 51 | // Drop a custom view into XIB, set its class to MASShortcutView 52 | // and its height to 19. If you select another appearance style, 53 | // look up the correct height values in MASShortcutView.h. 54 | @property (nonatomic, weak) IBOutlet MASShortcutView *shortcutView; 55 | 56 | // Pick a preference key to store the shortcut between launches 57 | static NSString *const kPreferenceGlobalShortcut = @"GlobalShortcut"; 58 | 59 | // Associate the shortcut view with user defaults 60 | self.shortcutView.associatedUserDefaultsKey = kPreferenceGlobalShortcut; 61 | 62 | // Associate the preference key with an action 63 | [[MASShortcutBinder sharedBinder] 64 | bindShortcutWithDefaultsKey:kPreferenceGlobalShortcut 65 | toAction:^{ 66 | // Let me know if you find a better or a more convenient API. 67 | }]; 68 | ``` 69 | 70 | You can see a real usage example in the Demo target. Enjoy! 71 | 72 | # Shortcut Recorder Compatibility 73 | 74 | By default, MASShortcut uses a different User Defaults storage format incompatible with Shortcut Recorder. But it’s easily possible to change that, so that you can replace Shortcut Recorder with MASShortcut without having to migrate the shortcuts previously stored by your apps. There are two parts of the story: 75 | 76 | If you bind the recorder control (`MASShortcutView`) to User defaults, set the Value Transformer field in the Interface Builder to `MASDictionaryTransformer`. This makes sure the shortcuts are written in the Shortcut Recorder format. 77 | 78 | If you use `MASShortcutBinder` to automatically load shortcuts from User Defaults, set the `bindingOptions` accordingly: 79 | 80 | ```objective-c 81 | [[MASShortcutBinder sharedBinder] setBindingOptions:@{NSValueTransformerNameBindingOption:MASDictionaryTransformerName}]; 82 | ``` 83 | 84 | This makes sure that the shortcuts in the Shortcut Recorder format are loaded correctly. 85 | 86 | # Notifications 87 | 88 | By registering for KVO notifications from `NSUserDefaultsController`, you can get a callback whenever a user changes the shortcut, allowing you to perform any UI updates, or other code handling tasks. 89 | 90 | This is just as easy to implement: 91 | 92 | ```objective-c 93 | // Declare an ivar for key path in the user defaults controller 94 | NSString *_observableKeyPath; 95 | 96 | // Make a global context reference 97 | void *kGlobalShortcutContext = &kGlobalShortcutContext; 98 | 99 | // Implement when loading view 100 | _observableKeyPath = [@"values." stringByAppendingString:kPreferenceGlobalShortcut]; 101 | [[NSUserDefaultsController sharedUserDefaultsController] addObserver:self forKeyPath:_observableKeyPath 102 | options:NSKeyValueObservingOptionInitial 103 | context:kGlobalShortcutContext]; 104 | 105 | // Capture the KVO change and do something 106 | - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)obj 107 | change:(NSDictionary *)change context:(void *)ctx 108 | { 109 | if (ctx == kGlobalShortcutContext) { 110 | NSLog(@"Shortcut has changed"); 111 | } 112 | else { 113 | [super observeValueForKeyPath:keyPath ofObject:obj change:change context:ctx]; 114 | } 115 | } 116 | 117 | // Do not forget to remove the observer 118 | [[NSUserDefaultsController sharedUserDefaultsController] removeObserver:self 119 | forKeyPath:_observableKeyPath 120 | context:kGlobalShortcutContext]; 121 | ``` 122 | 123 | # Using in Swift projects 124 | 125 | 1. Install as a Pod using the latest CocoaPods with Swift support. 126 | 2. Create a bridging header file [using the instructions here](http://swiftalicio.us/2014/11/using-cocoapods-from-swift/) 127 | 3. Your bridging header file should contain the following [two](https://github.com/shpakovski/MASShortcut/issues/36) imports: 128 | 129 | ```objective-c 130 | #import 131 | #import 132 | ``` 133 | 134 | # Copyright 135 | 136 | MASShortcut is licensed under the 2-clause BSD license. 137 | -------------------------------------------------------------------------------- /Pods/MASShortcut/cs.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "Zrušit"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "Kliknutím nahrajete novou zkratku"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "Smazat zkratku"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "klávesová zkratka"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "OK"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "Nahrát zkratku"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "zkratka smazána"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "zkratka nastavena"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "Mezerník"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "Kombinace %@ se nedá použít"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "Tato zkratka se nedá použít, protože už ji obsadil systém.\nKdybyste na ní trvali, většina systémových zkratek se dá přenastavit v Předvolbách systému."; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "Tato zkratka se nedá použít, protože už je použita pro menu (%@)."; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "Pokud chcete nahrát novou zkratku, stiskněte toto tlačítko a následně vybranou zkratku. Stisknutím Delete vymažete stávající zkratku."; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "Stiskněte zkratku"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "Stiskněte zkratku"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "Vrátit se k původní"; 48 | -------------------------------------------------------------------------------- /Pods/MASShortcut/de.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "Abbrechen"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "Klicken um neuen Kurzbefehl aufzunehmen"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "Kurzbefehl Löschen"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "Kurzbefehl"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "OK"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "Kurzbefehl aufnehmen"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "Kurzbefehl gelöscht"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "Kurzbefehl gesetzt"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "Leertaste"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "Die Tastenkombination %@ kann nicht genutzt werden"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "Diese Kombination kann nicht genutzt werden, weil sie bereits als systemweiter Kurzbefehl genutzt wird.\nFalls du diese Tastenkombination wirklich benutzen willst, können die meisten Kurzbefehle in den Tastatur Systemeinstellungen geändert werden."; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "Dieser Kurzbefehl kann nicht genutzt werden, weil er bereits vom Menüpunkt „%@“ genutzt wird."; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "Drücke diesen Button, um einen neuen Kurzbefehl aufzunehmen. Tippe dann den neuen Kurzbefehl oder drücke Löschen, um den aktuellen Kurzbefehl zu löschen."; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "Neuen eingeben"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "Kurzbefehl eingeben"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "Alten nutzen"; 48 | -------------------------------------------------------------------------------- /Pods/MASShortcut/en.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "Cancel"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "Click to record new shortcut"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "Delete shortcut"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "keyboard shortcut"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "OK"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "Record Shortcut"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "Shortcut cleared"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "Shortcut set"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "Space"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "The key combination %@ cannot be used"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences."; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "This shortcut cannot be used because it is already used by the menu item ‘%@’."; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut."; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "Type New Shortcut"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "Type Shortcut"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "Use Old Shortcut"; 48 | -------------------------------------------------------------------------------- /Pods/MASShortcut/es.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "Cancelar"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "Haga clic para grabar nuevo atajo"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "Borrar atajo"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "atajo de teklado"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "OK"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "Grabar atajo"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "Atajo borrado"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "Atajo creado"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "Espacio"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "La combinación de claves %@ no se puede utilizada"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "Esta combinación no se puede utilizar debido a que ya es en us como atajo del sistema.\nSi realmente desea utilizar esta combinación de teclas, la mayoría de los atajos se puede cambiar en el panel de Teclado y Ratón de Preferencias del Sistema."; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "Este atajo no se puede utilizar debido a que ya es utilizado por el elemento de menú '%@'."; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "Para grabar un nuevo atajo, haga clic en este botón, a continuar, escriba el nuevo atajo, o pulse borrar para qutar un atajo existente."; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "Escribir atajo"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "Escribir atajo"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "Usa atajo anterior"; -------------------------------------------------------------------------------- /Pods/MASShortcut/fr.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "Annuler"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "Cliquez pour enregistrer le raccourci"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "Supprimer le raccourci"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "raccourci clavier"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "OK"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "Enregistrer le raccourci"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "Raccourci supprimé"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "Raccourci configuré"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "Espace"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "La combinaison %@ ne peut être utilisée"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "Cette combinaison de touches ne peut être utilisée parce qu’elle est réservée pour un raccourci du système.\nSi vous désirez l’utiliser, la plupart des raccourcis peuvent être modifiés dans l’onglet Clavier, dans Préférences Système."; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "Ce raccourci ne peut être utilisé parce qu’il est déjà utilisé par le point de menu «%@»."; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "Pour enregistrer un nouveau raccourci, cliquez sur ce bouton et tapez le nouveau raccourci, ou bien, tapez sur «Supprimer» pour supprimer le raccourci configuré."; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "Saisir un raccourci"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "Saisir un raccourci"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "Revenir au raccourci précédent"; 48 | -------------------------------------------------------------------------------- /Pods/MASShortcut/it.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "Annulla"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "Cliccare per registrare una nuova combinazione"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "Cancella scorciatoia"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "Scorciatoia da tastiera"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "OK"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "Registra scorciatoia"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "Scorciatoia rimossa"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "Scorciatoia impostata"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "Spazio"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "Questa combinazione %@ di tasti non può essere usata"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "Questa combinazione di tasti non può essere usata perchè è già usata da una scorciatoia da tastiera a livello di Sistema.\nSe volete davvero usare questa combinazione di tasti, la maggior parte delle scorciatoie possono essere cambiate nel pannello Tastiera e Mouse delle Preferenze di Sistema."; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "Questa combinazione di tasti non può essere usata perchè è già usata dalla voce di menù ‘%@’."; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "Per registrare una nuova scorciatoia, cliccare su questo pulsante e poi inserire la muova scorciatoia o premere cancella per resettare una scorciatoia esistente."; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "Digita nuova"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "Digita scorciatoia"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "Usare vecchia"; 48 | -------------------------------------------------------------------------------- /Pods/MASShortcut/ja.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "キャンセルする"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "クリックしてショートカットを入力"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "ショートカットを削除"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "キーボードショートカット"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "OK"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "ショートカットを入力"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "ショートカットが削除されました"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "ショートカットが設定されました"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "スペース"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "%@ はショートカットに設定できません"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "このショートカットは、システム全体で使用されているショートカットのため、設定することができません。\nもしこのショートカットを使用したい場合、「システム環境設定」の「キーボード」、「マウス」のパネルから既に設定されているショートカットを変更してください。"; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "このショートカットは、メニュー操作の「%@」で使われているため、設定できません。"; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "このボタンをクリックし、ショートカットを入力すると、新しいショートカットが設定されます。また、削除ボタンをおすと、ショートカットが削除されます。"; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "ショートカットを入力"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "ショートカットを入力"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "古いショートカットを使用"; 48 | -------------------------------------------------------------------------------- /Pods/MASShortcut/ko.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "취소"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "클릭해 단축 키를 입력"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "단축키 삭제"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "키보드 단축키"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "좋아"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "단축키 입력"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "단축키 삭제됨"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "단축키 설정됨"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "스페이스 바"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "%@ 단축키로 설정할 수 없습니다"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "이 결합은 시스템 전체에서 사용 때문에 단축키로 설정 할 수 없습니다.\n단축키를 사용하고 싶으면 시스템 환경 설정의 키보드, 마우스 패널에서 이미 설정되어있는 단축키를 변경하십시오."; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "이 단축키는 ‘%@’ 메뉴 아이템에 사용되고 있기 때문에 설정할 수 없습니다."; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "이 버튼을 클릭하고 단축키를 입력하면 새로운 단축키가 설정됩니다. 또한 삭제 버튼을 누르면 단축키가 삭제됩니다."; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "새 단축키 입력"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "단축키 입력"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "오래된 단축키를 사용"; 48 | -------------------------------------------------------------------------------- /Pods/MASShortcut/nl.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "Verbreken"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "Druk om een nieuwe sneltoets in te voeren"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "Verwijder sneltoets"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "sneltoets"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "OK"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "Sneltoets opnemen"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "Sneltoets verwijderd"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "Sneltoets zetten"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "Spatie"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "De sneltoetsencombinatie kan niet worden gebruikt"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "Deze combinatie kan niet worden gebruikt want hij wordt al gebruikt door een systeembreed sneltoets.\nAls je deze combinatie echt wilt gebruiken, kun je de meeste sneltoetsen binnen Toetsenbordinstellingen veranderen."; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "Deze sneltoets kan niet worden gebruikt want hij wordt al gebruikt door het menu item ‘%@’."; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "Om nieuwe sneltoets op te nemen, druk op deze knop, en voer een nieuwe sneltoets in, of druk op verwijder om bestaande sneltoets te verwijderen."; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "Voer Nieuwe Sneltoets in"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "Voer Sneltoets in"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "Gebruik Oude Sneltoets"; -------------------------------------------------------------------------------- /Pods/MASShortcut/pl.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "Anuluj"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "Kliknij, by ustawić nowy skrót"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "Usuń skrót"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "skrót klawiszowy"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "OK"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "Utwórz skrót"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "Skrót usunięty"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "Skrót ustawiony"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "Spacja"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "Nie można użyć kombinacji klawiszy %@"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "Nie można użyć tej kombinacji, ponieważ jest już zajęta przez skrót systemowy.\nMożesz to zmienić w panelu Klawiatura w Preferencjach systemowych."; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "Ten skrót nie może być użyty, ponieważ w menu ma już przypisaną funkcję ‘%@’."; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "Aby ustawić nowy skrót, użyj tego przycisku, a następnie wpisz nowy skrót albo naciśnij klawisz delete, by usunąć istniejący skrót"; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "Wpisz nowy skrót"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "Wpisz skrót"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "Użyj starego skrótu"; -------------------------------------------------------------------------------- /Pods/MASShortcut/ru.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "Отмена"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "Нажмите для записи сочетания клавиш"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "Удалить горячую клавишу"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "сочетание клавиш"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "ОК"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "Ввести сочетание"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "Сочетание клавиш удалено"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "Сочетание клавиш назначено"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "Пробел"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "Нельзя использовать сочетание клавиш %@"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "Нельзя использовать это сочетание клавиш, потому что оно уже используется в системе.\n Если вы хотите использовать это сочетание, измените существующее системное сочетание клавиш через панель Клавиатура в Cистемных настройках."; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "Нельзя использовать это сочетание, потому что оно уже связано с элементом ‘%@’."; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "Чтобы назначить новое сочетание клавиш, нажмите эту кнопку и введите новое сочетание, или нажмите \"Удалить\", чтобы удалить действующее сочетание клавиш."; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "Введите сочетание"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "Введите сочетание"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "Вернуть старое"; -------------------------------------------------------------------------------- /Pods/MASShortcut/zh-Hans.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "取消"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "点击以记录新快捷键"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "删除快捷键"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "键盘快捷键"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "好"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "记录快捷键"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "快捷键已清除"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "快捷键已设置"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "空格键"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "按键组合“%@”无法使用"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "当前按键组合无法使用,因为它已经用作其他系统全局快捷键。\n如果您真的想使用这个按键组合,大部分系统全局快捷键能在“系统偏好设置”里的“键盘”和“鼠标”面板中重设。"; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "当前快捷键无法使用,因为它已用作菜单项“%@”的快捷键。"; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "若要记录新的快捷键,单击此按钮,然后键入新的快捷键,或者按“delete键”删除已经存在的快捷键。"; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "键入新快捷键"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "键入快捷键"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "还原快捷键"; 48 | -------------------------------------------------------------------------------- /Pods/MASShortcut/zh-Hant.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | /* Cancel action button in recording state */ 2 | "Cancel" = "取消"; 3 | 4 | /* Tooltip for non-empty shortcut button */ 5 | "Click to record new shortcut" = "點選以記錄新快捷鍵"; 6 | 7 | /* Tooltip for hint button near the non-empty shortcut */ 8 | "Delete shortcut" = "刪除快捷鍵"; 9 | 10 | /* VoiceOver title */ 11 | "keyboard shortcut" = "鍵盤快捷鍵"; 12 | 13 | /* Alert button when shortcut is already used */ 14 | "OK" = "好"; 15 | 16 | /* Empty shortcut button in normal state */ 17 | "Record Shortcut" = "記錄快捷鍵"; 18 | 19 | /* VoiceOver: Shortcut cleared */ 20 | "Shortcut cleared" = "快捷鍵已清除"; 21 | 22 | /* VoiceOver: Shortcut set */ 23 | "Shortcut set" = "快捷鍵已設定"; 24 | 25 | /* Shortcut glyph name for SPACE key */ 26 | "Space" = "空格鍵"; 27 | 28 | /* Title for alert when shortcut is already used */ 29 | "The key combination %@ cannot be used" = "按鍵組合“%@”無法使用"; 30 | 31 | /* Message for alert when shortcut is already used by the system */ 32 | "This combination cannot be used because it is already used by a system-wide keyboard shortcut.\nIf you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences." = "當前按鍵組合無法使用,因為它已經用作其他系統全局快捷鍵。\n如果您真的想使用這個按鍵組合,大部分系統全局快捷鍵能在“系統偏好設定”裡的“鍵盤”和“滑鼠”面板中重設。"; 33 | 34 | /* Message for alert when shortcut is already used */ 35 | "This shortcut cannot be used because it is already used by the menu item ‘%@’." = "當前快捷鍵無法使用,因為它已用作選單項“%@”的快捷鍵。"; 36 | 37 | /* VoiceOver shortcut help */ 38 | "To record a new shortcut, click this button, and then type the new shortcut, or press delete to clear an existing shortcut." = "若要記錄新的快捷鍵,單擊此按鈕,然後鍵入新的快捷鍵,或者按“delete鍵”刪除已經存在的快捷鍵。"; 39 | 40 | /* Non-empty shortcut button in recording state */ 41 | "Type New Shortcut" = "鍵入新快捷鍵"; 42 | 43 | /* Empty shortcut button in recording state */ 44 | "Type Shortcut" = "鍵入快捷鍵"; 45 | 46 | /* Cancel action button for non-empty shortcut in recording state */ 47 | "Use Old Shortcut" = "還原快捷鍵"; 48 | -------------------------------------------------------------------------------- /Pods/Manifest.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - MASShortcut (2.3.6) 3 | - SwiftyMarkdown (1.2.2) 4 | 5 | DEPENDENCIES: 6 | - MASShortcut 7 | - SwiftyMarkdown 8 | 9 | SPEC REPOS: 10 | https://github.com/CocoaPods/Specs.git: 11 | - MASShortcut 12 | trunk: 13 | - SwiftyMarkdown 14 | 15 | SPEC CHECKSUMS: 16 | MASShortcut: 9c215e8a8a78f3d01ce56da48e2730ab66b538fa 17 | SwiftyMarkdown: 716936bd2031df713a8d22d166b9408f4884cab3 18 | 19 | PODFILE CHECKSUM: 15de64ce7c892b1c0f643628afa329d8277efe00 20 | 21 | COCOAPODS: 1.9.1 22 | -------------------------------------------------------------------------------- /Pods/Pods.xcodeproj/xcuserdata/buddax2.xcuserdatad/xcschemes/MASShortcut-MASShortcut.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 34 | 35 | 45 | 46 | 52 | 53 | 54 | 55 | 56 | 57 | 63 | 64 | 66 | 67 | 70 | 71 | 72 | -------------------------------------------------------------------------------- /Pods/Pods.xcodeproj/xcuserdata/buddax2.xcuserdatad/xcschemes/MASShortcut.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 45 | 46 | 52 | 53 | 55 | 56 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /Pods/Pods.xcodeproj/xcuserdata/buddax2.xcuserdatad/xcschemes/Pods-tmpNote.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 34 | 35 | 45 | 46 | 52 | 53 | 54 | 55 | 56 | 57 | 63 | 64 | 66 | 67 | 70 | 71 | 72 | -------------------------------------------------------------------------------- /Pods/Pods.xcodeproj/xcuserdata/buddax2.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | MASShortcut-MASShortcut.xcscheme 8 | 9 | isShown 10 | 11 | orderHint 12 | 2 13 | 14 | MASShortcut.xcscheme 15 | 16 | isShown 17 | 18 | orderHint 19 | 1 20 | 21 | Pods-tmpNote.xcscheme 22 | 23 | isShown 24 | 25 | orderHint 26 | 3 27 | 28 | 29 | SuppressBuildableAutocreation 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /Pods/Pods.xcodeproj/xcuserdata/oyakub.xcuserdatad/xcschemes/MASShortcut-MASShortcut.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 50 | 51 | 53 | 54 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /Pods/Pods.xcodeproj/xcuserdata/oyakub.xcuserdatad/xcschemes/MASShortcut.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 45 | 46 | 52 | 53 | 55 | 56 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /Pods/Pods.xcodeproj/xcuserdata/oyakub.xcuserdatad/xcschemes/Pods-tmpNote.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 50 | 51 | 53 | 54 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /Pods/Pods.xcodeproj/xcuserdata/oyakub.xcuserdatad/xcschemes/SwiftyMarkdown.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 45 | 46 | 52 | 53 | 55 | 56 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /Pods/Pods.xcodeproj/xcuserdata/oyakub.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | MASShortcut-MASShortcut.xcscheme 8 | 9 | isShown 10 | 11 | orderHint 12 | 1 13 | 14 | MASShortcut.xcscheme 15 | 16 | isShown 17 | 18 | orderHint 19 | 0 20 | 21 | Pods-tmpNote.xcscheme 22 | 23 | isShown 24 | 25 | orderHint 26 | 2 27 | 28 | SwiftyMarkdown.xcscheme 29 | 30 | isShown 31 | 32 | orderHint 33 | 3 34 | 35 | 36 | SuppressBuildableAutocreation 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /Pods/SwiftyMarkdown/LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2016 Simon Fairbairn 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /Pods/SwiftyMarkdown/Sources/SwiftyMarkdown/CharacterRule.swift: -------------------------------------------------------------------------------- 1 | // 2 | // CharacterRule.swift 3 | // SwiftyMarkdown 4 | // 5 | // Created by Simon Fairbairn on 04/02/2020. 6 | // 7 | 8 | import Foundation 9 | 10 | public enum SpaceAllowed { 11 | case no 12 | case bothSides 13 | case oneSide 14 | case leadingSide 15 | case trailingSide 16 | } 17 | 18 | public enum Cancel { 19 | case none 20 | case allRemaining 21 | case currentSet 22 | } 23 | 24 | public enum CharacterRuleTagType { 25 | case open 26 | case close 27 | case metadataOpen 28 | case metadataClose 29 | case repeating 30 | } 31 | 32 | 33 | public struct CharacterRuleTag { 34 | let tag : String 35 | let type : CharacterRuleTagType 36 | 37 | public init( tag : String, type : CharacterRuleTagType ) { 38 | self.tag = tag 39 | self.type = type 40 | } 41 | } 42 | 43 | public struct CharacterRule : CustomStringConvertible { 44 | 45 | public let primaryTag : CharacterRuleTag 46 | public let tags : [CharacterRuleTag] 47 | public let escapeCharacters : [Character] 48 | public let styles : [Int : CharacterStyling] 49 | public let minTags : Int 50 | public let maxTags : Int 51 | public var metadataLookup : Bool = false 52 | public var isRepeatingTag : Bool { 53 | return self.primaryTag.type == .repeating 54 | } 55 | public var definesBoundary = false 56 | public var shouldCancelRemainingRules = false 57 | public var balancedTags = false 58 | 59 | public var description: String { 60 | return "Character Rule with Open tag: \(self.primaryTag.tag) and current styles : \(self.styles) " 61 | } 62 | 63 | public func tag( for type : CharacterRuleTagType ) -> CharacterRuleTag? { 64 | return self.tags.filter({ $0.type == type }).first ?? nil 65 | } 66 | 67 | public init(primaryTag: CharacterRuleTag, otherTags: [CharacterRuleTag], escapeCharacters : [Character] = ["\\"], styles: [Int : CharacterStyling] = [:], minTags : Int = 1, maxTags : Int = 1, metadataLookup : Bool = false, definesBoundary : Bool = false, shouldCancelRemainingRules : Bool = false, balancedTags : Bool = false) { 68 | self.primaryTag = primaryTag 69 | self.tags = otherTags 70 | self.escapeCharacters = escapeCharacters 71 | self.styles = styles 72 | self.metadataLookup = metadataLookup 73 | self.definesBoundary = definesBoundary 74 | self.shouldCancelRemainingRules = shouldCancelRemainingRules 75 | self.minTags = maxTags < minTags ? maxTags : minTags 76 | self.maxTags = minTags > maxTags ? minTags : maxTags 77 | self.balancedTags = balancedTags 78 | } 79 | } 80 | 81 | 82 | 83 | enum ElementType { 84 | case tag 85 | case escape 86 | case string 87 | case space 88 | case newline 89 | case metadata 90 | } 91 | 92 | struct Element { 93 | let character : Character 94 | var type : ElementType 95 | var boundaryCount : Int = 0 96 | var isComplete : Bool = false 97 | var styles : [CharacterStyling] = [] 98 | var metadata : [String] = [] 99 | } 100 | 101 | extension CharacterSet { 102 | func containsUnicodeScalars(of character: Character) -> Bool { 103 | return character.unicodeScalars.allSatisfy(contains(_:)) 104 | } 105 | } 106 | 107 | 108 | 109 | -------------------------------------------------------------------------------- /Pods/SwiftyMarkdown/Sources/SwiftyMarkdown/PerfomanceLog.swift: -------------------------------------------------------------------------------- 1 | // 2 | // PerfomanceLog.swift 3 | // SwiftyMarkdown 4 | // 5 | // Created by Simon Fairbairn on 04/02/2020. 6 | // 7 | 8 | import Foundation 9 | import os.log 10 | 11 | class PerformanceLog { 12 | var timer : TimeInterval = 0 13 | let enablePerfomanceLog : Bool 14 | let log : OSLog 15 | let identifier : String 16 | 17 | init( with environmentVariableName : String, identifier : String, log : OSLog ) { 18 | self.log = log 19 | self.enablePerfomanceLog = (ProcessInfo.processInfo.environment[environmentVariableName] != nil) 20 | self.identifier = identifier 21 | } 22 | 23 | func start() { 24 | guard enablePerfomanceLog else { return } 25 | self.timer = Date().timeIntervalSinceReferenceDate 26 | os_log("--- TIMER %{public}@ began", log: self.log, type: .info, self.identifier) 27 | } 28 | 29 | func tag( with string : String) { 30 | guard enablePerfomanceLog else { return } 31 | if timer == 0 { 32 | self.start() 33 | } 34 | os_log("TIMER %{public}@: %f %@", log: self.log, type: .info, self.identifier, Date().timeIntervalSinceReferenceDate - self.timer, string) 35 | } 36 | 37 | func end() { 38 | guard enablePerfomanceLog else { return } 39 | self.timer = Date().timeIntervalSinceReferenceDate 40 | os_log("--- TIMER %{public}@ finished. Total time: %f", log: self.log, type: .info, self.identifier, Date().timeIntervalSinceReferenceDate - self.timer) 41 | self.timer = 0 42 | 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /Pods/SwiftyMarkdown/Sources/SwiftyMarkdown/String+SwiftyMarkdown.swift: -------------------------------------------------------------------------------- 1 | // 2 | // String+SwiftyMarkdown.swift 3 | // SwiftyMarkdown 4 | // 5 | // Created by Simon Fairbairn on 08/12/2019. 6 | // Copyright © 2019 Voyage Travel Apps. All rights reserved. 7 | // 8 | 9 | import Foundation 10 | 11 | /// Some helper functions based on this: 12 | /// https://stackoverflow.com/questions/32305891/index-of-a-substring-in-a-string-with-swift/32306142#32306142 13 | extension StringProtocol { 14 | func index(of string: S, options: String.CompareOptions = []) -> Index? { 15 | range(of: string, options: options)?.lowerBound 16 | } 17 | func endIndex(of string: S, options: String.CompareOptions = []) -> Index? { 18 | range(of: string, options: options)?.upperBound 19 | } 20 | func indices(of string: S, options: String.CompareOptions = []) -> [Index] { 21 | var indices: [Index] = [] 22 | var startIndex = self.startIndex 23 | while startIndex < endIndex, 24 | let range = self[startIndex...] 25 | .range(of: string, options: options) { 26 | indices.append(range.lowerBound) 27 | startIndex = range.lowerBound < range.upperBound ? range.upperBound : 28 | index(range.lowerBound, offsetBy: 1, limitedBy: endIndex) ?? endIndex 29 | } 30 | return indices 31 | } 32 | func ranges(of string: S, options: String.CompareOptions = []) -> [Range] { 33 | var result: [Range] = [] 34 | var startIndex = self.startIndex 35 | while startIndex < endIndex, 36 | let range = self[startIndex...] 37 | .range(of: string, options: options) { 38 | result.append(range) 39 | startIndex = range.lowerBound < range.upperBound ? range.upperBound : 40 | index(range.lowerBound, offsetBy: 1, limitedBy: endIndex) ?? endIndex 41 | } 42 | return result 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /Pods/SwiftyMarkdown/Sources/SwiftyMarkdown/SwiftyLineProcessor.swift: -------------------------------------------------------------------------------- 1 | // 2 | // SwiftyLineProcessor.swift 3 | // SwiftyMarkdown 4 | // 5 | // Created by Simon Fairbairn on 16/12/2019. 6 | // Copyright © 2019 Voyage Travel Apps. All rights reserved. 7 | // 8 | 9 | import Foundation 10 | import os.log 11 | 12 | extension OSLog { 13 | private static var subsystem = "SwiftyLineProcessor" 14 | static let swiftyLineProcessorPerformance = OSLog(subsystem: subsystem, category: "Swifty Line Processor Performance") 15 | } 16 | 17 | public protocol LineStyling { 18 | var shouldTokeniseLine : Bool { get } 19 | func styleIfFoundStyleAffectsPreviousLine() -> LineStyling? 20 | } 21 | 22 | public struct SwiftyLine : CustomStringConvertible { 23 | public let line : String 24 | public let lineStyle : LineStyling 25 | public var description: String { 26 | return self.line 27 | } 28 | } 29 | 30 | extension SwiftyLine : Equatable { 31 | public static func == ( _ lhs : SwiftyLine, _ rhs : SwiftyLine ) -> Bool { 32 | return lhs.line == rhs.line 33 | } 34 | } 35 | 36 | public enum Remove { 37 | case leading 38 | case trailing 39 | case both 40 | case entireLine 41 | case none 42 | } 43 | 44 | public enum ChangeApplication { 45 | case current 46 | case previous 47 | case untilClose 48 | } 49 | 50 | public struct FrontMatterRule { 51 | let openTag : String 52 | let closeTag : String 53 | let keyValueSeparator : Character 54 | } 55 | 56 | public struct LineRule { 57 | let token : String 58 | let removeFrom : Remove 59 | let type : LineStyling 60 | let shouldTrim : Bool 61 | let changeAppliesTo : ChangeApplication 62 | 63 | public init(token : String, type : LineStyling, removeFrom : Remove = .leading, shouldTrim : Bool = true, changeAppliesTo : ChangeApplication = .current ) { 64 | self.token = token 65 | self.type = type 66 | self.removeFrom = removeFrom 67 | self.shouldTrim = shouldTrim 68 | self.changeAppliesTo = changeAppliesTo 69 | } 70 | } 71 | 72 | public class SwiftyLineProcessor { 73 | 74 | public var processEmptyStrings : LineStyling? 75 | public internal(set) var frontMatterAttributes : [String : String] = [:] 76 | 77 | var closeToken : String? = nil 78 | let defaultType : LineStyling 79 | 80 | let lineRules : [LineRule] 81 | let frontMatterRules : [FrontMatterRule] 82 | 83 | let perfomanceLog = PerformanceLog(with: "SwiftyLineProcessorPerformanceLogging", identifier: "Line Processor", log: OSLog.swiftyLineProcessorPerformance) 84 | 85 | public init( rules : [LineRule], defaultRule: LineStyling, frontMatterRules : [FrontMatterRule] = []) { 86 | self.lineRules = rules 87 | self.defaultType = defaultRule 88 | self.frontMatterRules = frontMatterRules 89 | } 90 | 91 | func findLeadingLineElement( _ element : LineRule, in string : String ) -> String { 92 | var output = string 93 | if let range = output.index(output.startIndex, offsetBy: element.token.count, limitedBy: output.endIndex), output[output.startIndex.. String { 101 | var output = string 102 | let token = element.token.trimmingCharacters(in: .whitespaces) 103 | if let range = output.index(output.endIndex, offsetBy: -(token.count), limitedBy: output.startIndex), output[range.. SwiftyLine? { 112 | if text.isEmpty, let style = processEmptyStrings { 113 | return SwiftyLine(line: "", lineStyle: style) 114 | } 115 | let previousLines = lineRules.filter({ $0.changeAppliesTo == .previous }) 116 | 117 | for element in lineRules { 118 | guard element.token.count > 0 else { 119 | continue 120 | } 121 | var output : String = (element.shouldTrim) ? text.trimmingCharacters(in: .whitespaces) : text 122 | let unprocessed = output 123 | 124 | if let hasToken = self.closeToken, unprocessed != hasToken { 125 | return nil 126 | } 127 | 128 | if !text.contains(element.token) { 129 | continue 130 | } 131 | 132 | switch element.removeFrom { 133 | case .leading: 134 | output = findLeadingLineElement(element, in: output) 135 | case .trailing: 136 | output = findTrailingLineElement(element, in: output) 137 | case .both: 138 | output = findLeadingLineElement(element, in: output) 139 | output = findTrailingLineElement(element, in: output) 140 | case .entireLine: 141 | let maybeOutput = output.replacingOccurrences(of: element.token, with: "") 142 | output = ( maybeOutput.isEmpty ) ? maybeOutput : output 143 | default: 144 | break 145 | } 146 | // Only if the output has changed in some way 147 | guard unprocessed != output else { 148 | continue 149 | } 150 | if element.changeAppliesTo == .untilClose { 151 | self.closeToken = (self.closeToken == nil) ? element.token : nil 152 | return nil 153 | } 154 | 155 | 156 | 157 | output = (element.shouldTrim) ? output.trimmingCharacters(in: .whitespaces) : output 158 | return SwiftyLine(line: output, lineStyle: element.type) 159 | 160 | } 161 | 162 | for element in previousLines { 163 | let output = (element.shouldTrim) ? text.trimmingCharacters(in: .whitespaces) : text 164 | let charSet = CharacterSet(charactersIn: element.token ) 165 | if output.unicodeScalars.allSatisfy({ charSet.contains($0) }) { 166 | return SwiftyLine(line: "", lineStyle: element.type) 167 | } 168 | } 169 | 170 | return SwiftyLine(line: text.trimmingCharacters(in: .whitespaces), lineStyle: defaultType) 171 | } 172 | 173 | func processFrontMatter( _ strings : [String] ) -> [String] { 174 | guard let firstString = strings.first?.trimmingCharacters(in: .whitespacesAndNewlines) else { 175 | return strings 176 | } 177 | var rulesToApply : FrontMatterRule? = nil 178 | for matter in self.frontMatterRules { 179 | if firstString == matter.openTag { 180 | rulesToApply = matter 181 | break 182 | } 183 | } 184 | guard let existentRules = rulesToApply else { 185 | return strings 186 | } 187 | var outputString = strings 188 | // Remove the first line, which is the front matter opening tag 189 | let _ = outputString.removeFirst() 190 | var closeFound = false 191 | while !closeFound { 192 | let nextString = outputString.removeFirst() 193 | if nextString == existentRules.closeTag { 194 | closeFound = true 195 | continue 196 | } 197 | var keyValue = nextString.components(separatedBy: "\(existentRules.keyValueSeparator)") 198 | if keyValue.count < 2 { 199 | continue 200 | } 201 | let key = keyValue.removeFirst() 202 | let value = keyValue.joined() 203 | self.frontMatterAttributes[key] = value 204 | } 205 | while outputString.first?.isEmpty ?? false { 206 | outputString.removeFirst() 207 | } 208 | return outputString 209 | } 210 | 211 | public func process( _ string : String ) -> [SwiftyLine] { 212 | var foundAttributes : [SwiftyLine] = [] 213 | 214 | 215 | self.perfomanceLog.start() 216 | 217 | var lines = string.components(separatedBy: CharacterSet.newlines) 218 | lines = self.processFrontMatter(lines) 219 | 220 | self.perfomanceLog.tag(with: "(Front matter completed)") 221 | 222 | 223 | for heading in lines { 224 | 225 | if processEmptyStrings == nil && heading.isEmpty { 226 | continue 227 | } 228 | 229 | guard let input = processLineLevelAttributes(String(heading)) else { 230 | continue 231 | } 232 | 233 | if let existentPrevious = input.lineStyle.styleIfFoundStyleAffectsPreviousLine(), foundAttributes.count > 0 { 234 | if let idx = foundAttributes.firstIndex(of: foundAttributes.last!) { 235 | let updatedPrevious = foundAttributes.last! 236 | foundAttributes[idx] = SwiftyLine(line: updatedPrevious.line, lineStyle: existentPrevious) 237 | } 238 | continue 239 | } 240 | foundAttributes.append(input) 241 | 242 | self.perfomanceLog.tag(with: "(line completed: \(heading)") 243 | } 244 | return foundAttributes 245 | } 246 | 247 | } 248 | 249 | 250 | -------------------------------------------------------------------------------- /Pods/SwiftyMarkdown/Sources/SwiftyMarkdown/SwiftyMarkdown+iOS.swift: -------------------------------------------------------------------------------- 1 | // 2 | // SwiftyMarkdown+macOS.swift 3 | // SwiftyMarkdown 4 | // 5 | // Created by Simon Fairbairn on 17/12/2019. 6 | // Copyright © 2019 Voyage Travel Apps. All rights reserved. 7 | // 8 | 9 | import Foundation 10 | 11 | #if !os(macOS) 12 | import UIKit 13 | 14 | extension SwiftyMarkdown { 15 | 16 | func font( for line : SwiftyLine, characterOverride : CharacterStyle? = nil ) -> UIFont { 17 | let textStyle : UIFont.TextStyle 18 | var fontName : String? 19 | var fontSize : CGFloat? 20 | 21 | var globalBold = false 22 | var globalItalic = false 23 | 24 | let style : FontProperties 25 | // What type are we and is there a font name set? 26 | switch line.lineStyle as! MarkdownLineStyle { 27 | case .h1: 28 | style = self.h1 29 | if #available(iOS 9, *) { 30 | textStyle = UIFont.TextStyle.title1 31 | } else { 32 | textStyle = UIFont.TextStyle.headline 33 | } 34 | case .h2: 35 | style = self.h2 36 | if #available(iOS 9, *) { 37 | textStyle = UIFont.TextStyle.title2 38 | } else { 39 | textStyle = UIFont.TextStyle.headline 40 | } 41 | case .h3: 42 | style = self.h3 43 | if #available(iOS 9, *) { 44 | textStyle = UIFont.TextStyle.title2 45 | } else { 46 | textStyle = UIFont.TextStyle.subheadline 47 | } 48 | case .h4: 49 | style = self.h4 50 | textStyle = UIFont.TextStyle.headline 51 | case .h5: 52 | style = self.h5 53 | textStyle = UIFont.TextStyle.subheadline 54 | case .h6: 55 | style = self.h6 56 | textStyle = UIFont.TextStyle.footnote 57 | case .codeblock: 58 | style = self.code 59 | textStyle = UIFont.TextStyle.body 60 | case .blockquote: 61 | style = self.blockquotes 62 | textStyle = UIFont.TextStyle.body 63 | default: 64 | style = self.body 65 | textStyle = UIFont.TextStyle.body 66 | } 67 | 68 | fontName = style.fontName 69 | fontSize = style.fontSize 70 | switch style.fontStyle { 71 | case .bold: 72 | globalBold = true 73 | case .italic: 74 | globalItalic = true 75 | case .boldItalic: 76 | globalItalic = true 77 | globalBold = true 78 | case .normal: 79 | break 80 | } 81 | 82 | if fontName == nil { 83 | fontName = body.fontName 84 | } 85 | 86 | if let characterOverride = characterOverride { 87 | switch characterOverride { 88 | case .code: 89 | fontName = code.fontName ?? fontName 90 | fontSize = code.fontSize 91 | case .link: 92 | fontName = link.fontName ?? fontName 93 | fontSize = link.fontSize 94 | case .bold: 95 | fontName = bold.fontName ?? fontName 96 | fontSize = bold.fontSize 97 | globalBold = true 98 | case .italic: 99 | fontName = italic.fontName ?? fontName 100 | fontSize = italic.fontSize 101 | globalItalic = true 102 | case .strikethrough: 103 | fontName = strikethrough.fontName ?? fontName 104 | fontSize = strikethrough.fontSize 105 | default: 106 | break 107 | } 108 | } 109 | 110 | fontSize = fontSize == 0.0 ? nil : fontSize 111 | var font : UIFont 112 | if let existentFontName = fontName { 113 | font = UIFont.preferredFont(forTextStyle: textStyle) 114 | let finalSize : CGFloat 115 | if let existentFontSize = fontSize { 116 | finalSize = existentFontSize 117 | } else { 118 | let styleDescriptor = UIFontDescriptor.preferredFontDescriptor(withTextStyle: textStyle) 119 | finalSize = styleDescriptor.fontAttributes[.size] as? CGFloat ?? CGFloat(14) 120 | } 121 | 122 | if let customFont = UIFont(name: existentFontName, size: finalSize) { 123 | let fontMetrics = UIFontMetrics(forTextStyle: textStyle) 124 | font = fontMetrics.scaledFont(for: customFont) 125 | } else { 126 | font = UIFont.preferredFont(forTextStyle: textStyle) 127 | } 128 | } else { 129 | font = UIFont.preferredFont(forTextStyle: textStyle) 130 | } 131 | 132 | if globalItalic, let italicDescriptor = font.fontDescriptor.withSymbolicTraits(.traitItalic) { 133 | font = UIFont(descriptor: italicDescriptor, size: 0) 134 | } 135 | if globalBold, let boldDescriptor = font.fontDescriptor.withSymbolicTraits(.traitBold) { 136 | font = UIFont(descriptor: boldDescriptor, size: 0) 137 | } 138 | 139 | return font 140 | 141 | } 142 | 143 | func color( for line : SwiftyLine ) -> UIColor { 144 | // What type are we and is there a font name set? 145 | switch line.lineStyle as! MarkdownLineStyle { 146 | case .yaml: 147 | return body.color 148 | case .h1, .previousH1: 149 | return h1.color 150 | case .h2, .previousH2: 151 | return h2.color 152 | case .h3: 153 | return h3.color 154 | case .h4: 155 | return h4.color 156 | case .h5: 157 | return h5.color 158 | case .h6: 159 | return h6.color 160 | case .body: 161 | return body.color 162 | case .codeblock: 163 | return code.color 164 | case .blockquote: 165 | return blockquotes.color 166 | case .unorderedList, .unorderedListIndentFirstOrder, .unorderedListIndentSecondOrder, .orderedList, .orderedListIndentFirstOrder, .orderedListIndentSecondOrder: 167 | return body.color 168 | case .referencedLink: 169 | return link.color 170 | } 171 | } 172 | 173 | } 174 | #endif 175 | -------------------------------------------------------------------------------- /Pods/SwiftyMarkdown/Sources/SwiftyMarkdown/SwiftyMarkdown+macOS.swift: -------------------------------------------------------------------------------- 1 | // 2 | // SwiftyMarkdown+macOS.swift 3 | // SwiftyMarkdown 4 | // 5 | // Created by Simon Fairbairn on 17/12/2019. 6 | // Copyright © 2019 Voyage Travel Apps. All rights reserved. 7 | // 8 | 9 | import Foundation 10 | #if os(macOS) 11 | import AppKit 12 | 13 | extension SwiftyMarkdown { 14 | 15 | func font( for line : SwiftyLine, characterOverride : CharacterStyle? = nil ) -> NSFont { 16 | var fontName : String? 17 | var fontSize : CGFloat? 18 | 19 | var globalBold = false 20 | var globalItalic = false 21 | 22 | let style : FontProperties 23 | // What type are we and is there a font name set? 24 | switch line.lineStyle as! MarkdownLineStyle { 25 | case .h1: 26 | style = self.h1 27 | case .h2: 28 | style = self.h2 29 | case .h3: 30 | style = self.h3 31 | case .h4: 32 | style = self.h4 33 | case .h5: 34 | style = self.h5 35 | case .h6: 36 | style = self.h6 37 | case .codeblock: 38 | style = self.code 39 | case .blockquote: 40 | style = self.blockquotes 41 | default: 42 | style = self.body 43 | } 44 | 45 | fontName = style.fontName 46 | fontSize = style.fontSize 47 | switch style.fontStyle { 48 | case .bold: 49 | globalBold = true 50 | case .italic: 51 | globalItalic = true 52 | case .boldItalic: 53 | globalItalic = true 54 | globalBold = true 55 | case .normal: 56 | break 57 | } 58 | 59 | if fontName == nil { 60 | fontName = body.fontName 61 | } 62 | 63 | if let characterOverride = characterOverride { 64 | switch characterOverride { 65 | case .code: 66 | fontName = code.fontName ?? fontName 67 | fontSize = code.fontSize 68 | case .link: 69 | fontName = link.fontName ?? fontName 70 | fontSize = link.fontSize 71 | case .bold: 72 | fontName = bold.fontName ?? fontName 73 | fontSize = bold.fontSize 74 | globalBold = true 75 | case .italic: 76 | fontName = italic.fontName ?? fontName 77 | fontSize = italic.fontSize 78 | globalItalic = true 79 | default: 80 | break 81 | } 82 | } 83 | 84 | fontSize = fontSize == 0.0 ? nil : fontSize 85 | let finalSize : CGFloat 86 | if let existentFontSize = fontSize { 87 | finalSize = existentFontSize 88 | } else { 89 | finalSize = NSFont.systemFontSize 90 | } 91 | var font : NSFont 92 | if let existentFontName = fontName { 93 | if let customFont = NSFont(name: existentFontName, size: finalSize) { 94 | font = customFont 95 | } else { 96 | font = NSFont.systemFont(ofSize: finalSize) 97 | } 98 | } else { 99 | font = NSFont.systemFont(ofSize: finalSize) 100 | } 101 | 102 | if globalItalic { 103 | let italicDescriptor = font.fontDescriptor.withSymbolicTraits(.italic) 104 | font = NSFont(descriptor: italicDescriptor, size: 0) ?? font 105 | } 106 | if globalBold { 107 | let boldDescriptor = font.fontDescriptor.withSymbolicTraits(.bold) 108 | font = NSFont(descriptor: boldDescriptor, size: 0) ?? font 109 | } 110 | 111 | return font 112 | 113 | } 114 | 115 | func color( for line : SwiftyLine ) -> NSColor { 116 | // What type are we and is there a font name set? 117 | switch line.lineStyle as! MarkdownLineStyle { 118 | case .h1, .previousH1: 119 | return h1.color 120 | case .h2, .previousH2: 121 | return h2.color 122 | case .h3: 123 | return h3.color 124 | case .h4: 125 | return h4.color 126 | case .h5: 127 | return h5.color 128 | case .h6: 129 | return h6.color 130 | case .body: 131 | return body.color 132 | case .codeblock: 133 | return code.color 134 | case .blockquote: 135 | return blockquotes.color 136 | case .unorderedList, .unorderedListIndentFirstOrder, .unorderedListIndentSecondOrder, .orderedList, .orderedListIndentFirstOrder, .orderedListIndentSecondOrder: 137 | return body.color 138 | case .yaml: 139 | return body.color 140 | case .referencedLink: 141 | return body.color 142 | } 143 | } 144 | 145 | } 146 | #endif 147 | -------------------------------------------------------------------------------- /Pods/SwiftyMarkdown/Sources/SwiftyMarkdown/SwiftyTokeniser.swift: -------------------------------------------------------------------------------- 1 | // 2 | // SwiftyTokeniser.swift 3 | // SwiftyMarkdown 4 | // 5 | // Created by Simon Fairbairn on 16/12/2019. 6 | // Copyright © 2019 Voyage Travel Apps. All rights reserved. 7 | // 8 | import Foundation 9 | import os.log 10 | 11 | extension OSLog { 12 | private static var subsystem = "SwiftyTokeniser" 13 | static let tokenising = OSLog(subsystem: subsystem, category: "Tokenising") 14 | static let styling = OSLog(subsystem: subsystem, category: "Styling") 15 | static let performance = OSLog(subsystem: subsystem, category: "Peformance") 16 | } 17 | 18 | public class SwiftyTokeniser { 19 | let rules : [CharacterRule] 20 | var replacements : [String : [Token]] = [:] 21 | 22 | var enableLog = (ProcessInfo.processInfo.environment["SwiftyTokeniserLogging"] != nil) 23 | let totalPerfomanceLog = PerformanceLog(with: "SwiftyTokeniserPerformanceLogging", identifier: "Tokeniser Total Run Time", log: OSLog.performance) 24 | let currentPerfomanceLog = PerformanceLog(with: "SwiftyTokeniserPerformanceLogging", identifier: "Tokeniser Current", log: OSLog.performance) 25 | 26 | public var metadataLookup : [String : String] = [:] 27 | 28 | let newlines = CharacterSet.newlines 29 | let spaces = CharacterSet.whitespaces 30 | 31 | 32 | public init( with rules : [CharacterRule] ) { 33 | self.rules = rules 34 | 35 | self.totalPerfomanceLog.start() 36 | } 37 | 38 | deinit { 39 | self.totalPerfomanceLog.end() 40 | } 41 | 42 | 43 | /// This goes through every CharacterRule in order and applies it to the input string, tokenising the string 44 | /// if there are any matches. 45 | /// 46 | /// The for loop in the while loop (yeah, I know) is there to separate strings from within tags to 47 | /// those outside them. 48 | /// 49 | /// e.g. "A string with a \[link\]\(url\) tag" would have the "link" text tokenised separately. 50 | /// 51 | /// This is to prevent situations like **\[link**\](url) from returing a bold string. 52 | /// 53 | /// - Parameter inputString: A string to have the CharacterRules in `self.rules` applied to 54 | public func process( _ inputString : String ) -> [Token] { 55 | let currentTokens = [Token(type: .string, inputString: inputString)] 56 | guard rules.count > 0 else { 57 | return currentTokens 58 | } 59 | var mutableRules = self.rules 60 | 61 | if inputString.isEmpty { 62 | return [Token(type: .string, inputString: "", characterStyles: [])] 63 | } 64 | 65 | self.currentPerfomanceLog.start() 66 | 67 | var elementArray : [Element] = [] 68 | for char in inputString { 69 | if newlines.containsUnicodeScalars(of: char) { 70 | let element = Element(character: char, type: .newline) 71 | elementArray.append(element) 72 | continue 73 | } 74 | if spaces.containsUnicodeScalars(of: char) { 75 | let element = Element(character: char, type: .space) 76 | elementArray.append(element) 77 | continue 78 | } 79 | let element = Element(character: char, type: .string) 80 | elementArray.append(element) 81 | } 82 | 83 | while !mutableRules.isEmpty { 84 | let nextRule = mutableRules.removeFirst() 85 | if enableLog { 86 | os_log("------------------------------", log: .tokenising, type: .info) 87 | os_log("RULE: %@", log: OSLog.tokenising, type:.info , nextRule.description) 88 | } 89 | self.currentPerfomanceLog.tag(with: "(start rule %@)") 90 | 91 | let scanner = SwiftyScanner(withElements: elementArray, rule: nextRule, metadata: self.metadataLookup) 92 | elementArray = scanner.scan() 93 | } 94 | 95 | var output : [Token] = [] 96 | var lastElement = elementArray.first! 97 | 98 | func empty( _ string : inout String, into tokens : inout [Token] ) { 99 | guard !string.isEmpty else { 100 | return 101 | } 102 | var token = Token(type: .string, inputString: string) 103 | token.metadataStrings.append(contentsOf: lastElement.metadata) 104 | token.characterStyles = lastElement.styles 105 | string.removeAll() 106 | tokens.append(token) 107 | } 108 | 109 | var accumulatedString = "" 110 | for element in elementArray { 111 | guard element.type != .escape else { 112 | continue 113 | } 114 | 115 | guard element.type == .string || element.type == .space || element.type == .newline else { 116 | empty(&accumulatedString, into: &output) 117 | continue 118 | } 119 | if lastElement.styles as? [CharacterStyle] != element.styles as? [CharacterStyle] { 120 | empty(&accumulatedString, into: &output) 121 | } 122 | accumulatedString.append(element.character) 123 | lastElement = element 124 | } 125 | empty(&accumulatedString, into: &output) 126 | 127 | self.currentPerfomanceLog.tag(with: "(finished all rules)") 128 | 129 | if enableLog { 130 | os_log("=====RULE PROCESSING COMPLETE=====", log: .tokenising, type: .info) 131 | os_log("==================================", log: .tokenising, type: .info) 132 | } 133 | return output 134 | } 135 | } 136 | 137 | 138 | extension String { 139 | func repeating( _ max : Int ) -> String { 140 | var output = self 141 | for _ in 1.. Bool 13 | } 14 | 15 | // Token definition 16 | public enum TokenType { 17 | case repeatingTag 18 | case openTag 19 | case intermediateTag 20 | case closeTag 21 | case string 22 | case escape 23 | case replacement 24 | } 25 | 26 | public struct Token { 27 | public let id = UUID().uuidString 28 | public let type : TokenType 29 | public let inputString : String 30 | public var metadataStrings : [String] = [] 31 | public internal(set) var group : Int = 0 32 | public internal(set) var characterStyles : [CharacterStyling] = [] 33 | public internal(set) var count : Int = 0 34 | public internal(set) var shouldSkip : Bool = false 35 | public internal(set) var tokenIndex : Int = -1 36 | public internal(set) var isProcessed : Bool = false 37 | public internal(set) var isMetadata : Bool = false 38 | public var children : [Token] = [] 39 | 40 | public var outputString : String { 41 | get { 42 | switch self.type { 43 | case .repeatingTag: 44 | if count <= 0 { 45 | return "" 46 | } else { 47 | let range = inputString.startIndex.. Token { 69 | var newToken = Token(type: (isReplacement) ? .replacement : .string , inputString: string, characterStyles: self.characterStyles) 70 | newToken.metadataStrings = self.metadataStrings 71 | newToken.isMetadata = self.isMetadata 72 | newToken.isProcessed = self.isProcessed 73 | return newToken 74 | } 75 | } 76 | 77 | extension Sequence where Iterator.Element == Token { 78 | var oslogDisplay: String { 79 | return "[\"\(self.map( { ($0.outputString.isEmpty) ? "\($0.type): \($0.inputString)" : $0.outputString }).joined(separator: "\", \""))\"]" 80 | } 81 | } 82 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 2.3.6 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/MASShortcut-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 2.3.6 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/MASShortcut-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_MASShortcut : NSObject 3 | @end 4 | @implementation PodsDummy_MASShortcut 5 | @end 6 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/MASShortcut-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/MASShortcut-umbrella.h: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | #import "MASDictionaryTransformer.h" 14 | #import "MASHotKey.h" 15 | #import "MASKeyCodes.h" 16 | #import "MASKeyMasks.h" 17 | #import "MASLocalization.h" 18 | #import "MASShortcut.h" 19 | #import "MASShortcutBinder.h" 20 | #import "MASShortcutMonitor.h" 21 | #import "MASShortcutValidator.h" 22 | #import "MASShortcutView+Bindings.h" 23 | #import "MASShortcutView.h" 24 | #import "Shortcut.h" 25 | 26 | FOUNDATION_EXPORT double MASShortcutVersionNumber; 27 | FOUNDATION_EXPORT const unsigned char MASShortcutVersionString[]; 28 | 29 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/MASShortcut.debug.xcconfig: -------------------------------------------------------------------------------- 1 | CODE_SIGN_IDENTITY = 2 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/MASShortcut 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | OTHER_LDFLAGS = $(inherited) -framework "AppKit" -framework "Carbon" 5 | PODS_BUILD_DIR = ${BUILD_DIR} 6 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 7 | PODS_ROOT = ${SRCROOT} 8 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/MASShortcut 9 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 10 | SKIP_INSTALL = YES 11 | USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES 12 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/MASShortcut.modulemap: -------------------------------------------------------------------------------- 1 | framework module MASShortcut { 2 | umbrella header "MASShortcut-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/MASShortcut.release.xcconfig: -------------------------------------------------------------------------------- 1 | CODE_SIGN_IDENTITY = 2 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/MASShortcut 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | OTHER_LDFLAGS = $(inherited) -framework "AppKit" -framework "Carbon" 5 | PODS_BUILD_DIR = ${BUILD_DIR} 6 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 7 | PODS_ROOT = ${SRCROOT} 8 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/MASShortcut 9 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 10 | SKIP_INSTALL = YES 11 | USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES 12 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/MASShortcut.xcconfig: -------------------------------------------------------------------------------- 1 | CODE_SIGN_IDENTITY = 2 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/MASShortcut 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | OTHER_LDFLAGS = -framework "AppKit" -framework "Carbon" 5 | PODS_BUILD_DIR = ${BUILD_DIR} 6 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 7 | PODS_ROOT = ${SRCROOT} 8 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/MASShortcut 9 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 10 | SKIP_INSTALL = YES 11 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/ResourceBundle-MASShortcut-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleIdentifier 8 | ${PRODUCT_BUNDLE_IDENTIFIER} 9 | CFBundleInfoDictionaryVersion 10 | 6.0 11 | CFBundleName 12 | ${PRODUCT_NAME} 13 | CFBundlePackageType 14 | BNDL 15 | CFBundleShortVersionString 16 | 2.3.6 17 | CFBundleSignature 18 | ???? 19 | CFBundleVersion 20 | 1 21 | NSPrincipalClass 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /Pods/Target Support Files/MASShortcut/ResourceBundle-MASShortcut-MASShortcut-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleIdentifier 8 | ${PRODUCT_BUNDLE_IDENTIFIER} 9 | CFBundleInfoDictionaryVersion 10 | 6.0 11 | CFBundleName 12 | ${PRODUCT_NAME} 13 | CFBundlePackageType 14 | BNDL 15 | CFBundleShortVersionString 16 | 2.3.6 17 | CFBundleSignature 18 | ???? 19 | CFBundleVersion 20 | 1 21 | NSPrincipalClass 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-tmpNote/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-tmpNote/Pods-tmpNote-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-tmpNote/Pods-tmpNote-acknowledgements.markdown: -------------------------------------------------------------------------------- 1 | # Acknowledgements 2 | This application makes use of the following third party libraries: 3 | 4 | ## MASShortcut 5 | 6 | Copyright (c) 2012-2013, Vadim Shpakovski 7 | All rights reserved. 8 | 9 | Redistribution and use in source and binary forms, with or without 10 | modification, are permitted provided that the following conditions are met: 11 | 12 | 1. Redistributions of source code must retain the above copyright notice, this 13 | list of conditions and the following disclaimer. 14 | 2. Redistributions in binary form must reproduce the above copyright notice, 15 | this list of conditions and the following disclaimer in the documentation 16 | and/or other materials provided with the distribution. 17 | 18 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 19 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 20 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 21 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 22 | ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 23 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 24 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 25 | ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 26 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 27 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 | 29 | 30 | ## SwiftyMarkdown 31 | 32 | The MIT License (MIT) 33 | 34 | Copyright (c) 2016 Simon Fairbairn 35 | 36 | Permission is hereby granted, free of charge, to any person obtaining a copy 37 | of this software and associated documentation files (the "Software"), to deal 38 | in the Software without restriction, including without limitation the rights 39 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 40 | copies of the Software, and to permit persons to whom the Software is 41 | furnished to do so, subject to the following conditions: 42 | 43 | The above copyright notice and this permission notice shall be included in all 44 | copies or substantial portions of the Software. 45 | 46 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 47 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 48 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 49 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 50 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 51 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 52 | SOFTWARE. 53 | 54 | Generated by CocoaPods - https://cocoapods.org 55 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-tmpNote/Pods-tmpNote-acknowledgements.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreferenceSpecifiers 6 | 7 | 8 | FooterText 9 | This application makes use of the following third party libraries: 10 | Title 11 | Acknowledgements 12 | Type 13 | PSGroupSpecifier 14 | 15 | 16 | FooterText 17 | Copyright (c) 2012-2013, Vadim Shpakovski 18 | All rights reserved. 19 | 20 | Redistribution and use in source and binary forms, with or without 21 | modification, are permitted provided that the following conditions are met: 22 | 23 | 1. Redistributions of source code must retain the above copyright notice, this 24 | list of conditions and the following disclaimer. 25 | 2. Redistributions in binary form must reproduce the above copyright notice, 26 | this list of conditions and the following disclaimer in the documentation 27 | and/or other materials provided with the distribution. 28 | 29 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 30 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 31 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 32 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 33 | ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 34 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 35 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 36 | ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 37 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 38 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 39 | 40 | License 41 | BSD 2-clause 42 | Title 43 | MASShortcut 44 | Type 45 | PSGroupSpecifier 46 | 47 | 48 | FooterText 49 | The MIT License (MIT) 50 | 51 | Copyright (c) 2016 Simon Fairbairn 52 | 53 | Permission is hereby granted, free of charge, to any person obtaining a copy 54 | of this software and associated documentation files (the "Software"), to deal 55 | in the Software without restriction, including without limitation the rights 56 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 57 | copies of the Software, and to permit persons to whom the Software is 58 | furnished to do so, subject to the following conditions: 59 | 60 | The above copyright notice and this permission notice shall be included in all 61 | copies or substantial portions of the Software. 62 | 63 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 64 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 65 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 66 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 67 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 68 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 69 | SOFTWARE. 70 | 71 | License 72 | MIT 73 | Title 74 | SwiftyMarkdown 75 | Type 76 | PSGroupSpecifier 77 | 78 | 79 | FooterText 80 | Generated by CocoaPods - https://cocoapods.org 81 | Title 82 | 83 | Type 84 | PSGroupSpecifier 85 | 86 | 87 | StringsTable 88 | Acknowledgements 89 | Title 90 | Acknowledgements 91 | 92 | 93 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-tmpNote/Pods-tmpNote-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Pods_tmpNote : NSObject 3 | @end 4 | @implementation PodsDummy_Pods_tmpNote 5 | @end 6 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-tmpNote/Pods-tmpNote-resources.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -e 3 | set -u 4 | set -o pipefail 5 | 6 | if [ -z ${UNLOCALIZED_RESOURCES_FOLDER_PATH+x} ]; then 7 | # If UNLOCALIZED_RESOURCES_FOLDER_PATH is not set, then there's nowhere for us to copy 8 | # resources to, so exit 0 (signalling the script phase was successful). 9 | exit 0 10 | fi 11 | 12 | mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 13 | 14 | RESOURCES_TO_COPY=${PODS_ROOT}/resources-to-copy-${TARGETNAME}.txt 15 | > "$RESOURCES_TO_COPY" 16 | 17 | XCASSET_FILES=() 18 | 19 | # This protects against multiple targets copying the same framework dependency at the same time. The solution 20 | # was originally proposed here: https://lists.samba.org/archive/rsync/2008-February/020158.html 21 | RSYNC_PROTECT_TMP_FILES=(--filter "P .*.??????") 22 | 23 | case "${TARGETED_DEVICE_FAMILY:-}" in 24 | 1,2) 25 | TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone" 26 | ;; 27 | 1) 28 | TARGET_DEVICE_ARGS="--target-device iphone" 29 | ;; 30 | 2) 31 | TARGET_DEVICE_ARGS="--target-device ipad" 32 | ;; 33 | 3) 34 | TARGET_DEVICE_ARGS="--target-device tv" 35 | ;; 36 | 4) 37 | TARGET_DEVICE_ARGS="--target-device watch" 38 | ;; 39 | *) 40 | TARGET_DEVICE_ARGS="--target-device mac" 41 | ;; 42 | esac 43 | 44 | install_resource() 45 | { 46 | if [[ "$1" = /* ]] ; then 47 | RESOURCE_PATH="$1" 48 | else 49 | RESOURCE_PATH="${PODS_ROOT}/$1" 50 | fi 51 | if [[ ! -e "$RESOURCE_PATH" ]] ; then 52 | cat << EOM 53 | error: Resource "$RESOURCE_PATH" not found. Run 'pod install' to update the copy resources script. 54 | EOM 55 | exit 1 56 | fi 57 | case $RESOURCE_PATH in 58 | *.storyboard) 59 | echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" || true 60 | ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} 61 | ;; 62 | *.xib) 63 | echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" || true 64 | ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} 65 | ;; 66 | *.framework) 67 | echo "mkdir -p ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" || true 68 | mkdir -p "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 69 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" $RESOURCE_PATH ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" || true 70 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 71 | ;; 72 | *.xcdatamodel) 73 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH"`.mom\"" || true 74 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodel`.mom" 75 | ;; 76 | *.xcdatamodeld) 77 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd\"" || true 78 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd" 79 | ;; 80 | *.xcmappingmodel) 81 | echo "xcrun mapc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm\"" || true 82 | xcrun mapc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm" 83 | ;; 84 | *.xcassets) 85 | ABSOLUTE_XCASSET_FILE="$RESOURCE_PATH" 86 | XCASSET_FILES+=("$ABSOLUTE_XCASSET_FILE") 87 | ;; 88 | *) 89 | echo "$RESOURCE_PATH" || true 90 | echo "$RESOURCE_PATH" >> "$RESOURCES_TO_COPY" 91 | ;; 92 | esac 93 | } 94 | 95 | mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 96 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 97 | if [[ "${ACTION}" == "install" ]] && [[ "${SKIP_INSTALL}" == "NO" ]]; then 98 | mkdir -p "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 99 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 100 | fi 101 | rm -f "$RESOURCES_TO_COPY" 102 | 103 | if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ -n "${XCASSET_FILES:-}" ] 104 | then 105 | # Find all other xcassets (this unfortunately includes those of path pods and other targets). 106 | OTHER_XCASSETS=$(find "$PWD" -iname "*.xcassets" -type d) 107 | while read line; do 108 | if [[ $line != "${PODS_ROOT}*" ]]; then 109 | XCASSET_FILES+=("$line") 110 | fi 111 | done <<<"$OTHER_XCASSETS" 112 | 113 | if [ -z ${ASSETCATALOG_COMPILER_APPICON_NAME+x} ]; then 114 | printf "%s\0" "${XCASSET_FILES[@]}" | xargs -0 xcrun actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${!DEPLOYMENT_TARGET_SETTING_NAME}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 115 | else 116 | printf "%s\0" "${XCASSET_FILES[@]}" | xargs -0 xcrun actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${!DEPLOYMENT_TARGET_SETTING_NAME}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" --app-icon "${ASSETCATALOG_COMPILER_APPICON_NAME}" --output-partial-info-plist "${TARGET_TEMP_DIR}/assetcatalog_generated_info_cocoapods.plist" 117 | fi 118 | fi 119 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-tmpNote/Pods-tmpNote-umbrella.h: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | 14 | FOUNDATION_EXPORT double Pods_tmpNoteVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char Pods_tmpNoteVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-tmpNote/Pods-tmpNote.debug.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/MASShortcut" "${PODS_CONFIGURATION_BUILD_DIR}/SwiftyMarkdown" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/MASShortcut/MASShortcut.framework/Headers" "${PODS_CONFIGURATION_BUILD_DIR}/SwiftyMarkdown/SwiftyMarkdown.framework/Headers" 5 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/../Frameworks' '@loader_path/Frameworks' 6 | OTHER_LDFLAGS = $(inherited) -framework "AppKit" -framework "Carbon" -framework "MASShortcut" -framework "SwiftyMarkdown" 7 | OTHER_SWIFT_FLAGS = $(inherited) -D COCOAPODS 8 | PODS_BUILD_DIR = ${BUILD_DIR} 9 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 10 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/. 11 | PODS_ROOT = ${SRCROOT}/Pods 12 | USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES 13 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-tmpNote/Pods-tmpNote.modulemap: -------------------------------------------------------------------------------- 1 | framework module Pods_tmpNote { 2 | umbrella header "Pods-tmpNote-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-tmpNote/Pods-tmpNote.release.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/MASShortcut" "${PODS_CONFIGURATION_BUILD_DIR}/SwiftyMarkdown" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/MASShortcut/MASShortcut.framework/Headers" "${PODS_CONFIGURATION_BUILD_DIR}/SwiftyMarkdown/SwiftyMarkdown.framework/Headers" 5 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/../Frameworks' '@loader_path/Frameworks' 6 | OTHER_LDFLAGS = $(inherited) -framework "AppKit" -framework "Carbon" -framework "MASShortcut" -framework "SwiftyMarkdown" 7 | OTHER_SWIFT_FLAGS = $(inherited) -D COCOAPODS 8 | PODS_BUILD_DIR = ${BUILD_DIR} 9 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 10 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/. 11 | PODS_ROOT = ${SRCROOT}/Pods 12 | USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES 13 | -------------------------------------------------------------------------------- /Pods/Target Support Files/SwiftyMarkdown/SwiftyMarkdown-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.2.2 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Pods/Target Support Files/SwiftyMarkdown/SwiftyMarkdown-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_SwiftyMarkdown : NSObject 3 | @end 4 | @implementation PodsDummy_SwiftyMarkdown 5 | @end 6 | -------------------------------------------------------------------------------- /Pods/Target Support Files/SwiftyMarkdown/SwiftyMarkdown-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | -------------------------------------------------------------------------------- /Pods/Target Support Files/SwiftyMarkdown/SwiftyMarkdown-umbrella.h: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | 14 | FOUNDATION_EXPORT double SwiftyMarkdownVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char SwiftyMarkdownVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /Pods/Target Support Files/SwiftyMarkdown/SwiftyMarkdown.debug.xcconfig: -------------------------------------------------------------------------------- 1 | CODE_SIGN_IDENTITY = 2 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/SwiftyMarkdown 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | OTHER_SWIFT_FLAGS = $(inherited) -D COCOAPODS 5 | PODS_BUILD_DIR = ${BUILD_DIR} 6 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 7 | PODS_ROOT = ${SRCROOT} 8 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/SwiftyMarkdown 9 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 10 | SKIP_INSTALL = YES 11 | USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES 12 | -------------------------------------------------------------------------------- /Pods/Target Support Files/SwiftyMarkdown/SwiftyMarkdown.modulemap: -------------------------------------------------------------------------------- 1 | framework module SwiftyMarkdown { 2 | umbrella header "SwiftyMarkdown-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Pods/Target Support Files/SwiftyMarkdown/SwiftyMarkdown.release.xcconfig: -------------------------------------------------------------------------------- 1 | CODE_SIGN_IDENTITY = 2 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/SwiftyMarkdown 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | OTHER_SWIFT_FLAGS = $(inherited) -D COCOAPODS 5 | PODS_BUILD_DIR = ${BUILD_DIR} 6 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 7 | PODS_ROOT = ${SRCROOT} 8 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/SwiftyMarkdown 9 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 10 | SKIP_INSTALL = YES 11 | USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES 12 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # tmpNote 2 | ![screenshot](https://raw.githubusercontent.com/buddax2/tmpNote/master/Resources/screenshot_new.png) 3 | 4 | it's a "fork" of [Tyke.app](http://tyke.app) ([@torrez](https://twitter.com/torrez)) but with some improovements: 5 | - global hotkey 6 | - launch at system startup 7 | 8 | Please try it: [Mac App Store](https://itunes.apple.com/us/app/tmpnote/id1293664761?l=ru&ls=1&mt=12) 9 | -------------------------------------------------------------------------------- /Resources/screenshot_new.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/Resources/screenshot_new.png -------------------------------------------------------------------------------- /Resources/tmpNote.dmg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/Resources/tmpNote.dmg -------------------------------------------------------------------------------- /Resources/tmpNote2.dmg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/Resources/tmpNote2.dmg -------------------------------------------------------------------------------- /tmpNote.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /tmpNote.xcodeproj/xcuserdata/buddax2.xcuserdatad/xcschemes/tmpNote.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 31 | 32 | 33 | 34 | 40 | 41 | 42 | 43 | 44 | 45 | 56 | 58 | 64 | 65 | 66 | 67 | 68 | 69 | 75 | 77 | 83 | 84 | 85 | 86 | 88 | 89 | 92 | 93 | 94 | -------------------------------------------------------------------------------- /tmpNote.xcodeproj/xcuserdata/buddax2.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | LauncherApplication.xcscheme 8 | 9 | orderHint 10 | 5 11 | 12 | LauncherApplication.xcscheme_^#shared#^_ 13 | 14 | orderHint 15 | 4 16 | 17 | tmpNote.xcscheme 18 | 19 | orderHint 20 | 0 21 | 22 | 23 | SuppressBuildableAutocreation 24 | 25 | 2776565B1F75BBEC001B0294 26 | 27 | primary 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /tmpNote.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tmpNote.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /tmpNote.xcworkspace/xcuserdata/buddax2.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 9 | 22 | 23 | 24 | 26 | 39 | 40 | 41 | 43 | 56 | 57 | 58 | 60 | 73 | 74 | 75 | 77 | 90 | 91 | 92 | 94 | 107 | 108 | 109 | 111 | 123 | 124 | 125 | 127 | 139 | 140 | 141 | 143 | 155 | 156 | 157 | 158 | 159 | -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "16x16", 5 | "idiom" : "mac", 6 | "filename" : "icon_16x16.png", 7 | "scale" : "1x" 8 | }, 9 | { 10 | "size" : "16x16", 11 | "idiom" : "mac", 12 | "filename" : "icon_16x16@2x.png", 13 | "scale" : "2x" 14 | }, 15 | { 16 | "size" : "32x32", 17 | "idiom" : "mac", 18 | "filename" : "icon_32x32.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "32x32", 23 | "idiom" : "mac", 24 | "filename" : "icon_32x32@2x.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "128x128", 29 | "idiom" : "mac", 30 | "filename" : "icon_128x128.png", 31 | "scale" : "1x" 32 | }, 33 | { 34 | "size" : "128x128", 35 | "idiom" : "mac", 36 | "filename" : "icon_128x128@2x.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "256x256", 41 | "idiom" : "mac", 42 | "filename" : "icon_256x256.png", 43 | "scale" : "1x" 44 | }, 45 | { 46 | "size" : "256x256", 47 | "idiom" : "mac", 48 | "filename" : "icon_256x256@2x.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "512x512", 53 | "idiom" : "mac", 54 | "filename" : "icon_512x512.png", 55 | "scale" : "1x" 56 | }, 57 | { 58 | "size" : "512x512", 59 | "idiom" : "mac", 60 | "filename" : "icon_512x512@2x.png", 61 | "scale" : "2x" 62 | } 63 | ], 64 | "info" : { 65 | "version" : 1, 66 | "author" : "xcode" 67 | } 68 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/icon_128x128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/AppIcon.appiconset/icon_128x128.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/icon_128x128@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/AppIcon.appiconset/icon_128x128@2x.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/icon_16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/AppIcon.appiconset/icon_16x16.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/icon_16x16@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/AppIcon.appiconset/icon_16x16@2x.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/icon_256x256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/AppIcon.appiconset/icon_256x256.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/icon_256x256@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/AppIcon.appiconset/icon_256x256@2x.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/icon_32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/AppIcon.appiconset/icon_32x32.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/icon_32x32@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/AppIcon.appiconset/icon_32x32@2x.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/icon_512x512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/AppIcon.appiconset/icon_512x512.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/AppIcon.appiconset/icon_512x512@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/AppIcon.appiconset/icon_512x512@2x.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/Compose.imageset/ Compose.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/Compose.imageset/ Compose.pdf -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/Compose.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : " Compose.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "template" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/Compose_bg3.imageset/ Compose_bg3.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/Compose_bg3.imageset/ Compose_bg3.pdf -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/Compose_bg3.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : " Compose_bg3.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/Compose_bg_template.imageset/ Compose_bg_template.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/Compose_bg_template.imageset/ Compose_bg_template.pdf -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/Compose_bg_template.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : " Compose_bg_template.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "template" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/Compose_empty.imageset/Compose_empty.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/Compose_empty.imageset/Compose_empty.pdf -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/Compose_empty.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "Compose_empty.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "template" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/big_A.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "big_A.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "template" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/big_A.imageset/big_A.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/big_A.imageset/big_A.pdf -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/clear.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "clear.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "template" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/clear.imageset/clear.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/clear.imageset/clear.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/copy.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "copy.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "template" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/copy.imageset/copy.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/copy.imageset/copy.pdf -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/draw_empty.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "draw_empty.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "template" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/draw_empty.imageset/draw_empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/draw_empty.imageset/draw_empty.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/draw_filled.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "draw_filled.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "template" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/draw_filled.imageset/draw_filled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/draw_filled.imageset/draw_filled.png -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/menu.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "menu2.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/menu.imageset/menu2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/menu.imageset/menu2.pdf -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/page_indicator.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "page_indicator.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "original" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/page_indicator.imageset/page_indicator.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/page_indicator.imageset/page_indicator.pdf -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/page_indicator_active.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "page_indicator_active2.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/page_indicator_active.imageset/page_indicator_active2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/page_indicator_active.imageset/page_indicator_active2.pdf -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/settings.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "settings2.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "template" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/settings.imageset/settings2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/settings.imageset/settings2.pdf -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/small_A.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "small_A.pdf", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | }, 21 | "properties" : { 22 | "template-rendering-intent" : "template" 23 | } 24 | } -------------------------------------------------------------------------------- /tmpNote/Assets.xcassets/small_A.imageset/small_A.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Assets.xcassets/small_A.imageset/small_A.pdf -------------------------------------------------------------------------------- /tmpNote/DrawingScene.sks: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/DrawingScene.sks -------------------------------------------------------------------------------- /tmpNote/DrawingScene.swift: -------------------------------------------------------------------------------- 1 | // 2 | // DrawingScene.swift 3 | // tmpNote 4 | // 5 | // Created by BUDDAx2 on 1/2/19. 6 | // Copyright © 2019 BUDDAx2. All rights reserved. 7 | // 8 | 9 | import SpriteKit 10 | import Carbon.HIToolbox 11 | 12 | class DrawingScene: SKScene { 13 | 14 | var storage: StorageDataSource? 15 | var firstPoint: CGPoint? 16 | var lineNode = SKShapeNode() 17 | var pathToDraw: CGMutablePath? 18 | var redoArray = [SKShapeNode]() 19 | 20 | override func mouseDown(with event: NSEvent) { 21 | firstPoint = event.location(in: self) 22 | pathToDraw = CGMutablePath() 23 | } 24 | 25 | override func mouseDragged(with event: NSEvent) { 26 | let positionInScene = event.location(in: self) 27 | 28 | lineNode.removeFromParent() 29 | if let fp = firstPoint { 30 | pathToDraw?.move(to: CGPoint(x: fp.x, y: fp.y)) 31 | } 32 | pathToDraw?.addLine(to: CGPoint(x: positionInScene.x, y: positionInScene.y)) 33 | lineNode.path = pathToDraw 34 | lineNode.strokeColor = .textColor 35 | addChild(lineNode) 36 | firstPoint = positionInScene 37 | } 38 | 39 | override func mouseUp(with event: NSEvent) { 40 | if let path = pathToDraw { 41 | lineNode.removeFromParent() 42 | let newLine = SKShapeNode(path: path) 43 | newLine.strokeColor = .textColor 44 | addChild(newLine) 45 | DatasourceController.shared.lines.append(newLine) 46 | } 47 | } 48 | 49 | func clear() { 50 | DatasourceController.shared.lines.forEach { line in 51 | line.removeFromParent() 52 | } 53 | DatasourceController.shared.lines.removeAll() 54 | pathToDraw = nil 55 | } 56 | 57 | func load() { 58 | pathToDraw = CGMutablePath() 59 | 60 | for line in DatasourceController.shared.lines { 61 | line.removeFromParent() 62 | addChild(line) 63 | } 64 | } 65 | 66 | func undo() { 67 | if let lastLine = DatasourceController.shared.lines.last { 68 | redoArray.append(lastLine) 69 | lastLine.removeFromParent() 70 | DatasourceController.shared.lines.removeLast() 71 | } 72 | } 73 | 74 | func redo() { 75 | if let lastLine = redoArray.last { 76 | addChild(lastLine) 77 | DatasourceController.shared.lines.append(lastLine) 78 | redoArray.removeLast() 79 | } 80 | } 81 | } 82 | 83 | extension DrawingScene { 84 | 85 | override func keyDown(with event: NSEvent) { 86 | 87 | // ⌘S - Save content 88 | if event.modifierFlags.contains(.command) && event.keyCode == kVK_ANSI_S { 89 | DatasourceController.shared.saveSketch() 90 | } 91 | 92 | if event.keyCode == kVK_ANSI_Z { 93 | // ⌘⇧Z - Redo 94 | if event.modifierFlags.contains(.command) && event.modifierFlags.contains(.shift) { 95 | redo() 96 | } 97 | // ⌘Z - Undo 98 | else if event.modifierFlags.contains(.command) { 99 | undo() 100 | } 101 | } 102 | 103 | super.keyDown(with: event) 104 | } 105 | } 106 | -------------------------------------------------------------------------------- /tmpNote/EventMonitor.swift: -------------------------------------------------------------------------------- 1 | // 2 | // EventMonitor.swift 3 | // tmpNote 4 | // 5 | // Created by BUDDAx2 on 9/24/17. 6 | // Copyright © 2017 BUDDAx2. All rights reserved. 7 | // 8 | 9 | import Cocoa 10 | 11 | public class EventMonitor { 12 | private var monitor: Any? 13 | private let mask: NSEvent.EventTypeMask 14 | private let handler: (NSEvent?) -> Void 15 | 16 | public init(mask: NSEvent.EventTypeMask, handler: @escaping (NSEvent?) -> Void) { 17 | self.mask = mask 18 | self.handler = handler 19 | } 20 | 21 | deinit { 22 | stop() 23 | } 24 | 25 | public func start() { 26 | monitor = NSEvent.addGlobalMonitorForEvents(matching: mask, handler: handler) 27 | } 28 | 29 | public func stop() { 30 | if monitor != nil { 31 | NSEvent.removeMonitor(monitor!) 32 | monitor = nil 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /tmpNote/Extensions.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Extensions.swift 3 | // tmpNote 4 | // 5 | // Created by BUDDAx2 on 1/6/19. 6 | // Copyright © 2019 BUDDAx2. All rights reserved. 7 | // 8 | 9 | import Cocoa 10 | 11 | extension CGPath { 12 | func forEach( body: @escaping @convention(block) (CGPathElement) -> Void) { 13 | typealias Body = @convention(block) (CGPathElement) -> Void 14 | let callback: @convention(c) (UnsafeMutableRawPointer, UnsafePointer) -> Void = { (info, element) in 15 | let body = unsafeBitCast(info, to: Body.self) 16 | body(element.pointee) 17 | } 18 | 19 | let unsafeBody = unsafeBitCast(body, to: UnsafeMutableRawPointer.self) 20 | self.apply(info: unsafeBody, function: unsafeBitCast(callback, to: CGPathApplierFunction.self)) 21 | } 22 | func getPathElementsPoints() -> [CGPoint] { 23 | var arrayPoints : [CGPoint]! = [CGPoint]() 24 | self.forEach { element in 25 | switch (element.type) { 26 | case CGPathElementType.moveToPoint: 27 | arrayPoints.append(element.points[0]) 28 | case .addLineToPoint: 29 | arrayPoints.append(element.points[0]) 30 | case .addQuadCurveToPoint: 31 | arrayPoints.append(element.points[0]) 32 | arrayPoints.append(element.points[1]) 33 | case .addCurveToPoint: 34 | arrayPoints.append(element.points[0]) 35 | arrayPoints.append(element.points[1]) 36 | arrayPoints.append(element.points[2]) 37 | default: break 38 | } 39 | } 40 | return arrayPoints 41 | } 42 | func getPathElementsPointsAndTypes() -> ([CGPoint],[CGPathElementType]) { 43 | var arrayPoints : [CGPoint]! = [CGPoint]() 44 | var arrayTypes : [CGPathElementType]! = [CGPathElementType]() 45 | self.forEach { element in 46 | switch (element.type) { 47 | case CGPathElementType.moveToPoint: 48 | arrayPoints.append(element.points[0]) 49 | arrayTypes.append(element.type) 50 | case .addLineToPoint: 51 | arrayPoints.append(element.points[0]) 52 | arrayTypes.append(element.type) 53 | case .addQuadCurveToPoint: 54 | arrayPoints.append(element.points[0]) 55 | arrayPoints.append(element.points[1]) 56 | arrayTypes.append(element.type) 57 | arrayTypes.append(element.type) 58 | case .addCurveToPoint: 59 | arrayPoints.append(element.points[0]) 60 | arrayPoints.append(element.points[1]) 61 | arrayPoints.append(element.points[2]) 62 | arrayTypes.append(element.type) 63 | arrayTypes.append(element.type) 64 | arrayTypes.append(element.type) 65 | default: break 66 | } 67 | } 68 | return (arrayPoints,arrayTypes) 69 | } 70 | } 71 | 72 | // Taken from here: https://gist.github.com/juliensagot/9749c3a1df28c38fb9f9 73 | // But I removed forced closing NSBezierPath 74 | extension NSBezierPath { 75 | 76 | var cgPath: CGPath { 77 | get { return self.transformToCGPath() } 78 | } 79 | 80 | /// Transforms the NSBezierPath into a CGPath 81 | /// 82 | /// :returns: The transformed NSBezierPath 83 | private func transformToCGPath() -> CGPath { 84 | 85 | // Create path 86 | let path = CGMutablePath() 87 | let points = UnsafeMutablePointer.allocate(capacity: 3) 88 | let numElements = self.elementCount 89 | 90 | if numElements > 0 { 91 | 92 | for index in 0..())? 14 | var onMouseExitedClosure: (()->())? 15 | 16 | override func awakeFromNib() { 17 | self.backgroundColor = .clear 18 | addTrackingArea(NSTrackingArea(rect: bounds, options: [.activeAlways, .mouseEnteredAndExited], owner: self, userInfo: nil)) 19 | } 20 | 21 | override func layout() { 22 | super.layout() 23 | 24 | self.trackingAreas.forEach { [weak self] area in 25 | self?.removeTrackingArea(area) 26 | } 27 | 28 | addTrackingArea(NSTrackingArea(rect: bounds, options: [.activeAlways, .mouseEnteredAndExited], owner: self, userInfo: nil)) 29 | } 30 | 31 | override func mouseEntered(with event: NSEvent) { 32 | onMouseEnteredClosure?() 33 | } 34 | 35 | override func mouseExited(with event: NSEvent) { 36 | onMouseExitedClosure?() 37 | } 38 | 39 | } 40 | 41 | 42 | extension NSView { 43 | 44 | var backgroundColor: NSColor? { 45 | 46 | get { 47 | if let colorRef = self.layer?.backgroundColor { 48 | return NSColor(cgColor: colorRef) 49 | } else { 50 | return nil 51 | } 52 | } 53 | 54 | set { 55 | self.wantsLayer = true 56 | self.layer?.backgroundColor = newValue?.cgColor 57 | } 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /tmpNote/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIconFile 10 | 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | $(MARKETING_VERSION) 21 | CFBundleVersion 22 | $(CURRENT_PROJECT_VERSION) 23 | LSApplicationCategoryType 24 | public.app-category.productivity 25 | LSMinimumSystemVersion 26 | $(MACOSX_DEPLOYMENT_TARGET) 27 | LSUIElement 28 | 29 | NSHumanReadableCopyright 30 | Copyright © 2020 BUDDAx2. All rights reserved. 31 | NSMainStoryboardFile 32 | Main 33 | NSPrincipalClass 34 | NSApplication 35 | NSUbiquitousContainers 36 | 37 | iCloud.$(PRODUCT_BUNDLE_IDENTIFIER) 38 | 39 | NSUbiquitousContainerIsDocumentScopePublic 40 | 41 | NSUbiquitousContainerName 42 | $(PRODUCT_NAME) 43 | NSUbiquitousContainerSupportedFolderLevels 44 | Any 45 | 46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /tmpNote/PreferencesWindow.swift: -------------------------------------------------------------------------------- 1 | // 2 | // PreferencesWindow.swift 3 | // tmpNote 4 | // 5 | // Created by BUDDAx2 on 9/25/17. 6 | // Copyright © 2017 BUDDAx2. All rights reserved. 7 | // 8 | 9 | import AppKit 10 | import MASShortcut 11 | 12 | 13 | protocol PreferencesDelegate: class { 14 | func settingsDidChange() 15 | } 16 | 17 | 18 | class PreferencesWindowController: NSWindowController { 19 | 20 | } 21 | 22 | extension PreferencesWindowController { 23 | 24 | static func freshController() -> PreferencesWindowController { 25 | 26 | let storyBoard = NSStoryboard(name: "Main", bundle: nil) 27 | let identifier = "PreferencesWindowController" 28 | guard let vc = storyBoard.instantiateController(withIdentifier: identifier) as? PreferencesWindowController else { 29 | 30 | fatalError("Can't instantiate PreferencesWindowController. Check Main.storyboard") 31 | } 32 | 33 | return vc 34 | } 35 | } 36 | 37 | enum IconColor: Int { 38 | case `default` 39 | case red 40 | 41 | func color() -> NSColor { 42 | switch self { 43 | case .default: 44 | return IconColor.defaultColor() 45 | case .red: 46 | return .red 47 | } 48 | } 49 | 50 | static func defaultColor() -> NSColor { 51 | if #available(macOS 11, *) { 52 | return .controlColor 53 | } 54 | 55 | return .textColor 56 | } 57 | } 58 | 59 | class GeneralViewController: NSViewController { 60 | 61 | @IBOutlet weak var syncToggleButton: NSButton! 62 | @IBOutlet weak var colorPicker: NSPopUpButton! 63 | @IBOutlet weak var colorView: NSStackView! 64 | @IBOutlet weak var launchAtStartupCheckbox: NSButton! 65 | @IBOutlet var shortcutView: MASShortcutView! { 66 | didSet { 67 | shortcutView.associatedUserDefaultsKey = GeneralViewController.kPreferenceGlobalShortcut 68 | } 69 | } 70 | 71 | static let kPreferenceGlobalShortcut = "GlobalShortcut" 72 | weak var delegate: PreferencesDelegate? 73 | 74 | override func viewDidLoad() { 75 | super.viewDidLoad() 76 | 77 | MASShortcutBinder.shared().bindShortcut(withDefaultsKey: GeneralViewController.kPreferenceGlobalShortcut, toAction: { 78 | let appDelegate = NSApplication.shared.delegate as! AppDelegate 79 | appDelegate.togglePopover(self) 80 | }) 81 | } 82 | 83 | override func viewWillAppear() { 84 | syncUI() 85 | } 86 | 87 | @IBAction func toggleDynamicIcon(_ sender: Any) { 88 | let isDynamicIconON = UserDefaults.standard.bool(forKey: "DynamicIcon") 89 | colorView.isHidden = isDynamicIconON == false 90 | delegate?.settingsDidChange() 91 | } 92 | 93 | @IBAction func toggleLaunchState(_ sender: NSButton) { 94 | let appDelegate = NSApplication.shared.delegate as! AppDelegate 95 | appDelegate.setupLaunchOnStartup() 96 | } 97 | 98 | @IBAction func tintColorDidChange(_ sender: NSPopUpButton) { 99 | delegate?.settingsDidChange() 100 | } 101 | 102 | @IBAction func shopIconPopover(_ sender: NSButton) { 103 | let popover = NSPopover() 104 | popover.behavior = .transient 105 | let storyBoard = NSStoryboard(name: "Main", bundle: nil) 106 | let identifier = "PopoverAnimationVC" 107 | guard let vc = storyBoard.instantiateController(withIdentifier: identifier) as? PopoverAnimationVC else { return } 108 | popover.contentViewController = vc 109 | popover.show(relativeTo: sender.bounds, of: sender, preferredEdge: NSRectEdge.maxX) 110 | } 111 | 112 | func syncUI() { 113 | syncToggleButton.isEnabled = Datasource.containerUrl != nil 114 | } 115 | } 116 | 117 | class PopoverAnimationVC: NSViewController { 118 | 119 | @IBOutlet weak var imageView: NSImageView! { 120 | didSet { 121 | imageView.canDrawSubviewsIntoLayer = true 122 | imageView.imageScaling = .scaleNone 123 | imageView.animates = true 124 | imageView.image = NSImage(named: "example") 125 | } 126 | } 127 | } 128 | -------------------------------------------------------------------------------- /tmpNote/Resources/example.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/buddax2/tmpNote/73073a5beec7f8e9969bec09efc05bb6267ba753/tmpNote/Resources/example.gif -------------------------------------------------------------------------------- /tmpNote/tmpNote.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.developer.icloud-container-identifiers 6 | 7 | iCloud.$(CFBundleIdentifier) 8 | 9 | com.apple.developer.icloud-services 10 | 11 | CloudDocuments 12 | 13 | com.apple.developer.ubiquity-container-identifiers 14 | 15 | iCloud.$(CFBundleIdentifier) 16 | 17 | com.apple.security.app-sandbox 18 | 19 | com.apple.security.files.user-selected.read-only 20 | 21 | 22 | 23 | --------------------------------------------------------------------------------