Skip to content

Commit a80c146

Browse files
committed
Renamed FactoryReport::txtProductDescription to mTxtProductDescription
1 parent fe0dd7b commit a80c146

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

OPHD/UI/Reports/FactoryReport.cpp

+10-10
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,8 @@ FactoryReport::FactoryReport() :
118118

119119
add(lstProducts, {cboFilterByProduct.rect().position.x + cboFilterByProduct.rect().size.x + 20, mRect.position.y + 230});
120120

121-
txtProductDescription.height(128);
122-
txtProductDescription.textColor(constants::PrimaryTextColor);
121+
mTxtProductDescription.height(128);
122+
mTxtProductDescription.textColor(constants::PrimaryTextColor);
123123

124124
fillLists();
125125
}
@@ -140,7 +140,7 @@ void FactoryReport::clearSelected()
140140
{
141141
lstFactoryList.clearSelected();
142142
selectedFactory = nullptr;
143-
txtProductDescription.text("");
143+
mTxtProductDescription.text("");
144144
}
145145

146146

@@ -270,8 +270,8 @@ void FactoryReport::onResize()
270270
lstProducts.size({detailPanelRect.size.x / 3, detailPanelRect.size.y - 219});
271271
lstProducts.selectionChanged().connect({this, &FactoryReport::onProductSelectionChange});
272272

273-
txtProductDescription.position(lstProducts.rect().crossXPoint() + NAS2D::Vector{158, 0});
274-
txtProductDescription.width(mRect.size.x - txtProductDescription.positionX() - 30);
273+
mTxtProductDescription.position(lstProducts.rect().crossXPoint() + NAS2D::Vector{158, 0});
274+
mTxtProductDescription.width(mRect.size.x - mTxtProductDescription.positionX() - 30);
275275
}
276276

277277

@@ -289,7 +289,7 @@ void FactoryReport::onVisibilityChange(bool visible)
289289

290290
if (selectedProductType != ProductType::PRODUCT_NONE)
291291
{
292-
txtProductDescription.text(ProductCatalogue::get(selectedProductType).Description);
292+
mTxtProductDescription.text(ProductCatalogue::get(selectedProductType).Description);
293293
}
294294
}
295295

@@ -416,11 +416,11 @@ void FactoryReport::onListSelectionChange()
416416

417417
if (productTypeInRange(selectedProductType))
418418
{
419-
txtProductDescription.text(ProductCatalogue::get(selectedProductType).Description);
419+
mTxtProductDescription.text(ProductCatalogue::get(selectedProductType).Description);
420420
}
421421
else
422422
{
423-
txtProductDescription.text("");
423+
mTxtProductDescription.text("");
424424
}
425425

426426
StructureState state = selectedFactory->state();
@@ -431,7 +431,7 @@ void FactoryReport::onListSelectionChange()
431431
void FactoryReport::onProductSelectionChange()
432432
{
433433
selectedProductType = static_cast<ProductType>(lstProducts.isItemSelected() ? lstProducts.selected().tag : 0);
434-
txtProductDescription.text(ProductCatalogue::get(selectedProductType).Description);
434+
mTxtProductDescription.text(ProductCatalogue::get(selectedProductType).Description);
435435
}
436436

437437

@@ -494,7 +494,7 @@ void FactoryReport::drawProductPane(Renderer& renderer)
494494
{
495495
renderer.drawText(fontBigBold, ProductCatalogue::get(selectedProductType).Name, NAS2D::Point{position_x, detailPanelRect.position.y + 180}, constants::PrimaryTextColor);
496496
renderer.drawImage(productImage(selectedProductType), NAS2D::Point{position_x, lstProducts.positionY()});
497-
txtProductDescription.update();
497+
mTxtProductDescription.update();
498498
}
499499

500500
if (selectedFactory->productType() == ProductType::PRODUCT_NONE) { return; }

OPHD/UI/Reports/FactoryReport.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ class FactoryReport : public ReportInterface
9797

9898
ListBox<> lstProducts;
9999

100-
TextArea txtProductDescription;
100+
TextArea mTxtProductDescription;
101101

102102
Factory* selectedFactory = nullptr;
103103
ProductType selectedProductType = ProductType::PRODUCT_NONE;

0 commit comments

Comments
 (0)