Hi Cam, This is a regression, the button is not activating correctly anymore. A CTRL+F now is invisble...
-Ton- ------------------------------------------------------------------------ Ton Roosendaal Blender Foundation [email protected] www.blender.org Blender Institute Entrepotdok 57A 1018AD Amsterdam The Netherlands On 24 Mar, 2013, at 20:08, Campbell Barton wrote: > Revision: 55554 > > http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=55554 > Author: campbellbarton > Date: 2013-03-24 19:08:24 +0000 (Sun, 24 Mar 2013) > Log Message: > ----------- > edit to 55549, replace fake click event with call to uiButActiveOnly(). > also make it more clear args are for rna buttons. > > Modified Paths: > -------------- > trunk/blender/source/blender/editors/include/UI_interface.h > trunk/blender/source/blender/editors/interface/interface_handlers.c > > Modified: trunk/blender/source/blender/editors/include/UI_interface.h > =================================================================== > --- trunk/blender/source/blender/editors/include/UI_interface.h > 2013-03-24 18:59:15 UTC (rev 55553) > +++ trunk/blender/source/blender/editors/include/UI_interface.h > 2013-03-24 19:08:24 UTC (rev 55554) > @@ -643,7 +643,8 @@ > void (*func)(const struct bContext *C, void > *, void *, void *, struct rcti *rect), > void *arg1, void *arg2); > > -void UI_textbutton_activate_event(const struct bContext *C, struct ARegion > *ar, void *basepoin, const char *identifier); > +void UI_textbutton_activate_event(const struct bContext *C, struct ARegion > *ar, > + const void *rna_poin_data, const char > *rna_prop_id); > > void uiButSetFocusOnEnter(struct wmWindow *win, uiBut *but); > > > Modified: trunk/blender/source/blender/editors/interface/interface_handlers.c > =================================================================== > --- trunk/blender/source/blender/editors/interface/interface_handlers.c > 2013-03-24 18:59:15 UTC (rev 55553) > +++ trunk/blender/source/blender/editors/interface/interface_handlers.c > 2013-03-24 19:08:24 UTC (rev 55554) > @@ -7456,18 +7456,20 @@ > WM_event_remove_ui_handler(handlers, ui_handler_popup, > ui_handler_remove_popup, popup, FALSE); > } > > -void UI_textbutton_activate_event(const bContext *C, ARegion *ar, void > *basepoin, const char *identifier) > +void UI_textbutton_activate_event(const bContext *C, ARegion *ar, > + const void *rna_poin_data, const char > *rna_prop_id) > { > uiBlock *block; > - uiBut *but; > + uiBut *but = NULL; > > for (block = ar->uiblocks.first; block; block = block->next) { > for (but = block->buttons.first; but; but = but->next) { > if (but->type == TEX) { > - if (but->rnaprop && but->rnapoin.data == > basepoin) > - if > (strcmp(RNA_property_identifier(but->rnaprop), identifier)==0) > + if (but->rnaprop && but->rnapoin.data == > rna_poin_data) { > + if > (STREQ(RNA_property_identifier(but->rnaprop), rna_prop_id)) { > break; > - > + } > + } > } > } > if (but) > @@ -7475,16 +7477,7 @@ > } > > if (but) { > - wmWindow *win = CTX_wm_window(C); > - wmEvent event; > - > - event = *(win->eventstate); /* XXX huh huh? make api call */ > - event.type = EVT_BUT_OPEN; > - event.val = KM_PRESS; > - event.customdata = but; > - event.customdatafree = FALSE; > - wm_event_add(win, &event); > - > + uiButActiveOnly(C, block, but); > } > } > > > _______________________________________________ > Bf-blender-cvs mailing list > [email protected] > http://lists.blender.org/mailman/listinfo/bf-blender-cvs _______________________________________________ Bf-committers mailing list [email protected] http://lists.blender.org/mailman/listinfo/bf-committers
