supp_comp partial support (db/prefs management, usage is missing)
[brisk.git] / web / Obj / brisk.phh
index 803d28b..4c9c26e 100644 (file)
@@ -698,6 +698,7 @@ class Delay_Manager
 
 class Client_prefs {
     var $listen;
+    var $supp_comp;
 
     function Client_prefs()
     {
@@ -725,6 +726,7 @@ class Client_prefs {
     {
         fprintf(STDERR, "QQ %s: %x\n", __FUNCTION__, $user->flags);
         $this->listen = ($user->flags & USER_FLAG_MAP_AUTH) >> 2;
+        $this->supp_comp = $user->rec->supp_comp;
 
         fprintf(STDERR, "QQ %s: LISTEN: %d\n", __FUNCTION__, $this->listen);
     }
@@ -738,7 +740,8 @@ class Client_prefs {
         else {
             $json = $json_s;
         }
-        $this->listen = $json->listen;
+        $this->listen    = $json->listen;
+        $this->supp_comp = $json->supp_comp;
 
         return TRUE;
     }
@@ -751,6 +754,7 @@ class Client_prefs {
         $user->flags_set(($this->listen << 2), USER_FLAG_MAP_AUTH);
         fprintf(STDERR, "QQ %s::%s %x\n", __CLASS__, __FUNCTION__,
                 $user->flags);
+        $user->rec->supp_comp = $this->supp_comp;
         if ($is_save)
             $user->store_set();
     }
@@ -1875,6 +1879,8 @@ class Room
       $this->user[$idx]->bantime = 0;
       $this->user[$idx]->ip = $ip;
 
+      $this->user[$idx]->rec = $authenticate;
+      fprintf(STDERR, "MOP: [%s]\n", $authenticate->supp_comp);
       $this->user[$idx]->flags = $user_type;
       $this->user[$idx]->flags |= ($authenticate != FALSE ? USER_FLAG_AUTH : 0x00);
       $this->user[$idx]->flags |= ( ($pass != FALSE && $bdb == FALSE) ? USER_FLAG_DBFAILED : 0x00);