Added a button in the header to toggle full screen mode. It'd be nice to have this right-aligned, but this doesn't seem possible in the layout engine currently.

This commit is contained in:
William Reynish 2009-10-20 13:56:53 +00:00
parent 5e2ddea1f3
commit b8eec2b8fe
3 changed files with 6 additions and 5 deletions

@ -17,7 +17,7 @@ class DATA_PT_empty(DataButtonsPanel):
ob = context.object
layout.itemR(ob, "empty_draw_type", text="Draw Type")
layout.itemR(ob, "empty_draw_size", text="Draw Size")
layout.itemR(ob, "empty_draw_type", text="Display")
layout.itemR(ob, "empty_draw_size", text="Size")
bpy.types.register(DATA_PT_empty)

@ -39,7 +39,8 @@ class INFO_HT_header(bpy.types.Header):
layout.template_running_jobs()
layout.itemL(text=scene.statistics())
layout.itemO("wm.window_fullscreen_toggle", icon='ICON_ARROW_LEFTRIGHT', text="")
class INFO_MT_file(bpy.types.Menu):
__label__ = "File"

@ -1405,13 +1405,13 @@ static void rna_def_object(BlenderRNA *brna)
prop= RNA_def_property(srna, "empty_draw_type", PROP_ENUM, PROP_NONE);
RNA_def_property_enum_sdna(prop, NULL, "empty_drawtype");
RNA_def_property_enum_items(prop, empty_drawtype_items);
RNA_def_property_ui_text(prop, "Empty Draw Type", "Viewport display style for empties.");
RNA_def_property_ui_text(prop, "Empty Display Type", "Viewport display style for empties.");
RNA_def_property_update(prop, NC_OBJECT|ND_DRAW, NULL);
prop= RNA_def_property(srna, "empty_draw_size", PROP_FLOAT, PROP_DISTANCE);
RNA_def_property_float_sdna(prop, NULL, "empty_drawsize");
RNA_def_property_range(prop, 0.01, 10.0);
RNA_def_property_ui_text(prop, "Empty Draw Size", "Size of of display for empties in the viewport.");
RNA_def_property_ui_text(prop, "Empty Display Size", "Size of of display for empties in the viewport.");
RNA_def_property_update(prop, NC_OBJECT|ND_DRAW, NULL);
/* render */