Fix #28539: redraw issue with grease pencil active layer button, this was a regular

button that acted like a toggle, now made it an actual toggle button.
This commit is contained in:
Brecht Van Lommel
2011-12-02 19:08:40 +00:00
parent 0539a3f1e9
commit 069f46ac89

View File

@@ -125,7 +125,7 @@ static void gp_drawui_layer (uiLayout *layout, bGPdata *gpd, bGPDlayer *gpl, con
/* active */
block= uiLayoutGetBlock(sub);
icon= (gpl->flag & GP_LAYER_ACTIVE) ? ICON_RADIOBUT_ON : ICON_RADIOBUT_OFF;
but= uiDefIconBut(block, BUT, 0, icon, 0, 0, UI_UNIT_X, UI_UNIT_Y, NULL, 0.0, 0.0, 0.0, 0.0, "Set active layer");
but= uiDefIconButBitI(block, TOG, GP_LAYER_ACTIVE, 0, icon, 0, 0, UI_UNIT_X, UI_UNIT_Y, &gpd->flag, 0.0, 0.0, 0.0, 0.0, "Set active layer");
uiButSetFunc(but, gp_ui_activelayer_cb, gpd, gpl);
/* locked */