Author: mordante
Date: Sat Oct 11 21:53:43 2008
New Revision: 30057

URL: http://svn.gna.org/viewcvs/wesnoth?rev=30057&view=rev
Log:
Remove the now obsolete multiline_label_.

Modified:
    trunk/src/gui/widgets/control.cpp
    trunk/src/gui/widgets/control.hpp
    trunk/src/gui/widgets/tooltip.hpp

Modified: trunk/src/gui/widgets/control.cpp
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/src/gui/widgets/control.cpp?rev=30057&r1=30056&r2=30057&view=diff
==============================================================================
--- trunk/src/gui/widgets/control.cpp (original)
+++ trunk/src/gui/widgets/control.cpp Sat Oct 11 21:53:43 2008
@@ -23,7 +23,6 @@
 tcontrol::tcontrol(const unsigned canvas_count)
        : visible_(true)
        , label_()
-       , multiline_label_(false)
        , use_tooltip_on_label_overflow_(true)
        , tooltip_()
        , help_message_()
@@ -337,11 +336,6 @@
                renderer_.set_ellipse_mode(PANGO_ELLIPSIZE_NONE);
        }
 
-       if(multiline_label_) {
-               // FIXME multiline seems to be unused
-               renderer_.set_maximum_height(size.y);
-       }
-
        DBG_G_L << "tcontrol(" + get_control_type() + ") status:\n";
        DBG_G_L << "minimum_size " << minimum_size
                << " maximum_size " << maximum_size
@@ -357,9 +351,6 @@
                // but also we don't adjust for the extra text space yet!!!
                const tpoint maximum_size(config_->max_width, 
config_->max_height);
                renderer_.set_maximum_width(maximum_size.x ? maximum_size.x - 
border.x : -1);
-               if(multiline_label_) {
-                       renderer_.set_maximum_height(maximum_size.y ? 
maximum_size.y - border.y : -1);
-               }
        }
 
        size = renderer_.get_size() + border;

Modified: trunk/src/gui/widgets/control.hpp
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/src/gui/widgets/control.hpp?rev=30057&r1=30056&r2=30057&view=diff
==============================================================================
--- trunk/src/gui/widgets/control.hpp (original)
+++ trunk/src/gui/widgets/control.hpp Sat Oct 11 21:53:43 2008
@@ -167,10 +167,6 @@
        void set_visible(const bool visible = true) 
                { if(visible_ != visible) { visible_ = visible; set_dirty();} }
 
-       bool get_multiline_label() const { return multiline_label_; }
-       void set_multiline_label(const bool multiline = true) 
-               { if(multiline != multiline_label_) { multiline_label_ = 
multiline; set_dirty(); } }
-
        bool get_use_tooltip_on_label_overflow() const { return 
use_tooltip_on_label_overflow_; }
        void set_use_tooltip_on_label_overflow(const bool use_tooltip = true) 
                { use_tooltip_on_label_overflow_ = use_tooltip; }
@@ -234,14 +230,6 @@
 
        /** Contain the non-editable text associated with control. */
        t_string label_;
-
-       /** 
-        * Can the label contain multiple lines.
-        *
-        * This is needed in order to get the sizing, when the control can 
contain
-        * multiple lines of text we need to find the best width/height 
combination.
-        */
-       bool multiline_label_;
 
        /**
         * If the text doesn't fit on the label should the text be used as 
tooltip?

Modified: trunk/src/gui/widgets/tooltip.hpp
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/src/gui/widgets/tooltip.hpp?rev=30057&r1=30056&r2=30057&view=diff
==============================================================================
--- trunk/src/gui/widgets/tooltip.hpp (original)
+++ trunk/src/gui/widgets/tooltip.hpp Sat Oct 11 21:53:43 2008
@@ -24,6 +24,8 @@
  *
  * This is a small class which only has one state and that's active, so the
  * functions implemented are mostly dummies.
+ *
+ * @todo Allow wrapping for the tooltip.
  */
 class ttooltip : public tcontrol
 {
@@ -32,7 +34,6 @@
        ttooltip() :
                tcontrol(1)
        {
-               set_multiline_label();
        }
 
        /** Inherited from tcontrol. */


_______________________________________________
Wesnoth-commits mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-commits

Reply via email to