Windows 10 reached EOS (end of support) on October 14, 2025. If you are on Windows 10, see this article.

Mozilla サポートの検索

サポート詐欺に注意してください。 私たちはあなたに通話やショートメッセージの送信、個人情報の共有を求めることはありません。疑わしい行為を見つけたら「迷惑行為を報告」からご報告ください。

詳しく学ぶ
Solved

Thundebird 155 changes Shortcut handling? How can we change shortcuts in 155?

Benedikt Schindler

With Thunderbird 155 our Shortcuts deletion plugin doesn't work anymore.

Now all the worst shortcuts like "a" are back. 

(I never understood why it isn't something like "Alt+A" )

We need to deactivate all the *(/&%$&% shortcuts. We deactivated them via a plugin. But the plugin does't work with 155. Does someone knew what mozilla chaged with the shortcuts handling, so we can change our plugin acordingly?

With Thunderbird 155 our Shortcuts deletion plugin doesn't work anymore. Now all the worst shortcuts like "a" are back. (I never understood why it isn't something like "Alt+A" ) We need to deactivate all the *(/&%$&% shortcuts. We deactivated them via a plugin. But the plugin does't work with 155. Does someone knew what mozilla chaged with the shortcuts handling, so we can change our plugin acordingly?

すべての返信 (1)

選ばれた解決策

Lösung:

1. Wo wir uns einklinken — about:3pane statt nur messenger.xhtml

Die eigentliche Mail-Oberfläche (Ordnerbaum, Nachrichtenliste) läuft seit TB 115 in about:3pane, einem eingebetteten <browser>-Rahmen. Dort müssen wir hin.

2. Wie wir da hinkommen — gTabmail.currentAbout3Pane

Das war die eigentliche Hürde. ExtensionSupport.registerWindowListener sieht nur echte Fenster, und about:3pane ist keins. Der offizielle Weg aus der Thunderbird-Migrationsdoku:


implementation.js Ln 177–232 _install3PaneCaptureHandler(frameWin) {

 // ...

}, _injectIntoAllAbout3Panes(outerWin) {

 try {
   // Weg 1: gTabmail.currentAbout3Pane – offizieller TB-API-Weg
   if (outerWin.gTabmail && outerWin.gTabmail.currentAbout3Pane) {
     this._install3PaneCaptureHandler(outerWin.gTabmail.currentAbout3Pane);
   }
   // Weg 2: alle tabInfo-Einträge (auch nicht-aktive Tabs)
   // ...
 }

}, Dazu TabOpen/TabSelect-Listener, damit auch später geöffnete Tabs erfasst werden.

3. Wann im Event-Flow — Capture- statt Bubble-Phase

Mousetrap registriert sich immer in der Bubble-Phase und ist damit zu spät. Der neue Handler nutzt die Capture-Phase und läuft dadurch garantiert vor Thunderbirds eigenen Handlern:


implementation.js Ln 196–203

 e.preventDefault();
 e.stopImmediatePropagation();
 if (command !== "unset") {
   executeCommand(frameWin, command);
 }

}; frameWin.document.addEventListener("keydown", captureHandler, true /* capture */); stopImmediatePropagation() sorgt dafür, dass Thunderbird die Taste danach gar nicht mehr zu sehen bekommt.

Nebeneffekt Weil Mousetrap zwingend in der Bubble-Phase arbeitet, konnten wir es in about:3pane nicht verwenden. Dort läuft jetzt eigener Code: buildComboString() übersetzt das KeyboardEvent in einen Mousetrap-kompatiblen String ("a", "ctrl+shift+f"), executeCommand() führt aus. In messenger.xhtml bleibt Mousetrap unverändert als Fallback — dieselbe keys-Map, zwei Ausführungswege.

質問する

投稿に返信するには あなたのアカウントにログイン する必要があります。まだアカウントをお持ちでなければ、新しい質問を開始 してください。