Changeset View
Changeset View
Standalone View
Standalone View
release/scripts/startup/bl_ui/space_outliner.py
| Show First 20 Lines • Show All 307 Lines • ▼ Show 20 Lines | def draw(self, context): | ||||
| layout.separator() | layout.separator() | ||||
| OUTLINER_MT_context_menu.draw_common_operators(layout) | OUTLINER_MT_context_menu.draw_common_operators(layout) | ||||
| class OUTLINER_MT_asset(Menu): | class OUTLINER_MT_asset(Menu): | ||||
| bl_label = "Assets" | bl_label = "Assets" | ||||
| @classmethod | |||||
| def poll(cls, context): | |||||
| return context.preferences.experimental.use_extended_asset_browser | |||||
Severin: Just always show the mark/clear context menu entries in the Outliner now. We //could// make it… | |||||
Done Inline Actions+1 on disabled + hint sybren: +1 on disabled + hint | |||||
| def draw(self, context): | def draw(self, context): | ||||
| layout = self.layout | layout = self.layout | ||||
| space = context.space_data | space = context.space_data | ||||
| layout.operator("asset.mark") | layout.operator("asset.mark") | ||||
| layout.operator("asset.clear", text="Clear Asset").set_fake_user = False | layout.operator("asset.clear", text="Clear Asset").set_fake_user = False | ||||
| layout.operator("asset.clear", text="Clear Asset (Set Fake User)").set_fake_user = True | layout.operator("asset.clear", text="Clear Asset (Set Fake User)").set_fake_user = True | ||||
| ▲ Show 20 Lines • Show All 157 Lines • Show Last 20 Lines | |||||
Just always show the mark/clear context menu entries in the Outliner now. We could make it "smarter" and only show it when supported assets are selected. Then we'd have to move the menu back to C though, and I think having a disabled button with a disabled hint is nice.