Skip to content

Instantly share code, notes, and snippets.

@jonmcclung
jonmcclung / Toast.qml
Last active July 19, 2024 14:10
Toast in QML. This implementation creates black toast with white text that appears at the bottom of the screen. It also supports adding multiple toast at a time using ToastManager with the newest toast at the bottom.
import QtQuick 2.0
/**
* adapted from StackOverflow:
* http://stackoverflow.com/questions/26879266/make-toast-in-android-by-qml
*/
/**
* @brief An Android-like timed message text in a box that self-destroys when finished if desired
*/
@lifeinafolder
lifeinafolder / radio-button-group.js
Last active December 23, 2015 20:09
Ember wrapper for radio button group
UiControls = window.UiControls || Ember.Namespace.create();
/**
* An Ember RadioButton Group Control
*
* @example
* {{#view UiControls.RadioButtonGroup group="segment-option" valueBinding="sendingPreference"}}
* {{view UiControls.RadioButton title="Title 1" value="1"}}
* {{view UiControls.RadioButton title="Title 2" value="2"}}
* {{/view}}
@lifeinafolder
lifeinafolder / chosen-multi-select.js
Created September 24, 2013 16:19
An Ember wrapper for chosen multi-select
//= require chosen-jquery
UiControls = window.UiControls || Ember.Namespace.create();
/**
* Custom Multi-Select enabled with 'chosen'
* @class
* @memberOf UiControls
* @extends Ember.Select
*
@lifeinafolder
lifeinafolder / onoff-switch.js
Created September 24, 2013 16:17
An ember wrapper for the bootstrap-switch module.
//= require bootstrap-switch
UiControls = window.UiControls || Ember.Namespace.create();
/**
* Custom iPhone style ON-OFF switch control
*
* @class
* @memberOf UiControls
* @extends Ember.View
@brandonb927
brandonb927 / osx-for-hackers.sh
Last active November 11, 2025 10:27
OSX for Hackers: Yosemite/El Capitan Edition. This script tries not to be *too* opinionated and any major changes to your system require a prompt. You've been warned.
#!/bin/sh
###
# SOME COMMANDS WILL NOT WORK ON macOS (Sierra or newer)
# For Sierra or newer, see https://github.com/mathiasbynens/dotfiles/blob/master/.macos
###
# Alot of these configs have been taken from the various places
# on the web, most from here
# https://github.com/mathiasbynens/dotfiles/blob/5b3c8418ed42d93af2e647dc9d122f25cc034871/.osx