T.R | Title | User | Personal Name | Date | Lines |
---|
2093.1 | | ULTRA::WRAY | John Wray, Secure Systems Development | Sat Jan 20 1990 21:26 | 6 |
| I can't help with the problems you've been experiencing, but an
alternative approach would be to have all the options always on the
menu-bar, but have the privileged ones greyed-out (Sensitive=False)
when the application is invoked by an unprivileged user.
John
|
2093.2 | Still searching??? | TOWNS::RUFFIEUX | | Sat Jan 20 1990 22:23 | 9 |
| re .1
Thanks, I know this is an option. I would still like to know if
anyone has any other ideas...
Thanks,
Chris
|
2093.3 | easy in UIL, declare unmanaged and Manage them later | RTL::OBRYAN | When in doubt, let the user decide. | Sun Jan 21 1990 02:01 | 59 |
|
re:.0
As you've recognized, there are two ways to go here: declare things unmanaged
and manage them as needed, or delay creation until needed.
Let's look at the easiest one to program (the unmanaged approach.) Here is
a sample menu bar declared in UIL
test_MenuBar : menu_bar
{
arguments
{
orientation = DwtOrientationHorizontal;
help_widget = pulldown_entry test_Help_Entry;
};
controls
{
pulldown_entry test_File_Entry;
unmanaged pulldown_entry test_Edit_Entry; !*
unmanaged pulldown_entry test_Customize_Entry; !*
pulldown_entry test_Help_Entry;
};
}; ! test_MenuBar
test_Edit_Entry : pulldown_entry ! The other entries are
{ ! similarly declared
arguments
{
label_label = k_tst_test_Edit_Entry_str;
};
controls
{
pulldown_menu
{
controls
{
push_button test_Cut_Btn;
push_button test_Paste_Btn;
separator gnc_Sep;
push_button test_selall_Btn;
};
};
};
callbacks
{
create = procedure tst_create_proc (k_tst_test_Edit_Entry);
};
}; ! test_Edit_Entry
In the segment of code in which you have determined that the two invisible
Entries need to become visible, simply XtManageChild each of the (saved)
Entry widget ids. This particular approach also has the advantage that the
two mystery Entries will appear positioned in the menu_bar where you desire
them. (Menu_bar places them in the order they were created, with the exception
of the designated "help_widget" which always is positioned last.)
|
2093.4 | Got it.. | TOWNS::RUFFIEUX | | Sun Jan 21 1990 12:15 | 5 |
| re. 3
Thanks alot. That is what I needed!
Chris
|