From 1afc45aaae50ab208f75e27e7a4d88004402023e Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Fri, 7 Sep 2012 01:40:13 +0200 Subject: menu/static: code style: remove this/getter if not needed --- src/menu/static.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/menu') diff --git a/src/menu/static.cpp b/src/menu/static.cpp index 8bd61ff1..40ff3f6e 100644 --- a/src/menu/static.cpp +++ b/src/menu/static.cpp @@ -85,8 +85,7 @@ namespace usdx void Static::draw(void) { // shortcut if not initilized or nothing to draw - if ((this->vertices == NULL) - || (!this->get_filled() && !this->get_stroked())) + if ((vertices == NULL) || !(filled || stroked)) return; glEnableClientState(GL_VERTEX_ARRAY); @@ -94,7 +93,7 @@ namespace usdx glVertexPointer(2, GL_FLOAT, 0, vertices); - if (this->get_filled()) { + if (filled) { // draw filling glEnable(GL_BLEND); glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); @@ -106,7 +105,7 @@ namespace usdx glDisable(GL_BLEND); } - if (this->get_stroked()) { + if (stroked) { // draw border glColorPointer(stroke.get_array_comonent_count(), GL_UNSIGNED_BYTE, 0, stroke.get_array(vertices_count)); -- cgit v1.2.3