listbox have def_export_options();

This commit is contained in:
qPCR4vir 2015-04-25 20:53:13 +02:00
parent 8fdbb0bf44
commit 2767fa75ca
2 changed files with 14 additions and 1 deletions

View File

@ -432,7 +432,7 @@ namespace nana
struct export_options
{
nana::string sep = nana::string {STR(";" )},
nana::string sep = nana::string {STR("\t" )},
endl= nana::string {STR("\n")} ;
bool only_selected_items{true},
only_checked_items {false},
@ -591,6 +591,7 @@ By \a clicking on a header the list get \a reordered, first up, and then down al
void enable_single(bool for_selection, bool category_limited);
void disable_single(bool for_selection);
export_options& def_export_options();
private:
drawerbase::listbox::essence_t & _m_ess() const;
nana::any* _m_anyobj(size_type cat, size_type index, bool allocate_if_empty) const;

View File

@ -1856,6 +1856,13 @@ namespace nana
unsigned item_size{24};
unsigned text_height{0};
unsigned suspension_width{0};
::nana::listbox::export_options def_exp_options ;
::nana::listbox::export_options& def_export_options()
{
return def_exp_options;
}
es_header header;
es_lister lister; // we have at least one emty cat. the #0
@ -4191,6 +4198,11 @@ namespace nana
_m_ess().lister.disable_single(for_selection);
}
listbox::export_options& listbox::def_export_options()
{
return _m_ess().def_export_options();
}
drawerbase::listbox::essence_t & listbox::_m_ess() const
{
return get_drawer_trigger().essence();