Package sabayon :: Package sources :: Module gconfsource :: Class GConfSource
[hide private]
[frames] | no frames]

Class GConfSource

source code


GConf user profile source.

Instance Methods [hide private]
  __init__(self, storage)
Construct a GConfSource
  get_path_description(self, path)
Returns a human readable description for @path.
  get_committing_client_and_address(self, mandatory)
Get a GConfClient using either GCONF_DEFAULTS_SOURCE or GCONF_MANDATORY_SOURCE (in the temporary profile location) as its source.
  commit_change(self, change, mandatory=False)
Commit a GConf change to the profile.
  start_monitoring(self)
Start monitoring for GConf changes.
  stop_monitoring(self)
Stop monitoring for GConf changes.
  sync_changes(self)
Ensure that all committed changes are saved to disk.
  set_enforce_mandatory(self, enforce)
Temporary make mandatory setting non-mandatory.
  apply(self, is_sabayon_session)
Apply the profile by writing the default and mandatory sources location to ~/.gconf.path.defaults and ~/.gconf.path.mandatory.
  add_gconf_notify(self, key, handler, data)
  remove_gconf_notify(self, id)
  get_gconf_key_is_mandatory(self, key)
  set_value(self, key, gconf_value, mandatory)
  set_gconf_boolean(self, key, value, mandatory)
  set_gconf_int(self, key, value, mandatory)
  set_gconf_string(self, key, value, mandatory)
  set_gconf_list(self, key, list_type, value, mandatory)

Inherited from userprofile.ProfileSource: emit_change, get_delegate, get_name


Class Variables [hide private]

Inherited from userprofile.ProfileSource: __gsignals__


Method Details [hide private]

__init__(self, storage)
(Constructor)

source code 
Construct a GConfSource
Overrides: userprofile.ProfileSource.__init__

get_path_description(self, path)

source code 
Returns a human readable description for @path. @path must have been previously added by the source to the #ProfileStorage.
Overrides: userprofile.ProfileSource.get_path_description
(inherited documentation)

get_committing_client_and_address(self, mandatory)

source code 

Get a GConfClient using either GCONF_DEFAULTS_SOURCE or GCONF_MANDATORY_SOURCE (in the temporary profile location) as its source.

mandatory: whether to get the mandatory or defaults source

commit_change(self, change, mandatory=False)

source code 
Commit a GConf change to the profile.
Overrides: userprofile.ProfileSource.commit_change

start_monitoring(self)

source code 
Start monitoring for GConf changes. Note that this is seriously resource intensive as must load the value of all existing keys so that we can determine whether a write to the database resulted in an actual change in the value of the key.
Overrides: userprofile.ProfileSource.start_monitoring

stop_monitoring(self)

source code 
Stop monitoring for GConf changes.
Overrides: userprofile.ProfileSource.stop_monitoring

sync_changes(self)

source code 
Ensure that all committed changes are saved to disk.
Overrides: userprofile.ProfileSource.sync_changes

set_enforce_mandatory(self, enforce)

source code 
Temporary make mandatory setting non-mandatory.
Overrides: userprofile.ProfileSource.set_enforce_mandatory
(inherited documentation)

apply(self, is_sabayon_session)

source code 

Apply the profile by writing the default and mandatory sources location to ~/.gconf.path.defaults and ~/.gconf.path.mandatory.

Note that $(sysconfdir)/gconf/2/path needs to contain something like the following in order for this to work:

include $(HOME)/.gconf.path.mandatory xml:readwrite:$(HOME)/.gconf include $(HOME)/.gconf.path.defaults
Overrides: userprofile.ProfileSource.apply

add_gconf_notify(self, key, handler, data)

source code 
None

remove_gconf_notify(self, id)

source code 
None

get_gconf_key_is_mandatory(self, key)

source code 
None

set_value(self, key, gconf_value, mandatory)

source code 
None

set_gconf_boolean(self, key, value, mandatory)

source code 
None

set_gconf_int(self, key, value, mandatory)

source code 
None

set_gconf_string(self, key, value, mandatory)

source code 
None

set_gconf_list(self, key, list_type, value, mandatory)

source code 
None