Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e36c1ed3 authored by Frank Preel's avatar Frank Preel
Browse files

Revert "Fix background"

This reverts commit 8798afac.
parent 0c485fd5
Loading
Loading
Loading
Loading
+8 −14
Original line number Original line Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android" xmlns:aapt="http://schemas.android.com/aapt"
<!--
    android:viewportWidth="22.97"
    SPDX-FileCopyrightText: Material Design Authors / Google LLC
    android:viewportHeight="31.17"
    SPDX-License-Identifier: Apache-2.0
    android:width="22.97dp"
-->
    android:height="31.17dp">
<vector xmlns:android="http://schemas.android.com/apk/res/android"
    android:height="24dp"
    android:width="24dp"
    android:viewportWidth="24"
    android:viewportHeight="24">

    <path
    <path
        android:fillColor="?android:attr/colorControlNormal"
        android:pathData="M11.48 19.69c2.72 0 4.91 -2.2 4.91 -4.92l0.02 -9.84c0 -2.72 -2.2 -4.92 -4.92 -4.92s-4.92 2.2 -4.92 4.92v9.84c0 2.72 2.2 4.92 4.92 4.92ZM20.18 14.77c0 4.92 -4.17 8.37 -8.7 8.37S2.79 19.69 2.79 14.77H0c0 5.59 4.46 10.22 9.84 11.03v5.38h3.28v-5.38c5.38 -0.79 9.84 -5.41 9.84 -11.03h-2.79Z"
        android:pathData="M17,13H13V17H11V13H7V11H11V7H13V11H17M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z" />
        android:fillColor="#DEADB5B9" />
</vector>
</vector>
 No newline at end of file
+13 −19
Original line number Original line Diff line number Diff line
@@ -25,7 +25,7 @@
    android:layout_gravity="bottom">
    android:layout_gravity="bottom">


    <LinearLayout
    <LinearLayout
        android:layout_width="wrap_content"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_height="wrap_content"
        android:layout_gravity="bottom"
        android:layout_gravity="bottom"
        android:orientation="vertical">
        android:orientation="vertical">
@@ -49,23 +49,17 @@
            android:layout_height="wrap_content" />
            android:layout_height="wrap_content" />
    </LinearLayout>
    </LinearLayout>


    <FrameLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent">

    <ImageButton
    <ImageButton
        android:id="@+id/floating_button"
        android:id="@+id/floating_button"
        android:layout_width="48dp"
        android:layout_width="48dp"
        android:layout_height="48dp"
        android:layout_height="48dp"
            android:layout_gravity="end|bottom"
        android:layout_gravity="top|end"
            android:layout_marginEnd="16dp"
        android:layout_marginTop="-4dp"
            android:layout_marginBottom="16dp"
        android:layout_marginEnd="4dp"
        android:background="@android:color/transparent"
        android:background="@android:color/transparent"
        android:src="@drawable/ic_ime_switch"
        android:src="@drawable/ic_ime_switch"
        android:contentDescription="@string/ime_switch_button"
        android:contentDescription="@string/ime_switch_button"
        android:focusable="true"
        android:focusable="true"
            android:focusableInTouchMode="true" />
        android:clickable="true" />

    </FrameLayout>


</FrameLayout>
</FrameLayout>
+27 −7
Original line number Original line Diff line number Diff line
@@ -106,6 +106,8 @@ import com.android.inputmethod.latin.utils.StatsUtilsManager;
import com.android.inputmethod.latin.utils.SubtypeLocaleUtils;
import com.android.inputmethod.latin.utils.SubtypeLocaleUtils;
import com.android.inputmethod.latin.utils.ViewLayoutUtils;
import com.android.inputmethod.latin.utils.ViewLayoutUtils;


import android.content.ContentResolver;

import java.io.FileDescriptor;
import java.io.FileDescriptor;
import java.io.PrintWriter;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.ArrayList;
@@ -872,6 +874,8 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen


        ImageButton floatingButton = view.findViewById(R.id.floating_button);
        ImageButton floatingButton = view.findViewById(R.id.floating_button);
        if (floatingButton != null) {
        if (floatingButton != null) {
            if (isSetupWizardFinished()) {
                floatingButton.setVisibility(View.VISIBLE);
                floatingButton.setOnClickListener(new View.OnClickListener() {
                floatingButton.setOnClickListener(new View.OnClickListener() {
                    @Override
                    @Override
                    public void onClick(View v) {
                    public void onClick(View v) {
@@ -879,9 +883,25 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
                        //launchSettings(SettingsActivity.EXTRA_ENTRY_VALUE_LONG_PRESS_COMMA);
                        //launchSettings(SettingsActivity.EXTRA_ENTRY_VALUE_LONG_PRESS_COMMA);
                    }
                    }
                });
                });
            } else {
                floatingButton.setVisibility(View.GONE);
            }
        }
        }
    }
    }


    private boolean isSetupWizardFinished() {
        Log.d(TAG, "isSetupWizardFinished");
        ContentResolver contentResolver = mDisplayContext.getContentResolver();
        Log.d(TAG, "isSetupWizardFinished 2");
        boolean isDeviceProvisioned = android.provider.Settings.Global.getInt(contentResolver,
            android.provider.Settings.Global.DEVICE_PROVISIONED, 0) == 1;
        //boolean isUserSetupComplete = android.provider.Settings.Secure.getInt(contentResolver,
        //    android.provider.Settings.Secure.USER_SETUP_COMPLETE, 0) == 1;
        Log.d(TAG, "isSetupWizardFinished " + isDeviceProvisioned );

        return isDeviceProvisioned;// && isUserSetupComplete;
    }

    @Override
    @Override
    public void setCandidatesView(final View view) {
    public void setCandidatesView(final View view) {
        // To ensure that CandidatesView will never be set.
        // To ensure that CandidatesView will never be set.