Changed page browsing keyboard shortcuts to make it possible to browse through files and pages without moving any hands.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@5383 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -267,10 +267,10 @@ ShowImageWindow::LoadMenus(BMenuBar *pbar)
|
|||||||
pbar->AddItem(pmenu);
|
pbar->AddItem(pmenu);
|
||||||
|
|
||||||
pmenu = fpBrowseMenu = new BMenu("Browse");
|
pmenu = fpBrowseMenu = new BMenu("Browse");
|
||||||
AddItemMenu(pmenu, "First Page", MSG_PAGE_FIRST, 'F', 0, 'W', true);
|
AddItemMenu(pmenu, "First Page", MSG_PAGE_FIRST, B_LEFT_ARROW, B_SHIFT_KEY, 'W', true);
|
||||||
AddItemMenu(pmenu, "Last Page", MSG_PAGE_LAST, 'L', 0, 'W', true);
|
AddItemMenu(pmenu, "Last Page", MSG_PAGE_LAST, B_RIGHT_ARROW, B_SHIFT_KEY, 'W', true);
|
||||||
AddItemMenu(pmenu, "Next Page", MSG_PAGE_NEXT, 'N', 0, 'W', true);
|
AddItemMenu(pmenu, "Next Page", MSG_PAGE_NEXT, B_RIGHT_ARROW, 0, 'W', true);
|
||||||
AddItemMenu(pmenu, "Previous Page", MSG_PAGE_PREV, 'P', 0, 'W', true);
|
AddItemMenu(pmenu, "Previous Page", MSG_PAGE_PREV, B_LEFT_ARROW, 0, 'W', true);
|
||||||
fpGoToPageMenu = new BMenu("Go To Page");
|
fpGoToPageMenu = new BMenu("Go To Page");
|
||||||
pmenu->AddItem(fpGoToPageMenu);
|
pmenu->AddItem(fpGoToPageMenu);
|
||||||
pmenu->AddSeparatorItem();
|
pmenu->AddSeparatorItem();
|
||||||
@@ -281,8 +281,8 @@ ShowImageWindow::LoadMenus(BMenuBar *pbar)
|
|||||||
pmenu = new BMenu("Image");
|
pmenu = new BMenu("Image");
|
||||||
AddItemMenu(pmenu, "Dither Image", MSG_DITHER_IMAGE, 0, 0, 'W', true);
|
AddItemMenu(pmenu, "Dither Image", MSG_DITHER_IMAGE, 0, 0, 'W', true);
|
||||||
pmenu->AddSeparatorItem();
|
pmenu->AddSeparatorItem();
|
||||||
AddItemMenu(pmenu, "Rotate Clockwise", MSG_ROTATE_CLOCKWISE, B_RIGHT_ARROW, 0, 'W', true);
|
AddItemMenu(pmenu, "Rotate Clockwise", MSG_ROTATE_CLOCKWISE, ']', 0, 'W', true);
|
||||||
AddItemMenu(pmenu, "Rotate Anticlockwise", MSG_ROTATE_ACLKWISE, B_LEFT_ARROW, 0, 'W', true);
|
AddItemMenu(pmenu, "Rotate Anticlockwise", MSG_ROTATE_ACLKWISE, '[', 0, 'W', true);
|
||||||
pmenu->AddSeparatorItem();
|
pmenu->AddSeparatorItem();
|
||||||
AddItemMenu(pmenu, "Mirror Vertical", MSG_MIRROR_VERTICAL, 0, 0, 'W', true);
|
AddItemMenu(pmenu, "Mirror Vertical", MSG_MIRROR_VERTICAL, 0, 0, 'W', true);
|
||||||
AddItemMenu(pmenu, "Mirror Horizontal", MSG_MIRROR_HORIZONTAL, 0, 0, 'W', true);
|
AddItemMenu(pmenu, "Mirror Horizontal", MSG_MIRROR_HORIZONTAL, 0, 0, 'W', true);
|
||||||
@@ -302,7 +302,7 @@ ShowImageWindow::AddItemMenu(BMenu *pmenu, char *caption, long unsigned int msg,
|
|||||||
char shortcut, uint32 modifier, char target, bool benabled)
|
char shortcut, uint32 modifier, char target, bool benabled)
|
||||||
{
|
{
|
||||||
BMenuItem* pitem;
|
BMenuItem* pitem;
|
||||||
pitem = new BMenuItem(caption, new BMessage(msg), shortcut);
|
pitem = new BMenuItem(caption, new BMessage(msg), shortcut, modifier);
|
||||||
|
|
||||||
if (target == 'A')
|
if (target == 'A')
|
||||||
pitem->SetTarget(be_app);
|
pitem->SetTarget(be_app);
|
||||||
|
|||||||
Reference in New Issue
Block a user