mirror of
https://github.com/openmoh/openmohaa.git
synced 2025-04-28 21:57:57 +03:00
Activate the control and connect dialog's W_Deactivated after its creation
As the control is activated before, the connection should be done after the activation because ActivateControl() sends W_Activated to the UIFloatingWindow, which will cause ActivateControl() to be called again to activate the dialog's title bar button (and would deactivate the gamespy dialog)
This commit is contained in:
parent
3c836144e2
commit
9922a7095b
1 changed files with 4 additions and 2 deletions
|
@ -79,8 +79,6 @@ void GameSpyDialog::FrameInitialized(void) {
|
|||
overlay->AllowActivate(true);
|
||||
|
||||
overlay->Connect(this, W_Button_Pressed, W_Deactivated);
|
||||
|
||||
Connect(this, W_Deactivated, W_Deactivated);
|
||||
}
|
||||
|
||||
void GameSpyDialog::Create(UIWidget* parent, const UIRect2D& rect, const char* title, const UColor& bgColor, const UColor& fgColor)
|
||||
|
@ -107,4 +105,8 @@ void UI_LaunchGameSpy_f(void) {
|
|||
UColor(0.15f, 0.195f, 0.278f),
|
||||
UHudColor
|
||||
);
|
||||
|
||||
uWinMan.ActivateControl(dialog);
|
||||
|
||||
dialog->Connect(dialog, W_Deactivated, W_Deactivated);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue