Merge remote-tracking branch 'nana_jh/develop' into dev_nana_fs
* nana_jh/develop: restore travis and CMakeLists fix missing ~other_tag, remove some warings fix crash that deprecation is included in NANA_IGNORE_CONF debug travis debug travis debug travis debug travis debug travis debug travis debug travis debug travis debug travis debug travis debug travis debug crash for travis debug a crash for travis debug a crash for travis
This commit is contained in:
@@ -449,7 +449,7 @@ namespace std
|
||||
//template< >
|
||||
std::string put_time/*<char, std::string>*/(const std::tm* tmb, const char* fmt)
|
||||
{
|
||||
unsigned sz = 200;
|
||||
std::size_t sz = 200;
|
||||
std::string str(sz, '\0');
|
||||
sz = std::strftime(&str[0], str.size() - 1, fmt, tmb);
|
||||
str.resize(sz);
|
||||
|
||||
@@ -211,19 +211,24 @@ namespace nana
|
||||
basic_window::other_tag::other_tag(category::flags categ)
|
||||
: category(categ), active_window(nullptr), upd_state(update_state::none)
|
||||
{
|
||||
#ifndef WIDGET_FRAME_DEPRECATED
|
||||
switch(categ)
|
||||
{
|
||||
case category::flags::root:
|
||||
attribute.root = new attr_root_tag;
|
||||
break;
|
||||
#ifndef WIDGET_FRAME_DEPRECATED
|
||||
case category::flags::frame:
|
||||
attribute.frame = new attr_frame_tag;
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
attribute.root = nullptr;
|
||||
}
|
||||
#else
|
||||
if (category::flags::root == categ)
|
||||
attribute.root = new attr_root_tag;
|
||||
else
|
||||
attribute.root = nullptr;
|
||||
#endif
|
||||
}
|
||||
|
||||
basic_window::other_tag::~other_tag()
|
||||
|
||||
@@ -23,6 +23,8 @@
|
||||
#include <stdexcept>
|
||||
#include <algorithm>
|
||||
|
||||
#include <iostream> //debug travis
|
||||
|
||||
namespace nana
|
||||
{
|
||||
|
||||
@@ -92,7 +94,9 @@ namespace detail
|
||||
{
|
||||
void operator()(basic_window* wd) const
|
||||
{
|
||||
std::cout << "delete basic_window " << wd <<" category="<<static_cast<int>(wd->other.category)<< std::endl;
|
||||
delete wd;
|
||||
std::cout << " delete successfully" << std::endl;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -2078,7 +2078,7 @@ namespace nana
|
||||
|
||||
unsigned x_offset() const
|
||||
{
|
||||
return (h.empty() ? 0 : h.value());
|
||||
return static_cast<unsigned>(h.empty() ? 0 : h.value());
|
||||
}
|
||||
|
||||
index_pair offset_y_abs, offset_y_dpl; //cat stands for category, item stands for item. "item == npos" means that is a category.
|
||||
|
||||
@@ -3451,7 +3451,7 @@ namespace nana{ namespace widgets
|
||||
|
||||
unsigned text_editor::_m_char_by_pixels(const unicode_bidi::entity& ent, unsigned pos)
|
||||
{
|
||||
unsigned len = ent.end - ent.begin;
|
||||
auto len = static_cast<std::size_t>(ent.end - ent.begin);
|
||||
|
||||
std::unique_ptr<unsigned[]> pxbuf(new unsigned[len]);
|
||||
if (graph_.glyph_pixels(ent.begin, len, pxbuf.get()))
|
||||
|
||||
@@ -627,7 +627,7 @@ namespace nana
|
||||
std::unique_ptr<unsigned[]> pixels(new unsigned[text.size()]);
|
||||
graph_.glyph_pixels(text.c_str(), text.size(), pixels.get());
|
||||
|
||||
unsigned substr_len = 0;
|
||||
std::size_t substr_len = 0;
|
||||
unsigned substr_px = 0;
|
||||
|
||||
if (align::right == text_align_ex_)
|
||||
|
||||
Reference in New Issue
Block a user