Skip to content

Instantly share code, notes, and snippets.

View nikunjparadva's full-sized avatar
🤓
Building Gradle

Nikunj paradva nikunjparadva

🤓
Building Gradle
View GitHub Profile
@micer
micer / NestedScrollableHost
Created August 24, 2020 11:24
Fixes issue with nested scrolling elements with the same scroll direction inside ViewPager2. https://issuetracker.google.com/issues/123006042
package com.betvictor.casino.presentation.views
/*
* Copyright 2019 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
@ArsalRaza
ArsalRaza / VideoUtils.java
Last active January 25, 2024 11:39
Extract Audio from Video, Mute Video, Crop Video from start, Crop Video from end Android MediaMuxer - JAVA
import android.annotation.SuppressLint;
import android.media.MediaCodec;
import android.media.MediaExtractor;
import android.media.MediaFormat;
import android.media.MediaMetadataRetriever;
import android.media.MediaMuxer;
import android.util.Log;
import java.io.IOException;
import java.nio.ByteBuffer;
@saiaspire
saiaspire / RadioGridGroup.java
Last active March 24, 2024 10:33
A Radio Group that has GridLayout as its parent. This allows for more complex layouts of RadioButton (use AppCompatRadioButton). For example, when you need multiple rows of Radio Buttons.
import android.content.Context;
import android.support.annotation.NonNull;
import android.support.v7.widget.AppCompatRadioButton;
import android.support.v7.widget.GridLayout;
import android.util.AttributeSet;
import android.view.View;
import android.view.ViewGroup;
import android.view.accessibility.AccessibilityEvent;
import android.view.accessibility.AccessibilityNodeInfo;
import android.widget.CompoundButton;
@PurpleBooth
PurpleBooth / README-Template.md
Last active May 1, 2024 17:49
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@protrolium
protrolium / ffmpeg.md
Last active May 2, 2024 12:02
ffmpeg guide

ffmpeg

Converting Audio into Different Formats / Sample Rates

Minimal example: transcode from MP3 to WMA:
ffmpeg -i input.mp3 output.wma

You can get the list of supported formats with:
ffmpeg -formats

You can get the list of installed codecs with:

@granoeste
granoeste / EachDirectoryPath.md
Last active April 4, 2024 22:32
[Android] How to get the each directory path.

System directories

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

External storage directories