mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-13 16:18:42 +00:00
Add What's this help for tile configuration in Overview charts
This commit is contained in:
@@ -541,6 +541,17 @@ OverviewConfigDialog::OverviewConfigDialog(ChartSpaceItem*item) : QDialog(NULL),
|
||||
setWindowFlags(windowFlags() | Qt::WindowCloseButtonHint);
|
||||
setModal(true);
|
||||
|
||||
// get the factory and set what's this string according to type
|
||||
ChartSpaceItemRegistry ®istry = ChartSpaceItemRegistry::instance();
|
||||
ChartSpaceItemDetail itemDetail = registry.detailForType(item->type);
|
||||
itemDetail.quick.replace(" ", "-"); // Blanks are replaced by - in Wiki URLs
|
||||
HelpWhatsThis *help = new HelpWhatsThis(this);
|
||||
if (item->parent->scope & OverviewScope::ANALYSIS) {
|
||||
this->setWhatsThis(help->getWhatsThisText(HelpWhatsThis::ChartRides_Overview_Config).arg(itemDetail.quick, itemDetail.description));
|
||||
} else {
|
||||
this->setWhatsThis(help->getWhatsThisText(HelpWhatsThis::Chart_Overview_Config).arg(itemDetail.quick, itemDetail.description));
|
||||
}
|
||||
|
||||
main = new QVBoxLayout(this);
|
||||
main->addWidget(item->config());
|
||||
item->config()->show();
|
||||
|
||||
@@ -213,6 +213,8 @@ HelpWhatsThis::getText(GCHelp chapter) {
|
||||
return text.arg("ChartTypes_Diary#navigator").arg(tr("Configurable activity log - with build in search capabilities"));
|
||||
case ChartRides_Overview:
|
||||
return text.arg("ChartTypes_Activities#Overview").arg(tr("Dashboard for a single activity - the tiles shown here are configurable"));
|
||||
case ChartRides_Overview_Config:
|
||||
return text.arg("ChartTypes_Activities#Overview-%1");
|
||||
case ChartRides_Summary:
|
||||
return text.arg("ChartTypes_Activities#activity-summary").arg(tr("Detailed information of a single activity - the metrics shown here are configurable"));
|
||||
case ChartRides_Details:
|
||||
@@ -255,6 +257,8 @@ HelpWhatsThis::getText(GCHelp chapter) {
|
||||
return text.arg("ChartTypes_Trends#summary").arg(tr("Chart specific filter/search and date range settings"));
|
||||
case Chart_Overview:
|
||||
return text.arg("ChartTypes_Trends#Overview").arg(tr("Dashboard for the selected data range - the tiles shown are configurable"));
|
||||
case Chart_Overview_Config:
|
||||
return text.arg("ChartTypes_Trends#Overview-%1");
|
||||
case Chart_R:
|
||||
return text.arg("Special-Topics_Working-with-R").arg(tr("Embedded R Chart"));
|
||||
case Chart_Python:
|
||||
|
||||
@@ -116,6 +116,7 @@ Q_OBJECT
|
||||
ChartDiary_Navigator,
|
||||
|
||||
ChartRides_Overview,
|
||||
ChartRides_Overview_Config,
|
||||
ChartRides_Summary,
|
||||
ChartRides_Details,
|
||||
ChartRides_Editor,
|
||||
@@ -137,6 +138,7 @@ Q_OBJECT
|
||||
Chart_Summary,
|
||||
Chart_Summary_Config,
|
||||
Chart_Overview,
|
||||
Chart_Overview_Config,
|
||||
Chart_R,
|
||||
Chart_Python,
|
||||
Chart_User,
|
||||
|
||||
Reference in New Issue
Block a user