Qt: move dependencies into Window_p.h#4
Open
ahigerd wants to merge 1 commit into
Open
Conversation
This was referenced Aug 9, 2025
f77fcf2 to
5700abc
Compare
1bf37a1 to
8706222
Compare
8706222 to
be0bb2c
Compare
ahigerd
commented
Aug 9, 2025
| void Window::scriptingOpen() { | ||
| ensureScripting(); | ||
| ScriptingView* view = new ScriptingView(m_scripting.get(), m_config); | ||
| ScriptingView* view = new ScriptingView(d->scripting.get(), m_config); |
Owner
Author
There was a problem hiding this comment.
It's worth observing that I did not deduplicate the scripting view. It wouldn't have been difficult to do so but it's one that someone might reasonably WANT two of.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is the third of a series of patches that intend to refactor the way mGBA handles popup windows.
First PR: mgba-emu#3549
Second PR: #3
Fourth PR: #5
Description
Moves as many
#includestatements as possible out ofWindow.hinto a private header file.Motivation
src/platform/qt/Window.his included by 8 .cpp files and itself includes quite a few other header files. This slows down incremental builds because the surface area for changes that will trigger recompilation is so large. Using the pimpl pattern is standard C++ practice to avoid this problem.