oops..layer.cpp got broken by mistake, reverting back.
This commit is contained in:
parent
ec92236c1f
commit
10b7debd72
1 changed files with 38 additions and 10 deletions
|
@ -37,6 +37,8 @@ namespace mapnik
|
|||
Layer::Layer()
|
||||
: params_(),
|
||||
name_("unknown"),
|
||||
title_(""),
|
||||
abstract_(""),
|
||||
minZoom_(0),
|
||||
maxZoom_(std::numeric_limits<double>::max()),
|
||||
active_(true),
|
||||
|
@ -47,6 +49,8 @@ namespace mapnik
|
|||
Layer::Layer(const parameters& params)
|
||||
:params_(params),
|
||||
name_(params_["name"]),
|
||||
title_(params_["title"]),
|
||||
abstract_(params_["abstract"]),
|
||||
minZoom_(0),
|
||||
maxZoom_(std::numeric_limits<double>::max()),
|
||||
active_(true),
|
||||
|
@ -55,15 +59,17 @@ namespace mapnik
|
|||
{}
|
||||
|
||||
Layer::Layer(const Layer& rhs)
|
||||
: params_(rhs.params_),
|
||||
name_(rhs.name_),
|
||||
minZoom_(rhs.minZoom_),
|
||||
maxZoom_(rhs.maxZoom_),
|
||||
active_(rhs.active_),
|
||||
selectable_(rhs.selectable_),
|
||||
styles_(rhs.styles_),
|
||||
selection_style_(rhs.selection_style_),
|
||||
ds_(rhs.ds_) {}
|
||||
:params_(rhs.params_),
|
||||
name_(rhs.name_),
|
||||
title_(rhs.title_),
|
||||
abstract_(rhs.abstract_),
|
||||
minZoom_(rhs.minZoom_),
|
||||
maxZoom_(rhs.maxZoom_),
|
||||
active_(rhs.active_),
|
||||
selectable_(rhs.selectable_),
|
||||
ds_(rhs.ds_),
|
||||
styles_(rhs.styles_),
|
||||
selection_style_(rhs.selection_style_) {}
|
||||
|
||||
Layer& Layer::operator=(const Layer& rhs)
|
||||
{
|
||||
|
@ -81,11 +87,13 @@ namespace mapnik
|
|||
{
|
||||
params_=rhs.params_;
|
||||
name_=rhs.name_;
|
||||
title_=rhs.title_;
|
||||
abstract_=rhs.abstract_;
|
||||
minZoom_=rhs.minZoom_;
|
||||
maxZoom_=rhs.maxZoom_;
|
||||
active_=rhs.active_;
|
||||
selectable_=rhs.selectable_;
|
||||
ds_=rhs.ds_;
|
||||
//ds_=rhs.ds_;
|
||||
styles_=rhs.styles_;
|
||||
selection_style_=rhs.selection_style_;
|
||||
}
|
||||
|
@ -107,6 +115,26 @@ namespace mapnik
|
|||
return name_;
|
||||
}
|
||||
|
||||
void Layer::set_title( std::string const& title)
|
||||
{
|
||||
title_ = title;
|
||||
}
|
||||
|
||||
string const& Layer::title() const
|
||||
{
|
||||
return title_;
|
||||
}
|
||||
|
||||
void Layer::set_abstract( std::string const& abstract)
|
||||
{
|
||||
abstract_ = abstract;
|
||||
}
|
||||
|
||||
string const& Layer::abstract() const
|
||||
{
|
||||
return abstract_;
|
||||
}
|
||||
|
||||
void Layer::add_style(std::string const& stylename)
|
||||
{
|
||||
styles_.push_back(stylename);
|
||||
|
|
Loading…
Add table
Reference in a new issue