diff --git a/app/common/constants/settingsEnums.js b/app/common/constants/settingsEnums.js index 74ba6ab0424..4a139dde2e8 100644 --- a/app/common/constants/settingsEnums.js +++ b/app/common/constants/settingsEnums.js @@ -24,7 +24,6 @@ const bookmarksToolbarMode = { const tabCloseAction = { LAST_ACTIVE: 'lastActive', NEXT: 'next', - FIRST: 'first', PARENT: 'parent' } diff --git a/app/extensions/brave/locales/en-US/preferences.properties b/app/extensions/brave/locales/en-US/preferences.properties index 5641d11cd87..751fd432db5 100644 --- a/app/extensions/brave/locales/en-US/preferences.properties +++ b/app/extensions/brave/locales/en-US/preferences.properties @@ -131,10 +131,9 @@ startsWith=Brave starts with startsWithOptionLastTime=My windows / tabs from last time startsWithOptionHomePage=Home page startsWithOptionNewTabPage=a new tab -tabCloseActionLastActive=Last active tab -tabCloseActionNext=Next tab -tabCloseActionFirst=First tab -tabCloseActionParent=Parent tab +tabCloseActionLastActive=Select the last viewed tab +tabCloseActionNext=Select the next tab +tabCloseActionParent=Select its parent tab newTabMode=A new tab shows newTabBlank=blank newTabNewTabPage=Dashboard @@ -149,7 +148,7 @@ engineGoKey=Engine Go Key (Type First) switchToNewTabs=Switch to new tabs immediately paintTabs=Show tabs in page theme color tabsPerTabPage=Number of tabs per tab set: -tabCloseAction=Which tab should be activated after the tab is closed: +tabCloseAction=When closing an active tab: showTabPreviews=Show tab previews on hover showHistoryMatches=Show history matches showBookmarkMatches=Show bookmark matches diff --git a/js/about/preferences.js b/js/about/preferences.js index ce56d02cffb..c8664b00d69 100644 --- a/js/about/preferences.js +++ b/js/about/preferences.js @@ -12,7 +12,7 @@ const SwitchControl = require('../components/switchControl') const ModalOverlay = require('../components/modalOverlay') const {SettingsList, SettingItem} = require('../../app/renderer/components/settings') const {SettingTextbox} = require('../../app/renderer/components/textbox') -const {FormDropdown, SettingDropdown} = require('../../app/renderer/components/dropdown') +const {SettingDropdown} = require('../../app/renderer/components/dropdown') const Button = require('../components/button') // Tabs @@ -836,14 +836,13 @@ class TabsTab extends ImmutableComponent { - + diff --git a/js/state/frameStateUtil.js b/js/state/frameStateUtil.js index 819e9b22336..dfabaf4c871 100644 --- a/js/state/frameStateUtil.js +++ b/js/state/frameStateUtil.js @@ -469,9 +469,6 @@ function removeFrame (frames, tabs, closedFrames, frameProps, activeFrameKey, fr case tabCloseAction.NEXT: activeFrameIndex = ((frames.count() - 1) === framePropsIndex) ? (framePropsIndex - 1) : framePropsIndex break - case tabCloseAction.FIRST: - activeFrameIndex = 0 - break // Default is a parent tab default: let parentFrameIndex = findIndexForFrameKey(frames, frameProps.get('parentFrameKey')) diff --git a/test/unit/state/frameStateUtilTest.js b/test/unit/state/frameStateUtilTest.js index 670b1fb69e6..e49241d0139 100644 --- a/test/unit/state/frameStateUtilTest.js +++ b/test/unit/state/frameStateUtilTest.js @@ -200,19 +200,6 @@ describe('frameStateUtil', function () { assert.equal(result.activeFrameKey, 5) }) - it('first tab action', function () { - const result = frameStateUtil.removeFrame( - frames, - tabs, - closedFrames, - frameProps, - activeFrameKey, - framePropsIndex, - tabCloseAction.FIRST - ) - assert.equal(result.activeFrameKey, 2) - }) - it('next tab action', function () { const result = frameStateUtil.removeFrame( frames,