Publish Vulpes Preview 15 sources for desktop, Android and Tundra

Share Gaia assets and adapters, keep private profiles and development documents local, and update both public READMEs.
This commit is contained in:
OverSu 2026-09-30 23:13:03 +02:00
commit b38dea0597
25901 changed files with 9982925 additions and 369 deletions

View file

@ -0,0 +1,32 @@
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1">
<meta charset="utf-8">
<title>Test Receiver</title>
<script src="js/inline-receiver.js" defer></script>
<style>
button {
font-size: 30px;
}
input {
font-size: 30px;
}
body {
background-color: #e0e0e0;
}
</style>
</head>
<body>
<h1>Inline Web Activities receiver</h1>
<p><button disabled id="button">Send "Hello Back!"</button></p>
<!-- add an input field to test keyboard work well -->
<p><input type="number" id="number" size="4" /></p>
<p><button disabled id="cancelButton">Cancel</button></p>
<p><button id="promptButton">Prompt</button></p>
<p><button id="go">Go</button></p>
<p>Result<span id="result"></span></p>
</body>
</html>

View file

@ -0,0 +1,93 @@
var activityRequest;
document.getElementById('go').onclick = function _go() {
var a = new MozActivity(
{
name: 'test',
data: {
type: 'inline'
}
}
);
a.onsuccess = function () {
document.getElementById('result').textContent = this.result.text;
};
a.onerror = function() {
document.getElementById('result').textContent = '(canceled)';
};
};
var webActivityHandler = function (request) {
activityRequest = request;
document.getElementById('button').disabled = '';
document.getElementById('cancelButton').disabled = '';
document.getElementById('number').focus();
};
window.onload = function () {
document.getElementById('button').onclick = go;
document.getElementById('cancelButton').onclick = cancel;
document.getElementById('promptButton').onclick = promptButton;
// If the app is being loaded because a inline disposition web activity,
// it will came with a pending system message.
if (!navigator.mozHasPendingMessage('activity')) {
console.warn('This application is not intend to launch directly.');
} else {
// Register for activity system message handling.
// Do NOT register for message handling on the main app frame.
}
navigator.mozSetMessageHandler('activity', webActivityHandler);
};
var go = function go() {
if (!activityRequest) {
alert('There are no any pending activity request.');
return;
}
// Return the request
activityRequest.postResult({
type: 'inline',
text: 'Hello back!'
});
activityRequest = null;
// close app, currently useless,
// see https://bugzilla.mozilla.org/show_bug.cgi?id=789392
window.close();
};
var cancel = function cancel() {
if (!activityRequest) {
alert('There are no any pending activity request.');
return;
}
activityRequest.postError('canceled');
activityRequest = null;
// close app, currently useless,
// see https://bugzilla.mozilla.org/show_bug.cgi?id=789392
window.close();
};
var promptButton = function promptButton() {
var a = prompt('inline-activty prompt!');
document.getElementById('result').textContent = a;
};
// When the app is being closed or killed, we will cancel the pending
// request.
document.addEventListener('visibilitychange', function visibility(e) {
if (!document.hidden || !activityRequest)
return;
activityRequest.postError('canceled');
activityRequest = null;
});

View file

@ -0,0 +1,25 @@
{
"name": "Test receiver (inline)",
"description": "Dummy app to respond to Test web activities",
"launch_path": "/index.html",
"developer": {
"name": "The Gaia Team",
"url": "https://github.com/mozilla-b2g/gaia"
},
"activities": {
"test": {
"filters": {
"type": "inline"
},
"disposition": "inline",
"returnValue": true
}
},
"icons": {
"84": "/style/icons/test-receiver_84.png",
"126": "/style/icons/test-receiver_126.png",
"142": "/style/icons/test-receiver_142.png",
"189": "/style/icons/test-receiver_189.png",
"284": "/style/icons/test-receiver_284.png"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB