MPVolumeView未在iOS模拟器中显示

Hen*_*Two 6 iphone xcode ios swift xcode6.3

此代码在物理iPhone 6上运行良好,但在iOS模拟器上,MPVolumeView不显示.

- (void)setUpVolumeView
{    
    CGRect sliderRect = CGRectMake(20, 400, 300, 20);
    self.myVolumeView = [[MPVolumeView alloc] initWithFrame:sliderRect];
    [self.view addSubview: self.myVolumeView];
}
Run Code Online (Sandbox Code Playgroud)

self 在这种情况下是一个ViewController.

谁知道为什么会这样?

bgi*_*ham 12

就我的记忆而言,MPVolumeView从未在模拟器中运行过.它始终显示为空白或在白色文本中显示"无可用音量".