Removed the "Block/Write" menu item, and introduced new "Save" menu items;

they are not yet working, though.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6756 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler
2004-02-26 12:54:51 +00:00
parent c7a76e9f26
commit 6781cbdc9b
4 changed files with 32 additions and 11 deletions
+17 -5
View File
@@ -969,12 +969,25 @@ ProbeView::UpdateAttributesMenu(BMenu *menu)
void
ProbeView::AddFileMenuItems(BMenu *menu, int32 index)
ProbeView::AddSaveMenuItems(BMenu *menu, int32 index)
{
BMenuItem *item;
menu->AddItem(item = new BMenuItem("Save", new BMessage(B_SAVE_REQUESTED)), index++);
item->SetTarget(this);
item->SetEnabled(false);
//menu->AddItem(new BMenuItem("Save As" B_UTF8_ELLIPSIS, NULL));
}
void
ProbeView::AddPrintMenuItems(BMenu *menu, int32 index)
{
BMenuItem *item;
menu->AddItem(item = new BMenuItem("Page Setup" B_UTF8_ELLIPSIS, NULL), index++);
item->SetTarget(this);
item->SetEnabled(false);
menu->AddItem(item = new BMenuItem("Print" B_UTF8_ELLIPSIS, NULL, 'P', B_COMMAND_KEY), index++);
item->SetTarget(this);
item->SetEnabled(false);
}
@@ -1002,7 +1015,9 @@ ProbeView::AttachedToWindow()
ResizeBy(0, -bar->Bounds().Height());
BMenu *menu = new BMenu(fEditor.IsAttribute() ? "Attribute" : fEditor.IsDevice() ? "Device" : "File");
AddFileMenuItems(menu, 0);
AddSaveMenuItems(menu, 0);
menu->AddSeparatorItem();
AddPrintMenuItems(menu, menu->CountItems());
menu->AddSeparatorItem();
menu->AddItem(new BMenuItem("Close", new BMessage(B_CLOSE_REQUESTED), 'W', B_COMMAND_KEY));
@@ -1058,9 +1073,6 @@ ProbeView::AttachedToWindow()
UpdateSelectionMenuItems(0, 0);
menu->AddSeparatorItem();
menu->AddItem(new BMenuItem("Write", NULL, 'S', B_COMMAND_KEY));
menu->AddSeparatorItem();
subMenu = new BMenu("Bookmarks");
subMenu->AddItem(new BMenuItem("Add", NULL, 'B', B_COMMAND_KEY));
menu->AddItem(new BMenuItem(subMenu));