# Path: epymc/extapi/onlinevideo.py
# ACT_DEFAULT = 0
# ACT_NONE = 1
# ACT_FOLDER = 2
# ACT_MORE = 3
# ACT_PLAY = 4
# ACT_SEARCH = 5
# def state_get():
# def language_get():
# def item_add(next_state, label, url, info=None, icon=None, poster=None, action=ACT_DEFAULT):
# def play_url(url):
# def report_error(msg):
# def local_resource(_file_, res):
# def fetch_url(url, headers=None, parser=None):
# def ydl_executable():
# def call_ydl(url):
# def url_encode(params):
# def seconds_to_duration(seconds):
# def relative_date(date):
# def format_date(date):


import os
import traceback
from bs4 import BeautifulSoup
from epymc.extapi.onlinevideo import api_version, state_get, \
    fetch_url, play_url, item_add, call_ydl, relative_date, \
    ACT_NONE, ACT_FOLDER, ACT_MORE, ACT_PLAY, ACT_SEARCH
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.

from __future__ import absolute_import, print_function, unicode_literals, division



ST_HOME = 0
ST_VIDEO_LIST = 1
ST_PLAY = 2

base = 'http://www.zapiks.com/'

STATE, URL = state_get()

# this is the first page, show fixed categories
if STATE == ST_HOME:
    b = base
    u = '/popular_1.php'
    d = os.path.dirname(__file__)
    item_add(ST_VIDEO_LIST, 'Brand New Videos', b + 'p_1', action=ACT_FOLDER)
    item_add(ST_VIDEO_LIST, 'Surf', b + 'surf_' + u, poster=os.path.join(d, 'surf.png'), action=ACT_FOLDER)

# Path: epymc/extapi/onlinevideo.py
# ACT_DEFAULT = 0
# ACT_NONE = 1
# ACT_FOLDER = 2
# ACT_MORE = 3
# ACT_PLAY = 4
# ACT_SEARCH = 5
# def state_get():
# def language_get():
# def item_add(next_state, label, url, info=None, icon=None, poster=None, action=ACT_DEFAULT):
# def play_url(url):
# def report_error(msg):
# def local_resource(_file_, res):
# def fetch_url(url, headers=None, parser=None):
# def ydl_executable():
# def call_ydl(url):
# def url_encode(params):
# def seconds_to_duration(seconds):
# def relative_date(date):
# def format_date(date):


# Path: epymc/plugins/onlinevideo/zapiks/zapiks.py
import os
import traceback
from bs4 import BeautifulSoup
from epymc.extapi.onlinevideo import api_version, state_get, \
    fetch_url, play_url, item_add, call_ydl, relative_date, \
    ACT_NONE, ACT_FOLDER, ACT_MORE, ACT_PLAY, ACT_SEARCH

# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.

from __future__ import absolute_import, print_function, unicode_literals, division



ST_HOME = 0
ST_VIDEO_LIST = 1
ST_PLAY = 2

base = 'http://www.zapiks.com/'

STATE, URL = state_get()

# this is the first page, show fixed categories
if STATE == ST_HOME:
    b = base
    u = '/popular_1.php'
    d = os.path.dirname(__file__)
    item_add(ST_VIDEO_LIST, 'Brand New Videos', b + 'p_1', action=ACT_FOLDER)
    item_add(ST_VIDEO_LIST, 'Surf', b + 'surf_' + u, poster=os.path.join(d, 'surf.png'), action=ACT_FOLDER)

    item_add(ST_VIDEO_LIST, 'Snowboard', b + 'snowboard_' + u, poster=os.path.join(d, 'snowboard.png'),