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

Commit 6a956659 authored by Jeff Brown's avatar Jeff Brown Committed by Android (Google) Code Review
Browse files

Merge "Add method for sending wallpaper commands directly to an engine."

parents 647fc85a 9f3bdfe3
Loading
Loading
Loading
Loading
+12 −1
Original line number Diff line number Diff line
@@ -36065,6 +36065,17 @@
 visibility="public"
>
</field>
<field name="COMMAND_SECONDARY_TAP"
 type="java.lang.String"
 transient="false"
 volatile="false"
 value="&quot;android.wallpaper.secondaryTap&quot;"
 static="true"
 final="true"
 deprecated="not deprecated"
 visibility="public"
>
</field>
<field name="COMMAND_TAP"
 type="java.lang.String"
 transient="false"
@@ -250200,7 +250211,7 @@
 deprecated="not deprecated"
 visibility="public"
>
<parameter name="t" type="T">
<parameter name="arg0" type="T">
</parameter>
</method>
</interface>
+8 −0
Original line number Diff line number Diff line
@@ -71,6 +71,14 @@ public class WallpaperManager {
     */
    public static final String COMMAND_TAP = "android.wallpaper.tap";
    
    /**
     * Command for {@link #sendWallpaperCommand}: reported by the wallpaper
     * host when the user releases a secondary pointer on an empty area
     * (not performing an action in the host).  The x and y arguments are
     * the location of the secondary tap in screen coordinates.
     */
    public static final String COMMAND_SECONDARY_TAP = "android.wallpaper.secondaryTap";

    /**
     * Command for {@link #sendWallpaperCommand}: reported by the wallpaper
     * host when the user drops an object into an area of the host.  The x
+3 −0
Original line number Diff line number Diff line
@@ -17,6 +17,7 @@
package android.service.wallpaper;

import android.view.MotionEvent;
import android.os.Bundle;

/**
 * @hide
@@ -25,5 +26,7 @@ oneway interface IWallpaperEngine {
    void setDesiredSize(int width, int height);
    void setVisibility(boolean visible);
    void dispatchPointer(in MotionEvent event);
    void dispatchWallpaperCommand(String action, int x, int y,
            int z, in Bundle extras);
	void destroy();
}
+8 −1
Original line number Diff line number Diff line
@@ -858,6 +858,13 @@ public abstract class WallpaperService extends Service {
            }
        }

        public void dispatchWallpaperCommand(String action, int x, int y,
                int z, Bundle extras) {
            if (mEngine != null) {
                mEngine.mWindow.dispatchWallpaperCommand(action, x, y, z, extras, false);
            }
        }

        public void destroy() {
            Message msg = mCaller.obtainMessage(DO_DETACH);
            mCaller.sendMessage(msg);