Mac Cocoa UI Api
来源:互联网 发布:java策略模式的优点 编辑:程序博客网 时间:2024/06/04 00:18
NSWindow setExcludedFromWindowsMenu
设定是否在 Window Menu 中显示。YES 不显示,NO 显示。
NSResponder becomeFirstResponder
Notifies the receiver that it’s about to become first responder in its NSWindow
.
Discussion
The default implementation returns YES
, accepting first responder status. Subclasses can override this method to update state or perform some action such as highlighting the selection, or to return NO
, refusing first responder status.
Use the NSWindow
makeFirstResponder:
method, not this method, to make an object the first responder. Never invoke this method directly.
NSButton *closeButton = [[self window] standardWindowButton:NSWindowCloseButton];
[closeButton setTarget:self];
[closeButton setAction:@selector(onClickCancel:)];
[[self window] standardWindowButton:NSWindowCloseButton]获得当前window 左上角 的
[closeButton setTarget:self];
[closeButton setAction:@selector(onClickCancel:)]; 重载 方法,可以在关闭时,添加自己的实现。
startAnimation:
Starts the animation of an indeterminate progress indicator.
Parameters
- sender
The object sending the message.
Discussion
Does nothing for a determinate progress indicator.
NSButton *miniaturizeButton = [[self window] standardWindowButton:NSWindowMiniaturizeButton]; //获得当前window的最小化button
[miniaturizeButton setTarget:self]; //将self 设定为 target
[miniaturizeButton setAction:@selector(onClickMiniaturize:)];//绑定最小化调用函数
- (void) onClickMiniaturize:(id)sender
{
[[self window] miniaturize:self];//将window 最小化
}[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(windowDidDeminiaturize) name:NSWindowDidDeminiaturizeNotification object:nil];//监听window 最小化事件
- Mac Cocoa UI Api
- 【Cocoa】cocoa UI 常用算法
- UI - Cocoa Touch框架
- mac cocoa笔记
- Cocoa.Programming.for.Mac 翻译
- Mac OS Cocoa绑定教程
- MAC OS X Cocoa NSToolbar 的使用
- Apple Mac cocoa入门级教程- HelloWorld!
- Cocoa.Programming.for.Mac系统文章翻译
- Mac开发 Cocoa编程 实现多国语
- Apple Mac cocoa入门级教程- HelloWorld!
- MAC COCOA一个简单的多线程程序
- Cocoa Mac应用程序创建DMG打包发布
- 学习mac编程之Cocoa介绍
- mac cocoa中注册全局快捷键
- Cocoa mac 应用程序打包为dmg
- 新Mac book安装cocoa pods
- cocoa之高级开发RunTime高级API
- linux 删除.svn 目录 .
- CSS 中文字体 Unicode 编码方案
- jstl1.0和EL引起的错误
- linux子系统的初始化_subsys_initcall():那些入口函数
- JavaScript开发: 打印json对象的内容
- Mac Cocoa UI Api
- CSS display:none和visibility:hidden区别
- 创建数据库失败。无法创建列出的某些文件名。请检查前面的错误消息。
- mysql导入数据时提示 USING BTREE 相关错误解决办法
- 验证PSP(程序段前缀)的作用
- error: 'ff_get_buffer' was not declared in this scope
- 将所有超链接改成form的post提交 防止ie6不兼容UTF-8的字符
- 使用 SymChk.exe 实用程序下载符号
- android英文用的是什么字体