You are here

public function ImceFM::deselectItem in IMCE 8.2

Same name and namespace in other branches
  1. 8 src/ImceFM.php \Drupal\imce\ImceFM::deselectItem()

Deselects an item.

File

src/ImceFM.php, line 408

Class

ImceFM
Imce File Manager.

Namespace

Drupal\imce

Code

public function deselectItem(ImceItem $item) {
  if ($item->selected) {
    $item->selected = FALSE;
    $index = array_search($item, $this->selection);
    if ($index !== FALSE) {
      array_splice($this->selection, $index, 1);
    }
  }
}