/* * @author: Qennix * Jan 12th, 2011 */ //Keyboard Events new Ext.KeyMap(document, { key: Ext.EventObject.F5, fn: function(keycode, e) { if (! e.ctrlKey) { if (Ext.isIE) { // IE6 doesn't allow cancellation of the F5 key, so trick it into // thinking some other key was pressed (backspace in this case) e.browserEvent.keyCode = 8; } e.stopEvent(); document.location = document.location; }else{ Ext.Msg.alert('Refresh', 'You clicked: CTRL-F5'); } } }); var newButton; var editButton; var deleteButton; var importButton; var backButton; var store; var expander; var cmodel; var infoGrid; var viewport; var smodel; var FIELD_CM; var FIELD_DS; Ext.onReady(function(){ var xColumns = new Array(); var xFields = new Array(); pageSize = parseInt(CONFIG.pageSize); newButton = new Ext.Action({ text: _('ID_ADD_ROW'), iconCls: 'button_menu_ext ss_sprite ss_add', handler: NewPMTableRow }); editButton = new Ext.Action({ text: _('ID_EDIT'), iconCls: 'button_menu_ext ss_sprite ss_pencil', handler: EditPMTableRow, disabled: true }); deleteButton = new Ext.Action({ text: _('ID_DELETE'), iconCls: 'button_menu_ext ss_sprite ss_delete', handler: DeletePMTableRow, disabled: true }); importButton = new Ext.Action({ text: _('ID_IMPORT'), iconCls: 'silk-add', icon: '/images/import.gif', handler: ImportPMTableCSV }); backButton = new Ext.Action({ text: _('ID_BACK'), iconCls: 'button_menu_ext ss_sprite ss_arrow_redo', handler: BackPMList }); contextMenu = new Ext.menu.Menu({ items: [editButton, deleteButton] }); //This loop loads columns and fields to store and column model for (var c=0; c