code: def request_permissions(self, permissions):
          
          f = self.create_future()
  
          #: Old versions of android did permissions at install time
          if self.api_level < 23:
              f.set_result({p: True for p in permissions})
              return f
  
          w = self.widget
          request_code = self._permission_code
          self._permission_code += 1  #: So next call has a unique code
  
          #: On first request, setup our listener, and request the permission
          if request_code == 0:
              w.setPermissionResultListener(w.getId())
              w.onRequestPermissionsResult.connect(self._on_permission_result)
  
          def on_results(code, perms, results):
              #: Check permissions
              f.set_result({p: r == Activity.PERMISSION_GRANTED
                            for (p, r) in zip(perms, results)})
  
          #: Save a reference
          self._permission_requests[request_code] = on_results
  
          #: Send out the request
          self.widget.requestPermissions(permissions, request_code)
  
          return f
docs: Return a future that resolves with the results 
          of the permission requests