sc_require('views/results_tab');
sc_require('views/search_tab');

GoogleSearch.TabHostView = SC.TabView.extend({

    layout: { 
        centerX: 0,
        left: 0,
        right: 0,
        top: 125,
        bottom: 0
    },
    classNames: ['bg-white'],
    
    tabLocation: SC.TOP_LOCATION,
    nowShowing: 'GoogleSearch.SearchTabView',
    itemTitleKey: 'title',
    itemValueKey: 'value',
    
    items: [
        { title: 'Otsi', value: 'GoogleSearch.SearchTabView' },
        { title: 'Tulemused', value: 'GoogleSearch.ResultsTabView' }
    ],
   
    tabsToggle: function()
    {
        (this.get('nowShowing') === 'GoogleSearch.ResultsTabView') ?
            this.set('nowShowing', 'GoogleSearch.SearchTabView') : 
            this.set('nowShowing', 'GoogleSearch.ResultsTabView');
    }
    
});