1/* menu.asc -- written by Alexis WILKE for Made to Order Software Corp. (c) 2005-2009 */ 2 3/* 4 5Copyright (c) 2005-2009 Made to Order Software Corp. 6 7Permission is hereby granted, free of charge, to any 8person obtaining a copy of this software and 9associated documentation files (the "Software"), to 10deal in the Software without restriction, including 11without limitation the rights to use, copy, modify, 12merge, publish, distribute, sublicense, and/or sell 13copies of the Software, and to permit persons to whom 14the Software is furnished to do so, subject to the 15following conditions: 16 17The above copyright notice and this permission notice 18shall be included in all copies or substantial 19portions of the Software. 20 21THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF 22ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT 23LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 24FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO 25EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 26LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 27WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 28ARISING FROM, OUT OF OR IN CONNECTION WITH THE 29SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 30SOFTWARE. 31 32*/ 33 34 35intrinsic package Native 36{ 37 dynamic class ContextMenuItem 38 { 39 function ContextMenuItem( 40 caption : String, 41 callback : function(obj : Object, menu_item : ContextMenuItem) : Void, 42 unchecked in var separatorBefore : Boolean, 43 unchecked in var enabled : Boolean, 44 unchecked in var visible : Boolean) : Void; 45 46 function copy(Void) : ContextMenuItem; 47 48 var caption : String; 49 50 var onSelect : function(obj : Object, menu_item : ContextMenuItem) : Void; 51 52 var separatorBefore : Boolean; 53 var enabled : Boolean; 54 var visible : Boolean; 55 } 56 57 class BuildInContextMenuItems 58 { 59 var save : Boolean; 60 var zoom : Boolean; 61 var quality : Boolean; 62 var play : Boolean; 63 var loop : Boolean; 64 var rewind : Boolean; 65 var forward_back : Boolean; 66 var print : Boolean; 67 } 68 69 dynamic class ContextMenu 70 { 71 function ContextMenu(unchecked const var callback : function(item : Object, item_menu : ContextMenu) : Void) : Void; 72 73 function copy(Void) : ContextMenu; 74 function hideBuiltInItems() : Void; 75 76 function onSelect(Void) : Void; 77 78 var buildInItems : BuildInContextMenuItems; 79 var customItems : Array; 80 } 81} 82 83 84