sbIPlaylistCommandsBuilder.idl
Go to the documentation of this file.
1 /*
2  *=BEGIN SONGBIRD GPL
3  *
4  * This file is part of the Songbird web player.
5  *
6  * Copyright(c) 2005-2010 POTI, Inc.
7  * http://www.songbirdnest.com
8  *
9  * This file may be licensed under the terms of of the
10  * GNU General Public License Version 2 (the ``GPL'').
11  *
12  * Software distributed under the License is distributed
13  * on an ``AS IS'' basis, WITHOUT WARRANTY OF ANY KIND, either
14  * express or implied. See the GPL for the specific language
15  * governing rights and limitations.
16  *
17  * You should have received a copy of the GPL along with this
18  * program. If not, go to http://www.gnu.org/licenses/gpl.html
19  * or write to the Free Software Foundation, Inc.,
20  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
21  *
22  *=END SONGBIRD GPL
23  */
24 
25 #include "nsISupports.idl"
26 #include "sbIPlaylistCommands.idl"
27 
28 interface nsIDOMNode;
29 interface nsIDOMDocument;
37 
42 // ----------------------------------------------------------------------------
43 
112 [scriptable, uuid(cc8b8082-1dd1-11b2-a707-e1fb775c0d9b)]
114 {
122  void init(in AString aId);
123 
134  void appendSubmenu(in AString aParentSubMenuId,
135  in AString aSubMenuId,
136  in AString aLabel,
137  in AString aTooltipText);
138 
149  void insertSubmenuBefore(in AString aParentSubMenuId,
150  in AString aBeforeId,
151  in AString aSubMenuId,
152  in AString aLabel,
153  in AString aTooltipText);
154 
165  void insertSubmenuAfter(in AString aParentSubMenuId,
166  in AString aAfterId,
167  in AString aSubMenuId,
168  in AString aLabel,
169  in AString aTooltipText);
170 
171  // --------------------------------------------------------------------------
172 
185  void appendAction(in AString aParentSubMenuId,
186  in AString aActionId,
187  in AString aLabel,
188  in AString aTooltipText,
189  in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback);
190 
202  void insertActionBefore(in AString aParentSubMenuId,
203  in AString aBeforeId,
204  in AString aActionId,
205  in AString aLabel,
206  in AString aTooltipText,
207  in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback);
208 
220  void insertActionAfter(in AString aParentSubMenuId,
221  in AString aAfterId,
222  in AString aActionId,
223  in AString aLabel,
224  in AString aTooltipText,
225  in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback);
226 
227  // --------------------------------------------------------------------------
228 
238  void appendSeparator(in AString aParentSubMenuId,
239  in AString aSeparatorId);
240 
249  void insertSeparatorBefore(in AString aParentSubMenuId,
250  in AString aBeforeId,
251  in AString aSeparatorId);
252 
261  void insertSeparatorAfter(in AString aParentSubMenuId,
262  in AString aAfterId,
263  in AString aSeparatorId);
264 
265  // --------------------------------------------------------------------------
266 
278  void appendFlag(in AString aParentSubMenuId,
279  in AString aFlagId,
280  in AString aLabel,
281  in AString aTooltipText,
282  in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback,
284 
297  void insertFlagBefore(in AString aParentSubMenuId,
298  in AString aBeforeId,
299  in AString aCommandId,
300  in AString aLabel,
301  in AString aTooltipText,
302  in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback,
303  in sbIPlaylistCommandsBuilderGetBoolCallback aGetValueCallback);
304 
317  void insertFlagAfter(in AString aParentSubMenuId,
318  in AString aAfterId,
319  in AString aCommandId,
320  in AString aLabel,
321  in AString aTooltipText,
322  in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback,
323  in sbIPlaylistCommandsBuilderGetBoolCallback aGetValueCallback);
324 
325  // --------------------------------------------------------------------------
326 
338  void appendValue(in AString aParentSubMenuId,
339  in AString aValueId,
340  in AString aLabel,
341  in AString aTooltipText,
342  in sbIPlaylistCommandsBuilderSetValueCallback aSetValueCallback,
343  in sbIPlaylistCommandsBuilderGetStringCallback aGetValueCallback);
344 
357  void insertValueBefore(in AString aParentSubMenuId,
358  in AString aBeforeId,
359  in AString aValueId,
360  in AString aLabel,
361  in AString aTooltipText,
362  in sbIPlaylistCommandsBuilderSetValueCallback aSetValueCallback,
363  in sbIPlaylistCommandsBuilderGetStringCallback aGetValueCallback);
364 
377  void insertValueAfter(in AString aParentSubMenuId,
378  in AString aAfterId,
379  in AString aValueId,
380  in AString aLabel,
381  in AString aTooltipText,
382  in sbIPlaylistCommandsBuilderSetValueCallback aSetValueCallback,
383  in sbIPlaylistCommandsBuilderGetStringCallback aGetValueCallback);
384 
385  // --------------------------------------------------------------------------
386 
397  void appendChoiceMenu(in AString aParentSubMenuId,
398  in AString aChoiceMenuId,
399  in AString aLabel,
400  in AString aTooltipText,
402 
414  void insertChoiceMenuBefore(in AString aParentSubMenuId,
415  in AString aBeforeId,
416  in AString aChoiceMenuId,
417  in AString aLabel,
418  in AString aTooltipText,
420 
432  void insertChoiceMenuAfter(in AString aParentSubMenuId,
433  in AString aAfterId,
434  in AString aChoiceMenuId,
435  in AString aLabel,
436  in AString aTooltipText,
438 
439  // --------------------------------------------------------------------------
440 
451  void appendChoiceMenuItem(in AString aParentSubMenuId,
452  in AString aChoiceMenuItemId,
453  in AString aLabel,
454  in AString aTooltipText,
455  in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback);
456 
468  void insertChoiceMenuItemBefore(in AString aParentSubMenuId,
469  in AString aBeforeId,
470  in AString aCommandId,
471  in AString aLabel,
472  in AString aTooltipText,
473  in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback);
474 
486  void insertChoiceMenuItemAfter(in AString aParentSubMenuId,
487  in AString aAfterId,
488  in AString aCommandId,
489  in AString aLabel,
490  in AString aTooltipText,
491  in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback);
492 
493  // --------------------------------------------------------------------------
494 
504  void appendCustomItem(in AString aParentSubMenuId,
505  in AString aCustomItemId,
506  in sbIPlaylistCommandsBuilderInstantiationCallback aInstantiationCallback,
507  in sbIPlaylistCommandsBuilderRefreshCallback aRefreshCallback);
508 
519  void insertCustomItemBefore(in AString aParentSubMenuId,
520  in AString aBeforeId,
521  in AString aCustomItemId,
522  in sbIPlaylistCommandsBuilderInstantiationCallback aInstantiationCallback,
523  in sbIPlaylistCommandsBuilderRefreshCallback aRefreshCallback);
524 
535  void insertCustomItemAfter(in AString aParentSubMenuId,
536  in AString aAfterId,
537  in AString aCustomItemId,
538  in sbIPlaylistCommandsBuilderInstantiationCallback aInstantiationCallback,
539  in sbIPlaylistCommandsBuilderRefreshCallback aRefreshCallback);
540 
541  // --------------------------------------------------------------------------
542 
553  void appendPlaylistCommands(in AString aParentSubMenuId,
554  in AString aCommandsId,
555  in sbIPlaylistCommands aPlaylistCommands);
556 
566  void insertPlaylistCommandsBefore(in AString aParentSubMenuId,
567  in AString aBeforeId,
568  in AString aCommandsId,
569  in sbIPlaylistCommands aPlaylistCommands);
570 
580  void insertPlaylistCommandsAfter(in AString aParentSubMenuId,
581  in AString aAfterId,
582  in AString aCommandsId,
583  in sbIPlaylistCommands aPlaylistCommands);
584 
585  // --------------------------------------------------------------------------
586 
598  void setCommandShortcut(in AString aParentSubMenuId,
599  in AString aCommandId,
600  in AString aShortcutKey,
601  in AString aShortcutKeyCode,
602  in AString aShortcutModifiers,
603  in PRBool aShortcutIsLocal);
604 
615  void setCommandEnabledCallback(in AString aParentSubMenuId,
616  in AString aCommandId,
617  in sbIPlaylistCommandsBuilderGetBoolCallback aEnabledCallback);
618 
628  void setCommandVisibleCallback(in AString aParentSubMenuId,
629  in AString aCommandId,
630  in sbIPlaylistCommandsBuilderGetBoolCallback aVisibleCallback);
631 
639 
647 
656 
664  void removeCommand(in AString aParentSubMenuId,
665  in AString aCommandId);
666 
672  void removeAllCommands([optional] in AString aParentSubMenuId);
673 
679  void shutdown();
680 };
681 
682 // ----------------------------------------------------------------------------
683 
689 [scriptable, uuid(c68a8813-7df9-41f4-888c-30f8a63cef60)]
691 {
696 };
697 
707 [scriptable, function, uuid(d93a113b-348a-4050-8c03-3806228f9293)]
709 {
719  in AString aSubMenuId,
720  in AString aCommandId,
721  in AString aHost);
722 };
723 
733 [scriptable, function, uuid(2474bfcf-bf50-4f27-b76e-b2472a126c08)]
735 {
747  in AString aSubMenuId,
748  in AString aCommandId,
749  in AString aHost,
750  in AString aData);
751 };
752 
762 [scriptable, function, uuid(68dde54c-5157-4650-addd-79ad331cf9ee)]
764 {
776  in AString aSubMenuId,
777  in AString aCommandId,
778  in AString aHost,
779  in AString aData);
780 };
781 
791 [scriptable, function, uuid(24b5f0d8-424f-43ee-8f97-4efbfad6500f)]
793 {
804  in AString aSubMenuId,
805  in AString aCommandId,
806  in AString aHost,
807  in AString aValue);
808 };
809 
819 [scriptable, function, uuid(fb4694de-ba89-4097-843b-a00091cc430b)]
821 {
832  nsIDOMNode handleCallback(in sbIPlaylistCommandsBuilderContext aContext,
833  in AString aSubMenuId,
834  in AString aCommandId,
835  in AString aHost,
836  in nsIDOMDocument aParentDocument);
837 };
838 
848 [scriptable, function, uuid(d5f091e8-9b14-47f5-bf48-0f64c9d23a0a)]
850 {
861  in AString aSubMenuId,
862  in AString aCommandId,
863  in AString aHost,
864  in nsIDOMNode aElement);
865 };
866 
876 [scriptable, function, uuid(9f578767-7f92-486d-b0a9-f760ff6e22d0)]
878 {
888  in AString aHost,
889  in AString aData);
890 };
891 
892  // end of playlistcommands group
894 
895 
void insertActionAfter(in AString aParentSubMenuId, in AString aAfterId, in AString aActionId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback)
Insert an action into the set of commands.
A helper used to construct sbIPlaylistCommands interfaces.
void insertChoiceMenuItemAfter(in AString aParentSubMenuId, in AString aAfterId, in AString aCommandId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback)
Insert a choicemenuitem into the set of commands.
attribute nsISupports implementorContext
The commands builder implementor context.
void setCommandVisibleCallback(in AString aParentSubMenuId, in AString aCommandId, in sbIPlaylistCommandsBuilderGetBoolCallback aVisibleCallback)
Assign a callback to a command item to dynamically determine its visible status.
onPageChanged aValue
Definition: FeedWriter.js:1395
void insertChoiceMenuItemBefore(in AString aParentSubMenuId, in AString aBeforeId, in AString aCommandId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback)
Insert a choicemenuitem into the set of commands.
void insertValueAfter(in AString aParentSubMenuId, in AString aAfterId, in AString aValueId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSetValueCallback aSetValueCallback, in sbIPlaylistCommandsBuilderGetStringCallback aGetValueCallback)
Insert a value into the set of commands.
void handleCallback(in sbIPlaylistCommandsBuilderContext aContext, in AString aSubMenuId, in AString aCommandId, in AString aHost, in nsIDOMNode aElement)
The callback function.
void setShutdownCallback(in sbIPlaylistCommandsBuilderPCCallback aInitCallback)
Assign a callback to the entire command set to perform shutdown.
AString handleCallback(in sbIPlaylistCommandsBuilderContext aContext, in AString aSubMenuId, in AString aCommandId, in AString aHost, in AString aData)
The callback function.
void appendChoiceMenu(in AString aParentSubMenuId, in AString aChoiceMenuId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderGetStringCallback aItemCallback)
Append a choicemenu to the set of commands.
void handleCallback(in sbIPlaylistCommandsBuilderContext aContext, in AString aSubMenuId, in AString aCommandId, in AString aHost, in AString aValue)
The callback function.
PRBool handleCallback(in sbIPlaylistCommandsBuilderContext aContext, in AString aSubMenuId, in AString aCommandId, in AString aHost, in AString aData)
The callback function.
void insertSeparatorAfter(in AString aParentSubMenuId, in AString aAfterId, in AString aSeparatorId)
Insert a separator into the set of commands.
_updateCookies aHost
void setInitCallback(in sbIPlaylistCommandsBuilderPCCallback aInitCallback)
Assign a callback to the entire command set to perform initialization.
The interface for giving context to playlist builder callbacks.
A callback interface used to receive callbacks from an sbIPlaylistCommandsBuilder object relating to ...
void setVisibleCallback(in sbIPlaylistCommandsBuilderPCCallback aVisibleCallback)
Assign a callback to the entire command set to dynamically determine its visible status (affects all ...
var uuid
void init(in AString aId)
A required initialization method that sets the id of the sbIPlaylistCommands object. A playlist command must have an id to be registered.
A callback interface used to instantiate a custom command DOM element for sbIPlaylistCommandsBuilder ...
void insertActionBefore(in AString aParentSubMenuId, in AString aBeforeId, in AString aActionId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback)
Insert an action into the set of commands.
nsIDOMNode handleCallback(in sbIPlaylistCommandsBuilderContext aContext, in AString aSubMenuId, in AString aCommandId, in AString aHost, in nsIDOMDocument aParentDocument)
The callback function.
void appendFlag(in AString aParentSubMenuId, in AString aFlagId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback, in sbIPlaylistCommandsBuilderGetBoolCallback aValueCallback)
Append a flag to the set of commands.
void appendSubmenu(in AString aParentSubMenuId, in AString aSubMenuId, in AString aLabel, in AString aTooltipText)
Append a submenu to the set of commands.
void handleCallback(in sbIPlaylistCommandsBuilderContext aContext, in AString aSubMenuId, in AString aCommandId, in AString aHost)
The callback function.
An interface used to receive generic callbacks from an sbIPlaylistCommandsBuilder object...
function d(s)
void insertChoiceMenuBefore(in AString aParentSubMenuId, in AString aBeforeId, in AString aChoiceMenuId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderGetStringCallback aItemCallback)
Insert a choicemenu into the set of commands.
An interface used to receive callbacks from an sbIPlaylistCommandsBuilder object when a string value ...
void removeAllCommands([optional] in AString aParentSubMenuId)
Remove all commands from the set.
A callback interface used to refresh a custom command DOM element for sbIPlaylistCommandsBuilder obje...
PRBool handleCallback(in sbIPlaylistCommandsBuilderContext aContext, in AString aHost, in AString aData)
The callback function.
An interface that represents the set of command buttons and context menu items available on a display...
void insertValueBefore(in AString aParentSubMenuId, in AString aBeforeId, in AString aValueId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSetValueCallback aSetValueCallback, in sbIPlaylistCommandsBuilderGetStringCallback aGetValueCallback)
Insert a value into the set of commands.
void insertCustomItemBefore(in AString aParentSubMenuId, in AString aBeforeId, in AString aCustomItemId, in sbIPlaylistCommandsBuilderInstantiationCallback aInstantiationCallback, in sbIPlaylistCommandsBuilderRefreshCallback aRefreshCallback)
Insert a customitem into the set of commands.
void insertPlaylistCommandsBefore(in AString aParentSubMenuId, in AString aBeforeId, in AString aCommandsId, in sbIPlaylistCommands aPlaylistCommands)
Insert an existing set of commands into this set of commands.
void insertCustomItemAfter(in AString aParentSubMenuId, in AString aAfterId, in AString aCustomItemId, in sbIPlaylistCommandsBuilderInstantiationCallback aInstantiationCallback, in sbIPlaylistCommandsBuilderRefreshCallback aRefreshCallback)
Insert a customitem into the set of commands.
void insertFlagAfter(in AString aParentSubMenuId, in AString aAfterId, in AString aCommandId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback, in sbIPlaylistCommandsBuilderGetBoolCallback aGetValueCallback)
Insert a flag into the set of commands.
void insertChoiceMenuAfter(in AString aParentSubMenuId, in AString aAfterId, in AString aChoiceMenuId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderGetStringCallback aItemCallback)
Insert a choicemenu into the set of commands.
void removeCommand(in AString aParentSubMenuId, in AString aCommandId)
Remove a command from the set.
void appendPlaylistCommands(in AString aParentSubMenuId, in AString aCommandsId, in sbIPlaylistCommands aPlaylistCommands)
Append an existing set of commands to this set of commands.
The interface for giving context to a playlistcommands object.
void appendAction(in AString aParentSubMenuId, in AString aActionId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback)
Append an action to the set of commands.
void setCommandEnabledCallback(in AString aParentSubMenuId, in AString aCommandId, in sbIPlaylistCommandsBuilderGetBoolCallback aEnabledCallback)
Assign a callback to a command item to dynamically determine its enabled status.
void appendCustomItem(in AString aParentSubMenuId, in AString aCustomItemId, in sbIPlaylistCommandsBuilderInstantiationCallback aInstantiationCallback, in sbIPlaylistCommandsBuilderRefreshCallback aRefreshCallback)
Append a customitem to the set of commands.
void shutdown()
Shutdown the builder object, ensure that no external reference remains in its internal arrays...
void appendValue(in AString aParentSubMenuId, in AString aValueId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSetValueCallback aSetValueCallback, in sbIPlaylistCommandsBuilderGetStringCallback aGetValueCallback)
Append a value to the set of commands.
void setCommandShortcut(in AString aParentSubMenuId, in AString aCommandId, in AString aShortcutKey, in AString aShortcutKeyCode, in AString aShortcutModifiers, in PRBool aShortcutIsLocal)
Assign a keyboard shortcut to a command item.
void insertPlaylistCommandsAfter(in AString aParentSubMenuId, in AString aAfterId, in AString aCommandsId, in sbIPlaylistCommands aPlaylistCommands)
Insert an existing set of commands into this set of commands.
void insertSubmenuBefore(in AString aParentSubMenuId, in AString aBeforeId, in AString aSubMenuId, in AString aLabel, in AString aTooltipText)
Insert a submenu into the set of commands.
void insertSubmenuAfter(in AString aParentSubMenuId, in AString aAfterId, in AString aSubMenuId, in AString aLabel, in AString aTooltipText)
Insert a submenu into the set of commands.
An interface used to receive callbacks from an sbIPlaylistCommandsBuilder object when a boolean value...
void insertFlagBefore(in AString aParentSubMenuId, in AString aBeforeId, in AString aCommandId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback, in sbIPlaylistCommandsBuilderGetBoolCallback aGetValueCallback)
Insert a flag into the set of commands.
void appendSeparator(in AString aParentSubMenuId, in AString aSeparatorId)
Append a separator to the set of commands.
A callback interface used to receive a string value from an sbIPlaylistCommandsBuilder object...
void appendChoiceMenuItem(in AString aParentSubMenuId, in AString aChoiceMenuItemId, in AString aLabel, in AString aTooltipText, in sbIPlaylistCommandsBuilderSimpleCallback aTriggerCallback)
Append a choicemenuitem to the set of commands.
_updateTextAndScrollDataForFrame aData
void insertSeparatorBefore(in AString aParentSubMenuId, in AString aBeforeId, in AString aSeparatorId)
Insert a separator into the set of commands.