我正在使用可变的“音量”
@property BOOL * volume;
设置音量开 (YES) 或关 (NO)
- (IBAction)manageVolume:(UIButton *)sender {
if (_volume == TRUE) {
_volume = !_volume;
// code...
} else {
_volume = !_volume;
// code...
}
}
它有效,但它返回三个警报:
if (_volume == TRUE) {
返回Comparison between pointer and integer ('BOOL *' (aka 'signed char *') and 'int')
_volume = !_volume;
返回Incompatible integer to pointer conversion assigning to 'BOOL *' (aka 'signed char *') from 'int'
我该如何解决?谢谢!