Skip to content

Instantly share code, notes, and snippets.

View T8RIN's full-sized avatar
💻
Coding...

Malik Mukhametzyanov T8RIN

💻
Coding...
View GitHub Profile
/*
* Copyright 2025 Kyriakos Georgiopoulos
*
* 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
*
* Unless required by applicable law or agreed to in writing, software
@makeevrserg
makeevrserg / DeclarativeModalBottomSheet.kt
Created February 3, 2025 09:14
DeclarativeModalBottomSheet
import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.WindowInsets
import androidx.compose.foundation.layout.WindowInsetsSides
import androidx.compose.foundation.layout.asPaddingValues
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.height
import androidx.compose.foundation.layout.imePadding
@T8RIN
T8RIN / HashUtils.kt
Created December 30, 2024 21:55 — forked from LongClipeus/HashUtils.kt
How to generate checksum hash for a file in Kotlin
import StringUtils.encodeHex
import java.io.File
import java.io.FileInputStream
import java.io.InputStream
import java.security.MessageDigest
object HashUtils {
const val STREAM_BUFFER_LENGTH = 1024
@awxkee
awxkee / OpenGLESResizeRenderPass.kt
Last active November 30, 2024 15:24
Resing methods OpenGL
package com.android.example.rsmigration
import android.content.Context
import android.graphics.Bitmap
import android.opengl.EGL14
import android.opengl.EGL15
import android.opengl.EGLConfig
import android.opengl.EGLContext
import android.opengl.EGLDisplay
import android.opengl.EGLExt
// Usage
// PingPongSwitch(
// textFirst = "Ping",
// textSecond = "Pong"
// )
@Composable
fun PingPongSwitch(
state: PingPongSwitchState = rememberPingPongSwitchState(),
textFirst: String,
@aartikov
aartikov / App.kt
Created January 10, 2023 21:45
Decompose DI
class App : Application(), KoinProvider {
override lateinit var koin: Koin
private set
override fun onCreate() {
super.onCreate()
koin = createKoin()
}
@LongClipeus
LongClipeus / HashUtils.kt
Last active January 15, 2025 06:32
How to generate checksum hash for a file in Kotlin
import StringUtils.encodeHex
import java.io.File
import java.io.FileInputStream
import java.io.InputStream
import java.security.MessageDigest
object HashUtils {
const val STREAM_BUFFER_LENGTH = 1024
@fiftyonemoon
fiftyonemoon / AndroidXI
Created July 12, 2021 14:57
File create, rename, duplicate and delete in Android11.
import android.app.PendingIntent;
import android.app.RecoverableSecurityException;
import android.content.ContentResolver;
import android.content.ContentValues;
import android.content.Context;
import android.content.IntentSender;
import android.database.Cursor;
import android.net.Uri;
import android.os.Build;
import android.provider.MediaStore;
@artem78
artem78 / SymbianDev-en.md
Last active March 13, 2026 23:21
Developing for Symbian OS guide
public ArrayList<ImagesFolder> SearchStorage() {
folders.clear();
int position = 0;
Uri uri;
Cursor cursor;
int column_index_data, column_index_folder_name;
String absolutePathOfImage = null;
uri = MediaStore.Images.Media.EXTERNAL_CONTENT_URI;