Bug 1819675 - rename SessionStore.getClosedTabCount and getClosedTabData to getClosedTabCountForWindow and getClosedTabDataForWindow. r=dao,fxview-reviewers,kcochrane

- As closed tabs will change to mean closed tabs from all windows, rename these functions to make
  changes in later patches clearer when we mean closed tabs from this window specifically, or closed
  tabs for all private/non-private windows

Differential Revision: https://phabricator.services.mozilla.com/D177849
This commit is contained in:
Sam Foster
2023-05-30 18:54:12 +00:00
parent 185115560e
commit ffc79712f2
46 changed files with 140 additions and 121 deletions

View File

@@ -115,7 +115,7 @@ export const CustomizableWidgets = [
lazy.PanelMultiView.getViewNode(
document,
"appMenuRecentlyClosedTabs"
).disabled = lazy.SessionStore.getClosedTabCount(window) == 0;
).disabled = lazy.SessionStore.getClosedTabCountForWindow(window) == 0;
lazy.PanelMultiView.getViewNode(
document,
"appMenuRecentlyClosedWindows"

View File

@@ -62,7 +62,8 @@ add_task(async function tabstrip_context() {
});
await shownPromise;
let closedTabsAvailable = SessionStore.getClosedTabCount(window) == 0;
let closedTabsAvailable =
SessionStore.getClosedTabCountForWindow(window) == 0;
info("Closed tabs: " + closedTabsAvailable);
let expectedEntries = [
["#toolbar-context-openANewTab", true],