Skip to content

Commit 5086b1a

Browse files
Rename PanoramaImagePanel to ImagePanel
1 parent 9fa091f commit 5086b1a

File tree

8 files changed

+16
-15
lines changed

8 files changed

+16
-15
lines changed

Source/Features/Hud/BombTimer/BombTimerContext.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#pragma once
22

3-
#include <GameClient/Panorama/PanoramaImagePanel.h>
3+
#include <GameClient/Panorama/ImagePanel.h>
44
#include <GameClient/Panorama/PanoramaLabel.h>
55
#include <GameClient/Panorama/PanoramaUiEngine.h>
66
#include <Utils/Lvalue.h>
@@ -55,7 +55,7 @@ struct BombTimerContext {
5555

5656
[[nodiscard]] auto bombSiteIconPanel() const noexcept
5757
{
58-
return BombSiteIconPanel{uiEngine().getPanelFromHandle(state().bombSiteIconPanelHandle).clientPanel().template as<PanoramaImagePanel>()};
58+
return BombSiteIconPanel{uiEngine().getPanelFromHandle(state().bombSiteIconPanelHandle).clientPanel().template as<ImagePanel>()};
5959
}
6060

6161
[[nodiscard]] auto bombTimerTextPanel() const noexcept

Source/Features/Hud/DefusingAlert/DefusingAlertContext.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#include <CS2/Panorama/CUILength.h>
44
#include <CS2/Panorama/StyleEnums.h>
55
#include <GameClient/Panorama/PanelMarginParams.h>
6-
#include <GameClient/Panorama/PanoramaImagePanel.h>
6+
#include <GameClient/Panorama/ImagePanel.h>
77
#include <GameClient/Panorama/PanoramaLabel.h>
88
#include <GameClient/Panorama/PanoramaUiEngine.h>
99
#include <Utils/Lvalue.h>

Source/Features/Visuals/PlayerInfoInWorld/PlayerInfoInWorldPanelFactory.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
#include <CS2/Constants/ColorConstants.h>
44
#include <CS2/Panorama/CUIPanel.h>
5-
#include <GameClient/Panorama/PanoramaImagePanel.h>
5+
#include <GameClient/Panorama/ImagePanel.h>
66
#include <GameClient/Panorama/PanoramaTransformations.h>
77
#include <Utils/Lvalue.h>
88

Source/Features/Visuals/PlayerInfoInWorld/PlayerWeaponIcon/ActiveWeaponIcon/PlayerActiveWeaponIconPanel.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
#include <Common/Visibility.h>
66
#include <GameClient/Entities/C4.h>
7-
#include <GameClient/Panorama/PanoramaImagePanel.h>
7+
#include <GameClient/Panorama/ImagePanel.h>
88
#include <Utils/CString.h>
99
#include <Utils/StringBuilder.h>
1010
#include "PlayerActiveWeaponIconPanelContext.h"
@@ -37,7 +37,7 @@ class PlayerActiveWeaponIconPanel {
3737
weaponIconPathBuilder.put("s2r://panorama/images/icons/equipment/", weaponName.string, ".svg");
3838
const auto weaponIconPath = weaponIconPathBuilder.cstring();
3939

40-
auto&& weaponIconImagePanel = context.panel().clientPanel().template as<PanoramaImagePanel>();
40+
auto&& weaponIconImagePanel = context.panel().clientPanel().template as<ImagePanel>();
4141
if (shouldUpdateImagePanel(weaponIconImagePanel, weaponIconPath))
4242
weaponIconImagePanel.setImageSvg(weaponIconPath, 24);
4343
}

Source/GameClient/Panorama/PanoramaImagePanel.h renamed to Source/GameClient/Panorama/ImagePanel.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,11 @@ struct SvgImageParams {
1717
};
1818

1919
template <typename HookContext>
20-
struct PanoramaImagePanel {
20+
class ImagePanel {
21+
public:
2122
using RawType = cs2::CImagePanel;
2223

23-
PanoramaImagePanel(HookContext& hookContext, cs2::CImagePanel* panel) noexcept
24+
ImagePanel(HookContext& hookContext, cs2::CImagePanel* panel) noexcept
2425
: hookContext{hookContext}
2526
, panel{panel}
2627
{

Source/GameClient/Panorama/PanelFactory.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#include <MemoryPatterns/PatternTypes/PanoramaImagePanelPatternTypes.h>
99
#include <MemoryPatterns/PatternTypes/PanoramaLabelPatternTypes.h>
1010
#include <GameClient/Panorama/ClientPanel.h>
11-
#include <GameClient/Panorama/PanoramaImagePanel.h>
11+
#include <GameClient/Panorama/ImagePanel.h>
1212

1313
template <typename HookContext>
1414
struct PanelFactory {
@@ -38,12 +38,12 @@ struct PanelFactory {
3838
[[nodiscard]] decltype(auto) createImagePanel(cs2::CUIPanel* parentPanel, const char* id = "") noexcept
3939
{
4040
if (!parentPanel || !imagePanelConstructor() || !imagePanelSize())
41-
return hookContext.template make<ClientPanel>(nullptr).template as<PanoramaImagePanel>();
41+
return hookContext.template make<ClientPanel>(nullptr).template as<ImagePanel>();
4242

4343
const auto memory{static_cast<cs2::CImagePanel*>(hookContext.template make<MemAlloc>().allocate(imagePanelSize()))};
4444
if (memory)
4545
imagePanelConstructor()(memory, parentPanel->clientPanel, id);
46-
return hookContext.template make<ClientPanel>(memory).template as<PanoramaImagePanel>();
46+
return hookContext.template make<ClientPanel>(memory).template as<ImagePanel>();
4747
}
4848

4949
private:

Source/Osiris.vcxproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -311,6 +311,7 @@
311311
<ClInclude Include="GameClient\MemAlloc.h" />
312312
<ClInclude Include="GameClient\MemAllocState.h" />
313313
<ClInclude Include="GameClient\Panorama\ClientPanel.h" />
314+
<ClInclude Include="GameClient\Panorama\ImagePanel.h" />
314315
<ClInclude Include="GameClient\Panorama\Ui3dPanel.h" />
315316
<ClInclude Include="GameClient\Panorama\PanelAlignmentParams.h" />
316317
<ClInclude Include="GameClient\Panorama\PanelFactory.h" />
@@ -320,7 +321,6 @@
320321
<ClInclude Include="GameClient\Panorama\PanelShadowParams.h" />
321322
<ClInclude Include="GameClient\Panorama\PanelStylePropertyFactory.h" />
322323
<ClInclude Include="GameClient\Panorama\PanoramaDropDown.h" />
323-
<ClInclude Include="GameClient\Panorama\PanoramaImagePanel.h" />
324324
<ClInclude Include="GameClient\Panorama\PanoramaLabel.h" />
325325
<ClInclude Include="GameClient\Panorama\PanoramaSymbols.h" />
326326
<ClInclude Include="GameClient\Panorama\PanoramaTransformations.h" />

Source/Osiris.vcxproj.filters

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1568,9 +1568,6 @@
15681568
<ClInclude Include="GameClient\Panorama\PanoramaDropDown.h">
15691569
<Filter>GameClient\Panorama</Filter>
15701570
</ClInclude>
1571-
<ClInclude Include="GameClient\Panorama\PanoramaImagePanel.h">
1572-
<Filter>GameClient\Panorama</Filter>
1573-
</ClInclude>
15741571
<ClInclude Include="GameClient\Panorama\PanoramaLabel.h">
15751572
<Filter>GameClient\Panorama</Filter>
15761573
</ClInclude>
@@ -1943,6 +1940,9 @@
19431940
<ClInclude Include="Utils\EnumFlags.h">
19441941
<Filter>Utils</Filter>
19451942
</ClInclude>
1943+
<ClInclude Include="GameClient\Panorama\ImagePanel.h">
1944+
<Filter>GameClient\Panorama</Filter>
1945+
</ClInclude>
19461946
</ItemGroup>
19471947
<ItemGroup>
19481948
<None Include="UI\Panorama\CreateGUI.js">

0 commit comments

Comments
 (0)