Eine aufbereitete Darstellung der Quelle

 
     
 
 
 
Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung


Impressum nsControllerCommandTable.h  Sprache: C


/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */


#ifndef nsControllerCommandTable_h_
#define nsControllerCommandTable_h_

#include "nsHashKeys.h"
#include "nsISupportsImpl.h"
#include "nsRefPtrHashtable.h"

namespace mozilla {
class ControllerCommand;
}

class nsICommandParams;

class nsControllerCommandTable final {
 public:
  nsControllerCommandTable();

  NS_INLINE_DECL_REFCOUNTING(nsControllerCommandTable);

  static nsControllerCommandTable* EditorCommandTable();
  static nsControllerCommandTable* EditingCommandTable();
  static nsControllerCommandTable* HTMLEditorCommandTable();
  static nsControllerCommandTable* HTMLEditorDocStateCommandTable();
  static nsControllerCommandTable* WindowCommandTable();

  void RegisterCommand(const nsACString&, mozilla::ControllerCommand*);
  void UnregisterCommand(const nsACString&, mozilla::ControllerCommand*);
  mozilla::ControllerCommand* FindCommandHandler(const nsACString&) const;
  bool IsCommandEnabled(const nsACString&, nsISupports* aContext) const;
  bool SupportsCommand(const nsACString& aName) const {
    return !!FindCommandHandler(aName);
  }
  void MakeImmutable() { mMutable = false; }
  void GetSupportedCommands(nsTArray<nsCString>&) const;

 private:
  ~nsControllerCommandTable();
  // Hash table of nsIControllerCommands, keyed by command name.
  nsRefPtrHashtable<nsCStringHashKey, mozilla::ControllerCommand>
      mCommandsTable;

  // Are we mutable?
  bool mMutable = true;
};

#endif  // nsControllerCommandTable_h_

Messung
CHZG
891009996

¤ Dauer der Verarbeitung: 0.0 Sekunden  (vorverarbeitet am  2026-11-25) ¤

*Bot Zugriff







                                                                                                                                                                                                                                                                                                                                                                                                     

 

Neuigkeiten

Aktuelles
Motto des Tages

Open Source Software


Gedichte
Musik
Bilder

Jenseits des Üblichen

Besucherstatistik

Besucherstatistik

Statistik
#Sources=1,188,892
#Domains=963,315