3 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
4 <title>The source code</title>
5 <link href="../resources/prettify/prettify.css" type="text/css" rel="stylesheet" />
6 <script type="text/javascript" src="../resources/prettify/prettify.js"></script>
8 <body onload="prettyPrint();">
9 <pre class="prettyprint lang-js">/*!
10 * Ext JS Library 3.3.1
11 * Copyright(c) 2006-2010 Sencha Inc.
12 * licensing@sencha.com
13 * http://www.sencha.com/license
15 <div id="cls-Ext.grid.AbstractSelectionModel"></div>/**
16 * @class Ext.grid.AbstractSelectionModel
17 * @extends Ext.util.Observable
18 * Abstract base class for grid SelectionModels. It provides the interface that should be
19 * implemented by descendant classes. This class should not be directly instantiated.
22 Ext.grid.AbstractSelectionModel = Ext.extend(Ext.util.Observable, {
23 <div id="prop-Ext.grid.AbstractSelectionModel-grid"></div>/**
24 * The GridPanel for which this SelectionModel is handling selection. Read-only.
29 constructor : function(){
31 Ext.grid.AbstractSelectionModel.superclass.constructor.call(this);
34 /** @ignore Called by the grid automatically. Do not call directly. */
35 init : function(grid){
38 delete this.lockOnInit;
45 <div id="method-Ext.grid.AbstractSelectionModel-lock"></div>/**
46 * Locks the selections.
51 // If the grid has been set, then the view is already initialized.
56 beforerefresh: this.sortUnLock,
57 refresh: this.sortLock
60 this.lockOnInit = true;
65 // set the lock states before and after a view refresh
66 sortLock : function() {
70 // set the lock states before and after a view refresh
71 sortUnLock : function() {
75 <div id="method-Ext.grid.AbstractSelectionModel-unlock"></div>/**
76 * Unlocks the selections.
84 // If the grid has been set, then the view is already initialized.
87 gv.un('beforerefresh', this.sortUnLock, this);
88 gv.un('refresh', this.sortLock, this);
90 delete this.lockOnInit;
95 <div id="method-Ext.grid.AbstractSelectionModel-isLocked"></div>/**
96 * Returns true if the selections are locked.
99 isLocked : function(){
105 this.purgeListeners();