ios developer tiny share-20160705

本文介绍了NSPanel类,它是NSWindow的子类,用于显示临时、全局或紧迫信息,如错误消息或需要用户响应的情况。同时,文章还概述了Mac OS X、iOS、tvOS和watchOS的不同SDK,以及它们之间的共同点和区别。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

今天分享NSPanel,如下:

The NSPanel class is a subclass of NSWindow that you use to display transient, global, or pressing information. For example, you would use an instance of NSPanel, rather than an instance of NSWindow, to display error messages or to query the user for a response to remarkable or unusual circumstances. AppKit implements some common panels for you such as the Save, Open and Print panels, used to save, open, and print documents. Using these panels gives the user a consistent “look and feel” across applications for common operations.

讲到今天,我们已经讲了NSApplication、NSWindow、NSView、NSPanel,但这些api都是用于Mac os上的Application开发的,就是在苹果电脑上开发的应用,不是在手机上开发的应用。

ios开发,按照设备,分为在Mac、iPhone、TV、Watch,他们一致的是都使用Xcode开发工具,都使用Object-C语言,不一致的是它们有各自的sdk,但是也有部分公用的。

Mac对应的sdk为OS X sdk

iPhone对应的sdk为iOS

TV对应的sdk为tvOS

watch对应的sdk为watchOS

要看哪个类属于哪个sdk,可以在该类的右侧看到,如下:


总的来说,苹果从电脑到手机,甚至手表、电视,提供了更一致、连贯的sdk供开发者。而Windows、android在这方面是无法做到的。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值