diff options
author | mingchen | 2007-07-19 15:01:14 +0000 |
---|---|---|
committer | mingchen | 2007-07-19 15:01:14 +0000 |
commit | de104536c156ebc743578a23dcc2950d20b6724e (patch) | |
tree | 38f2cece8e87faf533121d6f26479ecde00d21e3 /OpenSim/Framework/General/Configuration/UserConfig.cs | |
parent | Added some Alert methods to Scene , and a console command handler. So from th... (diff) | |
download | opensim-SC-de104536c156ebc743578a23dcc2950d20b6724e.zip opensim-SC-de104536c156ebc743578a23dcc2950d20b6724e.tar.gz opensim-SC-de104536c156ebc743578a23dcc2950d20b6724e.tar.bz2 opensim-SC-de104536c156ebc743578a23dcc2950d20b6724e.tar.xz |
*Handler Functions can now refuse an object as invalid by returning false, thus forcing the user to re-enter the data
*Added TYPE_STRING_NOT_EMPTY that requires some sort of text to be entered
*Added another parameter to addConfigurationOption called use_default_no_prompt that will not ask via the console a configuration option; it will use whatever is in the config file. If nothing is in the config file for that option, it will force itself to use default
Diffstat (limited to 'OpenSim/Framework/General/Configuration/UserConfig.cs')
-rw-r--r-- | OpenSim/Framework/General/Configuration/UserConfig.cs | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/OpenSim/Framework/General/Configuration/UserConfig.cs b/OpenSim/Framework/General/Configuration/UserConfig.cs index 9d607b3..a027ffc 100644 --- a/OpenSim/Framework/General/Configuration/UserConfig.cs +++ b/OpenSim/Framework/General/Configuration/UserConfig.cs | |||
@@ -24,16 +24,16 @@ namespace OpenSim.Framework.Configuration | |||
24 | 24 | ||
25 | public void loadConfigurationOptions() | 25 | public void loadConfigurationOptions() |
26 | { | 26 | { |
27 | configMember.addConfigurationOption("default_startup_message",ConfigurationOption.ConfigurationTypes.TYPE_STRING,"Default Startup Message","Welcome to OGS"); | 27 | configMember.addConfigurationOption("default_startup_message", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, "Default Startup Message", "Welcome to OGS",false); |
28 | 28 | ||
29 | configMember.addConfigurationOption("default_grid_server",ConfigurationOption.ConfigurationTypes.TYPE_STRING,"Default Grid Server URI","http://127.0.0.1:8001/"); | 29 | configMember.addConfigurationOption("default_grid_server", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, "Default Grid Server URI", "http://127.0.0.1:8001/", false); |
30 | configMember.addConfigurationOption("grid_send_key",ConfigurationOption.ConfigurationTypes.TYPE_STRING,"Key to send to grid server","null"); | 30 | configMember.addConfigurationOption("grid_send_key", ConfigurationOption.ConfigurationTypes.TYPE_STRING, "Key to send to grid server", "null", false); |
31 | configMember.addConfigurationOption("grid_recv_key",ConfigurationOption.ConfigurationTypes.TYPE_STRING,"Key to expect from grid server","null"); | 31 | configMember.addConfigurationOption("grid_recv_key", ConfigurationOption.ConfigurationTypes.TYPE_STRING, "Key to expect from grid server", "null", false); |
32 | 32 | ||
33 | 33 | ||
34 | } | 34 | } |
35 | 35 | ||
36 | public void handleIncomingConfiguration(string configuration_key, object configuration_result) | 36 | public bool handleIncomingConfiguration(string configuration_key, object configuration_result) |
37 | { | 37 | { |
38 | switch (configuration_key) | 38 | switch (configuration_key) |
39 | { | 39 | { |
@@ -50,6 +50,8 @@ namespace OpenSim.Framework.Configuration | |||
50 | this.GridRecvKey = (string)configuration_result; | 50 | this.GridRecvKey = (string)configuration_result; |
51 | break; | 51 | break; |
52 | } | 52 | } |
53 | |||
54 | return true; | ||
53 | } | 55 | } |
54 | } | 56 | } |
55 | } | 57 | } |