I am new to developing on for Mac. I have the following scenario:
A Login window with login button. when user presses login button, the main program view should appear.
The question is should i have LoginWindow that disappears once login clicked and OtherWindow that appears. Or, should i have one MainWindow with LoginView and OtheView?
In my opinion, you should simply open your main window and then ask the user for his/her credentials in a modal view. You can find the Apple docs here. Look also at how Mail.app does it, if you like.
Even better would be letting the user define credentials in a preference pane; the modal view will also come at hand in this case, if the user set the wrong credentials, e.g.