Skip to content

Commit

Permalink
formatting tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
johnspackman committed Jan 10, 2024
1 parent 318086f commit aa5a1b7
Show file tree
Hide file tree
Showing 20 changed files with 257 additions and 269 deletions.
13 changes: 5 additions & 8 deletions source/class/qxl/datagrid/DataGrid.js
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ qx.Class.define("qxl.datagrid.DataGrid", {
* @param {Integer} pos
*/
scrollToX(pos) {
// TODO
/* TODO */
},

/**
Expand All @@ -432,7 +432,7 @@ qx.Class.define("qxl.datagrid.DataGrid", {
* @param {Integer} pos
*/
scrollToY(pos) {
//TODO
/* TODO */
},

/**
Expand All @@ -446,7 +446,6 @@ qx.Class.define("qxl.datagrid.DataGrid", {
}

let size = this.getDataSource().getSize();

let scrollbarX = this.getChildControl("scrollbar-x");
let columns = this.getColumns();
let showX = this.getScrollbarX();
Expand Down Expand Up @@ -518,7 +517,9 @@ qx.Class.define("qxl.datagrid.DataGrid", {

control.exclude();
control.addListener("scroll", e => {
if (this.__inApplyStartRowIndex) return;
if (this.__inApplyStartRowIndex) {
return;
}
let position = e.getData();
let rowCount = this.getDataSource().getSize().getRow();
const startRowIndex = Math.floor(qxl.datagrid.util.Math.interpolate(0, 100, 0, Math.max(0, rowCount - this.getMaxRows()), position));
Expand All @@ -538,10 +539,6 @@ qx.Class.define("qxl.datagrid.DataGrid", {
return super._createChildControlImpl(id);
},

/**
* @Override
*
/**
* Updates the display after changes to data or columns etc
*/
Expand Down
38 changes: 19 additions & 19 deletions source/class/qxl/datagrid/column/Columns.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
/* ************************************************************************
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */

/**
* Provides a simple list of columns
Expand Down
38 changes: 19 additions & 19 deletions source/class/qxl/datagrid/column/FilteredColumns.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
/* ************************************************************************
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */

/**
* Wraps another instance of IColumns to filter and sort the list; this allows the user interface
Expand Down
38 changes: 19 additions & 19 deletions source/class/qxl/datagrid/column/IColumns.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
/* ************************************************************************
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */

/**
* Implemented by objects that can provide a list of columns for the datagrid.
Expand Down
2 changes: 1 addition & 1 deletion source/class/qxl/datagrid/column/tree/IExpansionWidget.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
*
* *********************************************************************** */

qx.Interface.define( "qxl.datagrid.column.tree.IExpansionWidget", {
qx.Interface.define("qxl.datagrid.column.tree.IExpansionWidget", {
properties: {
/** How deep the indentation level is */
indentationLevel: {
Expand Down
3 changes: 2 additions & 1 deletion source/class/qxl/datagrid/demo/array/DummyModel.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,9 @@ qx.Class.define("qxl.datagrid.demo.array.DummyModel", {
"Hawk",
"Falcon",
"Vulture",
"Penguin",
"Penguin"
];

return nouns[Math.floor(Math.random() * nouns.length)];
},

Expand Down
38 changes: 19 additions & 19 deletions source/class/qxl/datagrid/demo/theme/tangible/Appearance.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
/* ************************************************************************
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */

qx.Theme.define("qxl.datagrid.demo.theme.tangible.Appearance", {
extend: qx.theme.tangible.Appearance,
Expand Down
38 changes: 19 additions & 19 deletions source/class/qxl/datagrid/demo/theme/tangible/Decoration.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
/* ************************************************************************
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */

qx.Theme.define("qxl.datagrid.demo.theme.tangible.Decoration", {
extend: qx.theme.tangible.Decoration,
Expand Down
40 changes: 20 additions & 20 deletions source/class/qxl/datagrid/demo/theme/tangible/Theme.js
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
/* ************************************************************************
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */

qx.Theme.define( "qxl.datagrid.demo.theme.tangible.Theme", {
qx.Theme.define("qxl.datagrid.demo.theme.tangible.Theme", {
meta: {
color: qxl.datagrid.demo.theme.tangible.Color,
decoration: qxl.datagrid.demo.theme.tangible.Decoration,
Expand Down
38 changes: 19 additions & 19 deletions source/class/qxl/datagrid/demo/tree/TreeDemoNodeInspector.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
/* ************************************************************************
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */
*
* Qooxdoo DataGrid
*
* https://github.com/qooxdoo/qooxdoo
*
* Copyright:
* 2022-23 Zenesis Limited, https://www.zenesis.com
*
* License:
* MIT: https://opensource.org/licenses/MIT
*
* This software is provided under the same licensing terms as Qooxdoo,
* please see the LICENSE file in the Qooxdoo project's top-level directory
* for details.
*
* Authors:
* * John Spackman ([email protected], @johnspackman)
*
* *********************************************************************** */

qx.Class.define("qxl.datagrid.demo.tree.TreeDemoNodeInspector", {
extend: qxl.datagrid.source.tree.NodeInspector,
Expand Down
4 changes: 3 additions & 1 deletion source/class/qxl/datagrid/source/AbstractDataSource.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,9 @@ qx.Class.define("qxl.datagrid.source.AbstractDataSource", {
*/
_parseDataKey(str) {
let pos = 5;
if (str.length !== 11) pos = str.indexOf(":");
if (str.length !== 11) {
pos = str.indexOf(":");
}
let row = parseInt(str.substring(0, pos), 10);
let column = parseInt(str.substring(pos + 1), 10);
return { row, column };
Expand Down
2 changes: 1 addition & 1 deletion source/class/qxl/datagrid/source/Range.js
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ qx.Class.define("qxl.datagrid.source.Range", {
*/
__applyXxxx(value) {
if (value) {
value.addListener("change", evt => this.fireEvent("change"), this);
value.addListener("change", evt => this.fireEvent("change"));
}
}
},
Expand Down
Loading

0 comments on commit aa5a1b7

Please sign in to comment.