From b89a7ee8b956c96a1dcee995ea840feddc5d4b27 Mon Sep 17 00:00:00 2001 From: Pierre Frisch Date: Thu, 22 Dec 2011 07:25:50 -0800 Subject: First commit of Ninja to ninja-internal Signed-off-by: Valerio Virgillito --- .../ui/radio-button.reel/radio-button.html | 32 ++++++++++++++++ js/components/ui/radio-button.reel/radio-button.js | 44 ++++++++++++++++++++++ 2 files changed, 76 insertions(+) create mode 100644 js/components/ui/radio-button.reel/radio-button.html create mode 100644 js/components/ui/radio-button.reel/radio-button.js (limited to 'js/components/ui/radio-button.reel') diff --git a/js/components/ui/radio-button.reel/radio-button.html b/js/components/ui/radio-button.reel/radio-button.html new file mode 100644 index 00000000..265501f4 --- /dev/null +++ b/js/components/ui/radio-button.reel/radio-button.html @@ -0,0 +1,32 @@ + + + + + + + + + + + + + +
+
+
+ + + diff --git a/js/components/ui/radio-button.reel/radio-button.js b/js/components/ui/radio-button.reel/radio-button.js new file mode 100644 index 00000000..a356fefe --- /dev/null +++ b/js/components/ui/radio-button.reel/radio-button.js @@ -0,0 +1,44 @@ +/* +This file contains proprietary software owned by Motorola Mobility, Inc.
+No rights, expressed or implied, whatsoever to this software are provided by Motorola Mobility, Inc. hereunder.
+(c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved. +
*/ + +var Montage = require("montage/core/core").Montage; +var Component = require("montage/ui/component").Component; + +exports.RadioButton = Montage.create(Component, { + + data: { value: null }, + + _selected: { value: null }, + + selected: { + get: function() { return this._selected; }, + set: function(value) { + this._selected = value; + this.needsDraw = true; + } + }, + + prepareForDraw: { + enumerable: false, + value: function() { + this.element.addEventListener("click", this, false); + } + }, + + draw: { + enumerable: false, + value: function() { + + } + }, + + handleClick: { + value: function(event) { + + } + } + +}); -- cgit v1.2.3