hunk.code_window: import android.app.Activity;
   import android.content.Context;
   import android.content.Intent;
   import android.net.Uri;
   import android.os.Bundle;
   import androidx.core.content.FileProvider;
  
hunk.labels: keep keep keep add keep keep keep keep
hunk.after_edit: import android.content.pm.PackageManager;
   import android.content.pm.ResolveInfo;
  
hunk.file_path: android/versioned-abis/expoview-abi39_0_0/src/main/java/abi39_0_0/expo/modules/sharing/SharingModule.java
hunk.type: add
file: package abi39_0_0.host.exp.exponent.modules.api.components.gesturehandler.react;
  
  import androidx.core.util.Pools;
  
  import abi39_0_0.com.facebook.react.bridge.Arguments;
  import abi39_0_0.com.facebook.react.bridge.WritableMap;
  import abi39_0_0.com.facebook.react.uimanager.events.Event;
  import abi39_0_0.com.facebook.react.uimanager.events.RCTEventEmitter;
  import abi39_0_0.host.exp.exponent.modules.api.components.gesturehandler.GestureHandler;
  
  import androidx.annotation.Nullable;
  
  public class RNGestureHandlerStateChangeEvent extends Event<RNGestureHandlerStateChangeEvent>{
  
    public static final String EVENT_NAME = "onGestureHandlerStateChange";
  
    private static final int TOUCH_EVENTS_POOL_SIZE = 7; // magic
  
    private static final Pools.SynchronizedPool<RNGestureHandlerStateChangeEvent> EVENTS_POOL =
            new Pools.SynchronizedPool<>(TOUCH_EVENTS_POOL_SIZE);
  
    public static RNGestureHandlerStateChangeEvent obtain(
            GestureHandler handler,
            int newState,
            int oldState,
            @Nullable RNGestureHandlerEventDataExtractor dataExtractor) {
      RNGestureHandlerStateChangeEvent event = EVENTS_POOL.acquire();
      if (event == null) {
        event = new RNGestureHandlerStateChangeEvent();
      }
      event.init(handler, newState, oldState, dataExtractor);
      return event;
    }
  
    private WritableMap mExtraData;
  
    private RNGestureHandlerStateChangeEvent() {
    }
  
    private void init(
            GestureHandler handler,
            int newState,
            int oldState,
            @Nullable RNGestureHandlerEventDataExtractor dataExtractor) {
      super.init(handler.getView().getId());
      mExtraData = Arguments.createMap();
      if (dataExtractor != null) {
        dataExtractor.extractEventData(handler, mExtraData);
      }
      mExtraData.putInt("handlerTag", handler.getTag());
      mExtraData.putInt("state", newState);
      mExtraData.putInt("oldState", oldState);
    }
  
    @Override
    public void onDispose() {
      mExtraData = null;
      EVENTS_POOL.release(this);
    }
  
    @Override
    public String getEventName() {
      return EVENT_NAME;
    }
  
    @Override
    public boolean canCoalesce() {
      // TODO: coalescing
      return false;
    }
  
    @Override
    public short getCoalescingKey() {
      // TODO: coalescing
      return 0;
    }
  
    @Override
    public void dispatch(RCTEventEmitter rctEventEmitter) {
      rctEventEmitter.receiveEvent(getViewTag(), EVENT_NAME, mExtraData);
    }
  }
  