private function get_sel_item_update_action(&$user_input, &$plugin_cookies) { $parent_media_url = MediaURL::decode($user_input->parent_media_url); $sel_ndx = $user_input->sel_ndx; $group = $this->tv->get_group($parent_media_url->group_id); $channels = $group->get_channels($plugin_cookies); $items[] = $this->get_regular_folder_item($group, $channels->get_by_ndx($sel_ndx), $plugin_cookies); $range = HD::create_regular_folder_range($items, $sel_ndx, $channels->size()); return ActionFactory::update_regular_folder($range, false); }
private function get_update_action($sel_increment, &$user_input, &$plugin_cookies) { $parent_media_url = MediaURL::decode($user_input->parent_media_url); $num_favorites = count($this->tv->get_fav_channel_ids($plugin_cookies)); $sel_ndx = $user_input->sel_ndx + $sel_increment; if ($sel_ndx < 0) { $sel_ndx = 0; } if ($sel_ndx >= $num_favorites) { $sel_ndx = $num_favorites - 1; } $range = HD::create_regular_folder_range($this->get_all_folder_items($parent_media_url, $plugin_cookies)); return ActionFactory::update_regular_folder($range, true, $sel_ndx); }