mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2024-11-15 22:09:19 -07:00
25aa30ac69
Before, Free Look would accept background input by default, which means it was easy to accidentally move the camera while typing in another window. (This is because HotkeyScheduler::Run sets the input gate to `true` after it's copied the hotkey state, supposedly for other threads (though `SetInputGate` uses a `thread_local` variable so I'm not 100% sure that's correct) and for the GBA windows (which always accept unfocused input, presumably because they won't be focused normally).
32 lines
642 B
C++
32 lines
642 B
C++
// Copyright 2020 Dolphin Emulator Project
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
#pragma once
|
|
|
|
#include <QWidget>
|
|
|
|
class GraphicsChoice;
|
|
class QCheckBox;
|
|
class QPushButton;
|
|
class ToolTipCheckBox;
|
|
|
|
class FreeLookWidget final : public QWidget
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
explicit FreeLookWidget(QWidget* parent);
|
|
|
|
private:
|
|
void CreateLayout();
|
|
void ConnectWidgets();
|
|
|
|
void OnFreeLookControllerConfigured();
|
|
void LoadSettings();
|
|
void SaveSettings();
|
|
|
|
ToolTipCheckBox* m_enable_freelook;
|
|
GraphicsChoice* m_freelook_control_type;
|
|
QPushButton* m_freelook_controller_configure_button;
|
|
QCheckBox* m_freelook_background_input;
|
|
};
|