aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--js/components/converter/value-units-converter.js29
-rw-r--r--js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js2
2 files changed, 30 insertions, 1 deletions
diff --git a/js/components/converter/value-units-converter.js b/js/components/converter/value-units-converter.js
new file mode 100644
index 00000000..e4f9aee9
--- /dev/null
+++ b/js/components/converter/value-units-converter.js
@@ -0,0 +1,29 @@
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> */
6var Montage = require("montage").Montage,
7Converter = require("montage/core/converter/converter").Converter;
8
9exports.ValueUnitsConverter = Montage.create(Converter, {
10
11 // convert fahrenheit to celsius (showing our non-metric heritage here)
12 convert: {
13 value: function(value) {
14// return (parseInt(value, 10) - 32) / 1.8;
15// console.log(value);
16 console.log(value);
17 return parseInt(value);
18 }
19 },
20
21 // revert celsius to fahrenheit
22 revert: {
23 value: function(value) {
24// return (1.8 * parseInt(value, 10)) + 32;
25 console.log(value);
26 }
27 }
28
29});
diff --git a/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js b/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js
index d1cab096..94ca9b57 100644
--- a/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js
+++ b/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js
@@ -994,7 +994,7 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, {
994 this.arrLayers.splice(myIndex, 0, thingToPush); 994 this.arrLayers.splice(myIndex, 0, thingToPush);
995 995
996 } 996 }
997 this.selectLayer(myIndex); 997 this.selectLayer(myIndex, false);
998 } 998 }
999 }, 999 },
1000 1000