Make NSComboBox Appear when NSTextField is clicked
问题 How can I make an NSComboBox disappear when an NSTextField is clicked? This is the code I'm using: Class comboBox: (used as custom class for my NSComboBox in the interface builder) comboBox.h: #import <Cocoa/Cocoa.h> @interface comboBox1 : NSComboBox -(void)Hide; @end comboBox.m: #import "comboBox1.h" @implementation comboBox1 -(void)Hide { [self setHidden:YES]; } @end Class txtField: (used as custom class for my NSTextField in the interface builder) txtField.h: #import <Cocoa/Cocoa.h>