• Status Closed
  • Percent Complete
  • Task Type Patches
  • Category Rbutil
  • Assigned To No-one
  • Operating System All players
  • Severity Low
  • Priority Very Low
  • Reported Version Version 3.2
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by Domonoky - 2009-05-02
Last edited by Domonoky - 2009-05-09

FS#10183 - rbutil settings with static accessors

Here is a first attempt to static accessors for the RbSettings Class.

This removes the need to pass settings pointers around. And the settings are always accessible.

Closed by  Domonoky
2009-05-09 16:59
Reason for closing:  Accepted
Additional comments about closing:   Warning: Undefined array key "typography" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 371 Warning: Undefined array key "camelcase" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 407

Improved and commited.

I had a look at that patch and a few questions about it:
- why this split with creating a RbSettings object through the static access functions and accessing them through that object? This seems too complicated to me. Everything we need for this to work are the two QSettings objects and pointers. Why don’t you create two static QSettings pointers and make sure those are initialized (with ensureRbSettingsExist()). Then the only thing that needs to get changed is checking that before doing any access handling.
- those “p_” prefixes for private members is weird – I’ve never seen that before, and the rest of Rockbox Utility code doesn’t do that either. Why? It looks confusing (plus, if you remove the split I mentioned above I don’t see any reason for having static and private access functions)
- and for minor nitpicking, platform isn’t written with “tt” in english ;-)


Available keyboard shortcuts


Task Details

Task Editing