Skip to content

Instantly share code, notes, and snippets.

+ (AccountManager *)sharedManager {
static AccountManager *sharedAccountManagerInstance = nil;
static dispatch_once_t predicate;
dispatch_once(&predicate, ^{
sharedAccountManagerInstance = [[self alloc] init];
});
return sharedAccountManagerInstance;
@pengwll
pengwll / toast.js
Last active December 23, 2015 03:59 — forked from kamranzafar/toast.js
var aftertoast = function()
{
//do something aftertoast
}
var toast=function(msg,fun){
$("<div class='ui-loader ui-overlay-shadow ui-body-e ui-corner-all'><h3>"+msg+"</h3></div>")
.css({ display: "block",
opacity: 0.90,
position: "fixed",
@pengwll
pengwll / demo.md
Last active December 23, 2015 01:29

web widget js demo

  • ###checkbox

判断checkbox是否被选中

	if($("#checkbox-v-a").is(':checked'))
	{
    	advice = $("#lb-v-a").text();

}

Sublime Text 2 – Useful Shortcuts (Mac OS X)

General

⌘T go to file
⌘⌃P go to project
⌘R go to methods
⌃G go to line
⌘KB toggle side bar
⌘⇧P command prompt
// While you can edit this file, it's best to put your changes in
// "User/Preferences.sublime-settings", which overrides the settings in here.
//
// Settings may also be placed in file type specific options files, for
// example, in Packages/Python/Python.sublime-settings for python files.
{
// Sets the colors used within the text area
// 主题文件的路径
"color_scheme": "Packages/Color Scheme - Default/Monokai.tmTheme",