public ExtScript() { Console.WriteLine("ExtScript()"); var record = Record.create(new Schema[] { new Schema { name = "id", type = "int" }, new Schema { name = "value" } }); JsonReader reader = new JsonReader(new JsonReaderConfig { id = "id" }, record); Console.WriteLine(reader); Store store = new Store(new StoreConfig { reader = reader }); var data = new MyRecord[] { new MyRecord { id = 1, value = "first" }, new MyRecord { id = 2, value = "second" } }; Console.WriteLine(data); store.loadData(data); ColumnModelConfig[] columns = new ColumnModelConfig[] { new ColumnModelConfig { dataIndex = "id", header = "ID" }, new ColumnModelConfig { dataIndex = "value", header = "Value" } }; var colModel = new ColumnModel(columns); this.grid = new GridPanel(new GridPanelConfig { height = 150.0, renderTo = "grid", colModel = colModel, store = store }); Console.WriteLine(this.grid); this.grid.on("dblclick", new GridPanelDblclickDelegate(this.OnDblClick), this); Console.WriteLine("ready"); }
/// <summary> /// Binds the paging toolbar to the specified {@link Ext.data.Store} <b>(deprecated)</b> /// @param {Ext.data.Store} store The data store to bind /// </summary> public void bind(Store store) { }
/// <summary> /// @private /// Binds a new Store and ColumnModel to this GridView. Removes any listeners from the old objects (if present) /// and adds listeners to the new ones /// @param {Ext.data.Store} newStore The new Store instance /// @param {Ext.grid.ColumnModel} newColModel The new ColumnModel instance /// </summary> public void initData(Store newStore, ColumnModel newColModel) { }
/// <summary> /// @private /// Renders all of the rows to a string buffer and returns the string. This is called internally /// by renderRows and performs the actual string building for the rows - it does not inject HTML into the DOM. /// @param {Array} columns The column data acquired from getColumnData. /// @param {Array} records The array of records to render /// @param {Ext.data.Store} store The store to render the rows from /// @param {Number} startRow The index of the first row being rendered. Sometimes we only render a subset of /// the rows so this is used to maintain logic for striping etc /// @param {Number} colCount The total number of columns in the column model /// @param {Boolean} stripe True to stripe the rows /// @return {String} A string containing the HTML for the rendered rows /// </summary> public JsString doRender(JsArray columns, JsArray records, Store store, JsNumber startRow, JsNumber colCount, bool stripe) { return null; }
/// <summary> /// <p>Reconfigures the grid to use a different Store and Column Model /// and fires the 'reconfigure' event. The View will be bound to the new /// objects and refreshed.</p> /// <p>Be aware that upon reconfiguring a GridPanel, certain existing settings <i>may</i> become /// invalidated. For example the configured {@link #autoExpandColumn} may no longer exist in the /// new ColumnModel. Also, an existing {@link Ext.PagingToolbar PagingToolbar} will still be bound /// to the old Store, and will need rebinding. Any {@link #plugins} might also need reconfiguring /// with the new data.</p> /// @param {Ext.data.Store} store The new {@link Ext.data.Store} object /// @param {Ext.grid.ColumnModel} colModel The new {@link Ext.grid.ColumnModel} object /// </summary> public void reconfigure(Store store, ColumnModel colModel) { }
/// <summary> /// Tells this model instance that it has been removed from the store. /// @param {Ext.data.Store} store The store from which this model has been removed. /// </summary> public void unjoin(Store store){}
/// <summary> /// Tells this model instance that it has been added to a store. /// @param {Ext.data.Store} store The store to which this model has been added. /// </summary> public void join(Store store){}
public void reconfigure(Store store) { throw new Exception(); }
public void bindStore(Store store) { throw new Exception(); }
public void unbind(Store store) { throw new Exception(); }
public void bindStore(Store store, bool initial) { throw new Exception(); }
public void setStore(Store store) { throw new Exception(); }
public string getRowClass(Record record, double index, object rowParams, Store store) { throw new Exception(); }
public void reconfigure(Store store, ColumnModel colModel) { throw new Exception(); }
/// <summary> /// Unbinds the paging toolbar from the specified {@link Ext.data.Store} <b>(deprecated)</b> /// @param {Ext.data.Store} store The data store to unbind /// </summary> public void unbind(Store store) { }
/// <summary> /// Changes the data store bound to this LoadMask. /// @param {Ext.data.Store} store The store to bind to this LoadMask /// </summary> public void bindStore(Store store, object initial){}
/// <summary> /// Changes the data store bound to this view and refreshes it. ... /// </summary> public object bindStore(Ext.data.Store store, object initial) { return(null); }