Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
5cb1bda
feat: msdllib Android 16 QPR1
validcube Nov 16, 2025
6234d24
feat: animationlib Android 16 QPR1
validcube Nov 16, 2025
bc4dbec
feat: contextualeducation Android 16 QPR1
validcube Nov 16, 2025
cb3cfd4
feat: iconloaderlib Android 16 QPR1
validcube Nov 16, 2025
bb5f558
feat: searchuilib Android 16 QPR1
validcube Nov 16, 2025
c7ff98f
docs: Remove searchuilib from README.md
validcube Nov 16, 2025
2297e18
fix: Duplicated Iconloaderlib file
validcube Nov 16, 2025
f4395d4
feat: ViewCaptureLib
validcube Nov 16, 2025
17fb631
fix: Classes in iconloaderlib
validcube Nov 16, 2025
7a21c06
feat: Displaylib Android 16 QPR1
validcube Nov 16, 2025
8721978
feat: Displaylib Android 16 QPR1
validcube Nov 16, 2025
012c074
feat: Mechanics
validcube Nov 18, 2025
7db7f20
feat: Mechanics
validcube Nov 18, 2025
2eb34a4
Revert "feat: searchuilib Android 16 QPR1"
validcube Nov 20, 2025
f026dad
docs: Re-add searchuilib
validcube Nov 20, 2025
cba0e99
feat: Update searchuilib to Android U
validcube Nov 20, 2025
0910819
build: Just disable the disabled variant of compose
validcube Nov 20, 2025
3a70b29
feat: Update Submodule
validcube Nov 20, 2025
7bd36b3
fix: Checkout CompatTier2
validcube Nov 23, 2025
e5ae1ef
Merge branch '16-dev-qpr1' of https://github.com/BoringExperiments/pl…
validcube Nov 23, 2025
6d88bc8
feat: displaylib 16r4
validcube Dec 3, 2025
0377126
fix: displaylib tracing missing
validcube Dec 3, 2025
9780128
feat: viewcapturelib 16r4
validcube Dec 3, 2025
0389229
feat: mechanics 16r4
validcube Dec 3, 2025
e09314e
feat: iconloaderlib 16r4
validcube Dec 3, 2025
582b228
refactor: Remove test from mechanics entirely
validcube Dec 3, 2025
5b5456e
refactor: Remove tracing in displaylib
validcube Dec 3, 2025
2105c74
fix: Remove more tracing and correct usage in displaylib
validcube Dec 3, 2025
2475262
fix: Bring back protobuf in viewcapturelib
validcube Dec 3, 2025
4a903cc
fix: Duplicated file in Iconloaderlib (TODO)
validcube Dec 3, 2025
b97fefd
fix: A lot of stuff
validcube Dec 5, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ This repository contains multiple libraries in SystemUI used by Lawnchair.
A brief explanation of what each library does:
* `animationlib`: Handling playback and interpolator of the animations
* `contextualeducationlib`: Store "education" type
* `displaylib`: Handling presumably desktop displays
* `iconloaderlib`: Handling all of Launcher3 and Lawnchair icons
* `mechanics`: Complement the `animationlib`
* `msdllib`: Multi-Sensory-Design-Language, handling all new vibrations in Launcher3 Android 16
* `searchuilib`: Store search-related layout type
* See [AOSP Commit][searchuilib-url] instead because it's gone private after U
* `viewcapturelib`: Capture views... yep that's really that it

[searchuilib-url]: https://cs.android.com/android/_/android/platform/frameworks/libs/systemui/+/main:searchuilib/src/com/android/app/search/;drc=ace90b2ec32d3730141387c56e8abc761c380550;bpv=1;bpt=0
6 changes: 5 additions & 1 deletion animationlib/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,11 @@ android {
manifest.srcFile 'AndroidManifest.xml'
}
androidTest {
java.srcDirs = ["tests/src"]
java.srcDirs = ["tests/src", "tests/robolectric/src"]
manifest.srcFile 'tests/AndroidManifest.xml'
}
}

lintOptions {
abortOnError false
}
Expand All @@ -34,4 +35,7 @@ dependencies {
implementation libs.kotlin.stdlib.jdk7
implementation libs.androidx.core.animation
implementation libs.androidx.core.ktx
// androidTestImplementation libs.robolectric
// androidTestImplementation "androidx.test.ext:junit:1.1.3"
// androidTestImplementation "androidx.test:rules:1.4.0"
}
1 change: 0 additions & 1 deletion animationlib/src/com/android/app/animation/Animations.kt
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ package com.android.app.animation

import android.animation.Animator
import android.view.View
import com.android.app.animation.Animations.Companion.setOngoingAnimation

/** A static class for general animation-related utilities. */
class Animations {
Expand Down
46 changes: 23 additions & 23 deletions animationlib/src/com/android/app/animation/Interpolators.java
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,14 @@ public class Interpolators {
* is disappearing e.g. when moving off screen.
*/
public static final Interpolator EMPHASIZED_ACCELERATE = new PathInterpolator(
0.3f, 0f, 0.8f, 0.15f);
0.3f, 0f, 0.8f, 0.15f);

/**
* The decelerating emphasized interpolator. Used for hero / emphasized movement of content that
* is appearing e.g. when coming from off screen
*/
public static final Interpolator EMPHASIZED_DECELERATE = new PathInterpolator(
0.05f, 0.7f, 0.1f, 1f);
0.05f, 0.7f, 0.1f, 1f);


public static final Interpolator EXAGGERATED_EASE;
Expand Down Expand Up @@ -98,21 +98,21 @@ public class Interpolators {
* The standard interpolator that should be used on every normal animation
*/
public static final Interpolator STANDARD = new PathInterpolator(
0.2f, 0f, 0f, 1f);
0.2f, 0f, 0f, 1f);

/**
* The standard accelerating interpolator that should be used on every regular movement of
* content that is disappearing e.g. when moving off screen.
*/
public static final Interpolator STANDARD_ACCELERATE = new PathInterpolator(
0.3f, 0f, 1f, 1f);
0.3f, 0f, 1f, 1f);

/**
* The standard decelerating interpolator that should be used on every regular movement of
* content that is appearing e.g. when coming from off screen.
*/
public static final Interpolator STANDARD_DECELERATE = new PathInterpolator(
0f, 0f, 0f, 1f);
0f, 0f, 0f, 1f);

/*
* ============================================================================================
Expand Down Expand Up @@ -158,7 +158,7 @@ public class Interpolators {
* goes from 1 to 0 instead of 0 to 1).
*/
public static final Interpolator FAST_OUT_SLOW_IN_REVERSE =
new PathInterpolator(0.8f, 0f, 0.6f, 1f);
new PathInterpolator(0.8f, 0f, 0.6f, 1f);
public static final Interpolator SLOW_OUT_LINEAR_IN = new PathInterpolator(0.8f, 0f, 1f, 1f);
public static final Interpolator AGGRESSIVE_EASE = new PathInterpolator(0.2f, 0f, 0f, 1f);
public static final Interpolator AGGRESSIVE_EASE_IN_OUT = new PathInterpolator(0.6f,0, 0.4f, 1);
Expand All @@ -182,31 +182,31 @@ public class Interpolators {
public static final Interpolator CUSTOM_40_40 = new PathInterpolator(0.4f, 0f, 0.6f, 1f);
public static final Interpolator ICON_OVERSHOT = new PathInterpolator(0.4f, 0f, 0.2f, 1.4f);
public static final Interpolator ICON_OVERSHOT_LESS = new PathInterpolator(0.4f, 0f, 0.2f,
1.1f);
1.1f);
public static final Interpolator PANEL_CLOSE_ACCELERATED = new PathInterpolator(0.3f, 0, 0.5f,
1);
1);
public static final Interpolator BOUNCE = new BounceInterpolator();
/**
* For state transitions on the control panel that lives in GlobalActions.
*/
public static final Interpolator CONTROL_STATE = new PathInterpolator(0.4f, 0f, 0.2f,
1.0f);
1.0f);

/**
* Interpolator to be used when animating a move based on a click. Pair with enough duration.
*/
public static final Interpolator TOUCH_RESPONSE =
new PathInterpolator(0.3f, 0f, 0.1f, 1f);
new PathInterpolator(0.3f, 0f, 0.1f, 1f);

/**
* Like {@link #TOUCH_RESPONSE}, but used in case the animation is played in reverse (i.e. t
* goes from 1 to 0 instead of 0 to 1).
*/
public static final Interpolator TOUCH_RESPONSE_REVERSE =
new PathInterpolator(0.9f, 0f, 0.7f, 1f);
new PathInterpolator(0.9f, 0f, 0.7f, 1f);

public static final Interpolator TOUCH_RESPONSE_ACCEL_DEACCEL =
v -> ACCELERATE_DECELERATE.getInterpolation(TOUCH_RESPONSE.getInterpolation(v));
v -> ACCELERATE_DECELERATE.getInterpolation(TOUCH_RESPONSE.getInterpolation(v));


/**
Expand Down Expand Up @@ -236,7 +236,7 @@ public float getInterpolation(float v) {
*/
private float zInterpolate(float input) {
return (1.0f - FOCAL_LENGTH / (FOCAL_LENGTH + input)) /
(1.0f - FOCAL_LENGTH / (FOCAL_LENGTH + 1.0f));
(1.0f - FOCAL_LENGTH / (FOCAL_LENGTH + 1.0f));
}
};

Expand Down Expand Up @@ -297,13 +297,13 @@ public static Interpolator overshootInterpolatorForVelocity(float velocity) {
* @return the interpolated overshoot
*/
public static float getOvershootInterpolation(float progress, float overshootAmount,
float overshootStart) {
float overshootStart) {
if (overshootAmount == 0.0f || overshootStart == 0.0f) {
throw new IllegalArgumentException("Invalid values for overshoot");
}
float b = MathUtils.log((overshootAmount + 1) / (overshootAmount)) / overshootStart;
return MathUtils.max(0.0f,
(float) (1.0f - Math.exp(-b * progress)) * (overshootAmount + 1.0f));
(float) (1.0f - Math.exp(-b * progress)) * (overshootAmount + 1.0f));
}

/**
Expand Down Expand Up @@ -344,11 +344,11 @@ private static PathInterpolator createEmphasizedComplement() {
* 1 by upperBound.
*/
public static Interpolator clampToProgress(Interpolator interpolator, float lowerBound,
float upperBound) {
float upperBound) {
if (upperBound < lowerBound) {
throw new IllegalArgumentException(
String.format("upperBound (%f) must be greater than lowerBound (%f)",
upperBound, lowerBound));
String.format("upperBound (%f) must be greater than lowerBound (%f)",
upperBound, lowerBound));
}
return t -> clampToProgress(interpolator, t, lowerBound, upperBound);
}
Expand All @@ -361,11 +361,11 @@ public static Interpolator clampToProgress(Interpolator interpolator, float lowe
* interpolator.
*/
public static float clampToProgress(
Interpolator interpolator, float progress, float lowerBound, float upperBound) {
Interpolator interpolator, float progress, float lowerBound, float upperBound) {
if (upperBound < lowerBound) {
throw new IllegalArgumentException(
String.format("upperBound (%f) must be greater than lowerBound (%f)",
upperBound, lowerBound));
String.format("upperBound (%f) must be greater than lowerBound (%f)",
upperBound, lowerBound));
}

if (progress == lowerBound && progress == upperBound) {
Expand Down Expand Up @@ -398,7 +398,7 @@ private static float mapRange(float value, float min, float max) {
* such as to take over a user-controlled animation when they let go.
*/
public static Interpolator mapToProgress(Interpolator interpolator, float lowerBound,
float upperBound) {
float upperBound) {
return t -> mapRange(interpolator.getInterpolation(t), lowerBound, upperBound);
}

Expand All @@ -411,4 +411,4 @@ public static Interpolator mapToProgress(Interpolator interpolator, float lowerB
public static Interpolator reverse(Interpolator interpolator) {
return t -> 1 - interpolator.getInterpolation(1 - t);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,14 @@ public class InterpolatorsAndroidX {
* is disappearing e.g. when moving off screen.
*/
public static final Interpolator EMPHASIZED_ACCELERATE = new PathInterpolator(
0.3f, 0f, 0.8f, 0.15f);
0.3f, 0f, 0.8f, 0.15f);

/**
* The decelerating emphasized interpolator. Used for hero / emphasized movement of content that
* is appearing e.g. when coming from off screen
*/
public static final Interpolator EMPHASIZED_DECELERATE = new PathInterpolator(
0.05f, 0.7f, 0.1f, 1f);
0.05f, 0.7f, 0.1f, 1f);

public static final Interpolator EXAGGERATED_EASE;
static {
Expand Down Expand Up @@ -104,21 +104,21 @@ public class InterpolatorsAndroidX {
* The standard interpolator that should be used on every normal animation
*/
public static final Interpolator STANDARD = new PathInterpolator(
0.2f, 0f, 0f, 1f);
0.2f, 0f, 0f, 1f);

/**
* The standard accelerating interpolator that should be used on every regular movement of
* content that is disappearing e.g. when moving off screen.
*/
public static final Interpolator STANDARD_ACCELERATE = new PathInterpolator(
0.3f, 0f, 1f, 1f);
0.3f, 0f, 1f, 1f);

/**
* The standard decelerating interpolator that should be used on every regular movement of
* content that is appearing e.g. when coming from off screen.
*/
public static final Interpolator STANDARD_DECELERATE = new PathInterpolator(
0f, 0f, 0f, 1f);
0f, 0f, 0f, 1f);

/*
* ============================================================================================
Expand Down Expand Up @@ -164,7 +164,7 @@ public class InterpolatorsAndroidX {
* goes from 1 to 0 instead of 0 to 1).
*/
public static final Interpolator FAST_OUT_SLOW_IN_REVERSE =
new PathInterpolator(0.8f, 0f, 0.6f, 1f);
new PathInterpolator(0.8f, 0f, 0.6f, 1f);
public static final Interpolator SLOW_OUT_LINEAR_IN = new PathInterpolator(0.8f, 0f, 1f, 1f);
public static final Interpolator AGGRESSIVE_EASE = new PathInterpolator(0.2f, 0f, 0f, 1f);
public static final Interpolator AGGRESSIVE_EASE_IN_OUT = new PathInterpolator(0.6f,0, 0.4f, 1);
Expand All @@ -188,31 +188,31 @@ public class InterpolatorsAndroidX {
public static final Interpolator CUSTOM_40_40 = new PathInterpolator(0.4f, 0f, 0.6f, 1f);
public static final Interpolator ICON_OVERSHOT = new PathInterpolator(0.4f, 0f, 0.2f, 1.4f);
public static final Interpolator ICON_OVERSHOT_LESS = new PathInterpolator(0.4f, 0f, 0.2f,
1.1f);
1.1f);
public static final Interpolator PANEL_CLOSE_ACCELERATED = new PathInterpolator(0.3f, 0, 0.5f,
1);
1);
public static final Interpolator BOUNCE = new BounceInterpolator();
/**
* For state transitions on the control panel that lives in GlobalActions.
*/
public static final Interpolator CONTROL_STATE = new PathInterpolator(0.4f, 0f, 0.2f,
1.0f);
1.0f);

/**
* Interpolator to be used when animating a move based on a click. Pair with enough duration.
*/
public static final Interpolator TOUCH_RESPONSE =
new PathInterpolator(0.3f, 0f, 0.1f, 1f);
new PathInterpolator(0.3f, 0f, 0.1f, 1f);

/**
* Like {@link #TOUCH_RESPONSE}, but used in case the animation is played in reverse (i.e. t
* goes from 1 to 0 instead of 0 to 1).
*/
public static final Interpolator TOUCH_RESPONSE_REVERSE =
new PathInterpolator(0.9f, 0f, 0.7f, 1f);
new PathInterpolator(0.9f, 0f, 0.7f, 1f);

public static final Interpolator TOUCH_RESPONSE_ACCEL_DEACCEL =
v -> ACCELERATE_DECELERATE.getInterpolation(TOUCH_RESPONSE.getInterpolation(v));
v -> ACCELERATE_DECELERATE.getInterpolation(TOUCH_RESPONSE.getInterpolation(v));


/**
Expand Down Expand Up @@ -242,7 +242,7 @@ public float getInterpolation(float v) {
*/
private float zInterpolate(float input) {
return (1.0f - FOCAL_LENGTH / (FOCAL_LENGTH + input)) /
(1.0f - FOCAL_LENGTH / (FOCAL_LENGTH + 1.0f));
(1.0f - FOCAL_LENGTH / (FOCAL_LENGTH + 1.0f));
}
};

Expand Down Expand Up @@ -303,13 +303,13 @@ public static Interpolator overshootInterpolatorForVelocity(float velocity) {
* @return the interpolated overshoot
*/
public static float getOvershootInterpolation(float progress, float overshootAmount,
float overshootStart) {
float overshootStart) {
if (overshootAmount == 0.0f || overshootStart == 0.0f) {
throw new IllegalArgumentException("Invalid values for overshoot");
}
float b = MathUtils.log((overshootAmount + 1) / (overshootAmount)) / overshootStart;
return MathUtils.max(0.0f,
(float) (1.0f - Math.exp(-b * progress)) * (overshootAmount + 1.0f));
(float) (1.0f - Math.exp(-b * progress)) * (overshootAmount + 1.0f));
}

/**
Expand Down Expand Up @@ -350,11 +350,11 @@ private static PathInterpolator createEmphasizedComplement() {
* 1 by upperBound.
*/
public static Interpolator clampToProgress(Interpolator interpolator, float lowerBound,
float upperBound) {
float upperBound) {
if (upperBound < lowerBound) {
throw new IllegalArgumentException(
String.format("upperBound (%f) must be greater than lowerBound (%f)",
upperBound, lowerBound));
String.format("upperBound (%f) must be greater than lowerBound (%f)",
upperBound, lowerBound));
}
return t -> clampToProgress(interpolator, t, lowerBound, upperBound);
}
Expand All @@ -367,11 +367,11 @@ public static Interpolator clampToProgress(Interpolator interpolator, float lowe
* interpolator.
*/
public static float clampToProgress(
Interpolator interpolator, float progress, float lowerBound, float upperBound) {
Interpolator interpolator, float progress, float lowerBound, float upperBound) {
if (upperBound < lowerBound) {
throw new IllegalArgumentException(
String.format("upperBound (%f) must be greater than lowerBound (%f)",
upperBound, lowerBound));
String.format("upperBound (%f) must be greater than lowerBound (%f)",
upperBound, lowerBound));
}

if (progress == lowerBound && progress == upperBound) {
Expand Down Expand Up @@ -404,7 +404,7 @@ private static float mapRange(float value, float min, float max) {
* such as to take over a user-controlled animation when they let go.
*/
public static Interpolator mapToProgress(Interpolator interpolator, float lowerBound,
float upperBound) {
float upperBound) {
return t -> mapRange(interpolator.getInterpolation(t), lowerBound, upperBound);
}

Expand All @@ -417,4 +417,4 @@ public static Interpolator mapToProgress(Interpolator interpolator, float lowerB
public static Interpolator reverse(Interpolator interpolator) {
return t -> 1 - interpolator.getInterpolation(1 - t);
}
}
}
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
sdk=NEWEST_SDK
shadows=com.android.app.animation.robolectric.ShadowAnimationUtils2
Loading