<commit_before>package com.navigation.reactnative;

import android.content.Context;
import android.graphics.Rect;
import android.os.Build;
import android.util.DisplayMetrics;
import android.view.Surface;
import android.view.View;
import android.view.ViewGroup;
import android.view.ViewTreeObserver;
import android.view.WindowManager;

import androidx.coordinatorlayout.widget.CoordinatorLayout;
import androidx.fragment.app.Fragment;

import com.facebook.react.bridge.Arguments;
import com.facebook.react.bridge.ReactContext;
import com.facebook.react.bridge.WritableMap;
import com.facebook.react.modules.core.DeviceEventManagerModule;
import com.facebook.react.modules.deviceinfo.DeviceInfoModule;
import com.facebook.react.uimanager.DisplayMetricsHolder;
import com.facebook.react.uimanager.PixelUtil;
import com.facebook.react.uimanager.events.RCTEventEmitter;

import java.util.HashSet;

public class SceneView extends CoordinatorLayout implements NavigationBoundary {
    protected String sceneKey;
    protected String enterAnim;
    protected String exitAnim;
    public HashSet<View> sharedElements = new HashSet<>();
    public SharedElementTransitioner transitioner;
    private CustomGlobalLayoutListener customGlobalLayoutListener;
    Fragment fragment;

    public SceneView(Context context) {
        super(context);
    }

    @Override
    public void onAttachedToWindow() {
        super.onAttachedToWindow();
        if (fragment == null) {
            if (customGlobalLayoutListener == null)
                customGlobalLayoutListener = new CustomGlobalLayoutListener();
            getViewTreeObserver().addOnGlobalLayoutListener(customGlobalLayoutListener);
            View child = getChildAt(0);
            if (child != null && child.getClass().getSimpleName().contains("DrawerLayout")) {
                child.requestLayout();
                post(measureAndLayout);
            }
        }
    }

    @Override
    public void onDetachedFromWindow() {
        super.onDetachedFromWindow();
        if (fragment == null)<commit_msg>Set layout behavior of scrollview<commit_after>package com.navigation.reactnative;

import android.content.Context;
import android.graphics.Rect;
import android.os.Build;
import android.util.DisplayMetrics;
import android.view.Surface;
import android.view.View;
import android.view.ViewGroup;
import android.view.ViewTreeObserver;
import android.view.WindowManager;

import androidx.coordinatorlayout.widget.CoordinatorLayout;
import androidx.fragment.app.Fragment;

import com.facebook.react.bridge.Arguments;
import com.facebook.react.bridge.ReactContext;
import com.facebook.react.bridge.WritableMap;
import com.facebook.react.modules.core.DeviceEventManagerModule;
import com.facebook.react.modules.deviceinfo.DeviceInfoModule;
import com.facebook.react.uimanager.DisplayMetricsHolder;
import com.facebook.react.uimanager.PixelUtil;
import com.facebook.react.uimanager.events.RCTEventEmitter;
import com.google.android.material.appbar.AppBarLayout;

import java.util.HashSet;

public class SceneView extends CoordinatorLayout implements NavigationBoundary {
    protected String sceneKey;
    protected String enterAnim;
    protected String exitAnim;
    public HashSet<View> sharedElements = new HashSet<>();
    public SharedElementTransitioner transitioner;
    private CustomGlobalLayoutListener customGlobalLayoutListener;
    Fragment fragment;

    public SceneView(Context context) {
        super(context);
    }

    @Override
    public void onAttachedToWindow() {
        super.onAttachedToWindow();
        CoordinatorLayout.LayoutParams params = (CoordinatorLayout.LayoutParams) getChildAt(0).getLayoutParams();
        params.setBehavior(new AppBarLayout.ScrollingViewBehavior());
        getChildAt(0).requestLayout();
        if (fragment == null) {
            if (customGlobalLayoutListener == null)
                customGlobalLayoutListener = new CustomGlobalLayoutListener();
            getViewTreeObserver().addOnGlobalLayoutListener(customGlobalLayoutListener);
            View child = getChildAt(0);
            if (child != null && child.getClass().getSimpleName().contains("DrawerLayout")) {
                child.requestLayout();
                post(measureAndLayout);
            }
        }
    }

    @Override
    public void onDetachedFromWindow() {
        super.onDetachedFromWindow();
        if (fragment == null)
{'fraction_non_alphanumeric': 0.08829522300203758, 'fraction_numerical': 0.000905592030790129, 'mean_word_length': 4.031890660592255, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2774896', 'n_tokens_mistral': 1139, 'n_tokens_neox': 1121, 'n_words': 226}