From 3f335ce3d446372eeb9ed87f7e117099c4d2dd6a Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Tue, 11 Jun 2019 15:43:37 -0300 Subject: Texture refactor -Texture renamed to Texture2D -TextureLayered as base now inherits 2Darray, cubemap and cubemap array -Removed all references to flags in textures (they will go in the shader) -Texture3D gone for now (will come back later done properly) -Create base rasterizer for RenderDevice, RasterizerRD --- scene/gui/control.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'scene/gui/control.cpp') diff --git a/scene/gui/control.cpp b/scene/gui/control.cpp index 4c70bd1d39..be211504a6 100644 --- a/scene/gui/control.cpp +++ b/scene/gui/control.cpp @@ -358,7 +358,7 @@ void Control::_get_property_list(List *p_list) const { if (data.icon_override.has(E->get())) hint |= PROPERTY_USAGE_STORAGE | PROPERTY_USAGE_CHECKED; - p_list->push_back(PropertyInfo(Variant::OBJECT, "custom_icons/" + E->get(), PROPERTY_HINT_RESOURCE_TYPE, "Texture", hint)); + p_list->push_back(PropertyInfo(Variant::OBJECT, "custom_icons/" + E->get(), PROPERTY_HINT_RESOURCE_TYPE, "Texture2D", hint)); } } { @@ -813,11 +813,11 @@ Size2 Control::get_minimum_size() const { return Size2(); } -Ref Control::get_icon(const StringName &p_name, const StringName &p_type) const { +Ref Control::get_icon(const StringName &p_name, const StringName &p_type) const { if (p_type == StringName() || p_type == get_class_name()) { - const Ref *tex = data.icon_override.getptr(p_name); + const Ref *tex = data.icon_override.getptr(p_name); if (tex) return *tex; } @@ -1063,7 +1063,7 @@ int Control::get_constant(const StringName &p_name, const StringName &p_type) co bool Control::has_icon_override(const StringName &p_name) const { - const Ref *tex = data.icon_override.getptr(p_name); + const Ref *tex = data.icon_override.getptr(p_name); return tex != NULL; } @@ -1880,7 +1880,7 @@ Rect2 Control::get_anchorable_rect() const { return Rect2(Point2(), get_size()); } -void Control::add_icon_override(const StringName &p_name, const Ref &p_icon) { +void Control::add_icon_override(const StringName &p_name, const Ref &p_icon) { if (data.icon_override.has(p_name)) { data.icon_override[p_name]->disconnect("changed", this, "_override_changed"); -- cgit v1.2.3