comparison view/Pane.cpp @ 600:2bf6dc6bc4d1 integration_library

Merge from the default branch
author mathieub <mathieu.barthet@eecs.qmul.ac.uk>
date Mon, 10 Oct 2011 17:19:58 +0100
parents c080d14ff414 2f087d950621
children
comparison
equal deleted inserted replaced
595:c080d14ff414 600:2bf6dc6bc4d1
1236 1236
1237 kr.setCategory(tr("Select Tool Mouse Actions")); 1237 kr.setCategory(tr("Select Tool Mouse Actions"));
1238 kr.registerShortcut(tr("Select"), tr("Left"), 1238 kr.registerShortcut(tr("Select"), tr("Left"),
1239 tr("Click left button and drag to select region; drag region edge to resize")); 1239 tr("Click left button and drag to select region; drag region edge to resize"));
1240 kr.registerShortcut(tr("Multi Select"), tr("Ctrl+Left"), 1240 kr.registerShortcut(tr("Multi Select"), tr("Ctrl+Left"),
1241 #ifdef Q_OS_MAC
1242 tr("Cmd-click left button and drag to select an additional region"));
1243 #else
1241 tr("Ctrl-click left button and drag to select an additional region")); 1244 tr("Ctrl-click left button and drag to select an additional region"));
1245 #endif
1242 kr.registerShortcut(tr("Fine Select"), tr("Shift+Left"), 1246 kr.registerShortcut(tr("Fine Select"), tr("Shift+Left"),
1243 tr("Shift-click left button and drag to select without snapping to items or grid")); 1247 tr("Shift-click left button and drag to select without snapping to items or grid"));
1244 1248
1245 kr.setCategory(tr("Edit Tool Mouse Actions")); 1249 kr.setCategory(tr("Edit Tool Mouse Actions"));
1246 kr.registerShortcut(tr("Move"), tr("Left"), 1250 kr.registerShortcut(tr("Move"), tr("Left"),
2589 if (!hasTopLayerTimeXAxis()) return; 2593 if (!hasTopLayerTimeXAxis()) return;
2590 2594
2591 bool haveSelection = (m_manager && !m_manager->getSelections().empty()); 2595 bool haveSelection = (m_manager && !m_manager->getSelections().empty());
2592 2596
2593 if (haveSelection) { 2597 if (haveSelection) {
2598 #ifdef Q_OS_MAC
2599 if (editable) {
2600 help = tr("Click and drag to select a range; hold Shift to avoid snapping to items; hold Cmd for multi-select; middle-click and drag to navigate");
2601 } else {
2602 help = tr("Click and drag to select a range; hold Cmd for multi-select; middle-click and drag to navigate");
2603 }
2604 #else
2594 if (editable) { 2605 if (editable) {
2595 help = tr("Click and drag to select a range; hold Shift to avoid snapping to items; hold Ctrl for multi-select; middle-click and drag to navigate"); 2606 help = tr("Click and drag to select a range; hold Shift to avoid snapping to items; hold Ctrl for multi-select; middle-click and drag to navigate");
2596 } else { 2607 } else {
2597 help = tr("Click and drag to select a range; hold Ctrl for multi-select; middle-click and drag to navigate"); 2608 help = tr("Click and drag to select a range; hold Ctrl for multi-select; middle-click and drag to navigate");
2598 } 2609 }
2610 #endif
2599 2611
2600 if (pos) { 2612 if (pos) {
2601 bool closeToLeft = false, closeToRight = false; 2613 bool closeToLeft = false, closeToRight = false;
2602 Selection selection = getSelectionAt(pos->x(), closeToLeft, closeToRight); 2614 Selection selection = getSelectionAt(pos->x(), closeToLeft, closeToRight);
2603 if ((closeToLeft || closeToRight) && !(closeToLeft && closeToRight)) { 2615 if ((closeToLeft || closeToRight) && !(closeToLeft && closeToRight)) {