Пример #1
0
 public function getWinProceses()
 {
     $window = new api_wintask();
     $win_object = $window->getAllWindows();
     $c = count($win_object);
     $process_counter = array();
     $process_owners = array("root" => "root");
     for ($i = 0; $i < $c; $i++) {
         $p = explode("@", $win_object[$i]->getParam('app_id'));
         $app_id = $p[0];
         $process[$i] = $app_id;
         $process_owners[$app_id][] = $win_object[$i]->getID();
         if (!in_array($process[$i], $process_counter)) {
             $process_counter[] = $process[$i];
         }
     }
     return $process_owners;
 }