diff options
Diffstat (limited to 'source/blender/editors/interface/view2d_ops.c')
-rw-r--r-- | source/blender/editors/interface/view2d_ops.c | 38 |
1 files changed, 26 insertions, 12 deletions
diff --git a/source/blender/editors/interface/view2d_ops.c b/source/blender/editors/interface/view2d_ops.c index e84c9196e8b..7476751fecd 100644 --- a/source/blender/editors/interface/view2d_ops.c +++ b/source/blender/editors/interface/view2d_ops.c @@ -15,7 +15,7 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software Foundation, - * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * * The Original Code is Copyright (C) 2008 Blender Foundation. * All rights reserved. @@ -286,7 +286,7 @@ void VIEW2D_OT_pan(wmOperatorType *ot) { /* identifiers */ ot->name= "Pan View"; - ot->description= "Pan the view."; + ot->description= "Pan the view"; ot->idname= "VIEW2D_OT_pan"; /* api callbacks */ @@ -336,7 +336,7 @@ void VIEW2D_OT_scroll_right(wmOperatorType *ot) { /* identifiers */ ot->name= "Scroll Right"; - ot->description= "Scroll the view right."; + ot->description= "Scroll the view right"; ot->idname= "VIEW2D_OT_scroll_right"; /* api callbacks */ @@ -383,7 +383,7 @@ void VIEW2D_OT_scroll_left(wmOperatorType *ot) { /* identifiers */ ot->name= "Scroll Left"; - ot->description= "Scroll the view left."; + ot->description= "Scroll the view left"; ot->idname= "VIEW2D_OT_scroll_left"; /* api callbacks */ @@ -429,7 +429,7 @@ void VIEW2D_OT_scroll_down(wmOperatorType *ot) { /* identifiers */ ot->name= "Scroll Down"; - ot->description= "Scroll the view down."; + ot->description= "Scroll the view down"; ot->idname= "VIEW2D_OT_scroll_down"; /* api callbacks */ @@ -476,7 +476,7 @@ void VIEW2D_OT_scroll_up(wmOperatorType *ot) { /* identifiers */ ot->name= "Scroll Up"; - ot->description= "Scroll the view up."; + ot->description= "Scroll the view up"; ot->idname= "VIEW2D_OT_scroll_up"; /* api callbacks */ @@ -692,7 +692,7 @@ void VIEW2D_OT_zoom_in(wmOperatorType *ot) { /* identifiers */ ot->name= "Zoom In"; - ot->description= "Zoom in the view."; + ot->description= "Zoom in the view"; ot->idname= "VIEW2D_OT_zoom_in"; /* api callbacks */ @@ -748,7 +748,7 @@ void VIEW2D_OT_zoom_out(wmOperatorType *ot) { /* identifiers */ ot->name= "Zoom Out"; - ot->description= "Zoom out the view."; + ot->description= "Zoom out the view"; ot->idname= "VIEW2D_OT_zoom_out"; /* api callbacks */ @@ -1004,7 +1004,7 @@ void VIEW2D_OT_zoom(wmOperatorType *ot) { /* identifiers */ ot->name= "Zoom View"; - ot->description= "Zoom in/out the view."; + ot->description= "Zoom in/out the view"; ot->idname= "VIEW2D_OT_zoom"; /* api callbacks */ @@ -1106,7 +1106,7 @@ void VIEW2D_OT_zoom_border(wmOperatorType *ot) { /* identifiers */ ot->name= "Zoom to Border"; - ot->description= "Zoom in the view to the nearest item contained in the border."; + ot->description= "Zoom in the view to the nearest item contained in the border"; ot->idname= "VIEW2D_OT_zoom_border"; /* api callbacks */ @@ -1472,7 +1472,7 @@ void VIEW2D_OT_scroller_activate(wmOperatorType *ot) { /* identifiers */ ot->name= "Scroller Activate"; - ot->description= "Scroll view by mouse click and drag."; + ot->description= "Scroll view by mouse click and drag"; ot->idname= "VIEW2D_OT_scroller_activate"; /* flags */ @@ -1539,7 +1539,7 @@ void VIEW2D_OT_reset(wmOperatorType *ot) { /* identifiers */ ot->name= "Reset View"; - ot->description= "Reset the view."; + ot->description= "Reset the view"; ot->idname= "VIEW2D_OT_reset"; /* api callbacks */ @@ -1603,6 +1603,18 @@ void UI_view2d_keymap(wmKeyConfig *keyconf) WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_right", WHEELDOWNMOUSE, KM_PRESS, 0, 0); WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_left", WHEELUPMOUSE, KM_PRESS, 0, 0); + /* alternatives for page up/down to scroll */ +#if 0 // XXX disabled, since this causes conflicts with hotkeys in animation editors + /* scroll up/down may fall through to left/right */ + WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_down", PAGEDOWNKEY, KM_PRESS, 0, 0); + WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_up", PAGEUPKEY, KM_PRESS, 0, 0); + WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_right", PAGEDOWNKEY, KM_PRESS, 0, 0); + WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_left", PAGEUPKEY, KM_PRESS, 0, 0); + /* shift for moving view left/right with page up/down */ + WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_right", PAGEDOWNKEY, KM_PRESS, KM_SHIFT, 0); + WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_left", PAGEUPKEY, KM_PRESS, KM_SHIFT, 0); +#endif + /* zoom - drag */ WM_keymap_add_item(keymap, "VIEW2D_OT_zoom", MIDDLEMOUSE, KM_PRESS, KM_CTRL, 0); WM_keymap_add_item(keymap, "VIEW2D_OT_zoom", MOUSEZOOM, 0, 0, 0); @@ -1619,6 +1631,8 @@ void UI_view2d_keymap(wmKeyConfig *keyconf) WM_keymap_add_item(keymap, "VIEW2D_OT_pan", MOUSEPAN, 0, 0, 0); WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_down", WHEELDOWNMOUSE, KM_PRESS, 0, 0); WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_up", WHEELUPMOUSE, KM_PRESS, 0, 0); + WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_down", PAGEDOWNKEY, KM_PRESS, 0, 0); + WM_keymap_add_item(keymap, "VIEW2D_OT_scroll_up", PAGEUPKEY, KM_PRESS, 0, 0); WM_keymap_add_item(keymap, "VIEW2D_OT_zoom", MIDDLEMOUSE, KM_PRESS, KM_CTRL, 0); WM_keymap_add_item(keymap, "VIEW2D_OT_zoom", MOUSEZOOM, 0, 0, 0); WM_keymap_add_item(keymap, "VIEW2D_OT_zoom_out", PADMINUS, KM_PRESS, 0, 0); |