/* Copyright 2009 Palm, Inc.  All rights reserved. */
/*global Mojo, Class, $L */
/*jslint rhino:true, undef:true */

var ExpiredAssistant = Class.create({

    initialize: function() {
        //Mojo.Log.info("ExpiredAssistant: initialize");
    },

    setup: function() {
        //Mojo.Log.info("ExpiredAssistant: setup");

        // Set up the view buttons (header)
        this.viewMenuModel = { visible: true, items: this.viewMenu };

        this.controller.setupWidget(Mojo.Menu.viewMenu,
                                    undefined,
                                    this.viewMenuModel);

        this.controller.get('buy_button').observe(Mojo.Event.tap,
            this.doBuy.bindAsEventListener(this));

        this.controller.setupWidget(Mojo.Menu.appMenu,
                                    { omitDefaultItems: true },
                                    this.appMenuModel);
    },

    activate: function() {
        //Mojo.Log.info("ExpiredAssistant: activate");
    },

    ready: function() {
        //Mojo.Log.info("ExpiredAssistant: ready");
    },

    cleanup: function() {
        //Mojo.Log.info("ExpiredAssistant: cleanup");
    },

    deactivate: function() {
        //Mojo.Log.info("ExpiredAssistant: deactivate");
    },

    doBuy: function(event) {
        //Mojo.Log.info("ExpiredAssistant: doBuy");
    },

    appMenuModel: {
                    items: [
                             {
                               label: $L('Help...'),
                               command: Mojo.Menu.helpCmd,
                               disabled: true
                             }
                           ]
                  },

    viewMenu: [ { template: 'dataviz/dataviz_header' } ]
});
