mirror of
https://github.com/Pinball3D/Rabbit-R1.git
synced 2025-01-09 13:43:22 +00:00
60 lines
5.1 KiB
Java
60 lines
5.1 KiB
Java
package androidx.compose.ui.text.input;
|
|
|
|
import io.sentry.cache.EnvelopeCache;
|
|
import java.util.List;
|
|
import java.util.concurrent.atomic.AtomicReference;
|
|
import kotlin.Deprecated;
|
|
import kotlin.Metadata;
|
|
import kotlin.ReplaceWith;
|
|
import kotlin.Unit;
|
|
import kotlin.jvm.functions.Function1;
|
|
import kotlin.jvm.internal.Intrinsics;
|
|
|
|
/* compiled from: TextInputService.kt */
|
|
@Metadata(d1 = {"\u0000L\n\u0002\u0018\u0002\n\u0002\u0010\u0000\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\b\u0004\n\u0002\u0010\u0002\n\u0002\b\u0003\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\u0010 \n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0003\b\u0017\u0018\u00002\u00020\u0001B\r\u0012\u0006\u0010\u0002\u001a\u00020\u0003¢\u0006\u0002\u0010\u0004J\b\u0010\f\u001a\u00020\rH\u0007J\b\u0010\u000e\u001a\u00020\rH\u0007JI\u0010\u000f\u001a\u00020\u00072\u0006\u0010\u0010\u001a\u00020\u00112\u0006\u0010\u0012\u001a\u00020\u00132\u0018\u0010\u0014\u001a\u0014\u0012\n\u0012\b\u0012\u0004\u0012\u00020\u00170\u0016\u0012\u0004\u0012\u00020\r0\u00152\u0012\u0010\u0018\u001a\u000e\u0012\u0004\u0012\u00020\u0019\u0012\u0004\u0012\u00020\r0\u0015H\u0016ø\u0001\u0000J\u0010\u0010\u001a\u001a\u00020\r2\u0006\u0010\u001b\u001a\u00020\u0007H\u0016R\"\u0010\u0005\u001a\u0016\u0012\u0006\u0012\u0004\u0018\u00010\u00070\u0006j\n\u0012\u0006\u0012\u0004\u0018\u00010\u0007`\bX\u0082\u0004¢\u0006\u0002\n\u0000R\u0016\u0010\t\u001a\u0004\u0018\u00010\u00078@X\u0080\u0004¢\u0006\u0006\u001a\u0004\b\n\u0010\u000bR\u000e\u0010\u0002\u001a\u00020\u0003X\u0082\u0004¢\u0006\u0002\n\u0000\u0082\u0002\u0004\n\u0002\b\u0019¨\u0006\u001c"}, d2 = {"Landroidx/compose/ui/text/input/TextInputService;", "", "platformTextInputService", "Landroidx/compose/ui/text/input/PlatformTextInputService;", "(Landroidx/compose/ui/text/input/PlatformTextInputService;)V", "_currentInputSession", "Ljava/util/concurrent/atomic/AtomicReference;", "Landroidx/compose/ui/text/input/TextInputSession;", "Landroidx/compose/ui/text/AtomicReference;", "currentInputSession", "getCurrentInputSession$ui_text_release", "()Landroidx/compose/ui/text/input/TextInputSession;", "hideSoftwareKeyboard", "", "showSoftwareKeyboard", "startInput", "value", "Landroidx/compose/ui/text/input/TextFieldValue;", "imeOptions", "Landroidx/compose/ui/text/input/ImeOptions;", "onEditCommand", "Lkotlin/Function1;", "", "Landroidx/compose/ui/text/input/EditCommand;", "onImeActionPerformed", "Landroidx/compose/ui/text/input/ImeAction;", "stopInput", EnvelopeCache.PREFIX_CURRENT_SESSION_FILE, "ui-text_release"}, k = 1, mv = {1, 8, 0}, xi = 48)
|
|
/* loaded from: classes.dex */
|
|
public class TextInputService {
|
|
public static final int $stable = 8;
|
|
private final AtomicReference<TextInputSession> _currentInputSession;
|
|
private final PlatformTextInputService platformTextInputService;
|
|
|
|
public TextInputService(PlatformTextInputService platformTextInputService) {
|
|
Intrinsics.checkNotNullParameter(platformTextInputService, "platformTextInputService");
|
|
this.platformTextInputService = platformTextInputService;
|
|
this._currentInputSession = new AtomicReference<>(null);
|
|
}
|
|
|
|
public final TextInputSession getCurrentInputSession$ui_text_release() {
|
|
return this._currentInputSession.get();
|
|
}
|
|
|
|
public TextInputSession startInput(TextFieldValue value, ImeOptions imeOptions, Function1<? super List<? extends EditCommand>, Unit> onEditCommand, Function1<? super ImeAction, Unit> onImeActionPerformed) {
|
|
Intrinsics.checkNotNullParameter(value, "value");
|
|
Intrinsics.checkNotNullParameter(imeOptions, "imeOptions");
|
|
Intrinsics.checkNotNullParameter(onEditCommand, "onEditCommand");
|
|
Intrinsics.checkNotNullParameter(onImeActionPerformed, "onImeActionPerformed");
|
|
this.platformTextInputService.startInput(value, imeOptions, onEditCommand, onImeActionPerformed);
|
|
TextInputSession textInputSession = new TextInputSession(this, this.platformTextInputService);
|
|
this._currentInputSession.set(textInputSession);
|
|
return textInputSession;
|
|
}
|
|
|
|
public void stopInput(TextInputSession session) {
|
|
Intrinsics.checkNotNullParameter(session, "session");
|
|
if (this._currentInputSession.compareAndSet(session, null)) {
|
|
this.platformTextInputService.stopInput();
|
|
}
|
|
}
|
|
|
|
@Deprecated(message = "Use SoftwareKeyboardController.show or TextInputSession.showSoftwareKeyboard instead.", replaceWith = @ReplaceWith(expression = "textInputSession.showSoftwareKeyboard()", imports = {}))
|
|
public final void showSoftwareKeyboard() {
|
|
if (this._currentInputSession.get() != null) {
|
|
this.platformTextInputService.showSoftwareKeyboard();
|
|
}
|
|
}
|
|
|
|
@Deprecated(message = "Use SoftwareKeyboardController.hide or TextInputSession.hideSoftwareKeyboard instead.", replaceWith = @ReplaceWith(expression = "textInputSession.hideSoftwareKeyboard()", imports = {}))
|
|
public final void hideSoftwareKeyboard() {
|
|
this.platformTextInputService.hideSoftwareKeyboard();
|
|
}
|
|
}
|