ILXStatusBar::ILXStatusBar(int argc, char* argv[]) : Application(&argc, &argv, (AppOptions) (OptDaleAuto)) { setBackgroundImage(ILIXI_DATADIR"car/statusbar/statusbar_bg.png"); setMargins(0, 0, 0, 0); HBoxLayout* mainLayout = new HBoxLayout(); mainLayout->setVerticalAlignment(Alignment::Middle); mainLayout->setSpacing(0); setLayout(mainLayout); _home = new StatusbarButton(); _home->addImage(new Image(ILIXI_DATADIR"car/statusbar/home.png", Size(48, 48))); _home->addImage(new Image(ILIXI_DATADIR"car/statusbar/homeG.png", Size(48, 48))); _home->setActive(1); _home->sigClicked.connect(sigc::mem_fun(this, &ILXStatusBar::clickedHome)); addWidget(_home); _switch = new StatusbarButton(); _switch->addImage(new Image(ILIXI_DATADIR"car/statusbar/switch.png", Size(48, 48))); _switch->addImage(new Image(ILIXI_DATADIR"car/statusbar/switchG.png", Size(48, 48))); _switch->sigClicked.connect(sigc::mem_fun(this, &ILXStatusBar::clickedSwitcher)); addWidget(_switch); _dash = new StatusbarButton(); _dash->addImage(new Image(ILIXI_DATADIR"car/statusbar/dash.png", Size(48, 48))); _dash->addImage(new Image(ILIXI_DATADIR"car/statusbar/dashG.png", Size(48, 48))); _dash->sigClicked.connect(sigc::mem_fun(this, &ILXStatusBar::clickedDash)); addWidget(_dash); _sound = new StatusbarButton(); _sound->addImage(new Image(ILIXI_DATADIR"car/statusbar/vol0.png", Size(48, 48))); _sound->addImage(new Image(ILIXI_DATADIR"car/statusbar/vol0G.png", Size(48, 48))); _sound->addImage(new Image(ILIXI_DATADIR"car/statusbar/vol1.png", Size(48, 48))); _sound->addImage(new Image(ILIXI_DATADIR"car/statusbar/vol1G.png", Size(48, 48))); _sound->addImage(new Image(ILIXI_DATADIR"car/statusbar/vol2.png", Size(48, 48))); _sound->addImage(new Image(ILIXI_DATADIR"car/statusbar/vol2G.png", Size(48, 48))); _sound->addImage(new Image(ILIXI_DATADIR"car/statusbar/vol3.png", Size(48, 48))); _sound->addImage(new Image(ILIXI_DATADIR"car/statusbar/vol3G.png", Size(48, 48))); _sound->sigClicked.connect(sigc::mem_fun(this, &ILXStatusBar::clickedSound)); _sound->setButtonState(6); addWidget(_sound); _back = new StatusbarButton(); _back->setVisible(false); _back->addImage(new Image(ILIXI_DATADIR"car/statusbar/back0.png", Size(48, 48))); _back->sigClicked.connect(sigc::mem_fun(this, &ILXStatusBar::clickedBack)); addWidget(_back); addWidget(new Clock()); _rca = new RemoteContentArea(); addWidget(_rca); sigVisible.connect(sigc::mem_fun(this, &ILXStatusBar::onShow)); sigHidden.connect(sigc::mem_fun(this, &ILXStatusBar::onHide)); _statComp = new StatusbarComponent(this); }
/** void QBoxLayout::setSpacing(int space) * bind/QBoxLayout.h:19 */ static int HBoxLayout_setSpacing(lua_State *L) { try { HBoxLayout *self = *((HBoxLayout **)dub_checksdata(L, 1, "mimas.HBoxLayout")); int space = dub_checkint(L, 2); self->setSpacing(space); return 0; } catch (std::exception &e) { lua_pushfstring(L, "setSpacing: %s", e.what()); } catch (...) { lua_pushfstring(L, "setSpacing: Unknown exception"); } return dub_error(L); }