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
import <Foundation/CPObject.j> | |
@implementation AppController : CPObject | |
{ | |
CPTextField label; | |
} | |
- (void)applicationDidFinishLaunching:(CPNotification)aNotification | |
{ |
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
import <Foundation/CPObject.j> | |
@implementation CalculatorLogic : CPObject | |
{ | |
CPNumber currentValue; | |
CPString acumulatedValue; | |
var decimalPointActive; | |
//1 * 0.1 * 0.1 in Js = 0.010000000000000002 :) Strings never fails!!! | |
id changeValueNotifyDelegate; | |
} |
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
import <Foundation/CPObject.j> | |
import "CalculatorLogic.j" | |
@implementation CalculatorButton : CPButton | |
{ | |
} | |
+(id)newCalculatorButton:(CPText)buttonText target:(id)aTarget selector:(SEL)aSelector rect:(CGRect)aFrame | |
{ |
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
@implementation DTTextField : CPTextField | |
{ | |
} | |
+ (DOMElement)_inputElement | |
{ | |
var CPTextFieldDOMInputElement = nil; | |
if (!CPTextFieldDOMInputElement) | |
{ |
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
var CPTextFieldDOMInputElement = nil; | |
@implementation DTTextField : CPTextField | |
{ | |
} | |
+ (DOMElement)_inputElement | |
{ | |
if (!CPTextFieldDOMInputElement) | |
{ |
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
@import <Foundation/CPObject.j> | |
@import "AppInspector.j" | |
@implementation AppController : CPObject | |
{ | |
CPImageView imageView; | |
AppInspector inspector; | |
} | |
- (void)applicationDidFinishLaunching:(CPNotification)aNotification |
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
/* -*- coding: utf-8 -*- | |
* | |
* Starrater with a revised version from boucher from 280North | |
*/ | |
@import <AppKit/CPControl.j> | |
@import <AppKit/CPImage.j> | |
var starEmpty = [[CPImage alloc] initWithContentsOfFile: "Resources/StarRater/empty.gif" size: CPSizeMake(25, 25)], | |
starSet = [[CPImage alloc] initWithContentsOfFile: "Resources/StarRater/set.gif" size: CPSizeMake(25, 25)], |
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
function functionname(var1,var2) | |
{ | |
var var3; | |
if (var1 === var2) | |
{ | |
var3 = true; | |
} | |
else | |
{ | |
var3 = false; |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta http-equiv="Content-type" content="text/html; charset=utf-8" /> | |
<title>Stripe Sample Form</title> | |
<script type="text/javascript" src="/jquery.min.js"></script> | |
<script type="text/javascript" src="/jquery.validate.js"></script> | |
<script type="text/javascript" src="https://js.stripe.com/v1/"></script> | |
<script type="text/javascript"> |
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
<?php | |
require 'lib/Stripe.php'; | |
if ($_POST) { | |
Stripe::setApiKey("kLh5gUyytoTLN8YtyBI7dLovXhZmDkcb"); | |
$customer = Stripe_Customer::create(array("email" => $_POST['email'], | |
"description" => $_POST['description'], | |
"card" => $_POST['stripeToken'])); | |
Stripe_Charge::create(array("amount" => 1199, |
OlderNewer