Skip to content

Instantly share code, notes, and snippets.

@yanwei07
yanwei07 / AndroidBug5497Workaround.java
Created May 13, 2019 09:48 — forked from beilly/AndroidBug5497Workaround.java
WebView adjustResize windowSoftInputMode breaks when activity is fullscreen.Depent on https://github.com/madebycm/AndroidBug5497Workaround
package com.vcredit.utils;
import android.app.Activity;
import android.graphics.Rect;
import android.view.View;
import android.view.ViewTreeObserver;
import android.widget.FrameLayout;
/**
* Created by shibenli on 2016/8/31.
@yanwei07
yanwei07 / EachDirectoryPath.md
Created April 3, 2019 06:25 — forked from granoeste/EachDirectoryPath.md
[Android] How to get the each directory path.

System directories

Method Result
Environment.getDataDirectory() /data
Environment.getDownloadCacheDirectory() /cache
Environment.getRootDirectory() /system

External storage directories

@yanwei07
yanwei07 / build-boost-for-android.sh
Created July 17, 2018 10:09 — forked from enh/build-boost-for-android.sh
Shell script to build boost for Android
#!/bin/bash
version=1.67.0
echo "Building boost $version..."
set -eu
toolchain=$PWD/toolchain
if [ ! -d "$toolchain" ]; then
echo "Building toolchain..."
@yanwei07
yanwei07 / CustomVideoView.java
Created April 25, 2018 10:23 — forked from aaalaniz/CustomVideoView.java
VideoView that notifies of a frame rendered after requesting a reset
import android.content.Context;
import android.os.Handler;
import android.os.Looper;
import android.util.AttributeSet;
import com.twilio.video.I420Frame;
import com.twilio.video.VideoView;
/*
* VideoView that notifies Listener of the first frame rendered and the first frame after a reset
git config --global https.proxy http://127.0.0.1:1080
git config --global https.proxy https://127.0.0.1:1080
git config --global --unset http.proxy
git config --global --unset https.proxy
npm config delete proxy