This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defprotocol ReactorStateRef | |
(restore-state! [this] | |
"Restore the referenced state to the most recent snapshot if available | |
or to the initial state. Update the version to reflect the new state.") | |
(reset-state! [this] | |
"Reset the referenced state to the initial state. Update the version to 0.") | |
(apply-event! [this event version] | |
"Apply the supplied event to the referenced state and update the version. | |
Nil events are considered to be no-op and only update the version. If the | |
version is nil, apply the event but do not update the version.") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; Define a keymap for mark object commands | |
(define-prefix-command 'mark-object-map) | |
(global-set-key (kbd "C-x m") 'mark-object-map) | |
(define-key mark-object-map (kbd "(") 'er/mark-inside-pairs) | |
(define-key mark-object-map (kbd ")") 'er/mark-outside-pairs) | |
(define-key mark-object-map (kbd "\"") 'er/mark-inside-quotes) | |
(define-key mark-object-map (kbd "'") 'er/mark-outside-quotes) | |
(define-key mark-object-map (kbd "w") 'er/mark-word) | |
(define-key mark-object-map (kbd "u") 'er/mark-url) | |
(define-key mark-object-map (kbd "e") 'er/mark-email) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$("tr").each(function() { | |
var container = $(this); | |
var add_button = container.find("a.add"); | |
var field_container = container.find("td.fields"); | |
add_button.click(function() { | |
var new_elt = $("<div>...</div>"); | |
field_container.append(new_elt); | |
}) | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
property theURL : "" | |
set clipSave to the clipboard | |
tell application "Reeder" | |
activate | |
end tell | |
tell application "System Events" | |
keystroke "c" using {shift down, command down} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tell application "Address Book" to activate | |
tell application "System Events" | |
keystroke "f" using command down | |
keystroke "search text" | |
end tell |