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

Commit fbf2d5e7 authored by Stefan Andonian's avatar Stefan Andonian Committed by Android (Google) Code Review
Browse files

Merge "Add @WorkerThread Annotations to RPC calling methods in QsbContainerView." into udc-dev

parents 895392e9 7fcee916
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -38,6 +38,7 @@ import android.util.Log;
import android.util.Xml;

import androidx.annotation.Nullable;
import androidx.annotation.WorkerThread;

import com.android.launcher3.LauncherProvider.SqlArguments;
import com.android.launcher3.LauncherSettings.Favorites;
@@ -531,6 +532,7 @@ public class AutoInstallsLayout {
    protected class SearchWidgetParser extends PendingWidgetParser {
        @Override
        @Nullable
        @WorkerThread
        public ComponentName getComponentName(XmlPullParser parser) {
            return QsbContainerView.getSearchComponentName(mContext);
        }
+5 −0
Original line number Diff line number Diff line
@@ -40,6 +40,7 @@ import android.widget.FrameLayout;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.annotation.WorkerThread;

import com.android.launcher3.InvariantDeviceProfile;
import com.android.launcher3.LauncherAppState;
@@ -65,6 +66,7 @@ public class QsbContainerView extends FrameLayout {
     * @param context
     * @return String
     */
    @WorkerThread
    @Nullable
    public static String getSearchWidgetPackageName(@NonNull Context context) {
        String providerPkg = Settings.Global.getString(context.getContentResolver(),
@@ -84,6 +86,7 @@ public class QsbContainerView extends FrameLayout {
     * @param context
     * @return AppWidgetProviderInfo
     */
    @WorkerThread
    @Nullable
    public static AppWidgetProviderInfo getSearchWidgetProviderInfo(@NonNull Context context) {
        String providerPkg = getSearchWidgetPackageName(context);
@@ -110,6 +113,7 @@ public class QsbContainerView extends FrameLayout {
    /**
     * returns componentName for searchWidget if package name is known.
     */
    @WorkerThread
    @Nullable
    public static ComponentName getSearchComponentName(@NonNull  Context context) {
        AppWidgetProviderInfo providerInfo =
@@ -317,6 +321,7 @@ public class QsbContainerView extends FrameLayout {
         * If widgetCategory is not supported, or no such widget is found, returns the first widget
         * provided by the package.
         */
        @WorkerThread
        protected AppWidgetProviderInfo getSearchWidgetProvider() {
            return getSearchWidgetProviderInfo(getContext());
        }