Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -337,6 +337,8 @@ class FileManagerThumbnailListBox extends CollectionWidget {

_focusOutHandler() {}

_focusInHandler() {}

_getItems() {
return this.option('items') || [];
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import 'ui/file_manager';
import fx from 'common/core/animation/fx';
import { FileManagerWrapper, createTestFileSystem } from '../../../helpers/fileManagerHelpers.js';
import { shouldSkipOnMobile } from '../../../helpers/device.js';
import pointerMock from '../../../helpers/pointerMock.js';

const { test } = QUnit;

Expand Down Expand Up @@ -302,4 +303,13 @@ QUnit.module('Thumbnails View', moduleConfig, () => {
assert.notOk(this.wrapper.isThumbnailsItemSelected('..'), 'parent folder is not visually highlited');
});

test('Thumbnails view - should focus item only on selection (T1307139)', function(assert) {
this.wrapper.getThumbnailsViewPort().trigger('focusin');
assert.notOk(this.wrapper.isThumbnailsItemFocused('Folder 1'));

pointerMock(this.wrapper.findThumbnailsItem('Folder 1')).click();
this.clock.tick(400);
assert.ok(this.wrapper.isThumbnailsItemSelected('Folder 1'));
assert.ok(this.wrapper.isThumbnailsItemFocused('Folder 1'));
});
});
Loading