MCPcopy Index your code
hub / github.com/NativeScript/NativeScript / _layoutHeader

Method _layoutHeader

packages/core/ui/list-view/index.ios.ts:951–964  ·  view source on GitHub ↗
(headerView: View)

Source from the content-addressed store, hash-verified

949 }
950
951 private _layoutHeader(headerView: View): number {
952 if (headerView) {
953 const headerHeight = this.stickyHeaderHeight === 'auto' ? 44 : Length.toDevicePixels(this.stickyHeaderHeight, 44);
954 const heightMeasureSpec: number = layout.makeMeasureSpec(headerHeight, layout.EXACTLY);
955
956 const measuredSize = View.measureChild(this, headerView, this.widthMeasureSpec, heightMeasureSpec);
957 // Layout the header with the measured size
958 View.layoutChild(this, headerView, 0, 0, measuredSize.measuredWidth, measuredSize.measuredHeight);
959
960 return measuredSize.measuredHeight;
961 }
962
963 return 44;
964 }
965
966 private _getHeaderTemplate(): View {
967 if (this.stickyHeaderTemplate) {

Callers 1

_prepareHeaderMethod · 0.95

Calls 2

measureChildMethod · 0.45
layoutChildMethod · 0.45

Tested by

no test coverage detected