GameplayChat::GameplayChat() : Element(0, 0, LEMSCR_X, 20), msgs (Console::lines_max_number), name (0, 0), type (0, 0, LEMSCR_X), type_on_last_frame(0) { int y = 0; for (std::vector <Api::Label> ::iterator itr = msgs.begin(); itr != msgs.end(); ++itr) { itr->set_font(font_sml); itr->set_undraw_color(color[COL_PINK]); itr->set_y(y); y += y_msg; } set_undraw_color(color[COL_PINK]); name.set_undraw_color(color[COL_PINK]); type.set_undraw_color(color[COL_PINK]); std::string str = gloB->user_name + ':'; name.set_text(str); name.set_hidden(); type.set_x (name.get_xl()); type.set_xl(LEMSCR_X - name.get_xl()); type.set_on_enter(this, type_on_enter_callback); type.set_on_esc (this, type_on_esc_callback); type.set_invisible(); }
DirList::DirList(const int x, const int y, const int xl, const int yl, const Filename& bdir, const Filename& cdir) : Frame(x, y, xl, yl), page (0), bottom_button(yl/20-1), base_dir (bdir.get_dir_rootful()), current_dir (cdir.is_child_of(bdir) ? Filename(cdir.get_dir_rootful()) : base_dir), clicked (false) { load_current_dir(); set_undraw_color(color[COL_API_M]); }