1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
5 package org
.mozilla
.gecko
;
7 import android
.app
.Activity
;
9 public interface Driver
{
11 * Find the first Element using the given method.
13 * @param activity The activity the element belongs to
14 * @param id The resource id of the element
15 * @return The first matching element on the current context, or null if not found.
17 Element
findElement(Activity activity
, int id
);
20 * Sets up scroll handling so that data is received from the extension.
22 void setupScrollHandling();
25 int getScrollHeight();
32 void startFrameRecording();
33 int stopFrameRecording();
35 void startCheckerboardRecording();
36 float stopCheckerboardRecording();
39 * Get a copy of the painted content region.
40 * @return A 2-D array of pixels (indexed by y, then x). The pixels
41 * are in ARGB-8888 format.
43 PaintedSurface
getPaintedSurface();