User Tools

Site Tools


developer_guide_config

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
developer_guide_config [2012/07/10 12:32]
rryan [On-disk Storage]
developer_guide_config [2012/07/10 17:17] (current)
rryan
Line 39: Line 39:
 To get a preference setting that is stored in the ''​ConfigObject'',​ do something like the following: To get a preference setting that is stored in the ''​ConfigObject'',​ do something like the following:
  
-<​code>​+<​code ​c++>
 // ConfigObject is passed in to our constructor // ConfigObject is passed in to our constructor
 AnalyserBeats::​AnalyserBeats(ConfigObject<​ConfigValue>​* pConfig) { AnalyserBeats::​AnalyserBeats(ConfigObject<​ConfigValue>​* pConfig) {
Line 54: Line 54:
  
 Similarly, to set preference settings, simply call ''​set''​ with a ''​ConfigKey''​ and ''​QString''​ value. Similarly, to set preference settings, simply call ''​set''​ with a ''​ConfigKey''​ and ''​QString''​ value.
-<​code>​+<​code ​c++>
 // Store the user's preference that we should show the iTunes features to them. Assumes m_bShowItunes is a bool that tracks the current setting in Mixxx. ​ // Store the user's preference that we should show the iTunes features to them. Assumes m_bShowItunes is a bool that tracks the current setting in Mixxx. ​
 m_pConfig->​set(ConfigKey("​[Library]",​ "​ShowITunes"​),​ m_bShowItunes ? "​1"​ : "​0"​);​ m_pConfig->​set(ConfigKey("​[Library]",​ "​ShowITunes"​),​ m_bShowItunes ? "​1"​ : "​0"​);​
developer_guide_config.txt ยท Last modified: 2012/07/10 17:17 by rryan