Changes between Version 20 and Version 21 of GuiRpc


Ignore:
Timestamp:
Feb 20, 2009, 11:53:48 AM (16 years ago)
Author:
davea
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GuiRpc

    v20 v21  
    213213Convert the given structure to XML and write it to the global [PrefsOverride preferences override] file.
    214214
     215To modify a particular preference (e.g., CPU throttle):
     216{{{
     217GLOBAL_PREFS prefs;
     218GLOBAL_PREFS_MASK prefs_mask;
     219RPC_CLIENT rpc;
     220char password[256];
     221
     222read_gui_rpc_password(password);
     223rpc.init("localhost");
     224rpc.authorize(password);
     225
     226rpc.get_global_prefs_override_struct(prefs, prefs_mask);
     227prefs.cpu_usage_limit = 0.5;
     228prefs_mask.cpu_usage_limit = true;
     229rpc.set_global_prefs_override_struct(prefs, prefs_mask);
     230rpc.read_global_prefs_override();
     231}}}
     232
    215233=== `set_debts(std::vector<PROJECT>)` === #function-set_debts
    216234