compile without python works again
authorCampbell Barton <ideasman42@gmail.com>
Thu, 3 Nov 2011 23:20:54 +0000 (23:20 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Thu, 3 Nov 2011 23:20:54 +0000 (23:20 +0000)
source/blender/editors/interface/interface.c
source/blender/editors/interface/interface_ops.c
source/blender/makesrna/intern/rna_curve.c

index a6316dc0e9ec96e65c7ea005ecf597754504d50a..eff4d1f6397c6056942417602b803bf4ffe6741f 100644 (file)
@@ -2569,10 +2569,12 @@ static uiBut *ui_def_but(uiBlock *block, int type, int retval, const char *str,
        if(block->curlayout)
                ui_layout_add_but(block->curlayout, but);
 
+#ifdef WITH_PYTHON
        /* if the 'UI_OT_editsource' is running, extract the source info from the button  */
        if (UI_editsource_enable_check()) {
                UI_editsource_active_but_test(but);
        }
+#endif
 
        return but;
 }
index 27f94ae8e49ad454e27e7551cd641542f3b2da3a..d420b5c24c3c412f293c5de8d22ab95eb7cf2f88 100644 (file)
@@ -476,6 +476,7 @@ static void UI_OT_reports_to_textblock(wmOperatorType *ot)
        ot->exec= reports_to_text_exec;
 }
 
+#ifdef WITH_PYTHON
 
 /* ------------------------------------------------------------------------- */
 /* EditSource Utility funcs and operator,
@@ -711,6 +712,7 @@ static void UI_OT_editsource(wmOperatorType *ot)
        ot->exec= editsource_exec;
 }
 
+#endif /* WITH_PYTHON */
 
 /* ********************************************************* */
 /* Registration */
@@ -723,6 +725,9 @@ void UI_buttons_operatortypes(void)
        WM_operatortype_append(UI_OT_reset_default_button);
        WM_operatortype_append(UI_OT_copy_to_selected_button);
        WM_operatortype_append(UI_OT_reports_to_textblock); // XXX: temp?
+
+#ifdef WITH_PYTHON
        WM_operatortype_append(UI_OT_editsource);
+#endif
 }
 
index 1f52b0ac149d7bc4c87bb760da9a8e7ef7342e65..93fdc2b21364da9977e6a2642735c67f628506d9 100644 (file)
@@ -268,9 +268,6 @@ static void rna_Curve_active_textbox_index_range(PointerRNA *ptr, int *min, int
 static void rna_Curve_dimension_set(PointerRNA *ptr, int value)
 {
        Curve *cu= (Curve*)ptr->id.data;
-       ListBase *nurbs= BKE_curve_nurbs(cu);
-       Nurb *nu= nurbs->first;
-
        if(value==CU_3D) cu->flag |=  CU_3D;
        else cu->flag &= ~CU_3D;