Skip to content

Commit

Permalink
Be more aggressive about opening the composition window toolbar.
Browse files Browse the repository at this point in the history
  • Loading branch information
jperryhouts committed Nov 22, 2020
1 parent e418b00 commit 21b782d
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions experiments/sl3u.js
Original file line number Diff line number Diff line change
Expand Up @@ -1004,6 +1004,7 @@ var SL3U = class extends ExtensionCommon.ExtensionAPI {
const { document } = window;
const toolbarId = "composeToolbar2";
const toolbar = document.getElementById(toolbarId);

const widgetId = ExtensionCommon.makeWidgetId(extension.id);
const toolbarButtonId = `${widgetId}-composeAction-toolbarbutton`;
const windowURL =
Expand Down Expand Up @@ -1032,6 +1033,16 @@ var SL3U = class extends ExtensionCommon.ExtensionAPI {
);
// Services.xulStore.persist(toolbar, "currentset");
}

Services.xulStore.setValue(
windowURL,
toolbarId,
"collapsed",
"false"
);
toolbar.collapsed = false;
toolbar.hidden = false;

console.debug("Compose window has send later button now.");
} catch (err) {
console.error("Error enabling toolbar button", err);
Expand Down

0 comments on commit 21b782d

Please sign in to comment.