Skip to content

Conversation

@jamescowens
Copy link
Member

This is a cleanup PR to fix compiler warnings related to Qt6+ changes and also a few minor issues with gridcoin-config.h.cmake.in redefinition of SSE41 and similar flags where they have already been defined from cmake arguments. It is currently based on the depends_qt6 branch, so will include all of those commits as well until depends_qt6 is merged into development.

@jamescowens jamescowens self-assigned this Dec 4, 2025
@jamescowens jamescowens added this to the Natasha milestone Dec 4, 2025
@jamescowens jamescowens force-pushed the fix_qt6_and_other_warnings branch from b7101b2 to 39ca18a Compare December 5, 2025 00:20
@jamescowens jamescowens requested review from Copilot and removed request for Copilot December 8, 2025 13:32
@jamescowens jamescowens force-pushed the fix_qt6_and_other_warnings branch from 39ca18a to a8eefc9 Compare December 8, 2025 13:34
@jamescowens jamescowens requested a review from Copilot December 8, 2025 13:35
This commit contains minor fixes for Qt6+ related warnings, and
a minor CMake gridcoin-config.h.cmake.in issue where it would
(re)define SSE and similar flags even if they are passed in as
arguments by the cmake parameters.

The Qt6 fixes are wrapped in macro conditionals to maintain
compatibility with Qt5 for the time being.
@jamescowens jamescowens force-pushed the fix_qt6_and_other_warnings branch from a8eefc9 to 864fc8a Compare December 8, 2025 13:36
@jamescowens jamescowens requested review from Copilot and removed request for Copilot December 8, 2025 13:37
@jamescowens jamescowens marked this pull request as ready for review December 8, 2025 15:13
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses Qt6+ compatibility issues by updating deprecated API usage and fixing compiler warnings. The changes modernize the codebase for Qt 6.0+ while maintaining backward compatibility with Qt 5.x through preprocessor conditionals.

Key Changes:

  • Replaced deprecated + operator with | for Qt keyboard modifiers to fix operator deprecation warnings
  • Updated deprecated Qt API calls (e.g., invalidateFilter()invalidate(), nativeCountryName()nativeTerritoryName(), QLibraryInfo::location()QLibraryInfo::path())
  • Added Qt version checks to conditionally use appropriate APIs for different Qt versions

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/qt/voting/votingpage.cpp Changed keyboard shortcut operator from + to `
src/qt/voting/polltablemodel.cpp Added void cast to QtConcurrent::run() return value to suppress unused result warning
src/qt/transactionfilterproxy.cpp Updated header include path, fixed whitespace, and replaced deprecated invalidateFilter() with invalidate()
src/qt/sendcoinsdialog.cpp Added Qt version check to use checkStateChanged signal for Qt 6.7+ instead of deprecated stateChanged
src/qt/optionsdialog.cpp Added Qt version check for locale API (nativeTerritoryName() vs nativeCountryName()) and fixed trailing whitespace
src/qt/bitcoingui.cpp Updated all keyboard shortcut operators from + to `
src/qt/bitcoin.cpp Added Qt version conditionals for deprecated high-DPI attributes and QLibraryInfo API changes
src/init.cpp Removed unused txdb.h include
src/config/gridcoin-config.h.cmake.in Added guards to prevent macro redefinition warnings for SSE41, AVX2, SHANI, and ARM feature flags

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@jamescowens jamescowens merged commit 5d1b975 into gridcoin-community:development Dec 8, 2025
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant