Bug 728614 - Part 0: Allow querying the viewport information from Java; r=dougt

This commit is contained in:
Brad Lassey
2012-02-18 19:22:56 -05:00
parent f5fd405a30
commit 2b2152d3a4
5 changed files with 87 additions and 1 deletions

View File

@@ -546,6 +546,8 @@ public:
nsGeoPositionAddress* GeoAddress() { return mGeoAddress; }
double Bandwidth() { return mBandwidth; }
bool CanBeMetered() { return mCanBeMetered; }
int TabId() { return mTabId; }
void DoCallback(const nsAString& data);
protected:
int mAction;
@@ -571,6 +573,7 @@ protected:
nsRefPtr<nsGeoPositionAddress> mGeoAddress;
double mBandwidth;
bool mCanBeMetered;
int mTabId;
void ReadIntArray(nsTArray<int> &aVals,
JNIEnv *jenv,
@@ -625,6 +628,9 @@ protected:
static jfieldID jBandwidthField;
static jfieldID jCanBeMeteredField;
static jfieldID jTabIdField;
static jmethodID jDoCallbackMethod;
public:
enum {
@@ -653,6 +659,7 @@ public:
PROXIMITY_EVENT = 23,
ACTIVITY_RESUMING = 24,
SCREENSHOT = 25,
META_VIEWPORT_QUERY = 26,
dummy_java_enum_list_end
};