#pragma once

#include "LiftoffWin32DesktopTestApp.h"
#include "control_ids.h"
#include <string>

extern void UpdatePlacementsUI(HWND hWnd);

extern void CreateControlsForTab1(HWND hwnd);
extern void CreateControlsForTab2(HWND hwnd);
extern void CreateControlsForDebugTab(HWND hwnd);
extern void CreatePrivacyTabControls(HWND hwnd);
extern void CreateControlsForTab7(HWND hwnd);
extern void CreateControlsForHeaderBiddingTab(HWND hwnd);
extern void ShowTabPage(int index);
extern void ResizeTabControl(HWND hwnd);
extern std::wstring GetSelectedPlacementName();

extern std::wstring FixAndSanitizeText(const std::wstring& input);

extern HWND hTab, hTabPages[NUM_TABS];
// Tab 1
extern HWND hLabelAppId, hEditAppId, hButtonInitialize, hButtonLoad, hButtonPlay, hButtonPlayInNewWindow, hPlacementsListBox, hButtonShowDataInExplorer;
// Tab 2 ("Options")
extern HWND hCheckBoxDisableASHWID;
extern HWND hLabelIncentivizedTitle, hEditIncentivizedTitle, hLabelIncentivizedBody, hEditIncentivizedBody, hLabelIncentivizedClose, hEditIncentivizedClose, hLabelIncentivizedContinue, hEditIncentivizedContinue;
extern HWND hLabelPositionX, hEditPositionX, hLabelPositionY, hEditPositionY;

// Tab 3 ("Debug")
extern HWND hProxyCheckbox, hProxyAddressLabel, hProxyAddressEdit, hProxyPortLabel, hProxyPortEdit, hWebView2DebugCheckbox;

extern HWND hEdits[2], hLabels[2], hCheckBoxes[2], hMultiLineEdit;

extern void UpdatePlayButtonState();

extern void HandlePaint(HWND hWnd);

extern std::wstring GetWStringFromControl(HWND hParent, int controlId);