lobby_preferences.cpp

Go to the documentation of this file.
00001 /* $Id: lobby_preferences.cpp 52533 2012-01-07 02:35:17Z shadowmaster $ */
00002 /*
00003    Copyright (C) 2009 - 2012 by Tomasz Sniatowski <kailoran@gmail.com>
00004    Part of the Battle for Wesnoth Project http://www.wesnoth.org/
00005 
00006    This program is free software; you can redistribute it and/or modify
00007    it under the terms of the GNU General Public License as published by
00008    the Free Software Foundation; either version 2 of the License, or
00009    (at your option) any later version.
00010    This program is distributed in the hope that it will be useful,
00011    but WITHOUT ANY WARRANTY.
00012 
00013    See the COPYING file for more details.
00014 */
00015 
00016 #include "lobby_preferences.hpp"
00017 #include "game_preferences.hpp"
00018 #include "serialization/string_utils.hpp"
00019 #include "util.hpp"
00020 
00021 namespace preferences {
00022 
00023 bool lobby_sounds()
00024 {
00025     return preferences::get("lobby_sounds", true);
00026 }
00027 
00028 bool sort_list()
00029 {
00030     return preferences::get("sort_list", true);
00031 }
00032 
00033 void _set_sort_list(bool sort)
00034 {
00035     preferences::set("sort_list", sort);
00036 }
00037 
00038 bool iconize_list()
00039 {
00040     return preferences::get("iconize_list", true);
00041 }
00042 
00043 void _set_iconize_list(bool sort)
00044 {
00045     preferences::set("iconize_list", sort);
00046 }
00047 
00048 
00049 bool whisper_friends_only()
00050 {
00051     return preferences::get("lobby_whisper_friends_only", false);
00052 }
00053 
00054 bool auto_open_whisper_windows()
00055 {
00056     return preferences::get("lobby_auto_open_whisper_windows", true);
00057 }
00058 
00059 bool playerlist_sort_relation()
00060 {
00061     return preferences::get("lobby_playerlist_sort_relation", true);
00062 }
00063 
00064 void set_playerlist_sort_relation(bool v)
00065 {
00066     return preferences::set("lobby_playerlist_sort_relation", v);
00067 }
00068 
00069 bool playerlist_sort_name()
00070 {
00071     return preferences::get("lobby_playerlist_sort_name", true);
00072 }
00073 
00074 void set_playerlist_sort_name(bool v)
00075 {
00076     return preferences::set("lobby_playerlist_sort_name", v);
00077 }
00078 
00079 bool playerlist_group_players()
00080 {
00081     return preferences::get("lobby_playerlist_group_players", true);
00082 }
00083 
00084 bool filter_lobby()
00085 {
00086     return preferences::get("filter_lobby", false);
00087 }
00088 
00089 void set_filter_lobby(bool value)
00090 {
00091     preferences::set("filter_lobby", value);
00092 }
00093 
00094 bool fi_invert()
00095 {
00096     return preferences::get("fi_invert", false);
00097 }
00098 
00099 void set_fi_invert(bool value)
00100 {
00101     preferences::set("fi_invert", value);
00102 }
00103 
00104 bool fi_vacant_slots()
00105 {
00106     return preferences::get("fi_vacant_slots", false);
00107 }
00108 
00109 void set_fi_vacant_slots(bool value)
00110 {
00111     preferences::set("fi_vacant_slots", value);
00112 }
00113 
00114 bool fi_friends_in_game()
00115 {
00116     return preferences::get("fi_friends_in_game", false);
00117 }
00118 
00119 void set_fi_friends_in_game(bool value)
00120 {
00121     preferences::set("fi_friends_in_game", value);
00122 }
00123 
00124 std::string fi_text()
00125 {
00126     return preferences::get("fi_text");
00127 }
00128 
00129 void set_fi_text(const std::string& search_string)
00130 {
00131     preferences::set("fi_text", search_string);
00132 }
00133 
00134 } //end namespace preferences
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated by doxygen 1.7.1 on Fri May 25 2012 01:03:03 for The Battle for Wesnoth
Gna! | Forum | Wiki | CIA | devdocs