Skip to content

feat(settings): add location search to theme & gamma coordinates - #3010

Merged
purian23 merged 2 commits into
duxlabs-dev:masterfrom
Curious-r:feat/location-search-settings
Aug 7, 2026
Merged

purian23 merged 2 commits into
duxlabs-dev:masterfrom
Curious-r:feat/location-search-settings

Conversation

@Curious-r

@Curious-r Curious-r commented Aug 7, 2026 •

Copy link
Copy Markdown
Contributor

Description

Adds a searchable location picker to the automatic location sections of Theme & Colors (Color Mode) and Gamma Control, so users can search for a city and auto-fill the latitude/longitude coordinates (like the weather setting do) instead of typing them by hand.

Extracts the previously duplicated "Use IP Location + manual coordinates" UI into a new shared SettingsLocationSection component used by both tabs. The existing weather location search is left unchanged.

Tested on hardware: search → auto-fill coordinates, cross-tab sync (both tabs share the same coordinates), and the "Share Gamma Control Settings" toggle all work as before. No backend changes.

Follow-ups: While working on this, I spotted two minor things to address later: remembering and displaying the user's last selection in the search field, and fixing a visual glitch where the error icon flashes post-selection. Since both touch the shared DankLocationSearch component, I'll handle them in a separate PR over at dank-qml-common(maybe later).

Type of change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that changes existing behavior)
  • Refactor / internal cleanup
  • Documentation
  • Other

Related issues

Screenshots / video

1786094443586415099 1786094455518236885 1786094462625514714

Checklist

  • My code follows the conventions in CONTRIBUTING.md
  • I have tested my changes locally
  • New user-facing strings are wrapped in I18n.tr() with translator context, reusing existing terms where possible
  • Go changes: ran make fmt, added/updated tests, make test passes, and go mod tidy is clean
  • QML changes: ran make lint-qml with no new warnings
  • I have opened a corresponding pull request in dlx-docs to document any new behaviors: https://github.com/AvengeMedia/DankLinux-Docs

@purian23 purian23 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks for the PR, and good idea!

One ask before merge: after the lat/lon fields are edited, the SessionData binding can break so search/cross-tab updates don’t refresh the visible text. Matching weather’s pattern (set .text on select + Connections) in SettingsLocationSection would fix that.

Happy to re-review once that’s in and the dank-qml-common follow-ups are fine separately.

@Curious-r

Copy link
Copy Markdown
Contributor Author

Hi @purian23 , thanks for your time!
Ready for re-review — addressed in c33fe031.

SettingsLocationSection now follows the weather tab pattern: the coordinate fields initialize from SessionData in Component.onCompleted, refresh through Connections on SessionData changes, and onLocationSelected sets .text explicitly, so manual edits no longer break the visible text when search results or other tabs update the values.

Tested on hardware:

  • Manually editing lat/lon applies immediately (the day/night switch reacts as expected).
  • After a manual edit, re-searching and re-selecting the same city refreshes the coordinate fields and re-applies the location.
  • Cross-tab sync works in both directions (Gamma ⇄ Theme), including after manual edits.

One more thing: the "Share Gamma Control Settings" toggle only affects the time schedule — coordinates and the IP-location flag are always shared by design (there are no theme-specific coordinate fields). I kept that behavior unchanged.

@Curious-r
Curious-r requested a review from purian23 August 7, 2026 16:32
@purian23
purian23 merged commit 40a9ca3 into duxlabs-dev:master Aug 7, 2026
1 check passed
@Curious-r
Curious-r deleted the feat/location-search-settings branch August 7, 2026 17:02
marcusramberg pushed a commit to marcusramberg/DankMaterialShell that referenced this pull request Sep 2, 2026
…labs-dev#3010)

* feat(settings): add location search to theme & gamma coordinates

* fix(settings): refresh coordinate fields after manual edits
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants