diff --git a/src/lib/QtWidgets/QHeaderView.ts b/src/lib/QtWidgets/QHeaderView.ts index 28d7b662f..70f68f803 100644 --- a/src/lib/QtWidgets/QHeaderView.ts +++ b/src/lib/QtWidgets/QHeaderView.ts @@ -11,7 +11,22 @@ import { AlignmentFlag, checkIfNativeElement, Orientation, QPoint, SortOrder } f * **This class is a JS wrapper around Qt's [QHeaderView class](https://doc.qt.io/qt-5/qheaderview.html)** */ -export abstract class NodeHeaderView extends QAbstractItemView { +export class QHeaderView extends QAbstractItemView { + constructor(orientationOrNative: Orientation | NativeElement, parent: QWidget | null = null) { + let native: NativeElement; + if (checkIfNativeElement(orientationOrNative)) { + native = orientationOrNative as NativeElement; + } else { + if (parent != null) { + native = new addon.QHeaderView(orientationOrNative, parent.native); + } else { + native = new addon.QHeaderView(orientationOrNative); + } + } + super(native); + parent && this.setNodeParent(parent); + } + // *** Public Function *** cascadingSectionResizes(): boolean { return this.native.cascadingSectionResizes(); @@ -204,23 +219,6 @@ export abstract class NodeHeaderView extends } } -export class QHeaderView extends NodeHeaderView { - constructor(orientationOrNative: Orientation | NativeElement, parent: QWidget | null = null) { - let native: NativeElement; - if (checkIfNativeElement(orientationOrNative)) { - native = orientationOrNative as NativeElement; - } else { - if (parent != null) { - native = new addon.QHeaderView(orientationOrNative, parent.native); - } else { - native = new addon.QHeaderView(orientationOrNative); - } - } - super(native); - parent && this.setNodeParent(parent); - } -} - export enum QHeaderViewResizeMode { Interactive = 0, Fixed = 2,