View bugzilla-search.md

Note: Bugzilla has a [somewhat esoteric][bugzilla-searchhelp] search syntax. To look for all open and closed WebExtension bugs that mentioned the history API, [try searching][bugzilla-searchhistory] for ALL Component:WebExtensions #history, which should turn up [Bug 1208334][]: "Implement history API for open extension API."

View AXWindow.swift
import Cocoa
class AXWindow {
let app: AXUIElement
let window: AXUIElement
init(app: AXUIElement, window: AXUIElement) {
self.app = app
self.window = window
View keycodeCaptor.js
/*jshint moz: true, undef: true, unused: true */
/*global ctypes, require, console, exports */
let { Cu } = require('chrome');
let { setTimeout } = require('sdk/timers');
Cu.import('resource://gre/modules/ctypes.jsm');
var objc = ctypes.open(ctypes.libraryName('objc'));
var is64bit = ctypes.voidptr_t.size == 4 ? false : true;
View lib.hs
{-# LANGUAGE ForeignFunctionInterface #-}
module Test where
import Foreign.C.Types
hsfun :: CInt -> IO CInt
hsfun x = do
putStrLn "Hello from haskell"
return (42 * x)
hsfoo :: CInt -> IO CInt
View HTML Printing API Proposal
/**
* @constructs Printer
*/
function Printer(){};
Printer.prototype = {};
/**
* Returns if printer is local or network
* @returns {boolean}
*/
Printer.prototype.isLocal = function(){return true;};
View _ff-addon-snippet-xhrPromise.js
// rev10 - https://gist.github.com/Noitidart/30e44f6d88423bf5096e
function xhrPromise(aUrlOrFileUri, aOptions={}) {
// does an async request
// aUrlOrFileUri is either a string of a FileURI such as `OS.Path.toFileURI(OS.Path.join(OS.Constants.Path.desktopDir, 'test.png'));` or a URL such as `http://github.com/wet-boew/wet-boew/archive/master.zip`
// :note: When using XMLHttpRequest to access a file:// URL the request.status is not properly set to 200 to indicate success. In such cases, request.readyState == 4, request.status == 0 and request.response will evaluate to true.
// Returns a promise
// resolves with xhr object
// rejects with object holding property "xhr" which holds the xhr object
var aOptionsDefaults = {
View gist:7803415810fb4c09c975
// JSM for working out which globalproperties can be imported in a specific Firefox version.
// https://developer.mozilla.org/en-US/docs/Components.utils.importGlobalProperties
// I'm not certain availability always equates to functionality but it probably does
// and in any case it's a way to narrow down the more involved test for functionality of each property
// Run from browser toolbox scratchpad like:
// Components.utils.import("resource://test-importGlobalProperties-addon/test.jsm");
Components.utils.import("resource://gre/modules/devtools/Console.jsm");
View gist:c710b97dd55f98f8f0e3
let myWorker = {
//
// Worker initialization
//
get worker() {
if (this._worker) {
return this._worker;
}
// Otherwise, initialize PromiseWorker.
// TODO
View _ff-addon-snippet-X11_XGetWindowProperty.js
Cu.import('resource://gre/modules/ctypes.jsm');
var nixtypesInit = function() {
// BASIC TYPES (ones that arent equal to something predefined by me)
this.ATOM = ctypes.unsigned_long;
this.BOOL = ctypes.int;
this.CHAR = ctypes.char;
this.GDKDRAWABLE = ctypes.StructType('GdkDrawable');
this.GDKWINDOW = ctypes.StructType('GdkWindow');
this.DATA = ctypes.voidptr_t;
View init.coffee
atom.commands.add 'atom-text-editor',
'editor:scroll-down': ->
editor = atom.workspace.getActiveTextEditor()
editorElement = atom.views.getView(editor)
newScrollTop = editorElement.getScrollTop() + editorElement.getHeight()
editorElement.setScrollTop(newScrollTop)
'editor:scroll-up': ->
editor = atom.workspace.getActiveTextEditor()
editorElement = atom.views.getView(editor)