operator rename
authorCampbell Barton <ideasman42@gmail.com>
Thu, 9 Jul 2009 08:39:58 +0000 (08:39 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Thu, 9 Jul 2009 08:39:58 +0000 (08:39 +0000)
VIEW3D_OT_viewhome  ->  VIEW3D_OT_view_all
VIEW3D_OT_viewcenter  ->  VIEW3D_OT_view_center
VIEW3D_OT_clipping  ->  VIEW3D_OT_clip_border

source/blender/editors/space_view3d/view3d_edit.c
source/blender/editors/space_view3d/view3d_header.c
source/blender/editors/space_view3d/view3d_intern.h
source/blender/editors/space_view3d/view3d_ops.c

index 7880e588767dbfccc3ea8e16de0479df4c435686..bd89bd519f30c465ac935eaf62c2503332542b66 100644 (file)
@@ -910,12 +910,12 @@ static int viewhome_exec(bContext *C, wmOperator *op) /* was view3d_home() in 2.
        return OPERATOR_FINISHED;
 }
 
-void VIEW3D_OT_viewhome(wmOperatorType *ot)
+void VIEW3D_OT_view_all(wmOperatorType *ot)
 {
        /* identifiers */
        ot->name= "View home";
        ot->description = "View all objects in scene.";
-       ot->idname= "VIEW3D_OT_viewhome";
+       ot->idname= "VIEW3D_OT_view_all";
 
        /* api callbacks */
        ot->exec= viewhome_exec;
@@ -1048,13 +1048,13 @@ static int viewcenter_exec(bContext *C, wmOperator *op) /* like a localview with
        return OPERATOR_FINISHED;
 }
 
-void VIEW3D_OT_viewcenter(wmOperatorType *ot)
+void VIEW3D_OT_view_center(wmOperatorType *ot)
 {
 
        /* identifiers */
        ot->name= "View center";
        ot->description = "Move the view to the selection center.";
-       ot->idname= "VIEW3D_OT_viewcenter";
+       ot->idname= "VIEW3D_OT_view_center";
 
        /* api callbacks */
        ot->exec= viewcenter_exec;
@@ -1711,13 +1711,13 @@ static int view3d_clipping_invoke(bContext *C, wmOperator *op, wmEvent *event)
 }
 
 /* toggles */
-void VIEW3D_OT_clipping(wmOperatorType *ot)
+void VIEW3D_OT_clip_border(wmOperatorType *ot)
 {
 
        /* identifiers */
        ot->name= "Clipping Border";
        ot->description = "Set the view clipping border.";
-       ot->idname= "VIEW3D_OT_clipping";
+       ot->idname= "VIEW3D_OT_clip_border";
 
        /* api callbacks */
        ot->invoke= view3d_clipping_invoke;
index d5ec5e10b947716e39b2c849d137c01c896331ed..d23b47092bf9c1dd4cc7e3e6edd0e20c98e8ae83 100644 (file)
@@ -517,7 +517,7 @@ static void do_view3d_view_alignviewmenu(bContext *C, void *arg, int event)
 // XXX         mainqenter(PADASTERKEY, 1);
                break;
        case 6: /* Center View and Cursor to Origin */
-               WM_operator_name_call(C, "VIEW3D_OT_viewcenter", WM_OP_EXEC_REGION_WIN, NULL);
+               WM_operator_name_call(C, "VIEW3D_OT_view_center", WM_OP_EXEC_REGION_WIN, NULL);
                curs= give_cursor(scene, v3d);
                curs[0]=curs[1]=curs[2]= 0.0;
                break;
@@ -583,10 +583,10 @@ static void do_view3d_viewmenu(bContext *C, void *arg, int event)
        case 8: /* Global View */
                break;
        case 9: /* View All (Home) */
-               WM_operator_name_call(C, "VIEW3D_OT_viewhome", WM_OP_EXEC_REGION_WIN, NULL);
+               WM_operator_name_call(C, "VIEW3D_OT_view_all", WM_OP_EXEC_REGION_WIN, NULL);
                break;
        case 11: /* View Selected */
-               WM_operator_name_call(C, "VIEW3D_OT_viewcenter", WM_OP_EXEC_REGION_WIN, NULL);
+               WM_operator_name_call(C, "VIEW3D_OT_view_center", WM_OP_EXEC_REGION_WIN, NULL);
                break;
        case 13: /* Play Back Animation */
                break;
@@ -597,7 +597,7 @@ static void do_view3d_viewmenu(bContext *C, void *arg, int event)
 //             add_blockhandler(sa, VIEW3D_HANDLER_PROPERTIES, UI_PNL_UNSTOW);
                break;
        case 17: /* Set Clipping Border */
-               WM_operator_name_call(C, "VIEW3D_OT_clipping", WM_OP_INVOKE_REGION_WIN, NULL);
+               WM_operator_name_call(C, "VIEW3D_OT_clip_border", WM_OP_INVOKE_REGION_WIN, NULL);
                break;
        case 18: /* render preview */
 //             toggle_blockhandler(sa, VIEW3D_HANDLER_PREVIEW, 0);
@@ -685,13 +685,13 @@ static void view3d_viewmenu(bContext *C, uiLayout *layout, void *arg_unused)
 
        uiLayoutSetOperatorContext(layout, WM_OP_INVOKE_REGION_WIN);    
 
-       uiItemO(layout, NULL, 0, "VIEW3D_OT_clipping");
+       uiItemO(layout, NULL, 0, "VIEW3D_OT_clip_border");
        uiItemO(layout, NULL, 0, "VIEW3D_OT_zoom_border");
        
        uiItemS(layout);
        
-       uiItemO(layout, NULL, 0, "VIEW3D_OT_viewcenter");
-       uiItemO(layout, NULL, 0, "VIEW3D_OT_viewhome");
+       uiItemO(layout, NULL, 0, "VIEW3D_OT_view_center");
+       uiItemO(layout, NULL, 0, "VIEW3D_OT_view_all");
        
        uiItemS(layout);
        
@@ -4250,7 +4250,7 @@ static void do_view3d_header_buttons(bContext *C, void *arg, int event)
 
        switch(event) {
        case B_HOME:
-               WM_operator_name_call(C, "VIEW3D_OT_viewhome", WM_OP_EXEC_REGION_WIN, NULL);
+               WM_operator_name_call(C, "VIEW3D_OT_view_all", WM_OP_EXEC_REGION_WIN, NULL);
                break;
        case B_REDR:
                ED_area_tag_redraw(sa);
index 236f9b0904a35e8e01f70049cec07eab44a12a2d..3e9382509f4ca9d15fe2e8be2fb098ca5df822d3 100644 (file)
@@ -68,13 +68,13 @@ void view3d_keymap(struct wmWindowManager *wm);
 void VIEW3D_OT_zoom(struct wmOperatorType *ot);
 void VIEW3D_OT_viewmove(struct wmOperatorType *ot);
 void VIEW3D_OT_viewrotate(struct wmOperatorType *ot);
-void VIEW3D_OT_viewhome(struct wmOperatorType *ot);
+void VIEW3D_OT_view_all(struct wmOperatorType *ot);
 void VIEW3D_OT_viewnumpad(struct wmOperatorType *ot);
-void VIEW3D_OT_viewcenter(struct wmOperatorType *ot);
+void VIEW3D_OT_view_center(struct wmOperatorType *ot);
 void VIEW3D_OT_view_pan(struct wmOperatorType *ot);
 void VIEW3D_OT_view_persportho(struct wmOperatorType *ot);
 void VIEW3D_OT_view_orbit(struct wmOperatorType *ot);
-void VIEW3D_OT_clipping(struct wmOperatorType *ot);
+void VIEW3D_OT_clip_border(struct wmOperatorType *ot);
 void VIEW3D_OT_cursor3d(struct wmOperatorType *ot);
 void VIEW3D_OT_manipulator(struct wmOperatorType *ot);
 void VIEW3D_OT_render_border(struct wmOperatorType *ot);
index eb0fbabeeedc7dc929903adea2020920e943ab3b..70dde48101818c64de3cbc129d09b5314df28d62 100644 (file)
@@ -65,15 +65,15 @@ void view3d_operatortypes(void)
        WM_operatortype_append(VIEW3D_OT_viewrotate);
        WM_operatortype_append(VIEW3D_OT_viewmove);
        WM_operatortype_append(VIEW3D_OT_zoom);
-       WM_operatortype_append(VIEW3D_OT_viewhome);
+       WM_operatortype_append(VIEW3D_OT_view_all);
        WM_operatortype_append(VIEW3D_OT_viewnumpad);
        WM_operatortype_append(VIEW3D_OT_view_orbit);
        WM_operatortype_append(VIEW3D_OT_view_pan);
        WM_operatortype_append(VIEW3D_OT_view_persportho);
-       WM_operatortype_append(VIEW3D_OT_viewcenter);
+       WM_operatortype_append(VIEW3D_OT_view_center);
        WM_operatortype_append(VIEW3D_OT_select);
        WM_operatortype_append(VIEW3D_OT_select_border);
-       WM_operatortype_append(VIEW3D_OT_clipping);
+       WM_operatortype_append(VIEW3D_OT_clip_border);
        WM_operatortype_append(VIEW3D_OT_select_circle);
        WM_operatortype_append(VIEW3D_OT_smoothview);
        WM_operatortype_append(VIEW3D_OT_render_border);
@@ -141,7 +141,7 @@ void view3d_keymap(wmWindowManager *wm)
        WM_keymap_verify_item(keymap, "VIEW3D_OT_viewrotate", MIDDLEMOUSE, KM_PRESS, 0, 0);
        WM_keymap_verify_item(keymap, "VIEW3D_OT_viewmove", MIDDLEMOUSE, KM_PRESS, KM_SHIFT, 0);
        WM_keymap_verify_item(keymap, "VIEW3D_OT_zoom", MIDDLEMOUSE, KM_PRESS, KM_CTRL, 0);
-       WM_keymap_verify_item(keymap, "VIEW3D_OT_viewcenter", PADPERIOD, KM_PRESS, 0, 0);
+       WM_keymap_verify_item(keymap, "VIEW3D_OT_view_center", PADPERIOD, KM_PRESS, 0, 0);
        
        WM_keymap_verify_item(keymap, "VIEW3D_OT_smoothview", TIMER1, KM_ANY, KM_ANY, 0);
        
@@ -150,8 +150,8 @@ void view3d_keymap(wmWindowManager *wm)
        RNA_int_set(WM_keymap_add_item(keymap, "VIEW3D_OT_zoom", WHEELINMOUSE, KM_PRESS, 0, 0)->ptr, "delta", 1);
        RNA_int_set(WM_keymap_add_item(keymap, "VIEW3D_OT_zoom", WHEELOUTMOUSE, KM_PRESS, 0, 0)->ptr, "delta", -1);
 
-       RNA_boolean_set(WM_keymap_add_item(keymap, "VIEW3D_OT_viewhome", HOMEKEY, KM_PRESS, 0, 0)->ptr, "center", 0);
-       RNA_boolean_set(WM_keymap_add_item(keymap, "VIEW3D_OT_viewhome", CKEY, KM_PRESS, KM_SHIFT, 0)->ptr, "center", 1);
+       RNA_boolean_set(WM_keymap_add_item(keymap, "VIEW3D_OT_view_all", HOMEKEY, KM_PRESS, 0, 0)->ptr, "center", 0);
+       RNA_boolean_set(WM_keymap_add_item(keymap, "VIEW3D_OT_view_all", CKEY, KM_PRESS, KM_SHIFT, 0)->ptr, "center", 1);
 
        /* numpad view hotkeys*/
        RNA_enum_set(WM_keymap_add_item(keymap, "VIEW3D_OT_viewnumpad", PAD0, KM_PRESS, 0, 0)->ptr, "type", V3D_VIEW_CAMERA);
@@ -209,7 +209,7 @@ void view3d_keymap(wmWindowManager *wm)
        RNA_enum_set(WM_keymap_add_item(keymap, "VIEW3D_OT_select_lasso", EVT_TWEAK_A, KM_ANY, KM_SHIFT|KM_CTRL, 0)->ptr, "type", 1);
        WM_keymap_add_item(keymap, "VIEW3D_OT_select_circle", CKEY, KM_PRESS, 0, 0);
        
-       WM_keymap_add_item(keymap, "VIEW3D_OT_clipping", BKEY, KM_PRESS, KM_ALT, 0);
+       WM_keymap_add_item(keymap, "VIEW3D_OT_clip_border", BKEY, KM_PRESS, KM_ALT, 0);
        WM_keymap_add_item(keymap, "VIEW3D_OT_zoom_border", BKEY, KM_PRESS, KM_SHIFT, 0);
        WM_keymap_add_item(keymap, "VIEW3D_OT_render_border", BKEY, KM_PRESS, KM_SHIFT, 0);