Excise HacksSelectorCanvas
[Hacks.git] / Main.js
diff --git a/Main.js b/Main.js
index eb02da9..68194e2 100644 (file)
--- a/Main.js
+++ b/Main.js
@@ -7,7 +7,6 @@ enyo.kind({
        components: [
                {kind: "ApplicationEvents", onWindowActivated: "windowActivated", onWindowDeactivated: "windowDeactivated"},
                {name: "hacksCarousel", kind: "Carousel", flex: 1, onGetLeft: "getLeft", onGetRight: "getRight", onScroll: "scrolling", onScrollStart: "startScroll", onScrollStop: "stopScroll"},
-               //{name: "hacksSelector", kind: "HacksSelector"}
                {name: "info", kind: "HFlexBox", className: "info", style: "opacity: 0", showing: false, components: [
                        {name: "title"},
                        {kind: "Spacer"},
@@ -16,6 +15,7 @@ enyo.kind({
        ],
        hacksList: [
                {name: "Nimbus", kind: "Nimbus", dark: false},
+               {name: "HexaSpinner", kind: "HexaSpinnerHack", dark: false},
                {name: "Landscape", kind: "Landscape", dark: false},
                {name: "Munch", kind: "Munch", dark: true},
                {name: "Orbit", kind: "Orbit", dark: false},
@@ -34,7 +34,6 @@ enyo.kind({
                this.index = 0;
                this.lastScrollPos = 0;
                this.$.hacksCarousel.setCenterView(this.getHack(this.index));
-               //this.$.hacksSelector.setHacksList(this.hacksList);
        },
        ready: function() {
                this.startHack();
@@ -85,8 +84,12 @@ enyo.kind({
        },
        resizeHack: function() {
                var view = this.$.hacksCarousel.fetchView('center');
-
-               //enyo.log('resizing view ' + view);
+               if (view)
+                       view.resize(window.innerWidth, window.innerHeight);
+               var view = this.$.hacksCarousel.fetchView('left');
+               if (view)
+                       view.resize(window.innerWidth, window.innerHeight);
+               var view = this.$.hacksCarousel.fetchView('right');
                if (view)
                        view.resize(window.innerWidth, window.innerHeight);
        },
@@ -126,8 +129,6 @@ enyo.kind({
        scrolling: function(inSender) {
                if (inSender.scrollLeft == 0 || inSender.scrollLeft == inSender.getBoundaries().right)
                        this.startHack();
-               //this.$.hacksSelector.index = this.index + ((inSender.scrollLeft - this.lastScrollPos) / window.innerWidth);
-               //this.$.hacksSelector.draw();
        },
        startScroll: function(inSender) {
                this.stopHack();