Skip to content

Commit

Permalink
Reinvestigate Toolbar type File
Browse files Browse the repository at this point in the history
Added icons to the Open GL Render items, and one for the Search menu item. And added the Search menu item to the toolbar too.

Issue: https://www.bforartists.de/content/reinvestigate-toolbar-type-file
  • Loading branch information
ReinerBforartists committed Apr 1, 2017
1 parent d632664 commit facacb5
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 5 deletions.
2 changes: 2 additions & 0 deletions release/scripts/addons/bforartists_toolbar_settings.py
Expand Up @@ -51,6 +51,7 @@ class bforartists_toolbar_settings(AddonPreferences):
file_render = BoolProperty(name="Render", default=True, description = "Display the Render Toolbar\nAll Modes", )
file_render_opengl = BoolProperty(name="Render Open GL", default=False, description = "Display the Render Open GL Toolbar\nAll Modes", )
file_render_misc = BoolProperty(name="Render Misc", default=False, description = "Display the Render Misc Toolbar\nAll Modes", )
file_window_search = BoolProperty(name="Window Search", default=False, description = "Display the Search Toolbar\nAll Modes", )

# view

Expand Down Expand Up @@ -127,6 +128,7 @@ def draw(self, context):
row = layout.row()

row.prop(self, "file_render_misc")
row.prop(self, "file_window_search")

layout.label(text="The View toolbar container")

Expand Down
10 changes: 5 additions & 5 deletions release/scripts/startup/bl_ui/space_info.py
@@ -1,4 +1,4 @@
# ##### BEGIN GPL LICENSE BLOCK #####
# ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
Expand Down Expand Up @@ -351,13 +351,13 @@ def draw(self, context):

layout.separator()

layout.operator("render.opengl", text="OpenGL Render Image")
layout.operator("render.opengl", text="OpenGL Render Animation").animation = True
layout.operator("render.opengl", text="OpenGL Render Image", icon = 'RENDER_STILL_VIEW')
layout.operator("render.opengl", text="OpenGL Render Animation", icon = 'RENDER_ANI_VIEW').animation = True
layout.menu("INFO_MT_opengl_render")

layout.separator()

layout.operator("render.view_show")
layout.operator("render.view_show",icon = 'HIDE_RENDERVIEW')
layout.operator("render.play_rendered_anim", icon='PLAY')


Expand Down Expand Up @@ -407,7 +407,7 @@ def draw(self, context):

layout.separator()

layout.operator("wm.search_menu") # The search menu. Note that this just calls the pure search menu, and not the whole search menu addon.
layout.operator("wm.search_menu", icon='VIEWZOOM') # The search menu. Note that this just calls the pure search menu, and not the whole search menu addon.

class INFO_MT_help(Menu):
bl_label = "Help"
Expand Down
10 changes: 10 additions & 0 deletions release/scripts/startup/bl_ui/space_toolbar.py
Expand Up @@ -124,6 +124,7 @@ def draw(self, context):
layout.prop(addon_prefs, "file_render")
layout.prop(addon_prefs, "file_render_opengl")
layout.prop(addon_prefs, "file_render_misc")
layout.prop(addon_prefs, "file_window_search")


############### bfa - Load Save menu hidable by the flag in the right click menu
Expand Down Expand Up @@ -253,6 +254,15 @@ def draw_menus(layout, context):
row.operator("render.view_show", text="", icon = 'HIDE_RENDERVIEW')
row.operator("render.play_rendered_anim", icon='PLAY', text="")

## ------------------ Search

if addon_prefs.file_window_search:

row = layout.row(align=True)

row.operator("wm.search_menu", text= "", icon='VIEWZOOM') # The search menu. Note that this just calls the pure search menu, and not the whole search menu addon.


######################################## View ##############################################


Expand Down

0 comments on commit facacb5

Please sign in to comment.