Skip to content

Instantly share code, notes, and snippets.

View AnirudhaS's full-sized avatar

Anirudha Shingote AnirudhaS

View GitHub Profile
@AnirudhaS
AnirudhaS / remove_crashed_sessions.js
Created November 25, 2024 23:44 — forked from dcower/remove_crashed_sessions.js
Remove crashed sessions in Tabs Outliner
function search_and_remove() {
// Search for crashed windows and tabs. Reverse the list so that we delete
// from the bottom, which is MUCH faster.
elements = Array.from(document.querySelectorAll('li.savedwinNTASC,li.savedtabNTASC')).reverse();
if (elements.length == 0) {
console.log("Finished removing stale windows and tabs.");
return;
}
@AnirudhaS
AnirudhaS / generic_example.go
Created October 7, 2017 23:49
Basic example to demonstrate implementation of Generics in Go using interfaces.
package main
import (
"fmt"
"sort"
)
type Person struct {
Name string
Age int
public class YesNoDialog extends DialogFragment {
String message;
String title;
String yesText;
String noText;
/* The activity that creates an instance of this dialog fragment must
* implement this interface in order to receive event callbacks.
* Each method passes the DialogFragment in case the host needs to query it. */
public interface YesNoListener {