INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES

indexing

title: "Menu entry class"
project: "Visual Eiffel"
revision: "$Revision: 1.1 $"
copyright: "Copyright (C) 1996-2005 Object Tools Group"
license: "http://visual-eiffel.com/license"
cluster: grape
class MENU_ENTRY
inherit

TILE
rename
make as make_tile
redefine
destroy,
disable,
enable,
init,
set_name
end
creation {NONE}

make
creation

make_context_separator,
make_separator
feature

LITERAL: INTEGER

POPUP: INTEGER

SEPARATOR: INTEGER
feature

make_separator
-- Make a menu item filled with a horizontal separating line

make_context_separator (ctx: INTEGER)

enable
-- enables a previously disabled (grayed) item
-- Item must be added before to a menu.
require
item_is_not_a_separator: not is_separator

disable
-- disables a menu item (gray it), so no commands are generated
-- Separators cannot be disabled
require
item_is_not_a_separator: not is_separator

set_check_mark
-- Set a check mark inside of the menu item
require
item_is_not_a_separator: not is_separator

remove_check_mark
-- UnSet a check mark inside of the menu item
require
item_is_not_a_separator: not is_separator

set_name (new_name: STRING)
-- Changes the name of menu item, assigning to it a new string
require
item_is_not_a_separator: not is_separator

get_type: INTEGER

disabled: BOOLEAN

checked: BOOLEAN

init

destroy

is_separator: BOOLEAN
feature {NONE}

make (a_name: STRING; a_context: INTEGER)
-- Create a new menu item, which will be added later to some menu
end -- class MENU_ENTRY

INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES