Skip to content

Instantly share code, notes, and snippets.

View dylech30th's full-sized avatar
🥲
Mais il me reste, ce que vous ne voyez pas.

Dylech30th dylech30th

🥲
Mais il me reste, ce que vous ne voyez pas.
View GitHub Profile
@atifaziz
atifaziz / TaskWhenAll.cs
Last active May 29, 2021 14:12
Implementation of Task.WhenAll in C# and F#
// http://msdn.microsoft.com/en-us/library/system.threading.tasks.task.whenall.aspx
using System;
using System.Threading;
using System.Threading.Tasks;
static class TaskExtensions
{
public static Task<T[]> WhenAll<T>(this Task<T>[] tasks)
{
using System;
using System.Runtime.InteropServices;
using System.Windows;
using System.Windows.Interop;
using Walterlv.Demo.Interop.Native;
namespace Walterlv.Demo.Interop
{
public class WindowBlur
{
@zach-klippenstein
zach-klippenstein / SegmentedControl.kt
Last active June 24, 2024 01:54
iOS-style segmented control in Compose
import android.annotation.SuppressLint
import androidx.compose.animation.core.animateDpAsState
import androidx.compose.animation.core.animateFloatAsState
import androidx.compose.foundation.Canvas
import androidx.compose.foundation.background
import androidx.compose.foundation.gestures.awaitFirstDown
import androidx.compose.foundation.gestures.forEachGesture
import androidx.compose.foundation.gestures.horizontalDrag
import androidx.compose.foundation.layout.Arrangement.spacedBy
import androidx.compose.foundation.layout.Box