Parent window and child window
HI, I m new in cocoa, Im working in a project which is developed by other team and now I hv to work in this project.
I m displaying some data in tableview. and I am creating buttons for 开发者_运维问答executing some action in a column of this tableview. I m using all this by coding. that tableview is inside and an custom view. from that button in the tableview I m executing a some code and trying to display a window that should works as a child window of that custom view. when I m trying to close the child window the parent window also being closed.
I m using the following code for displaying the child window.
[[[self view] window] addChildWindow:childWindowOutlet ordered:NSWindowAbove];
[childWindowOutlet setMovableByWindowBackground:YES];
please help me for the following.... The child window should movable with parent window. when I closed child window the parent window should not be closed. The main window should not be accessible if the child window is opened.
Sounds to me like you want a sheet, not a child window
精彩评论