diff --git a/src/Spec2-Adapters-Morphic-ListView/SpMorphicListViewAdapter.class.st b/src/Spec2-Adapters-Morphic-ListView/SpMorphicListViewAdapter.class.st index 2767d11e..4d74bc2d 100644 --- a/src/Spec2-Adapters-Morphic-ListView/SpMorphicListViewAdapter.class.st +++ b/src/Spec2-Adapters-Morphic-ListView/SpMorphicListViewAdapter.class.st @@ -39,7 +39,6 @@ SpMorphicListViewAdapter >> newDataSource [ SpMorphicListViewAdapter >> newTableWith: datasource [ ^ SpFTTableMorph new - beRowNotHomogeneous; disableFunction; dataSource: datasource; hideColumnHeaders; diff --git a/src/Spec2-Adapters-Morphic/SpAbstractMorphicListAdapter.class.st b/src/Spec2-Adapters-Morphic/SpAbstractMorphicListAdapter.class.st index 26befd3e..940b5c6d 100644 --- a/src/Spec2-Adapters-Morphic/SpAbstractMorphicListAdapter.class.st +++ b/src/Spec2-Adapters-Morphic/SpAbstractMorphicListAdapter.class.st @@ -38,23 +38,15 @@ SpAbstractMorphicListAdapter >> addKeyBindingsTo: aWidget [ self addActivationKeyBindings: aWidget ] -{ #category : 'scrolling' } -SpAbstractMorphicListAdapter >> adjustDesiredVisibleRow: aNumber [ - - ^ aNumber + (self hasHeaderTitle - ifTrue: [ 0 ] - ifFalse: [ 1 ]) -] - { #category : 'scrolling' } SpAbstractMorphicListAdapter >> configureScrolling [ | vAlignment | vAlignment := self presenter verticalAlignment. vAlignment whenChangedDo: [ - widget scrollToIndex: (self adjustDesiredVisibleRow: vAlignment desiredVisibleRow) ]. + widget scrollToIndex: vAlignment desiredVisibleRow ]. self presenter whenDisplayDo: [ - widget scrollToIndex: (self adjustDesiredVisibleRow: vAlignment desiredVisibleRow). + widget scrollToIndex: vAlignment desiredVisibleRow. self scrollingChanged ]. widget diff --git a/src/Spec2-Adapters-Morphic/SpMorphicListAdapter.class.st b/src/Spec2-Adapters-Morphic/SpMorphicListAdapter.class.st index c9fa116c..9567b891 100644 --- a/src/Spec2-Adapters-Morphic/SpMorphicListAdapter.class.st +++ b/src/Spec2-Adapters-Morphic/SpMorphicListAdapter.class.st @@ -158,7 +158,7 @@ SpMorphicListAdapter >> refreshList [ { #category : 'widget API' } SpMorphicListAdapter >> refreshWidgetHeaderTitle [ - self presenter hasHeaderTitle + self hasHeaderTitle ifTrue: [ self widget columns first model title: self presenter headerTitle. self widget diff --git a/src/Spec2-Backend-Tests/SpListCommonPropertiestTest.class.st b/src/Spec2-Backend-Tests/SpListCommonPropertiestTest.class.st index bb52fbc6..c26c3554 100644 --- a/src/Spec2-Backend-Tests/SpListCommonPropertiestTest.class.st +++ b/src/Spec2-Backend-Tests/SpListCommonPropertiestTest.class.st @@ -54,8 +54,7 @@ SpListCommonPropertiestTest >> testScrollDownToNonExistingIndexScrollsBottomToLa { #category : 'tests - scrolling' } SpListCommonPropertiestTest >> testScrollDownToPosteriorIndexScrollsBottomToIndex [ - self flag: #pharo7. - SystemVersion current major < 8 ifTrue: [ self skip. "Feature not supported in Pharo 7" ]. + presenter items: (1 to: 500). presenter verticalAlignment desiredVisibleRow: 100. @@ -82,8 +81,7 @@ SpListCommonPropertiestTest >> testScrollUpToNegativeIndexScrollsTopToFirstIndex { #category : 'tests - scrolling' } SpListCommonPropertiestTest >> testScrollUpToPreviousIndexScrollsTopToIndex [ - self flag: #pharo7. - SystemVersion current major < 8 ifTrue: [ self skip. "Feature not supported in Pharo 7" ]. + presenter items: (1 to: 500). presenter verticalAlignment desiredVisibleRow: 100. self openInstance.