Browse Source

Add tag label to ModuleBrowser modules

pull/1639/head
Andrew Belt 7 years ago
parent
commit
2c1f4ba094
1 changed files with 10 additions and 1 deletions
  1. +10
    -1
      src/app/ModuleBrowser.cpp

+ 10
- 1
src/app/ModuleBrowser.cpp View File

@@ -113,7 +113,7 @@ struct ModelItem : BrowserListItem {
addChild(manufacturerLabel);

SequentialLayout *layout2 = Widget::create<SequentialLayout>(Vec(7, BND_WIDGET_HEIGHT));
layout2->spacing = 10;
layout2->spacing = 0;
addChild(layout2);

FavoriteRadioButton *favoriteButton = new FavoriteRadioButton();
@@ -132,6 +132,15 @@ struct ModelItem : BrowserListItem {
// tagButton->text = gTagNames[tag];
// layout2->addChild(tagButton);
// }

Label *tagsLabel = new Label();
int i = 0;
for (ModelTag tag : model->tags) {
if (i++ > 0)
tagsLabel->text += ", ";
tagsLabel->text += gTagNames[tag];
}
layout2->addChild(tagsLabel);
}

void step() override {


Loading…
Cancel
Save