Objective c 自定义下拉对话框(类似于“保存”对话框)
是否可以创建类似于文件保存对话框的自定义下拉对话框?下面的链接也说明了这一点 感谢您的帮助这些“下拉对话框”称为工作表,可以是一个窗口 可在NSApplication上找到使其显示的方法: 超级简单的实现看起来像这样:Objective c 自定义下拉对话框(类似于“保存”对话框),objective-c,macos,drop-down-menu,window,save,Objective C,Macos,Drop Down Menu,Window,Save,是否可以创建类似于文件保存对话框的自定义下拉对话框?下面的链接也说明了这一点 感谢您的帮助这些“下拉对话框”称为工作表,可以是一个窗口 可在NSApplication上找到使其显示的方法: 超级简单的实现看起来像这样: NSWindowController *sheet = [[NSWindowController alloc] initWithWindowNibName:@"Sheet"]; [NSApp beginSheet: sheet.window modalForWindow
NSWindowController *sheet = [[NSWindowController alloc] initWithWindowNibName:@"Sheet"];
[NSApp beginSheet: sheet.window
modalForWindow: self.view.window // The window from where the sheet will appear
modalDelegate: self
didEndSelector: nil // Optional @selector(didEndSheet:returnCode:contextInfo:)
contextInfo: nil];