Codechange: Silence warnings about intentionally unused parameters.
This commit is contained in:
@@ -580,7 +580,7 @@ void LinkGraphLegendWindow::SetOverlay(std::shared_ptr<LinkGraphOverlay> overlay
|
||||
}
|
||||
}
|
||||
|
||||
void LinkGraphLegendWindow::UpdateWidgetSize(int widget, Dimension *size, const Dimension &padding, Dimension *fill, Dimension *resize)
|
||||
void LinkGraphLegendWindow::UpdateWidgetSize(int widget, Dimension *size, [[maybe_unused]] const Dimension &padding, [[maybe_unused]] Dimension *fill, [[maybe_unused]] Dimension *resize)
|
||||
{
|
||||
if (IsInsideMM(widget, WID_LGL_SATURATION_FIRST, WID_LGL_SATURATION_LAST + 1)) {
|
||||
StringID str = STR_NULL;
|
||||
@@ -639,7 +639,7 @@ void LinkGraphLegendWindow::DrawWidget(const Rect &r, int widget) const
|
||||
}
|
||||
}
|
||||
|
||||
bool LinkGraphLegendWindow::OnTooltip(Point pt, int widget, TooltipCloseCondition close_cond)
|
||||
bool LinkGraphLegendWindow::OnTooltip([[maybe_unused]] Point, int widget, TooltipCloseCondition close_cond)
|
||||
{
|
||||
if (IsInsideMM(widget, WID_LGL_COMPANY_FIRST, WID_LGL_COMPANY_LAST + 1)) {
|
||||
if (this->IsWidgetDisabled(widget)) {
|
||||
@@ -686,7 +686,7 @@ void LinkGraphLegendWindow::UpdateOverlayCargoes()
|
||||
this->overlay->SetCargoMask(mask);
|
||||
}
|
||||
|
||||
void LinkGraphLegendWindow::OnClick(Point pt, int widget, int click_count)
|
||||
void LinkGraphLegendWindow::OnClick([[maybe_unused]] Point pt, int widget, [[maybe_unused]] int click_count)
|
||||
{
|
||||
/* Check which button is clicked */
|
||||
if (IsInsideMM(widget, WID_LGL_COMPANY_FIRST, WID_LGL_COMPANY_LAST + 1)) {
|
||||
@@ -718,7 +718,7 @@ void LinkGraphLegendWindow::OnClick(Point pt, int widget, int click_count)
|
||||
* @param data ignored
|
||||
* @param gui_scope ignored
|
||||
*/
|
||||
void LinkGraphLegendWindow::OnInvalidateData(int data, bool gui_scope)
|
||||
void LinkGraphLegendWindow::OnInvalidateData([[maybe_unused]] int data, [[maybe_unused]] bool gui_scope)
|
||||
{
|
||||
if (this->num_cargo != _sorted_cargo_specs.size()) {
|
||||
this->Close();
|
||||
|
@@ -108,10 +108,10 @@ public:
|
||||
LinkGraphLegendWindow(WindowDesc *desc, int window_number);
|
||||
void SetOverlay(std::shared_ptr<LinkGraphOverlay> overlay);
|
||||
|
||||
void UpdateWidgetSize(int widget, Dimension *size, const Dimension &padding, Dimension *fill, Dimension *resize) override;
|
||||
void UpdateWidgetSize(int widget, Dimension *size, [[maybe_unused]] const Dimension &padding, [[maybe_unused]] Dimension *fill, [[maybe_unused]] Dimension *resize) override;
|
||||
void DrawWidget(const Rect &r, int widget) const override;
|
||||
bool OnTooltip(Point pt, int widget, TooltipCloseCondition close_cond) override;
|
||||
void OnClick(Point pt, int widget, int click_count) override;
|
||||
bool OnTooltip([[maybe_unused]] Point pt, int widget, TooltipCloseCondition close_cond) override;
|
||||
void OnClick([[maybe_unused]] Point pt, int widget, [[maybe_unused]] int click_count) override;
|
||||
void OnInvalidateData(int data = 0, bool gui_scope = true) override;
|
||||
|
||||
private:
|
||||
|
@@ -108,10 +108,9 @@ public:
|
||||
|
||||
/**
|
||||
* Setup the node to start iterating at.
|
||||
* @param source Unused.
|
||||
* @param node Node to start iterating at.
|
||||
*/
|
||||
void SetNode(NodeID source, NodeID node)
|
||||
void SetNode(NodeID, NodeID node)
|
||||
{
|
||||
this->i = this->job[node].edges.cbegin();
|
||||
this->end = this->job[node].edges.cend();
|
||||
@@ -197,7 +196,7 @@ public:
|
||||
* @return True if base + the new edge would be better than the path associated
|
||||
* with this annotation.
|
||||
*/
|
||||
bool DistanceAnnotation::IsBetter(const DistanceAnnotation *base, uint cap,
|
||||
bool DistanceAnnotation::IsBetter(const DistanceAnnotation *base, uint,
|
||||
int free_cap, uint dist) const
|
||||
{
|
||||
/* If any of the paths is disconnected, the other one is better. If both
|
||||
|
Reference in New Issue
Block a user