diff options
author | William Reynish <billreynish> | 2018-10-28 19:51:40 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-10-29 21:04:07 +0300 |
commit | b18ac77df3c2eb002bd4c5ed2e6b606535cb67cc (patch) | |
tree | 2b8bbffc571a72172e7cdf27a432750c53ebc371 /source/blender/editors | |
parent | b5667c2ca7f7cc33903b7f664dfbd3bccd8cdd22 (diff) |
UI: icon set updates Andrzej Ambroz, and various fixes.
* Text editor word wrap, line numbers & syntax toggles now use consistent icons
that don’t change when you enable or disable them.
* Replaced icon toggle buttons in the snapping popover with normal checkboxes
and descriptive text labels. This makes it clearer which item is the main
radio button, is more consistent with other popovers, and allows us to use
more descriptive text.
* Added correct icons for grease pencil add menu.
* Added bespoke icons for grease pencil modifiers.
* Added icon for particle instance modifier.
* Added icon for fake user on & off states.
* Added correct icons for enabling/disabling modifiers in the dopesheet &
f-curve editor.
* Made it so the restrict viewport & restrict render toggles for modifier
update correctly when enabled or disabled, by flipping the order in the
icon sheet. This also required changing the outliner to match.
* Removed the few old remaining icons in the old style and made sure to replace
the last places where they were used.
* Updated many icons to be clearer & more consistent.
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/animation/anim_channels_defines.c | 3 | ||||
-rw-r--r-- | source/blender/editors/animation/drivers.c | 2 | ||||
-rw-r--r-- | source/blender/editors/include/UI_icons.h | 336 | ||||
-rw-r--r-- | source/blender/editors/interface/interface_icons.c | 2 | ||||
-rw-r--r-- | source/blender/editors/interface/interface_templates.c | 10 | ||||
-rw-r--r-- | source/blender/editors/space_outliner/outliner_draw.c | 137 |
6 files changed, 245 insertions, 245 deletions
diff --git a/source/blender/editors/animation/anim_channels_defines.c b/source/blender/editors/animation/anim_channels_defines.c index 8873a197aa8..d6f52114708 100644 --- a/source/blender/editors/animation/anim_channels_defines.c +++ b/source/blender/editors/animation/anim_channels_defines.c @@ -4282,8 +4282,7 @@ static void draw_setting_widget(bAnimContext *ac, bAnimListElem *ale, const bAni break; case ACHANNEL_SETTING_MOD_OFF: /* modifiers disabled */ - icon = ICON_MODIFIER; - usetoggle = false; + icon = ICON_MODIFIER_OFF; tooltip = TIP_("F-Curve modifiers are disabled"); break; diff --git a/source/blender/editors/animation/drivers.c b/source/blender/editors/animation/drivers.c index cf4ac21b7af..723da10e002 100644 --- a/source/blender/editors/animation/drivers.c +++ b/source/blender/editors/animation/drivers.c @@ -760,7 +760,7 @@ bool ANIM_driver_vars_paste(ReportList *reports, FCurve *fcu, bool replace) /* NOTE: Used by ANIM_OT_driver_button_add and UI_OT_eyedropper_driver */ // XXX: These names need reviewing EnumPropertyItem prop_driver_create_mapping_types[] = { - {CREATEDRIVER_MAPPING_1_N, "SINGLE_MANY", ICON_UI, "All from Target", + {CREATEDRIVER_MAPPING_1_N, "SINGLE_MANY", 0, "All from Target", "Drive all components of this property using the target picked"}, {CREATEDRIVER_MAPPING_1_1, "DIRECT", 0, "Single from Target", "Drive this component of this property using the target picked"}, diff --git a/source/blender/editors/include/UI_icons.h b/source/blender/editors/include/UI_icons.h index c005d6dcc07..b5e910a650a 100644 --- a/source/blender/editors/include/UI_icons.h +++ b/source/blender/editors/include/UI_icons.h @@ -71,15 +71,15 @@ DEF_ICON(GRIP) DEF_ICON(DOT) DEF_ICON(COLLAPSEMENU) DEF_ICON(X) -DEF_ICON_BLANK(5) /* XXX 'DOWNARROW' icon! */ -DEF_ICON_COLOR(GO_LEFT) -DEF_ICON_COLOR(PLUG) -DEF_ICON_COLOR(UI) +DEF_ICON_BLANK(74) +DEF_ICON_BLANK(75) +DEF_ICON_BLANK(76) +DEF_ICON_BLANK(77) DEF_ICON(NODE) DEF_ICON(NODE_SEL) /* ui */ -DEF_ICON_COLOR(FULLSCREEN) +DEF_ICON_BLANK(FULLSCREEN) DEF_ICON(WORKSPACE) DEF_ICON(RIGHTARROW_THIN) DEF_ICON(BORDERMOVE) @@ -89,7 +89,7 @@ DEF_ICON(REMOVE) DEF_ICON(PANEL_CLOSE) DEF_ICON_COLOR(COPY_ID) DEF_ICON(EYEDROPPER) -DEF_ICON_COLOR(LINK_AREA) +DEF_ICON_BLANK(92) DEF_ICON(AUTO) DEF_ICON(CHECKBOX_DEHLT) /* de-Hilight - Checkbox OFF */ DEF_ICON(CHECKBOX_HLT) /* Hilight - Checkbox ON */ @@ -100,27 +100,27 @@ DEF_ICON(PINNED) DEF_ICON(SCREEN_BACK) DEF_ICON(RIGHTARROW) DEF_ICON(DOWNARROW_HLT) -DEF_ICON_COLOR(DOTSUP) -DEF_ICON_COLOR(DOTSDOWN) -DEF_ICON(LINK) -DEF_ICON(INLINK) -DEF_ICON_COLOR(PLUGIN) +DEF_ICON_BLANK(103) +DEF_ICON_BLANK(104) +DEF_ICON_BLANK(105) +DEF_ICON_BLANK(106) +DEF_ICON(PLUGIN) /* various ui */ DEF_ICON(HELP) DEF_ICON(GHOST_ENABLED) DEF_ICON(COLOR) /* see COLOR_RED/GREEN/BLUE */ -DEF_ICON(LINKED) DEF_ICON(UNLINKED) +DEF_ICON(LINKED) DEF_ICON(HAND) DEF_ICON(ZOOM_ALL) DEF_ICON(ZOOM_SELECTED) DEF_ICON(ZOOM_PREVIOUS) DEF_ICON(ZOOM_IN) DEF_ICON(ZOOM_OUT) -DEF_ICON_COLOR(RENDER_REGION) -DEF_ICON_COLOR(BORDER_RECT) -DEF_ICON_COLOR(BORDER_LASSO) +DEF_ICON_BLANK(121) +DEF_ICON_BLANK(122) +DEF_ICON_BLANK(123) DEF_ICON(FREEZE) DEF_ICON(STYLUS_PRESSURE) DEF_ICON(GHOST_DISABLED) @@ -129,10 +129,10 @@ DEF_ICON(FILE_TICK) DEF_ICON(QUIT) DEF_ICON(URL) DEF_ICON(RECOVER_LAST) -DEF_ICON(30) +DEF_ICON(THREE_DOTS) DEF_ICON(FULLSCREEN_ENTER) DEF_ICON(FULLSCREEN_EXIT) -DEF_ICON_BLANK(33) +DEF_ICON_BLANK(135) /* BUTTONS */ DEF_ICON_SHADING(LIGHT) @@ -141,26 +141,26 @@ DEF_ICON_SHADING(TEXTURE) DEF_ICON(ANIM) DEF_ICON_SHADING(WORLD) DEF_ICON(SCENE) -DEF_ICON(EDIT) -DEF_ICON(GAME) -DEF_ICON(RADIO) -DEF_ICON_COLOR(SCRIPT) +DEF_ICON_BLANK(144) +DEF_ICON_BLANK(145) +DEF_ICON_BLANK(146) +DEF_ICON(SCRIPT) DEF_ICON_MODIFIER(PARTICLES) DEF_ICON(PHYSICS) DEF_ICON(SPEAKER) -DEF_ICON(TEXTURE_SHADED) +DEF_ICON_BLANK(151) DEF_ICON(TOOL_SETTINGS) DEF_ICON(SHADERFX) -DEF_ICON_BLANK(44) -DEF_ICON_BLANK(45) -DEF_ICON_BLANK(46) -DEF_ICON_BLANK(47) -DEF_ICON_BLANK(48) -DEF_ICON_BLANK(49) -DEF_ICON_BLANK(50) -DEF_ICON_BLANK(51) -DEF_ICON_BLANK(52) -DEF_ICON_COLOR(BLANK1) // Not actually blank - this is used all over the place +DEF_ICON_BLANK(154) +DEF_ICON_BLANK(155) +DEF_ICON_BLANK(156) +DEF_ICON_BLANK(157) +DEF_ICON_BLANK(158) +DEF_ICON_BLANK(159) +DEF_ICON_BLANK(160) +DEF_ICON(BLANK1) // Not actually blank - this is used all over the place +DEF_ICON(FAKE_USER_OFF) +DEF_ICON(FAKE_USER_ON) /* EDITORS */ DEF_ICON(VIEW3D) DEF_ICON(GRAPH) @@ -171,23 +171,23 @@ DEF_ICON(IMAGE) DEF_ICON(INFO) DEF_ICON(SEQUENCE) DEF_ICON(TEXT) -DEF_ICON_BLANK(62) +DEF_ICON_BLANK(174) DEF_ICON(SOUND) DEF_ICON(ACTION) DEF_ICON(NLA) DEF_ICON(PREFERENCES) DEF_ICON(TIME) DEF_ICON(NODETREE) -DEF_ICON(LOGIC) +DEF_ICON_BLANK(181) DEF_ICON(CONSOLE) -DEF_ICON_BLANK(54) +DEF_ICON_BLANK(183) DEF_ICON(CLIP) DEF_ICON(ASSET_MANAGER) DEF_ICON(NODE_COMPOSITING) DEF_ICON(NODE_TEXTURE) DEF_ICON(NODE_MATERIAL) -DEF_ICON_BLANK(60) -DEF_ICON_BLANK(61) +DEF_ICON_BLANK(189) +DEF_ICON_BLANK(190) /* MODES */ DEF_ICON(OBJECT_DATAMODE) // XXX fix this up @@ -199,13 +199,13 @@ DEF_ICON(WPAINT_HLT) DEF_ICON(SCULPTMODE_HLT) DEF_ICON(POSE_HLT) DEF_ICON(PARTICLEMODE) -DEF_ICON_COLOR(LIGHTPAINT) -DEF_ICON_COLOR(GREASEPENCIL_STROKE_PAINT) -DEF_ICON_BLANK(64) -DEF_ICON_BLANK(65) -DEF_ICON_BLANK(66) -DEF_ICON_BLANK(67) -DEF_ICON_BLANK(68) +DEF_ICON_BLANK(202) +DEF_ICON_BLANK(203) +DEF_ICON_BLANK(204) +DEF_ICON_BLANK(205) +DEF_ICON_BLANK(206) +DEF_ICON_BLANK(207) +DEF_ICON_BLANK(208) DEF_ICON(TRACKING) DEF_ICON(TRACKING_BACKWARDS) DEF_ICON(TRACKING_FORWARDS) @@ -238,12 +238,12 @@ DEF_ICON(ARMATURE_DATA) DEF_ICON(POSE_DATA) DEF_ICON(BONE_DATA) DEF_ICON_MODIFIER(CONSTRAINT) -DEF_ICON_COLOR(SHAPEKEY_DATA) +DEF_ICON(SHAPEKEY_DATA) DEF_ICON_MODIFIER(CONSTRAINT_BONE) DEF_ICON(CAMERA_STEREO) DEF_ICON(PACKAGE) DEF_ICON(UGLYPACKAGE) -DEF_ICON_BLANK(79b) +DEF_ICON_BLANK(246) /* DATA */ DEF_ICON_SHADING(BRUSH_DATA) @@ -254,11 +254,11 @@ DEF_ICON(FONT_DATA) DEF_ICON(RENDER_RESULT) DEF_ICON(SURFACE_DATA) DEF_ICON(EMPTY_DATA) -DEF_ICON_BLANK(88) +DEF_ICON(PRESET) DEF_ICON(RENDER_ANIMATION) DEF_ICON(RENDER_STILL) DEF_ICON(LIBRARY_DATA_BROKEN) -DEF_ICON_COLOR(BOIDS) +DEF_ICON(BOIDS) DEF_ICON(STRANDS) DEF_ICON(LIBRARY_DATA_INDIRECT) DEF_ICON(GREASEPENCIL) @@ -269,7 +269,7 @@ DEF_ICON(GROUP_VERTEX) DEF_ICON(GROUP_VCOL) DEF_ICON(GROUP_UVS) DEF_ICON(FACE_MAPS) -DEF_ICON_BLANK(90) +DEF_ICON_BLANK(272) DEF_ICON(RNA) DEF_ICON(RNA_ADD) @@ -281,21 +281,21 @@ DEF_ICON(MOUSE_MOVE) DEF_ICON(MOUSE_LMB_DRAG) DEF_ICON(MOUSE_MMB_DRAG) DEF_ICON(MOUSE_RMB_DRAG) -DEF_ICON_BLANK(99) -DEF_ICON(PRESET) -DEF_ICON_BLANK(101) +DEF_ICON_BLANK(284) +DEF_ICON_BLANK(285) +DEF_ICON_BLANK(286) DEF_ICON(DECORATE) DEF_ICON(DECORATE_KEYFRAME) DEF_ICON(DECORATE_ANIMATE) DEF_ICON(DECORATE_DRIVER) DEF_ICON(DECORATE_LINKED) -DEF_ICON(DECORATE_OVERRIDE) +DEF_ICON(DECORATE_LIBRARY_OVERRIDE) DEF_ICON(DECORATE_UNLOCKED) DEF_ICON(DECORATE_LOCKED) -DEF_ICON_BLANK(110) +DEF_ICON(DECORATE_OVERRIDE) DEF_ICON_BLANK(111) -DEF_ICON_BLANK(112) -DEF_ICON(FAKE_USER) +DEF_ICON(SEALED) +DEF_ICON(HEART) DEF_ICON(ORPHAN_DATA) DEF_ICON(USER) DEF_ICON(SYSTEM) @@ -318,7 +318,7 @@ DEF_ICON_OBJECT(OUTLINER_OB_GROUP_INSTANCE) DEF_ICON_OBJECT(OUTLINER_OB_GREASEPENCIL) DEF_ICON_OBJECT(OUTLINER_OB_LIGHTPROBE) DEF_ICON_OBJECT(OUTLINER_OB_IMAGE) -DEF_ICON_BLANK(125) +DEF_ICON_BLANK(321) DEF_ICON(RESTRICT_COLOR_OFF) DEF_ICON(RESTRICT_COLOR_ON) DEF_ICON(HIDE_OFF) @@ -327,10 +327,10 @@ DEF_ICON(RESTRICT_SELECT_OFF) DEF_ICON(RESTRICT_SELECT_ON) DEF_ICON(RESTRICT_RENDER_OFF) DEF_ICON(RESTRICT_RENDER_ON) -DEF_ICON_BLANK(127b) +DEF_ICON_BLANK(330) /* OUTLINER */ -DEF_ICON_BLANK(128) +DEF_ICON_OBJECT_DATA(OUTLINER_DATA_EMPTY) DEF_ICON_OBJECT_DATA(OUTLINER_DATA_MESH) DEF_ICON_OBJECT_DATA(OUTLINER_DATA_CURVE) DEF_ICON_OBJECT_DATA(OUTLINER_DATA_LATTICE) @@ -342,20 +342,20 @@ DEF_ICON_OBJECT_DATA(OUTLINER_DATA_FONT) DEF_ICON_OBJECT_DATA(OUTLINER_DATA_SURFACE) DEF_ICON_OBJECT_DATA(OUTLINER_DATA_SPEAKER) DEF_ICON_OBJECT_DATA(OUTLINER_DATA_POSE) -DEF_ICON_BLANK(130) +DEF_ICON_BLANK(345) DEF_ICON_OBJECT_DATA(OUTLINER_DATA_GREASEPENCIL) DEF_ICON(GP_SELECT_POINTS) DEF_ICON(GP_SELECT_STROKES) DEF_ICON(GP_MULTIFRAME_EDITING) DEF_ICON(GP_ONLY_SELECTED) -DEF_ICON_BLANK(136) -DEF_ICON_BLANK(137) -DEF_ICON_BLANK(138) +DEF_ICON_BLANK(351) +DEF_ICON(MODIFIER_OFF) +DEF_ICON(MODIFIER_ON) DEF_ICON(ONIONSKIN_OFF) DEF_ICON(ONIONSKIN_ON) DEF_ICON(RESTRICT_VIEW_OFF) DEF_ICON(RESTRICT_VIEW_ON) -DEF_ICON_BLANK(142b) +DEF_ICON_BLANK(353) /* PRIMITIVES */ DEF_ICON(MESH_PLANE) @@ -369,15 +369,15 @@ DEF_ICON(MESH_CYLINDER) DEF_ICON(MESH_TORUS) DEF_ICON(MESH_CONE) DEF_ICON(MESH_CAPSULE) -DEF_ICON_BLANK(611) +DEF_ICON_BLANK(372) DEF_ICON_SHADING(LIGHT_POINT) DEF_ICON_SHADING(LIGHT_SUN) DEF_ICON_SHADING(LIGHT_SPOT) DEF_ICON_SHADING(LIGHT_HEMI) DEF_ICON_SHADING(LIGHT_AREA) -DEF_ICON_BLANK(617) -DEF_ICON_BLANK(618) -DEF_ICON_COLOR(META_EMPTY) +DEF_ICON_BLANK(278) +DEF_ICON_BLANK(379) +DEF_ICON(META_EMPTY) DEF_ICON(META_PLANE) DEF_ICON(META_CUBE) DEF_ICON(META_BALL) @@ -394,7 +394,7 @@ DEF_ICON(SURFACE_NSPHERE) DEF_ICON(SURFACE_NTORUS) DEF_ICON(GP_EMPTY) DEF_ICON(GP_STROKE) -DEF_ICON_BLANK(638) +DEF_ICON_BLANK(397) DEF_ICON(CURVE_BEZCURVE) DEF_ICON(CURVE_BEZCIRCLE) DEF_ICON(CURVE_NCURVE) @@ -403,8 +403,8 @@ DEF_ICON(CURVE_PATH) DEF_ICON_SHADING(LIGHTPROBE_CUBEMAP) DEF_ICON_SHADING(LIGHTPROBE_PLANAR) DEF_ICON_SHADING(LIGHTPROBE_GRID) -DEF_ICON_BLANK(647) -DEF_ICON_BLANK(648) +DEF_ICON_BLANK(406) +DEF_ICON_BLANK(407) DEF_ICON(COLOR_RED) DEF_ICON(COLOR_GREEN) DEF_ICON(COLOR_BLUE) @@ -442,9 +442,9 @@ DEF_ICON_BLANK(684) DEF_ICON_BLANK(685) /* EMPTY */ -DEF_ICON_COLOR(TEMPERATURE) /* XXX 'Temperature' icon! */ -DEF_ICON_BLANK(691) /* XXX 'Temperature' icon! */ -DEF_ICON_COLOR(GEAR) /* XXX 'Gear' icon! */ +DEF_ICON_BLANK(445) +DEF_ICON_BLANK(446) +DEF_ICON_BLANK(447) DEF_ICON(NODE_INSERT_ON) DEF_ICON(NODE_INSERT_OFF) DEF_ICON(NODE_TOP) @@ -498,32 +498,32 @@ DEF_ICON_BLANK(754) DEF_ICON_BLANK(755) /* EMPTY */ -DEF_ICON_BLANK(760) -DEF_ICON_BLANK(761) -DEF_ICON_BLANK(762) -DEF_ICON_BLANK(763) -DEF_ICON_BLANK(764) -DEF_ICON_BLANK(765) -DEF_ICON_BLANK(766) -DEF_ICON_BLANK(767) -DEF_ICON_BLANK(768) -DEF_ICON_BLANK(769) -DEF_ICON_BLANK(770) -DEF_ICON_BLANK(771) -DEF_ICON_BLANK(772) -DEF_ICON_BLANK(773) -DEF_ICON_BLANK(774) -DEF_ICON_BLANK(775) -DEF_ICON_BLANK(776) -DEF_ICON_BLANK(777) -DEF_ICON_BLANK(778) -DEF_ICON_BLANK(779) -DEF_ICON_BLANK(780) -DEF_ICON_BLANK(781) -DEF_ICON_BLANK(782) -DEF_ICON_BLANK(783) -DEF_ICON_BLANK(784) -DEF_ICON_BLANK(785) +DEF_ICON_BLANK(501) +DEF_ICON_BLANK(502) +DEF_ICON_BLANK(503) +DEF_ICON_BLANK(504) +DEF_ICON_BLANK(505) +DEF_ICON_BLANK(506) +DEF_ICON_BLANK(507) +DEF_ICON_BLANK(508) +DEF_ICON_BLANK(509) +DEF_ICON_BLANK(510) +DEF_ICON_BLANK(511) +DEF_ICON_BLANK(512) +DEF_ICON_BLANK(513) +DEF_ICON_BLANK(514) +DEF_ICON_BLANK(515) +DEF_ICON_BLANK(516) +DEF_ICON_BLANK(517) +DEF_ICON_BLANK(518) +DEF_ICON_BLANK(519) +DEF_ICON_BLANK(520) +DEF_ICON_BLANK(521) +DEF_ICON_BLANK(522) +DEF_ICON_BLANK(523) +DEF_ICON_BLANK(524) +DEF_ICON_BLANK(525) +DEF_ICON_BLANK(526) /* MODIFIERS */ DEF_ICON_MODIFIER(MODIFIER) @@ -543,7 +543,7 @@ DEF_ICON_MODIFIER(MOD_UVPROJECT) DEF_ICON_MODIFIER(MOD_DISPLACE) DEF_ICON_MODIFIER(MOD_CURVE) DEF_ICON_MODIFIER(MOD_LATTICE) -DEF_ICON_COLOR(CONSTRAINT_DATA) +DEF_ICON_MODIFIER(MOD_TINT) DEF_ICON_MODIFIER(MOD_ARMATURE) DEF_ICON_MODIFIER(MOD_SHRINKWRAP) DEF_ICON_MODIFIER(MOD_CAST) @@ -571,15 +571,15 @@ DEF_ICON_MODIFIER(MOD_TRIANGULATE) DEF_ICON_MODIFIER(MOD_WIREFRAME) DEF_ICON_MODIFIER(MOD_DATA_TRANSFER) DEF_ICON_MODIFIER(MOD_NORMALEDIT) -DEF_ICON_BLANK(169) -DEF_ICON_BLANK(170) -DEF_ICON_BLANK(171) -DEF_ICON_BLANK(172) -DEF_ICON_BLANK(173) -DEF_ICON_BLANK(174) -DEF_ICON_BLANK(175) -DEF_ICON_BLANK(176) -DEF_ICON_BLANK(177) +DEF_ICON_MODIFIER(MOD_PARTICLE_INSTANCE) +DEF_ICON_MODIFIER(MOD_HUE_SATURATION) +DEF_ICON_MODIFIER(MOD_NOISE) +DEF_ICON_MODIFIER(MOD_OFFSET) +DEF_ICON_MODIFIER(MOD_SIMPLIFY) +DEF_ICON_MODIFIER(MOD_THICKNESS) +DEF_ICON_MODIFIER(MOD_INSTANCE) +DEF_ICON_MODIFIER(MOD_TIME) +DEF_ICON_MODIFIER(MOD_OPACITY) /* ANIMATION */ DEF_ICON(REC) @@ -595,7 +595,7 @@ DEF_ICON(PREVIEW_RANGE) DEF_ICON(ACTION_TWEAK) DEF_ICON(PMARKER_ACT) DEF_ICON(PMARKER_SEL) -DEF_ICON_COLOR(PMARKER) +DEF_ICON(PMARKER) DEF_ICON(MARKER_HLT) DEF_ICON(MARKER) DEF_ICON(KEYFRAME_HLT) @@ -632,10 +632,10 @@ DEF_ICON(IPO_EASE_IN) DEF_ICON(IPO_EASE_OUT) DEF_ICON(IPO_EASE_IN_OUT) DEF_ICON(NORMALIZE_FCURVES) -DEF_ICON_BLANK(204) -DEF_ICON_BLANK(205) -DEF_ICON_BLANK(206) -DEF_ICON_BLANK(207) +DEF_ICON_BLANK(635) +DEF_ICON_BLANK(636) +DEF_ICON_BLANK(637) +DEF_ICON_BLANK(638) /* EDITING */ DEF_ICON(VERTEXSEL) @@ -649,7 +649,7 @@ DEF_ICON(PIVOT_INDIVIDUAL) DEF_ICON(PIVOT_MEDIAN) DEF_ICON(PIVOT_ACTIVE) DEF_ICON(CENTER_ONLY) -DEF_ICON_BLANK(211) +DEF_ICON_BLANK(652) DEF_ICON(SMOOTHCURVE) DEF_ICON(SPHERECURVE) DEF_ICON(ROOTCURVE) @@ -666,10 +666,10 @@ DEF_ICON(PARTICLE_TIP) DEF_ICON(PARTICLE_PATH) /* EDITING */ -DEF_ICON_COLOR(MAN_TRANS) -DEF_ICON_COLOR(MAN_ROT) -DEF_ICON_COLOR(MAN_SCALE) -DEF_ICON_COLOR(MANIPUL) +DEF_ICON_BLANK(669) +DEF_ICON_BLANK(670) +DEF_ICON_BLANK(671) +DEF_ICON_BLANK(672) DEF_ICON(SNAP_OFF) DEF_ICON(SNAP_ON) DEF_ICON(SNAP_NORMAL) @@ -705,7 +705,7 @@ DEF_ICON(VIS_SEL_00) DEF_ICON_BLANK(231) DEF_ICON(AUTOMERGE_ON) DEF_ICON(AUTOMERGE_OFF) -DEF_ICON_COLOR(RETOPO) +DEF_ICON_BLANK(234) DEF_ICON(UV_VERTEXSEL) DEF_ICON(UV_EDGESEL) DEF_ICON(UV_FACESEL) @@ -763,18 +763,18 @@ DEF_ICON_BLANK(268) DEF_ICON_BLANK(269) DEF_ICON_BLANK(270) DEF_ICON_BLANK(271) -DEF_ICON_BLANK(272) -DEF_ICON_BLANK(273) +DEF_ICON_BLANK(766) +DEF_ICON_BLANK(767) DEF_ICON_BLANK(274) DEF_ICON_BLANK(275) DEF_ICON_BLANK(276) DEF_ICON_BLANK(277) -DEF_ICON_BLANK(278) -DEF_ICON_BLANK(279) -DEF_ICON_BLANK(280) -DEF_ICON_BLANK(281) -DEF_ICON_BLANK(282) -DEF_ICON_BLANK(282b) +DEF_ICON_BLANK(772) +DEF_ICON_BLANK(773) +DEF_ICON_BLANK(774) +DEF_ICON_BLANK(775) +DEF_ICON_BLANK(776) +DEF_ICON_BLANK(777) /* FILE SELECT */ DEF_ICON(SORTALPHA) @@ -783,15 +783,15 @@ DEF_ICON(SORTTIME) DEF_ICON(SORTSIZE) DEF_ICON(SHORTDISPLAY) DEF_ICON(LONGDISPLAY) -DEF_ICON_COLOR(GHOST) -DEF_ICON_COLOR(IMGDISPLAY) -DEF_ICON_BLANK(292) -DEF_ICON_BLANK(293) +DEF_ICON_BLANK(786) +DEF_ICON(IMGDISPLAY) +DEF_ICON_BLANK(788) +DEF_ICON_BLANK(789) DEF_ICON(BOOKMARKS) DEF_ICON(FONTPREVIEW) DEF_ICON(FILTER) DEF_ICON(NEWFOLDER) -DEF_ICON(OPEN_RECENT) +DEF_ICON_BLANK(794) DEF_ICON(FILE_PARENT) DEF_ICON(FILE_REFRESH) DEF_ICON(FILE_FOLDER) @@ -811,21 +811,21 @@ DEF_ICON(LINK_BLEND) DEF_ICON(APPEND_BLEND) DEF_ICON(IMPORT) DEF_ICON(EXPORT) -DEF_ICON_COLOR(EXTERNAL_DATA) -DEF_ICON_BLANK(299) -DEF_ICON_BLANK(300) -DEF_ICON_BLANK(301) -DEF_ICON_BLANK(302) -DEF_ICON_BLANK(303) -DEF_ICON_BLANK(304) +DEF_ICON_BLANK(814) +DEF_ICON_BLANK(815) +DEF_ICON_BLANK(816) +DEF_ICON_BLANK(817) +DEF_ICON_BLANK(818) +DEF_ICON_BLANK(819) +DEF_ICON_BLANK(820) DEF_ICON(LOOP_BACK) DEF_ICON(LOOP_FORWARDS) DEF_ICON(BACK) DEF_ICON(FORWARD) -DEF_ICON_BLANK(309) -DEF_ICON_BLANK(310) -DEF_ICON_BLANK(311) -DEF_ICON_BLANK(312) +DEF_ICON_BLANK(825) +DEF_ICON_BLANK(826) +DEF_ICON_BLANK(827) +DEF_ICON_BLANK(828) DEF_ICON(ALEMBIC) DEF_ICON(VOLUME) DEF_ICON(FILE_HIDDEN) @@ -841,24 +841,24 @@ DEF_ICON(HAIR) DEF_ICON(ALIASED) DEF_ICON(ANTIALIASED) DEF_ICON(MAT_SPHERE_SKY) -DEF_ICON_BLANK(319) -DEF_ICON_BLANK(320) -DEF_ICON_BLANK(321) -DEF_ICON_BLANK(322) +DEF_ICON(MATSHADERBALL) +DEF_ICON(MATCLOTH) +DEF_ICON(MATFLUID) +DEF_ICON_BLANK(847) DEF_ICON(WORDWRAP_OFF) DEF_ICON(WORDWRAP_ON) DEF_ICON(SYNTAX_OFF) DEF_ICON(SYNTAX_ON) DEF_ICON(LINENUMBERS_OFF) DEF_ICON(LINENUMBERS_ON) -DEF_ICON(SCRIPTPLUGINS) // XXX CREATE NEW -DEF_ICON_BLANK(323) -DEF_ICON_BLANK(324) -DEF_ICON_BLANK(325) -DEF_ICON_BLANK(326) -DEF_ICON_BLANK(327) -DEF_ICON_BLANK(328) -DEF_ICON_BLANK(328b) +DEF_ICON(SCRIPTPLUGINS) +DEF_ICON_BLANK(855) +DEF_ICON_BLANK(856) +DEF_ICON_BLANK(857) +DEF_ICON_BLANK(858) +DEF_ICON_BLANK(859) +DEF_ICON_BLANK(860) +DEF_ICON_BLANK(861) /* SEQUENCE / IMAGE EDITOR */ DEF_ICON(SEQ_SEQUENCER) @@ -867,21 +867,21 @@ DEF_ICON(SEQ_LUMA_WAVEFORM) DEF_ICON(SEQ_CHROMA_SCOPE) DEF_ICON(SEQ_HISTOGRAM) DEF_ICON(SEQ_SPLITVIEW) -DEF_ICON_BLANK(331) -DEF_ICON_BLANK(332) -DEF_ICON_BLANK(333) +DEF_ICON_BLANK(870) +DEF_ICON_BLANK(871) +DEF_ICON_BLANK(872) DEF_ICON(IMAGE_RGB) // XXX CHANGE TO STRAIGHT ALPHA, Z ETC DEF_ICON(IMAGE_RGB_ALPHA) DEF_ICON(IMAGE_ALPHA) DEF_ICON(IMAGE_ZDEPTH) -DEF_ICON_COLOR(IMAGEFILE) -DEF_ICON_BLANK(336) -DEF_ICON_BLANK(337) -DEF_ICON_BLANK(338) -DEF_ICON_BLANK(339) -DEF_ICON_BLANK(340) -DEF_ICON_BLANK(341) -DEF_ICON_BLANK(342) +DEF_ICON_BLANK(877) +DEF_ICON_BLANK(878) +DEF_ICON_BLANK(879) +DEF_ICON_BLANK(880) +DEF_ICON_BLANK(881) +DEF_ICON_BLANK(882) +DEF_ICON_BLANK(883) +DEF_ICON_BLANK(884) DEF_ICON(VIEW_PERSPECTIVE) DEF_ICON(VIEW_ORTHO) DEF_ICON(VIEW_CAMERA) diff --git a/source/blender/editors/interface/interface_icons.c b/source/blender/editors/interface/interface_icons.c index 0c5eb35f939..6289bc09f5a 100644 --- a/source/blender/editors/interface/interface_icons.c +++ b/source/blender/editors/interface/interface_icons.c @@ -1798,7 +1798,7 @@ int UI_rnaptr_icon_get(bContext *C, PointerRNA *ptr, int rnaicon, const bool big DynamicPaintSurface *surface = ptr->data; if (surface->format == MOD_DPAINT_SURFACE_F_PTEX) - return ICON_TEXTURE_SHADED; + return ICON_SHADING_TEXTURE; else if (surface->format == MOD_DPAINT_SURFACE_F_VERTEX) return ICON_OUTLINER_DATA_MESH; else if (surface->format == MOD_DPAINT_SURFACE_F_IMAGESEQ) diff --git a/source/blender/editors/interface/interface_templates.c b/source/blender/editors/interface/interface_templates.c index a3edde2cb6a..3cbfd1eb05e 100644 --- a/source/blender/editors/interface/interface_templates.c +++ b/source/blender/editors/interface/interface_templates.c @@ -748,7 +748,7 @@ static void template_ID( if (user_alert) UI_but_flag_enable(but, UI_BUT_REDALERT); if (id->lib == NULL && !(ELEM(GS(id->name), ID_GR, ID_SCE, ID_SCR, ID_TXT, ID_OB, ID_WS))) { - uiDefButR(block, UI_BTYPE_TOGGLE, 0, "F", 0, 0, UI_UNIT_X, UI_UNIT_Y, &idptr, "use_fake_user", -1, 0, 0, -1, -1, NULL); + uiDefIconButR(block, UI_BTYPE_ICON_TOGGLE, 0, ICON_FAKE_USER_OFF, 0, 0, UI_UNIT_X, UI_UNIT_Y, &idptr, "use_fake_user", -1, 0, 0, -1, -1, NULL); } } @@ -2010,7 +2010,7 @@ static uiLayout *draw_constraint(uiLayout *layout, Object *ob, bConstraint *con) UI_block_emboss_set(block, UI_EMBOSS_NONE); /* draw a ghost icon (for proxy) and also a lock beside it, to show that constraint is "proxy locked" */ - uiDefIconBut(block, UI_BTYPE_BUT, B_CONSTRAINT_TEST, ICON_GHOST, xco + 12.2f * UI_UNIT_X, yco, 0.95f * UI_UNIT_X, 0.95f * UI_UNIT_Y, + uiDefIconBut(block, UI_BTYPE_BUT, B_CONSTRAINT_TEST, ICON_GHOST_ENABLED, xco + 12.2f * UI_UNIT_X, yco, 0.95f * UI_UNIT_X, 0.95f * UI_UNIT_Y, NULL, 0.0, 0.0, 0.0, 0.0, TIP_("Proxy Protected")); uiDefIconBut(block, UI_BTYPE_BUT, B_CONSTRAINT_TEST, ICON_LOCKED, xco + 13.1f * UI_UNIT_X, yco, 0.95f * UI_UNIT_X, 0.95f * UI_UNIT_Y, NULL, 0.0, 0.0, 0.0, 0.0, TIP_("Proxy Protected")); @@ -3063,14 +3063,14 @@ static void curvemap_buttons_layout( UI_but_func_set(bt, curvemap_buttons_zoom_out, cumap, NULL); if (brush) - bt = uiDefIconBlockBut(block, curvemap_brush_tools_func, cumap, 0, ICON_MODIFIER, 0, 0, dx, dx, TIP_("Tools")); + bt = uiDefIconBlockBut(block, curvemap_brush_tools_func, cumap, 0, ICON_DOWNARROW_HLT, 0, 0, dx, dx, TIP_("Tools")); else if (neg_slope) bt = uiDefIconBlockBut( - block, curvemap_tools_negslope_func, cumap, 0, ICON_MODIFIER, + block, curvemap_tools_negslope_func, cumap, 0, ICON_DOWNARROW_HLT, 0, 0, dx, dx, TIP_("Tools")); else bt = uiDefIconBlockBut( - block, curvemap_tools_posslope_func, cumap, 0, ICON_MODIFIER, + block, curvemap_tools_posslope_func, cumap, 0, ICON_DOWNARROW_HLT, 0, 0, dx, dx, TIP_("Tools")); UI_but_funcN_set(bt, rna_update_cb, MEM_dupallocN(cb), NULL); diff --git a/source/blender/editors/space_outliner/outliner_draw.c b/source/blender/editors/space_outliner/outliner_draw.c index 41ec458c023..ba8522199c6 100644 --- a/source/blender/editors/space_outliner/outliner_draw.c +++ b/source/blender/editors/space_outliner/outliner_draw.c @@ -200,14 +200,6 @@ static void restrictbutton_r_lay_cb(bContext *C, void *poin, void *UNUSED(poin2) WM_event_add_notifier(C, NC_SCENE | ND_RENDER_OPTIONS, poin); } -static void restrictbutton_modifier_cb(bContext *C, void *UNUSED(poin), void *poin2) -{ - Object *ob = (Object *)poin2; - - DEG_id_tag_update(&ob->id, OB_RECALC_DATA); - WM_event_add_notifier(C, NC_OBJECT | ND_MODIFIER, ob); -} - static void restrictbutton_bone_visibility_cb(bContext *C, void *UNUSED(poin), void *poin2) { Bone *bone = (Bone *)poin2; @@ -483,25 +475,30 @@ static void namebutton_cb(bContext *C, void *tsep, char *oldname) static void outliner_draw_restrictbuts( uiBlock *block, Scene *scene, ViewLayer *view_layer, ARegion *ar, SpaceOops *soops, ListBase *lb) { - uiBut *bt; - - /* get RNA properties (once for speed) */ - PropertyRNA *object_prop_hide_viewport, *object_prop_hide_select, *object_prop_hide_render; - PropertyRNA *collection_prop_hide_viewport, *collection_prop_hide_select, *collection_prop_hide_render; - - object_prop_hide_viewport = RNA_struct_type_find_property(&RNA_Object, "hide_viewport"); - object_prop_hide_select = RNA_struct_type_find_property(&RNA_Object, "hide_select"); - object_prop_hide_render = RNA_struct_type_find_property(&RNA_Object, "hide_render"); - collection_prop_hide_select = RNA_struct_type_find_property(&RNA_Collection, "hide_select"); - collection_prop_hide_viewport = RNA_struct_type_find_property(&RNA_Collection, "hide_viewport"); - collection_prop_hide_render = RNA_struct_type_find_property(&RNA_Collection, "hide_render"); + /* Get RNA properties (once for speed). */ + static struct RestrictProperties { + bool initialized; + + PropertyRNA *object_hide_viewport, *object_hide_select, *object_hide_render; + PropertyRNA *collection_hide_viewport, *collection_hide_select, *collection_hide_render; + PropertyRNA *modifier_show_viewport, *modifier_show_render; + } props = {false}; + + if (!props.initialized) { + props.object_hide_viewport = RNA_struct_type_find_property(&RNA_Object, "hide_viewport"); + props.object_hide_select = RNA_struct_type_find_property(&RNA_Object, "hide_select"); + props.object_hide_render = RNA_struct_type_find_property(&RNA_Object, "hide_render"); + props.collection_hide_select = RNA_struct_type_find_property(&RNA_Collection, "hide_select"); + props.collection_hide_viewport = RNA_struct_type_find_property(&RNA_Collection, "hide_viewport"); + props.collection_hide_render = RNA_struct_type_find_property(&RNA_Collection, "hide_render"); + props.modifier_show_viewport = RNA_struct_type_find_property(&RNA_Modifier, "show_viewport"); + props.modifier_show_render = RNA_struct_type_find_property(&RNA_Modifier, "show_render"); + + props.initialized = true; + } - BLI_assert(object_prop_hide_viewport && - object_prop_hide_select && - object_prop_hide_render && - collection_prop_hide_viewport && - collection_prop_hide_select && - collection_prop_hide_render); + /* Create buttons. */ + uiBut *bt; for (TreeElement *te = lb->first; te; te = te->next) { TreeStoreElem *tselem = TREESTORE(te); @@ -511,11 +508,12 @@ static void outliner_draw_restrictbuts( ViewLayer *layer = te->directdata; bt = uiDefIconButBitS( - block, UI_BTYPE_ICON_TOGGLE_N, VIEW_LAYER_RENDER, 0, ICON_RESTRICT_RENDER_OFF, + block, UI_BTYPE_ICON_TOGGLE_N, VIEW_LAYER_RENDER, 0, ICON_RESTRICT_RENDER_ON, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_RENDERX), te->ys, UI_UNIT_X, UI_UNIT_Y, &layer->flag, 0, 0, 0, 0, TIP_("Use view layer for rendering")); UI_but_func_set(bt, restrictbutton_r_lay_cb, tselem->id, NULL); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); + UI_but_drawflag_enable(bt, UI_BUT_ICON_REVERSE); } else if (tselem->type == 0 && te->idcode == ID_OB) { Object *ob = (Object *)tselem->id; @@ -523,53 +521,50 @@ static void outliner_draw_restrictbuts( if (base) { bt = uiDefIconButBitS( - block, UI_BTYPE_ICON_TOGGLE, BASE_HIDDEN, 0, ICON_HIDE_OFF, + block, UI_BTYPE_ICON_TOGGLE, BASE_HIDDEN, 0, ICON_HIDE_ON, (int)(ar->v2d.cur.xmax - OL_TOG_HIDEX), te->ys, UI_UNIT_X, UI_UNIT_Y, &base->flag, 0, 0, 0, 0, TIP_("Hide object in viewport (Ctrl to isolate)")); UI_but_func_set(bt, hidebutton_base_flag_cb, view_layer, base); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); + UI_but_drawflag_enable(bt, UI_BUT_ICON_REVERSE); } PointerRNA ptr; - RNA_pointer_create((ID *)ob, &RNA_Object, ob, &ptr); + RNA_pointer_create(&ob->id, &RNA_Object, ob, &ptr); - bt = uiDefIconButR_prop(block, UI_BTYPE_ICON_TOGGLE, 0, ICON_RESTRICT_VIEW_OFF, + bt = uiDefIconButR_prop(block, UI_BTYPE_ICON_TOGGLE, 0, 0, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_VIEWX), te->ys, UI_UNIT_X, UI_UNIT_Y, - &ptr, object_prop_hide_viewport, -1, 0, 0, -1, -1, - TIP_("Restrict viewport visibility")); + &ptr, props.object_hide_viewport, -1, 0, 0, -1, -1, NULL); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); - bt = uiDefIconButR_prop(block, UI_BTYPE_ICON_TOGGLE, 0, ICON_RESTRICT_SELECT_OFF, + bt = uiDefIconButR_prop(block, UI_BTYPE_ICON_TOGGLE, 0, 0, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_SELECTX), te->ys, UI_UNIT_X, UI_UNIT_Y, - &ptr, object_prop_hide_select, -1, 0, 0, -1, -1, - TIP_("Restrict viewport selection")); + &ptr, props.object_hide_select, -1, 0, 0, -1, -1, NULL); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); - bt = uiDefIconButR_prop(block, UI_BTYPE_ICON_TOGGLE, 0, ICON_RESTRICT_RENDER_OFF, + bt = uiDefIconButR_prop(block, UI_BTYPE_ICON_TOGGLE, 0, 0, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_RENDERX), te->ys, UI_UNIT_X, UI_UNIT_Y, - &ptr, object_prop_hide_render, -1, 0, 0, -1, -1, - TIP_("Restrict render visibility")); + &ptr, props.object_hide_render, -1, 0, 0, -1, -1, NULL); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); } else if (tselem->type == TSE_MODIFIER) { ModifierData *md = (ModifierData *)te->directdata; - Object *ob = (Object *)tselem->id; - bt = uiDefIconButBitI( - block, UI_BTYPE_ICON_TOGGLE_N, eModifierMode_Realtime, 0, ICON_RESTRICT_VIEW_OFF, - (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_VIEWX), te->ys, UI_UNIT_X, - UI_UNIT_Y, &(md->mode), 0, 0, 0, 0, - TIP_("Restrict/Allow visibility in the 3D View")); - UI_but_func_set(bt, restrictbutton_modifier_cb, scene, ob); + PointerRNA ptr; + RNA_pointer_create(tselem->id, &RNA_Modifier, md, &ptr); + + bt = uiDefIconButR_prop( + block, UI_BTYPE_ICON_TOGGLE, 0, 0, + (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_VIEWX), te->ys, UI_UNIT_X, UI_UNIT_Y, + &ptr, props.modifier_show_viewport, -1, 0, 0, -1, -1, NULL); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); - bt = uiDefIconButBitI( - block, UI_BTYPE_ICON_TOGGLE_N, eModifierMode_Render, 0, ICON_RESTRICT_RENDER_OFF, - (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_RENDERX), te->ys, UI_UNIT_X, - UI_UNIT_Y, &(md->mode), 0, 0, 0, 0, TIP_("Restrict/Allow renderability")); - UI_but_func_set(bt, restrictbutton_modifier_cb, scene, ob); + bt = uiDefIconButR_prop( + block, UI_BTYPE_ICON_TOGGLE, 0, 0, + (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_RENDERX), te->ys, UI_UNIT_X, UI_UNIT_Y, + &ptr, props.modifier_show_render, -1, 0, 0, -1, -1, NULL); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); } else if (tselem->type == TSE_POSE_CHANNEL) { @@ -578,50 +573,55 @@ static void outliner_draw_restrictbuts( Object *ob = (Object *)tselem->id; bt = uiDefIconButBitI( - block, UI_BTYPE_ICON_TOGGLE, BONE_HIDDEN_P, 0, ICON_HIDE_OFF, + block, UI_BTYPE_ICON_TOGGLE, BONE_HIDDEN_P, 0, ICON_HIDE_ON, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_VIEWX), te->ys, UI_UNIT_X, UI_UNIT_Y, &(bone->flag), 0, 0, 0, 0, TIP_("Restrict/Allow visibility in the 3D View")); UI_but_func_set(bt, restrictbutton_bone_visibility_cb, ob->data, bone); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); + UI_but_drawflag_enable(bt, UI_BUT_ICON_REVERSE); bt = uiDefIconButBitI( - block, UI_BTYPE_ICON_TOGGLE, BONE_UNSELECTABLE, 0, ICON_RESTRICT_SELECT_OFF, + block, UI_BTYPE_ICON_TOGGLE, BONE_UNSELECTABLE, 0, ICON_RESTRICT_SELECT_ON, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_SELECTX), te->ys, UI_UNIT_X, UI_UNIT_Y, &(bone->flag), 0, 0, 0, 0, TIP_("Restrict/Allow selection in the 3D View")); UI_but_func_set(bt, restrictbutton_bone_select_cb, ob->data, bone); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); + UI_but_drawflag_enable(bt, UI_BUT_ICON_REVERSE); } else if (tselem->type == TSE_EBONE) { EditBone *ebone = (EditBone *)te->directdata; bt = uiDefIconButBitI( - block, UI_BTYPE_ICON_TOGGLE, BONE_HIDDEN_A, 0, ICON_RESTRICT_VIEW_OFF, + block, UI_BTYPE_ICON_TOGGLE, BONE_HIDDEN_A, 0, ICON_RESTRICT_VIEW_ON, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_VIEWX), te->ys, UI_UNIT_X, UI_UNIT_Y, &(ebone->flag), 0, 0, 0, 0, TIP_("Restrict/Allow visibility in the 3D View")); UI_but_func_set(bt, restrictbutton_ebone_visibility_cb, NULL, ebone); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); + UI_but_drawflag_enable(bt, UI_BUT_ICON_REVERSE); bt = uiDefIconButBitI( - block, UI_BTYPE_ICON_TOGGLE, BONE_UNSELECTABLE, 0, ICON_RESTRICT_SELECT_OFF, + block, UI_BTYPE_ICON_TOGGLE, BONE_UNSELECTABLE, 0, ICON_RESTRICT_SELECT_ON, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_SELECTX), te->ys, UI_UNIT_X, UI_UNIT_Y, &(ebone->flag), 0, 0, 0, 0, TIP_("Restrict/Allow selection in the 3D View")); UI_but_func_set(bt, restrictbutton_ebone_select_cb, NULL, ebone); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); + UI_but_drawflag_enable(bt, UI_BUT_ICON_REVERSE); } else if (tselem->type == TSE_GP_LAYER) { bGPDlayer *gpl = (bGPDlayer *)te->directdata; bt = uiDefIconButBitS( - block, UI_BTYPE_ICON_TOGGLE, GP_LAYER_HIDE, 0, ICON_HIDE_OFF, + block, UI_BTYPE_ICON_TOGGLE, GP_LAYER_HIDE, 0, ICON_HIDE_ON, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_VIEWX), te->ys, UI_UNIT_X, UI_UNIT_Y, &gpl->flag, 0, 0, 0, 0, TIP_("Restrict/Allow visibility in the 3D View")); UI_but_func_set(bt, restrictbutton_gp_layer_flag_cb, NULL, gpl); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); + UI_but_drawflag_enable(bt, UI_BUT_ICON_REVERSE); bt = uiDefIconButBitS( block, UI_BTYPE_ICON_TOGGLE, GP_LAYER_LOCKED, 0, ICON_UNLOCKED, @@ -642,33 +642,34 @@ static void outliner_draw_restrictbuts( { if (lc && (lc->runtime_flag & LAYER_COLLECTION_HAS_ENABLED_OBJECTS)) { bt = uiDefIconButBitS( - block, UI_BTYPE_ICON_TOGGLE_N, LAYER_COLLECTION_HAS_VISIBLE_OBJECTS, 0, ICON_HIDE_OFF, + block, UI_BTYPE_ICON_TOGGLE_N, LAYER_COLLECTION_HAS_VISIBLE_OBJECTS, 0, ICON_HIDE_ON, (int)(ar->v2d.cur.xmax - OL_TOG_HIDEX), te->ys, UI_UNIT_X, UI_UNIT_Y, &lc->runtime_flag, 0, 0, 0, 0, TIP_("Hide collection in viewport (Ctrl to isolate)")); UI_but_func_set(bt, hidebutton_layer_collection_flag_cb, view_layer, lc); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); + UI_but_drawflag_enable(bt, UI_BUT_ICON_REVERSE); } PointerRNA collection_ptr; RNA_id_pointer_create(&collection->id, &collection_ptr); bt = uiDefIconButR_prop( - block, UI_BTYPE_ICON_TOGGLE, 0, ICON_RESTRICT_VIEW_OFF, + block, UI_BTYPE_ICON_TOGGLE, 0, 0, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_VIEWX), te->ys, UI_UNIT_X, - UI_UNIT_Y, &collection_ptr, collection_prop_hide_viewport, -1, 0, 0, 0, 0, NULL); + UI_UNIT_Y, &collection_ptr, props.collection_hide_viewport, -1, 0, 0, 0, 0, NULL); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); bt = uiDefIconButR_prop( - block, UI_BTYPE_ICON_TOGGLE, 0, ICON_RESTRICT_RENDER_OFF, + block, UI_BTYPE_ICON_TOGGLE, 0, 0, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_RENDERX), te->ys, UI_UNIT_X, - UI_UNIT_Y, &collection_ptr, collection_prop_hide_render, -1, 0, 0, 0, 0, NULL); + UI_UNIT_Y, &collection_ptr, props.collection_hide_render, -1, 0, 0, 0, 0, NULL); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); bt = uiDefIconButR_prop( - block, UI_BTYPE_ICON_TOGGLE, 0, ICON_RESTRICT_SELECT_OFF, + block, UI_BTYPE_ICON_TOGGLE, 0, 0, (int)(ar->v2d.cur.xmax - OL_TOG_RESTRICT_SELECTX), te->ys, UI_UNIT_X, - UI_UNIT_Y, &collection_ptr, collection_prop_hide_select, -1, 0, 0, 0, 0, NULL); + UI_UNIT_Y, &collection_ptr, props.collection_hide_select, -1, 0, 0, 0, 0, NULL); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); } } @@ -1059,10 +1060,10 @@ TreeElementIcon tree_element_get_icon(TreeStoreElem *tselem, TreeElement *te) data.icon = ICON_MOD_SUBSURF; break; case eGpencilModifierType_Thick: - data.icon = ICON_MAN_ROT; + data.icon = ICON_MOD_THICKNESS; break; case eGpencilModifierType_Tint: - data.icon = ICON_COLOR; + data.icon = ICON_MOD_TINT; break; case eGpencilModifierType_Array: data.icon = ICON_MOD_ARRAY; @@ -1074,7 +1075,7 @@ TreeElementIcon tree_element_get_icon(TreeStoreElem *tselem, TreeElement *te) data.icon = ICON_MOD_MASK; break; case eGpencilModifierType_Color: - data.icon = ICON_GROUP_VCOL; + data.icon = ICON_MOD_TINT; break; case eGpencilModifierType_Lattice: data.icon = ICON_MOD_LATTICE; @@ -1083,7 +1084,7 @@ TreeElementIcon tree_element_get_icon(TreeStoreElem *tselem, TreeElement *te) data.icon = ICON_MOD_MIRROR; break; case eGpencilModifierType_Simplify: - data.icon = ICON_MOD_DECIM; + data.icon = ICON_MOD_SIMPLIFY; break; case eGpencilModifierType_Smooth: data.icon = ICON_MOD_SMOOTH; @@ -1092,7 +1093,7 @@ TreeElementIcon tree_element_get_icon(TreeStoreElem *tselem, TreeElement *te) data.icon = ICON_HOOK; break; case eGpencilModifierType_Offset: - data.icon = ICON_MOD_DISPLACE; + data.icon = ICON_MOD_OFFSET; break; case eGpencilModifierType_Armature: data.icon = ICON_MOD_ARMATURE; @@ -1113,7 +1114,7 @@ TreeElementIcon tree_element_get_icon(TreeStoreElem *tselem, TreeElement *te) data.icon = ICON_BONE_DATA; break; case TSE_PROXY: - data.icon = ICON_GHOST; + data.icon = ICON_GHOST_ENABLED; break; case TSE_R_LAYER_BASE: data.icon = ICON_RENDERLAYERS; |