aboutsummaryrefslogtreecommitdiff
path: root/js/components/tools-properties/pen-properties.reel
diff options
context:
space:
mode:
authorPierre Frisch2011-12-22 07:25:50 -0800
committerValerio Virgillito2012-01-27 11:18:17 -0800
commitb89a7ee8b956c96a1dcee995ea840feddc5d4b27 (patch)
tree0f3136ab0ecdbbbed6a83576581af0a53124d6f1 /js/components/tools-properties/pen-properties.reel
parent2401f05d1f4b94d45e4568b81fc73e67b969d980 (diff)
downloadninja-b89a7ee8b956c96a1dcee995ea840feddc5d4b27.tar.gz
First commit of Ninja to ninja-internal
Signed-off-by: Valerio Virgillito <rmwh84@motorola.com>
Diffstat (limited to 'js/components/tools-properties/pen-properties.reel')
-rw-r--r--js/components/tools-properties/pen-properties.reel/pen-properties.css6
-rw-r--r--js/components/tools-properties/pen-properties.reel/pen-properties.html34
-rw-r--r--js/components/tools-properties/pen-properties.reel/pen-properties.js28
3 files changed, 68 insertions, 0 deletions
diff --git a/js/components/tools-properties/pen-properties.reel/pen-properties.css b/js/components/tools-properties/pen-properties.reel/pen-properties.css
new file mode 100644
index 00000000..7f1b0f7f
--- /dev/null
+++ b/js/components/tools-properties/pen-properties.reel/pen-properties.css
@@ -0,0 +1,6 @@
1/* <copyright>
2 This file contains proprietary software owned by Motorola Mobility, Inc.<br/>
3 No rights, expressed or implied, whatsoever to this software are provided by Motorola Mobility, Inc. hereunder.<br/>
4 (c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved.
5 </copyright> */
6
diff --git a/js/components/tools-properties/pen-properties.reel/pen-properties.html b/js/components/tools-properties/pen-properties.reel/pen-properties.html
new file mode 100644
index 00000000..7af35a03
--- /dev/null
+++ b/js/components/tools-properties/pen-properties.reel/pen-properties.html
@@ -0,0 +1,34 @@
1<!DOCTYPE HTML>
2<!-- <copyright>
3 This file contains proprietary software owned by Motorola Mobility, Inc.<br/>
4 No rights, expressed or implied, whatsoever to this software are provided by Motorola Mobility, Inc. hereunder.<br/>
5 (c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved.
6 </copyright> -->
7<html>
8 <head>
9 <meta http-equiv="content-type" content="text/html; charset=utf-8" />
10 <link rel="stylesheet" type="text/css" href="pen-properties.css">
11
12 <script type="text/montage-serialization">
13 {
14
15 "owner": {
16 "module": "js/components/tools-properties/pen-properties.reel",
17 "name": "PenProperties",
18 "properties": {
19 "element": {"#": "penProperties"},
20 "reset": {"#": "resetPenTool"}
21 }
22 }
23 }
24 </script>
25
26 </head>
27
28 <body>
29 <div id="penProperties" class="subToolHolderPanel">
30 <button id="resetPenTool" tabindex="0" class="montage-button" aria-role="button" aria-busy="false">Reset</button>
31 </div>
32 </body>
33
34</html> \ No newline at end of file
diff --git a/js/components/tools-properties/pen-properties.reel/pen-properties.js b/js/components/tools-properties/pen-properties.reel/pen-properties.js
new file mode 100644
index 00000000..ec8efa69
--- /dev/null
+++ b/js/components/tools-properties/pen-properties.reel/pen-properties.js
@@ -0,0 +1,28 @@
1/* <copyright>
2This file contains proprietary software owned by Motorola Mobility, Inc.<br/>
3No rights, expressed or implied, whatsoever to this software are provided by Motorola Mobility, Inc. hereunder.<br/>
4(c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved.
5</copyright> */
6
7var Montage = require("montage/core/core").Montage;
8var Component = require("montage/ui/component").Component;
9var defaultEventManager = require("montage/core/event/event-manager").defaultEventManager;
10var ToolProperties = require("js/components/tools-properties/tool-properties").ToolProperties;
11
12exports.PenProperties = Montage.create(ToolProperties, {
13 reset: { value: null },
14
15 _subPrepare: {
16 value: function() {
17 this.reset.addEventListener("click", this, false);
18 }
19 },
20
21 handleClick: {
22 value: function(event) {
23 var newEvent = document.createEvent( "CustomEvent" );
24 newEvent.initCustomEvent( "resetPenTool", false, true );
25 defaultEventManager.dispatchEvent( newEvent );
26 }
27 }
28}); \ No newline at end of file