mirror of
				https://github.com/recloudstream/cloudstream.git
				synced 2024-08-15 01:53:11 +00:00 
			
		
		
		
	crash fix for pip in android 12
This commit is contained in:
		
							parent
							
								
									8ca808ce37
								
							
						
					
					
						commit
						d5ae225070
					
				
					 1 changed files with 15 additions and 6 deletions
				
			
		|  | @ -871,12 +871,21 @@ class PlayerFragment : Fragment() { | |||
|     } | ||||
| 
 | ||||
|     private fun getPen(code: Int): PendingIntent { | ||||
|         return PendingIntent.getBroadcast( | ||||
|             activity, | ||||
|             code, | ||||
|             Intent("media_control").putExtra("control_type", code), | ||||
|             0 | ||||
|         ) | ||||
|         return if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) { | ||||
|             PendingIntent.getBroadcast( | ||||
|                 activity, | ||||
|                 code, | ||||
|                 Intent("media_control").putExtra("control_type", code), | ||||
|                 PendingIntent.FLAG_IMMUTABLE | ||||
|             ) | ||||
|         } else { | ||||
|             PendingIntent.getBroadcast( | ||||
|                 activity, | ||||
|                 code, | ||||
|                 Intent("media_control").putExtra("control_type", code), | ||||
|                 0 | ||||
|             ) | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     @SuppressLint("NewApi") | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue