This file contains 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
var SharedController; | |
@implementation MyController : CPObject | |
{ | |
} | |
+ (MyController)sharedController | |
{ | |
if (!SharedController) |
This file contains 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
@import <Foundation/CPObject.j> | |
@import "../Models/MenuItem.j" | |
@import "../Views/AccountsWindow.j" | |
@implementation MainMenuController : CPObject | |
{ | |
CPView _mainView; | |
CPString _username; | |
MenuItem mainMenu @accessors; |
This file contains 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
function dateFromRailsAPI(aString){ | |
if (!aString) | |
return; | |
var regexp = /(\d\d\d\d)(-)?(\d\d)(-)?(\d\d)(T)?(\d\d)(:)?(\d\d)(:)?(\d\d)(\.\d+)?(Z|([+-])(\d\d)(:)?(\d\d))/, | |
matches = aString.match(new RegExp(regexp)), | |
offset = 0, | |
date = new Date(); | |
if (matches) |
This file contains 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
diff --git a/AppKit/CPArrayController.j b/AppKit/CPArrayController.j | |
index 5fefb58..729b937 100644 | |
--- a/AppKit/CPArrayController.j | |
+++ b/AppKit/CPArrayController.j | |
@@ -334,8 +334,12 @@ | |
- (CPArray)selectedObjects | |
{ | |
var objects = [[self arrangedObjects] objectsAtIndexes:[self selectionIndexes]]; | |
+ if (objects) | |
+ objects = [_CPObservableArray arrayWithArray:objects]; |
This file contains 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
var SharedController; | |
@implementation MyWindowController : CPWindowController | |
{ | |
} | |
+ (id)sharedController | |
{ | |
if (!SharedController) | |
SharedController = [[self alloc] init]; |
This file contains 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
/* | |
* Jakefile | |
* Shopify - com.shopify.Text.plugin | |
* | |
* Created by Nicholas Small on January 31, 2010. | |
* Copyright 2010, JadedPixel, Inc. All rights reserved. | |
*/ | |
var ENV = require("system").env, | |
FILE = require("file"), |
This file contains 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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>CPBundleIdentifier</key> | |
<string>com.shopify.Text.plugin</string> | |
<key>CPBundleInfoDictionaryVersion</key> | |
<string>6.0</string> | |
<key>CPBundleName</key> | |
<string>Text.plugin</string> |
This file contains 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
/* | |
* CPUserDefaults.j | |
* AppKit | |
* | |
* Created by Nicholas Small. | |
* Copyright 2009, 280 North, Inc. | |
* | |
* This library is free software; you can redistribute it and/or | |
* modify it under the terms of the GNU Lesser General Public | |
* License as published by the Free Software Foundation; either |