Qt: Only reset window dimensions when first shown
Jeffrey Pfau jeffrey@endrift.com
Mon, 31 Oct 2016 10:46:57 -0700
3 files changed,
7 insertions(+),
0 deletions(-)
M
CHANGES
→
CHANGES
@@ -23,6 +23,7 @@ - GB Memory: Fix patching ROM bank 0
- GB: Fix audio not being deinitialized - GBA Memory: Fix VCOUNT being writable - GBA Memory: Improve initial skipped BIOS state + - Qt: Only reset window dimensions when first shown Misc: - SDL: Remove scancode key input - GBA Video: Clean up unused timers
M
src/platform/qt/Window.cpp
→
src/platform/qt/Window.cpp
@@ -79,6 +79,7 @@ , m_mruMenu(nullptr)
, m_shortcutController(new ShortcutController(this)) , m_fullscreenOnStart(false) , m_autoresume(false) + , m_wasOpened(false) { setFocusPolicy(Qt::StrongFocus); setAcceptDrops(true);@@ -583,6 +584,10 @@ m_config->setOption("fullscreen", isFullScreen());
} void Window::showEvent(QShowEvent* event) { + if (m_wasOpened) { + return; + } + m_wasOpened = true; resizeFrame(m_screenWidget->sizeHint()); QVariant windowPos = m_config->getQtOption("windowPos"); if (!windowPos.isNull()) {
M
src/platform/qt/Window.h
→
src/platform/qt/Window.h
@@ -178,6 +178,7 @@ ShaderSelector* m_shaderView;
bool m_fullscreenOnStart; QTimer m_focusCheck; bool m_autoresume; + bool m_wasOpened; bool m_hitUnimplementedBiosCall;