Change the width of Master in UISplitViewController

前端 未结 16 1761
自闭症患者
自闭症患者 2020-11-28 05:55

The iPad programming guide says that the splitView\'s left pane is fixed to 320 points. But 320 pixels for my master view controller is too much. I would like to reduce it a

16条回答
  •  误落风尘
    2020-11-28 06:44

    This code work for me:)

    @interface UISplitViewController(myExt) 
    - (void)setNewMasterSize:(float)size; 
    @end

    @implementation UISplitViewController(myExt) - (void)setNewMasterSize:(float)size { _masterColumnWidth = size; } @end

    and use it on each operation with view (like rotation)

提交回复
热议问题