virtual void create_painter(painter_ptr & p_out) { if (p_wnd->get_wnd()) { p_out = new painter_impl(p_wnd.get_ptr()); } }
void file::g_transfer_object(service_ptr_t<file> p_src,service_ptr_t<file> p_dst,t_filesize p_bytes,abort_callback & p_abort) { if (p_bytes > 1024) /* don't bother on small objects */ { t_filesize oldsize = p_dst->get_size(p_abort); if (oldsize != filesize_invalid) { t_filesize newpos = p_dst->get_position(p_abort) + p_bytes; if (newpos > oldsize) p_dst->resize(newpos ,p_abort); } } g_transfer_object(pfc::implicit_cast<stream_reader*>(p_src.get_ptr()),pfc::implicit_cast<stream_writer*>(p_dst.get_ptr()),p_bytes,p_abort); }
void readbox(service_ptr_t<file> & p_file, abort_callback & p_abort) { readbox(p_file.get_ptr(), p_file->get_remaining(p_abort), p_abort); }
t_filesize file::g_transfer(service_ptr_t<file> p_src,service_ptr_t<file> p_dst,t_filesize p_bytes,abort_callback & p_abort) { return g_transfer(pfc::implicit_cast<stream_reader*>(p_src.get_ptr()),pfc::implicit_cast<stream_writer*>(p_dst.get_ptr()),p_bytes,p_abort); }