摘要: 1.添加URLSchema白名单 在info.plist文件中添加白名单,icon的图片文件格式 icon.icns 阅读全文
posted @ 2020-10-10 10:06 sundaysmac 阅读(283) 评论(0) 推荐(0) 编辑
摘要: 如何让App icon不显示在Dock中 有些App不需要在Dock中有图标,比如时钟之类,只需要在status bar中显示就可以了。我们可以在info.plist加上如下设置Application is agent (UIElement)=YES即可。 如果只在NSStatusBar中显示,不再 阅读全文
posted @ 2020-10-10 09:31 sundaysmac 阅读(238) 评论(0) 推荐(0) 编辑
摘要: 苹果开发官方文档 苹果开发官方文档 https://developer.apple.com/library/archive/navigation/#section=Platforms&topic=iOS https://developer.apple.com/documentation/ 阅读全文
posted @ 2020-10-10 09:17 sundaysmac 阅读(488) 评论(0) 推荐(0) 编辑
摘要: MacOS 开发 — 最近打开文件(Security-scoped bookmark) Mac OS X APP在开发完成,上线的时候必须支持sandbox[https://blog.csdn.net/heroguo_jp/article/details/54862223] 当设置完成SandBox 阅读全文
posted @ 2020-10-10 09:16 sundaysmac 阅读(715) 评论(0) 推荐(0) 编辑
摘要: https://github.com/shpakovski/MASShortcut 阅读全文
posted @ 2020-10-08 21:37 sundaysmac 阅读(135) 评论(0) 推荐(0) 编辑
摘要: // // ViewController.swift // MacSwiftAnimationExample // // Created by cb_2018 on 2019/4/10. // Copyright © 2019 cfwf. All rights reserved. // import 阅读全文
posted @ 2019-04-10 11:40 sundaysmac 阅读(405) 评论(0) 推荐(0) 编辑
摘要: //创建与设备无关的 //Gray // [NSColor colorWithCalibratedWhite:(CGFloat) alpha:(CGFloat)]; //RGB // [NSColor colorWithCalibratedRed:<#(CGFloat)#> green:<#(CGF 阅读全文
posted @ 2019-04-10 00:00 sundaysmac 阅读(270) 评论(0) 推荐(0) 编辑
摘要: import Cocoa class ViewController: NSViewController { override var representedObject: Any? { didSet { // Update the view, if already loaded. } } //6断点 阅读全文
posted @ 2019-04-01 20:30 sundaysmac 阅读(598) 评论(0) 推荐(0) 编辑
摘要: 工欲善其事,必先利其器,在写项目之前,给大家延伸个小知识:如何声明iOS和macOS** 公用的宏定义**。 《从零到一》创建一个完整的macOS APP 作为一个iOS开发者,可以很轻松的过渡到初级的macOS开发,介于macOS开发的相关资料甚少,于是发文以作记录,同时希望能帮助到志同道合的童鞋 阅读全文
posted @ 2019-04-01 15:45 sundaysmac 阅读(934) 评论(0) 推荐(0) 编辑
摘要: //// 使用系统默认的方式创建URLSession 基本流程如下 let kServerBaseUrl = "http://127.0.0.1/iosxHelper/SAPI" func urlSessionNoDelegateTest() { //创建一个默认的Session配置 let def 阅读全文
posted @ 2019-04-01 15:29 sundaysmac 阅读(564) 评论(0) 推荐(0) 编辑