- Removed ColUDA::is_uda override, because it was wrong.  Now in the base class
  a member variable is referenced.
This commit is contained in:
Paul Beckingham 2014-04-16 00:06:29 -04:00
parent 2aa224d278
commit 8d10d81198
5 changed files with 19 additions and 15 deletions

View file

@ -43,6 +43,7 @@ ColumnUDA::ColumnUDA ()
_type = "string";
_style = "default";
_label = "";
_uda = true;
_hyphenate = (_type == "string") ? true : false;
@ -56,12 +57,6 @@ ColumnUDA::~ColumnUDA ()
{
}
////////////////////////////////////////////////////////////////////////////////
bool ColumnUDA::is_uda () const
{
return true;
}
////////////////////////////////////////////////////////////////////////////////
bool ColumnUDA::validate (std::string& value)
{

View file

@ -39,7 +39,6 @@ public:
ColumnUDA ();
~ColumnUDA ();
bool is_uda () const;
bool validate (std::string&);
void measure (Task&, unsigned int&, unsigned int&);
void render (std::vector <std::string>&, Task&, int, Color&);

View file

@ -209,6 +209,7 @@ Column::Column ()
, _label ("")
, _report ("")
, _modifiable (true)
, _uda (false)
{
}
@ -221,6 +222,7 @@ Column::Column (const Column& other)
_label = other._label;
_label = other._report;
_modifiable = other._modifiable;
_uda = other._uda;
}
////////////////////////////////////////////////////////////////////////////////
@ -234,6 +236,7 @@ Column& Column::operator= (const Column& other)
_label = other._label;
_report = other._report;
_modifiable = other._modifiable;
_uda = other._uda;
}
return *this;
@ -242,12 +245,13 @@ Column& Column::operator= (const Column& other)
////////////////////////////////////////////////////////////////////////////////
bool Column::operator== (const Column& other) const
{
return _name == other._name &&
_type == other._type &&
_style == other._style &&
_label == other._label &&
_report == other._report &&
_modifiable == other._modifiable;
return _name == other._name &&
_type == other._type &&
_style == other._style &&
_label == other._label &&
_report == other._report &&
_modifiable == other._modifiable &&
_uda == other._uda;
}
////////////////////////////////////////////////////////////////////////////////

View file

@ -50,7 +50,7 @@ public:
std::string label () const { return _label; }
std::string type () const { return _type; }
bool modifiable () const { return _modifiable; }
bool is_uda () const { return false; }
bool is_uda () const { return _uda; }
std::vector <std::string> styles () const { return _styles; }
std::vector <std::string> examples () const { return _examples; }
@ -74,6 +74,7 @@ protected:
std::string _label;
std::string _report;
bool _modifiable;
bool _uda;
std::vector <std::string> _styles;
std::vector <std::string> _examples;
};