Bugfix #25652
[blender.git] / source / blender / editors / interface / interface_layout.c
index f39a0204dcb1108d69059c948e431c598a4a0bc3..d67946752daff735cc612fdaa4eaa899fc830a70 100644 (file)
@@ -1234,7 +1234,7 @@ void ui_but_add_search(uiBut *but, PointerRNA *ptr, PropertyRNA *prop, PointerRN
                but->hardmax= MAX2(but->hardmax, 256);
                but->rnasearchpoin= *searchptr;
                but->rnasearchprop= searchprop;
-               but->flag |= UI_ICON_LEFT|UI_TEXT_LEFT|UI_BUT_UNDO;
+               but->flag |= UI_ICON_LEFT|UI_TEXT_LEFT;
 
                uiButSetSearchFunc(but, rna_search_cb, but, NULL, NULL);
        }
@@ -2730,4 +2730,12 @@ void uiLayoutOperatorButs(const bContext *C, uiLayout *layout, wmOperator *op,in
                        uiItemL(layout, "No Properties.", ICON_NULL);
                }
        }
+       
+       /* no undo for buttons for operator redo panels */
+       {
+               uiBut *but;
+               
+               for(but= uiLayoutGetBlock(layout)->buttons.first; but; but= but->next)
+                       uiButClearFlag(but, UI_BUT_UNDO);
+       }
 }