Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ProductionTabsWidget: customize scroll decorations #20635

Conversation

michaeldgg2
Copy link
Contributor

@michaeldgg2 michaeldgg2 commented Jan 25, 2023

Makes it possible to customize left/right arrow buttons and panels for left/right buttons and tab buttons.

Other changes:

  • centers left/right arrow images on left/right buttons thus removing hack necessary for CNC mod
  • AddFactionSuffixLogic adds suffix to both TabButton and ArrowButton and also for Decorations fields on ProductionTabsWidget

Adding faction suffix to Decorations doesn't break CNC mod as chrome.yaml defines both scrollpanel-decorations-nod and scrollpanel-decorations-gdi.

Fixes #20619.

This moves initialization of Initialize getters for left/right arrow image from constructor Initialize method making it possible to override fields Decorations, DecorationScrollLeft and DecorationScrollRight after widget creation.
@michaeldgg2 michaeldgg2 marked this pull request as ready for review January 25, 2023 11:15
@michaeldgg2 michaeldgg2 force-pushed the ProductionTabsWidget-CustomizeScrollDecorations branch from 39b8496 to 9136fa6 Compare January 25, 2023 12:13
@michaeldgg2 michaeldgg2 force-pushed the ProductionTabsWidget-CustomizeScrollDecorations branch from fa9cbb1 to 372d576 Compare January 26, 2023 11:00
@michaeldgg2 michaeldgg2 force-pushed the ProductionTabsWidget-CustomizeScrollDecorations branch from 372d576 to cbea814 Compare January 26, 2023 13:36
@michaeldgg2 michaeldgg2 force-pushed the ProductionTabsWidget-CustomizeScrollDecorations branch from cbea814 to 5b39e87 Compare January 26, 2023 16:41
Copy link
Member

@PunkPun PunkPun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@PunkPun PunkPun merged commit 6f87c56 into OpenRA:bleed Jan 27, 2023
@PunkPun
Copy link
Member

PunkPun commented Jan 27, 2023

Changelog

@michaeldgg2 michaeldgg2 deleted the ProductionTabsWidget-CustomizeScrollDecorations branch February 15, 2023 21:07
@michaeldgg2 michaeldgg2 restored the ProductionTabsWidget-CustomizeScrollDecorations branch February 15, 2023 21:07
@michaeldgg2 michaeldgg2 deleted the ProductionTabsWidget-CustomizeScrollDecorations branch March 14, 2023 18:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ProductionTabsWidget: customizing production tabs
3 participants