/** 
  * @see	wcf\system\package\plugin\IPackageInstallationPlugin::uninstall()
  */
 public function uninstall()
 {
     // call uninstall event
     EventHandler::fireAction($this, 'uninstall');
     // get all style of this package
     $isDefault = false;
     $styleList = new StyleList();
     $styleList->getConditionBuilder()->add("packageID = ?", array($this->installation->getPackageID()));
     $styleList->sqlLimit = 0;
     $styleList->readObjects();
     foreach ($styleList->getObjects() as $style) {
         $styleEditor = new StyleEditor($style);
         $styleEditor->delete();
         $isDefault = $isDefault || $style->isDefault;
     }
     // default style deleted
     if ($isDefault) {
         $styleList = new StyleList();
         $styleList->sqlOrderBy = 'style.styleID ASC';
         $styleList->sqlLimit = 1;
         $styleList->readObjects();
         $styles = $styleList->getObjects();
         if (count($styles)) {
             $styleEditor = new StyleEditor($styles[0]);
             $styleEditor->setAsDefault();
         }
     }
 }