Merge branch 'hotfixes-0.9.1' into develop

Conflicts:
	include/nana/gui/widgets/progress.hpp
	source/gui/widgets/date_chooser.cpp
	source/gui/widgets/progress.cpp
	source/gui/widgets/treebox.cpp
This commit is contained in:
cnjinhao
2015-02-02 18:55:23 +08:00
15 changed files with 201 additions and 71 deletions

View File

@@ -44,7 +44,6 @@ namespace drawerbase
private:
static const int interval = 4;
widget* widget_;
unsigned state_;
std::unique_ptr<implement> imptr_;
implement * impl_;
};

View File

@@ -56,7 +56,7 @@ namespace nana
bool _m_get_trace(point, int & res);
void _m_perf_transform(transform_action tfid, graph_reference, graph_reference dirtybuf, graph_reference newbuf, const nana::point& refpos);
private:
void refresh(graph_reference);
void refresh(graph_reference) override;
void attached(widget_reference, graph_reference) override;
void mouse_move(graph_reference, const arg_mouse&) override;
void mouse_leave(graph_reference, const arg_mouse&) override;

View File

@@ -40,6 +40,7 @@ namespace nana
bool _m_check_changing(unsigned) const;
private:
static const unsigned border = 2;
widget * widget_{nullptr};
nana::paint::graphics* graph_{nullptr};
unsigned draw_width_{static_cast<unsigned>(-1)};

View File

@@ -185,7 +185,7 @@ namespace nana
return false;
}
private:
void attached(widget_reference widget, graph_reference graph)
void attached(widget_reference widget, graph_reference graph) override
{
graph_ = &graph;
widget_ = static_cast< ::nana::scroll<Vertical>*>(&widget);
@@ -195,12 +195,12 @@ namespace nana
timer_.elapse(std::bind(&trigger::_m_tick, this));
}
void detached()
void detached() override
{
graph_ = nullptr;
}
void refresh(graph_reference graph)
void refresh(graph_reference graph) override
{
drawer_.draw(graph, metrics_.what);
}
@@ -218,7 +218,7 @@ namespace nana
API::lazy_refresh();
}
void mouse_move(graph_reference graph, const ::nana::arg_mouse& arg)
void mouse_move(graph_reference graph, const ::nana::arg_mouse& arg) override
{
bool redraw = false;
if(metrics_.pressed && (metrics_.what == buttons::scroll))
@@ -245,7 +245,7 @@ namespace nana
}
}
void mouse_down(graph_reference graph, const arg_mouse& arg)
void mouse_down(graph_reference graph, const arg_mouse& arg) override
{
if(arg.left_button)
{
@@ -280,7 +280,7 @@ namespace nana
}
}
void mouse_up(graph_reference graph, const arg_mouse& arg)
void mouse_up(graph_reference graph, const arg_mouse& arg) override
{
timer_.stop();
@@ -292,7 +292,7 @@ namespace nana
API::lazy_refresh();
}
void mouse_leave(graph_reference graph, const arg_mouse&)
void mouse_leave(graph_reference graph, const arg_mouse&) override
{
if(metrics_.pressed) return;
@@ -301,7 +301,7 @@ namespace nana
API::lazy_refresh();
}
void mouse_wheel(graph_reference graph, const arg_wheel& arg)
void mouse_wheel(graph_reference graph, const arg_wheel& arg) override
{
if(make_step(arg.upwards == false, 3))
{

View File

@@ -45,9 +45,7 @@ namespace nana{ namespace widgets{ namespace skeletons
tokenizer(const nana::string& s, bool format_enabled)
: iptr_(s.data()),
endptr_(s.data() + s.size()),
format_enabled_(format_enabled),
format_state_(false),
revert_token_(token::eof)
format_enabled_(format_enabled)
{
}
@@ -414,17 +412,14 @@ namespace nana{ namespace widgets{ namespace skeletons
}
}
private:
const nana::char_t * iptr_;
const nana::char_t * endptr_;
const ::nana::char_t * iptr_;
const ::nana::char_t * endptr_;
const bool format_enabled_;
bool format_state_;
bool format_state_{false};
nana::string idstr_;
::nana::string idstr_;
std::pair<nana::string, nana::string> binary_;
std::size_t whspace_size_;
token revert_token_;
token revert_token_{token::eof};
};
//The fblock states a format, and a format from which it is inherted
@@ -528,7 +523,7 @@ namespace nana{ namespace widgets{ namespace skeletons
{
public:
data_image(const nana::string& imgpath, const nana::size & sz, std::size_t limited)
: image_(imgpath), limited_(limited)
: image_(imgpath)//, limited_(limited)
{
size_ = image_.size();
@@ -597,7 +592,6 @@ namespace nana{ namespace widgets{ namespace skeletons
nana::string str_;
nana::paint::image image_;
nana::size size_;
std::size_t limited_;
};
class dstream
@@ -927,7 +921,6 @@ namespace nana{ namespace widgets{ namespace skeletons
}
private:
bool format_enabled_;
std::vector<fblock*> fblocks_;
std::list<std::deque<value> > lines_;

View File

@@ -416,8 +416,6 @@ namespace nana
/// Determinte whether the checkbox is enabled.
bool checkable() const;
treebox& icon(const nana::string& id, const node_image_type& node_img);
node_image_type& icon(const nana::string& id) const;
void icon_erase(const nana::string& id);

View File

@@ -212,7 +212,7 @@ namespace nana
}
}
general_events& _m_get_general_events() const
general_events& _m_get_general_events() const override
{
return *events_;
}
@@ -295,7 +295,7 @@ namespace nana
}
}
general_events& _m_get_general_events() const
general_events& _m_get_general_events() const override
{
return *events_;
}
@@ -440,7 +440,7 @@ namespace nana
API::dev::attach_drawer(*this, trigger_);
}
general_events& _m_get_general_events() const
general_events& _m_get_general_events() const override
{
return *events_;
}
@@ -532,7 +532,7 @@ namespace nana
}
}
general_events& _m_get_general_events() const
general_events& _m_get_general_events() const override
{
return *events_;
}

View File

@@ -127,7 +127,7 @@ namespace nana
class arg_eval;
template<typename Return>
class arg_function
class arg_function: public eval_arg
{
public:
arg_function(std::function<Return()> fn)
@@ -208,4 +208,4 @@ namespace nana
};//end class i18n_eval;
}
#endif//NANA_I18N_HPP
#endif//NANA_I18N_HPP