3 This file is part of Ext JS 4
5 Copyright (c) 2011 Sencha Inc
7 Contact: http://www.sencha.com/contact
9 GNU General Public License Usage
10 This file may be used under the terms of the GNU General Public License version 3.0 as published by the Free Software Foundation and appearing in the file LICENSE included in the packaging of this file. Please review the following information to ensure the GNU General Public License version 3.0 requirements will be met: http://www.gnu.org/copyleft/gpl.html.
12 If you are unsure which license is appropriate for your use, please contact the sales department at http://www.sencha.com/contact.
15 Ext.require('Ext.chart.*');
16 Ext.require('Ext.data.*');
17 Ext.require('Ext.Window');
18 Ext.require('Ext.layout.container.Fit');
19 Ext.require('Ext.fx.target.Sprite');
240 Ext.onReady(function () {
241 var fields = ['IE', 'Chrome', 'Firefox', 'Safari', 'Opera', 'Other'];
243 var browserStore = Ext.create('Ext.data.JsonStore', {
248 var colors = ['rgb(47, 162, 223)',
251 'rgb(154, 176, 213)',
255 Ext.chart.theme.Browser = Ext.extend(Ext.chart.theme.Base, {
256 constructor: function(config) {
257 Ext.chart.theme.Base.prototype.constructor.call(this, Ext.apply({
263 var win = Ext.create('Ext.Window', {
271 title: 'What is the trend in Browser Usage?',
272 renderTo: Ext.getBody(),
277 style: 'background:#fff',
279 theme: 'Browser:gradients',
298 title: 'Month of the Year',
300 renderer: function(v) {
301 return v.match(/([0-9]*)\/[0-9]*\/[0-9][0-9]([0-9]*)/).slice(1).join('/');
313 renderer: function(storeItem, item) {
314 this.setTitle(item.storeField + ' - '
315 + Ext.Date.format(new Date(storeItem.get('date')), 'M y')
316 + ' - ' + storeItem.get(item.storeField) + '%');