1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3  * License, v. 2.0. If a copy of the MPL was not distributed with this
4  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
5 
6 #ifndef mozilla_EditorController_h
7 #define mozilla_EditorController_h
8 
9 #include "nscore.h"
10 
11 class nsControllerCommandTable;
12 
13 namespace mozilla {
14 
15 // the editor controller is used for both text widgets, and basic text editing
16 // commands in composer. The refCon that gets passed to its commands is an
17 // nsIEditor.
18 
19 class EditorController final {
20  public:
21   static nsresult RegisterEditorCommands(
22       nsControllerCommandTable* aCommandTable);
23   static nsresult RegisterEditingCommands(
24       nsControllerCommandTable* aCommandTable);
25   static void Shutdown();
26 };
27 
28 }  // namespace mozilla
29 
30 #endif  // #ifndef mozilla_EditorController_h
31