Difference between NSWindowController Vs NSViewController

前端 未结 3 2032
逝去的感伤
逝去的感伤 2021-02-03 22:55

I am coming from iOS background and starting to learn Cocoa. On iOS unless we have multiple targets for iPad and iPhone

3条回答
  •  我在风中等你
    2021-02-03 23:00

    A Window Controller creates a traditional window and has all the traditional APIs.

    A View Controller can also be shown outside of another view. It then gets a window frame but does not support the full traditional Window Controller API.

    In addition to custom, modal, and show, a View Controller can also be presented in the modes sheet and popover.

    So, View Controller has more presentation options and a more streamlined API but probably a few limitations in cases that are covered by the traditional Window Controller.

提交回复
热议问题