Alok
Alok

Reputation: 25938

Volume UI Should not appear when using on screen volume slider- iOS

enter image description here

Volume UI should not appear during use of volume slider of the application.

Upvotes: 2

Views: 364

Answers (1)

Alok
Alok

Reputation: 25938

I am not saying this is the perfect solution but somehow with this tricks, my problem has fled away:

 MPVolumeView *volumeView = [[MPVolumeView alloc] initWithFrame: CGRectMake(0, -100, 0, 0)];
[self.view addSubview: volumeView];

I have implemented above code in viewWillAppear and problem resolved. With above code you can also customise your volume controller frame.

Upvotes: 2

Related Questions