1
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
3
* The contents of this file are subject to the Mozilla Public
4
* License Version 1.1 (the "License"); you may not use this file
5
* except in compliance with the License. You may obtain a copy of
6
* the License at http://www.mozilla.org/MPL/
8
* Software distributed under the License is distributed on an "AS
9
* IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
10
* implied. See the License for the specific language governing
11
* rights and limitations under the License.
13
* The Original Code is Mozilla Communicator.
15
* The Initial Developer of the Original Code is Netscape Communications
16
* Corp. Portions created by Netscape are Copyright (C) 1999 Netscape
17
* Communications Corp. All Rights Reserved.
23
#include "nsISupports.idl"
26
interface nsIMenuItem;
30
// nsIMenuCommandDispatcher
32
// A central manager for registering and unregistering CommandIDs
33
// and their associated content node in the DOM.
36
[scriptable, uuid(d1969b7e-1dd1-11b2-a442-c5a01ae643d1)]
37
interface nsIMenuCommandDispatcher : nsISupports
39
// Given a menu item, creates a unique 4-character command ID and
40
// maps it to the item. Returns the id for use by the client.
41
unsigned long Register ( in nsIMenuItem aItem ) ;
43
// Removes the mapping between the given 4-character command ID
44
// and its associated menu item.
45
void Unregister ( in unsigned long aCommandID ) ;
47
}; // nsIMenuCommandDispatcher