summaryrefslogtreecommitdiffstats
path: root/abs
diff options
context:
space:
mode:
Diffstat (limited to 'abs')
-rw-r--r--abs/core-testing/LinHES-config/LinHES-release2
-rw-r--r--abs/core-testing/LinHES-config/PKGBUILD137
-rwxr-xr-xabs/core-testing/LinHES-config/mv_advanced.py3
-rwxr-xr-xabs/core-testing/LinHES-config/mv_common.py25
-rwxr-xr-xabs/core-testing/LinHES-config/mv_ddns.py5
-rwxr-xr-xabs/core-testing/LinHES-config/mv_hostype.py5
-rwxr-xr-xabs/core-testing/LinHES-config/mv_ir.py21
-rwxr-xr-xabs/core-testing/LinHES-config/mv_network.py11
-rwxr-xr-xabs/core-testing/LinHES-config/mv_screensaver.py3
-rwxr-xr-xabs/core-testing/LinHES-config/mv_smolt.py3
-rwxr-xr-xabs/core-testing/LinHES-config/mv_software.py4
-rwxr-xr-xabs/core-testing/LinHES-config/mv_webuser.py4
-rw-r--r--abs/core-testing/LinHES-config/mythvantage.cfg21
-rwxr-xr-xabs/core-testing/LinHES-config/restore_default_settings.sh160
-rwxr-xr-xabs/core-testing/LinHES-config/systemconfig.py45
-rw-r--r--abs/core-testing/LinHES-system/LinHES-run7
-rw-r--r--abs/core-testing/LinHES-system/PKGBUILD73
-rw-r--r--abs/core-testing/fluxbox/PKGBUILD9
-rw-r--r--abs/core-testing/fluxbox/fluxbox_fullscreen_focus.patch12
-rw-r--r--abs/core-testing/fluxbox/keys1
-rw-r--r--abs/core-testing/lighttpd/PKGBUILD11
-rw-r--r--abs/core-testing/lighttpd/__changelog2
-rw-r--r--abs/core-testing/lighttpd/lighttpd.conf2
-rw-r--r--abs/core-testing/linhes-scripts/PKGBUILD92
-rwxr-xr-xabs/core-testing/linhes-scripts/mythwelcome-config.py27
-rw-r--r--abs/core-testing/linhes-scripts/remove_php_mythvideo.sh7
-rwxr-xr-xabs/core-testing/linhes-scripts/screenshooter.sh4
-rw-r--r--abs/core-testing/linhes-theme/PKGBUILD6
-rw-r--r--abs/core-testing/linuxtv-dvb-apps/PKGBUILD2
-rw-r--r--abs/core-testing/local-website/PKGBUILD2
-rwxr-xr-xabs/core-testing/local-website/htdocs/404.html25
-rwxr-xr-x[-rw-r--r--]abs/core-testing/local-website/htdocs/index.html227
-rw-r--r--abs/core-testing/local-website/htdocs/layout.css29
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/default/header.css123
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/default/menus.css221
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/default/programming.css150
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/default/style.css (renamed from abs/core-testing/local-website/htdocs/style.css)14
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/default/welcome.css62
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/AC_OETags.js269
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/flowplayer-3.1.1.min.js24
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/pngbehavior.htc97
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/prototip/classic_toolbar.gifbin0 -> 2850 bytes
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/prototip/close.gifbin0 -> 367 bytes
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/prototip/close_hover.gifbin0 -> 366 bytes
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/prototip/close_hover_red.gifbin0 -> 371 bytes
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/prototip/prototip.css65
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/prototip/prototip.js506
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/prototype.js4320
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/builder.js136
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/controls.js965
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/dragdrop.js975
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/effects.js1130
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/jw_effects.js750
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/scriptaculous.js60
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/slider.js275
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/sound.js55
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/unittest.js568
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/table_sort.js569
-rw-r--r--abs/core-testing/local-website/htdocs/linhes/js/utils.js173
-rw-r--r--abs/core-testing/local-website/htdocs/rrd/index.html2
-rwxr-xr-xabs/core-testing/local-website/htdocs/wap.html118
-rw-r--r--abs/core-testing/mplayer-wrapper/PKGBUILD6
-rw-r--r--[-rwxr-xr-x]abs/core-testing/mplayer-wrapper/mplayer-wrapper.pl95
-rw-r--r--abs/core-testing/mythinstall/PKGBUILD4
-rwxr-xr-xabs/core-testing/mythinstall/checkout_MythVantage.sh2
-rw-r--r--abs/core-testing/mythstream/PKGBUILD4
-rwxr-xr-xabs/core-testing/mythtv/old/stable-0.22/clean_all.sh (renamed from abs/core-testing/mythtv/stable-0.22/clean_all.sh)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/morethemes/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/morethemes/PKGBUILD)0
-rwxr-xr-xabs/core-testing/mythtv/old/stable-0.22/mp_all.sh (renamed from abs/core-testing/mythtv/stable-0.22/mp_all.sh)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mytharchive/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mytharchive/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythbrowser/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythbrowser/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythflix/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythflix/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythgallery/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythgallery/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythgame/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythgame/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythmovies/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythmovies/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythmusic/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythmusic/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythnews/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythnews/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythsmolt/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythsmolt/PKGBUILD)9
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythsmolt/smolt_init_login.sh39
-rwxr-xr-xabs/core-testing/mythtv/old/stable-0.22/myththemes/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/myththemes/PKGBUILD)0
-rwxr-xr-xabs/core-testing/mythtv/old/stable-0.22/mythtv/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/changeset_r23616.patch (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/changeset_r23616.patch)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/HOST_SETTINGS.xml (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/HOST_SETTINGS.xml)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/is.xml (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/is.xml)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/library.xml.patch (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/library.xml.patch)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/linhes.xml (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/linhes.xml)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mainmenu.tv.patch (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mainmenu.tv.patch)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mainmenu.xml.patch (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mainmenu.xml.patch)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mythbackup.xml (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mythbackup.xml)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mythrestore.xml (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mythrestore.xml)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/optical_menu.xml.patch (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/optical_menu.xml.patch)0
-rwxr-xr-xabs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/original/create_patch.sh (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/original/create_patch.sh)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/setup.xml (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/setup.xml)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/siriusmenu.xml (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/siriusmenu.xml)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/themeinfo.xml-tv (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/themeinfo.xml-tv)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/update.xml (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/update.xml)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/update2.xml (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/update2.xml)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/util_menu.xml.patch (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/util_menu.xml.patch)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/xmmenu.xml (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/xmmenu.xml)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/menutheme_fallback.patch (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/menutheme_fallback.patch)0
-rwxr-xr-xabs/core-testing/mythtv/old/stable-0.22/mythtv/myth.sh (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/myth.sh)0
-rwxr-xr-xabs/core-testing/mythtv/old/stable-0.22/mythtv/mythbackend (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/mythbackend)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/mythbackend.lr (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/mythbackend.lr)0
-rwxr-xr-xabs/core-testing/mythtv/old/stable-0.22/mythtv/mythbackend.sh (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/mythbackend.sh)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/mythfrontend.lr (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/mythfrontend.lr)0
-rwxr-xr-xabs/core-testing/mythtv/old/stable-0.22/mythtv/mythtv.install (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/mythtv.install)0
-rwxr-xr-xabs/core-testing/mythtv/old/stable-0.22/mythtv/pretty (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/pretty)3
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythtv/smolt_jump.patch (renamed from abs/core-testing/mythtv/stable-0.22/mythtv/smolt_jump.patch)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythvideo/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythvideo/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythweather/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythweather/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythweb/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythweb/PKGBUILD)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythweb/mythweb.install (renamed from abs/core-testing/mythtv/stable-0.22/mythweb/mythweb.install)0
-rw-r--r--abs/core-testing/mythtv/old/stable-0.22/mythzoneminder/PKGBUILD (renamed from abs/core-testing/mythtv/stable-0.22/mythzoneminder/PKGBUILD)0
-rwxr-xr-xabs/core-testing/mythtv/stable-0.23/clean_all.sh22
-rw-r--r--abs/core-testing/mythtv/stable-0.23/morethemes/PKGBUILD54
-rwxr-xr-xabs/core-testing/mythtv/stable-0.23/mp_all.sh30
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mytharchive/PKGBUILD47
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythbrowser/PKGBUILD47
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythgallery/PKGBUILD45
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythgame/PKGBUILD47
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythmovies/PKGBUILD48
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythmusic/PKGBUILD51
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythnetvision/PKGBUILD47
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythnews/PKGBUILD47
-rwxr-xr-xabs/core-testing/mythtv/stable-0.23/myththemes/PKGBUILD47
-rwxr-xr-xabs/core-testing/mythtv/stable-0.23/mythtv/PKGBUILD93
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/HOST_SETTINGS.xml94
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/is.xml3
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/library.xml.patch12
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/linhes.xml59
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mainmenu.xml.patch95
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mythbackup.xml20
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mythrestore.xml20
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/optical_menu.xml.patch16
-rwxr-xr-xabs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/original/create_patch.sh5
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/setup.xml111
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/siriusmenu.xml419
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/update.xml20
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/update2.xml26
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/util_menu.xml.patch16
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/xmmenu.xml574
-rwxr-xr-xabs/core-testing/mythtv/stable-0.23/mythtv/myth.sh4
-rwxr-xr-xabs/core-testing/mythtv/stable-0.23/mythtv/mythbackend38
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/mythbackend.lr9
-rwxr-xr-xabs/core-testing/mythtv/stable-0.23/mythtv/mythbackend.sh117
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/mythfrontend.lr9
-rwxr-xr-xabs/core-testing/mythtv/stable-0.23/mythtv/mythtv.install47
-rwxr-xr-xabs/core-testing/mythtv/stable-0.23/mythtv/pretty9
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythtv/smolt_jump.patch30
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythvideo/PKGBUILD47
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythweather/PKGBUILD47
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythweb/PKGBUILD46
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythweb/mythweb.install10
-rw-r--r--abs/core-testing/mythtv/stable-0.23/mythzoneminder/PKGBUILD47
-rwxr-xr-xabs/core-testing/mythtv/trunk/mythtv/pretty1
-rw-r--r--abs/core-testing/nvidia-96xx-utils/PKGBUILD104
-rw-r--r--abs/core-testing/nvidia-96xx-utils/nvidia-96xx.install22
-rw-r--r--abs/core-testing/nvidia-96xx-utils/nvidia.install6
-rw-r--r--abs/core-testing/nvidia-96xx/NVIDIA_173.14.12_2.6.27.patch87
-rw-r--r--abs/core-testing/nvidia-96xx/PKGBUILD53
-rw-r--r--abs/core-testing/nvidia-96xx/nvidia-96.43.11-2.6.30.patch103
-rw-r--r--abs/core-testing/nvidia-96xx/nvidia-96xx.install22
-rw-r--r--abs/core-testing/nvidia-96xx/nvidia.install14
-rw-r--r--abs/core-testing/perl_modules/libxml-perl/PKGBUILD (renamed from abs/core-testing/libxml-perl/PKGBUILD)0
-rw-r--r--abs/core-testing/perl_modules/perl-xml-dom/PKGBUILD (renamed from abs/core-testing/perl-xml-dom/PKGBUILD)0
-rw-r--r--abs/core-testing/perl_modules/perlxml/PKGBUILD (renamed from abs/core-testing/perlxml/PKGBUILD)0
-rwxr-xr-xabs/core-testing/runit-scripts/PKGBUILD2
-rwxr-xr-xabs/core-testing/runit-scripts/runitscripts/services/lircd/run76
-rwxr-xr-xabs/core-testing/runit-scripts/runitscripts/services/postfix/run8
-rwxr-xr-xabs/core-testing/system-templates/PKGBUILD2
-rw-r--r--abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/lircd-haupgrey-alt.conf199
-rw-r--r--abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/lircrc-haupgrey-alt533
-rw-r--r--abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/preview.jpgbin0 -> 3069 bytes
-rw-r--r--abs/core-testing/system-templates/templates/remotes/imon/lircrc240
-rw-r--r--abs/core-testing/system-templates/templates/settings/default_1/jumppoints.txt44
-rw-r--r--abs/core-testing/system-templates/templates/settings/default_2/jumppoints.txt44
-rw-r--r--abs/core-testing/system-templates/templates/settings/default_2/settings.txt10
-rw-r--r--[-rwxr-xr-x]abs/core-testing/system-templates/templates/transmit/motorola_dct700/lircd.conf432
-rw-r--r--abs/core-testing/vdpauinfo-legacy/PKGBUILD (renamed from abs/core-testing/vdpinfo-71xx/PKGBUILD)17
-rwxr-xr-xabs/core-testing/vdpauinfo-legacy/vdpauinfo (renamed from abs/core-testing/vdpinfo-96xx/vdpinfo)0
-rw-r--r--abs/core-testing/vdpauinfo/PKGBUILD7
-rw-r--r--abs/core-testing/vdpauinfo/__changelog2
-rwxr-xr-xabs/core-testing/vdpinfo-71xx/vdpinfo2
-rw-r--r--abs/core-testing/vdpinfo-96xx/PKGBUILD25
-rw-r--r--abs/extra-testing/alpine/2.00-lpam.patch13
-rw-r--r--abs/extra-testing/alpine/CVE-2008-5514.patch20
-rw-r--r--abs/extra-testing/alpine/ChangeLog43
-rw-r--r--abs/extra-testing/alpine/PKGBUILD37
-rw-r--r--abs/extra-testing/bluez/PKGBUILD24
-rw-r--r--abs/extra-testing/bluez/__Changelog7
-rw-r--r--abs/extra-testing/bluez/bluez.install15
-rw-r--r--abs/extra-testing/bluez/rc.bluetooth106
-rw-r--r--abs/extra-testing/bluez/run.bluetoothd12
-rw-r--r--abs/extra-testing/bluez/run.dund14
-rw-r--r--abs/extra-testing/bluez/run.hidd14
-rw-r--r--abs/extra-testing/bluez/run.pand14
-rw-r--r--abs/extra-testing/bluez/run.rfcomm17
-rw-r--r--abs/extra-testing/bluez/runit.bluetooth65
-rw-r--r--abs/extra-testing/community/mythtv-contrib/PKGBUILD9
-rw-r--r--abs/extra-testing/community/transmission-cli/PKGBUILD17
-rwxr-xr-xabs/extra-testing/community/transmission-cli/finish15
-rwxr-xr-xabs/extra-testing/community/transmission-cli/run.transmissiond (renamed from abs/extra-testing/community/transmission-cli/run)8
-rw-r--r--abs/extra-testing/community/transmission-cli/transmission-cli.install23
-rw-r--r--abs/extra-testing/community/transmission-cli/transmission.include15
-rw-r--r--abs/extra-testing/gnupg/PKGBUILD25
-rw-r--r--abs/extra-testing/gnupg/gnupg.install21
-rw-r--r--abs/extra-testing/gpgme/PKGBUILD25
-rw-r--r--abs/extra-testing/gpgme/__changelog1
-rw-r--r--abs/extra-testing/gpgme/gpgme.install18
-rw-r--r--abs/extra-testing/lcdproc/PKGBUILD17
-rw-r--r--abs/extra-testing/lcdproc/__changelog5
-rwxr-xr-xabs/extra-testing/lcdproc/lcdd38
-rw-r--r--abs/extra-testing/lcdproc/lcdproc.install7
-rw-r--r--abs/extra-testing/mime-types/PKGBUILD17
-rw-r--r--abs/extra-testing/mime-types/mime.types758
-rw-r--r--abs/extra-testing/mutt/PKGBUILD39
-rw-r--r--abs/extra-testing/mutt/mutt-unmailbox.patch10
-rw-r--r--abs/extra-testing/mutt/mutt.install15
-rw-r--r--abs/extra-testing/postfix/PKGBUILD52
-rw-r--r--abs/extra-testing/postfix/__changelog1
-rwxr-xr-xabs/extra-testing/postfix/postfix58
-rw-r--r--abs/extra-testing/postfix/postfix.install38
-rw-r--r--abs/extra-testing/postfix/postfix.patch.bz2bin0 -> 373 bytes
-rw-r--r--abs/extra-testing/procmail/PKGBUILD21
-rw-r--r--abs/extra-testing/pth/PKGBUILD22
225 files changed, 17957 insertions, 1125 deletions
diff --git a/abs/core-testing/LinHES-config/LinHES-release b/abs/core-testing/LinHES-config/LinHES-release
index 79e2144..4f1b8f1 100644
--- a/abs/core-testing/LinHES-config/LinHES-release
+++ b/abs/core-testing/LinHES-config/LinHES-release
@@ -1 +1 @@
-LinHES R6.02.01 (hot nanners)
+LinHES R6.02.02 (hot nanners)
diff --git a/abs/core-testing/LinHES-config/PKGBUILD b/abs/core-testing/LinHES-config/PKGBUILD
index 60c6b07..61a9148 100644
--- a/abs/core-testing/LinHES-config/PKGBUILD
+++ b/abs/core-testing/LinHES-config/PKGBUILD
@@ -1,49 +1,51 @@
pkgname=LinHES-config
pkgver=2.1
-pkgrel=27
+pkgrel=37
conflicts=(MythVantage-config MythVantage-config-dev LinHES-config-dev LinHes-config )
pkgdesc="Install and configure your system"
-depends=('bc' 'libstatgrab' 'mysql-python' 'expect' 'curl' 'dnsutils' 'parted'
- 'sg3_utils' 'nmbscan' 'system-templates' 'rsync' 'python-parted'
- 'ddcxinfo' 'python-pexpect' 'python-netifaces' 'LinHES-timezone'
+depends=('bc' 'libstatgrab' 'mysql-python' 'expect' 'curl' 'dnsutils' 'parted'
+ 'sg3_utils' 'nmbscan' 'system-templates' 'rsync' 'python-parted'
+ 'ddcxinfo' 'python-pexpect' 'python-netifaces' 'LinHES-timezone'
'python-iplib' 'mythinstall>=2-10')
arch=('i686')
-source=(mv_install.py
- mv_config.py
- myth_user_call
- file_time_offset.py
- install_proxy.sh
- install_functions.sh
- systemconfig.sh
- install_db_chroot.sh
- restore_default_settings.sh
- xconfig.sh
- timezip.py
- soundconfig.sh
- LinHES-release
- issue
- MythVantage.sh
- create_master.sh
- build_diskless.sh
- networkconfig.sh
- autocard.py
- restore_km_db_chroot.sh
- README
- mv_advanced.py
- mv_common.py
- mv_ddns.py
- mv_ir.py
- mv_misc.py
- mv_network.py
- mv_screensaver.py
- mv_smolt.py
- mv_software.py
- mv_webuser.py
- mv_hostype.py
- systemconfig.py
- myth_user_call.py)
+source=(mv_install.py
+ mv_config.py
+ myth_user_call
+ file_time_offset.py
+ install_proxy.sh
+ install_functions.sh
+ systemconfig.sh
+ install_db_chroot.sh
+ restore_default_settings.sh
+ xconfig.sh
+ timezip.py
+ soundconfig.sh
+ LinHES-release
+ issue
+ MythVantage.sh
+ create_master.sh
+ build_diskless.sh
+ networkconfig.sh
+ autocard.py
+ restore_km_db_chroot.sh
+ README
+ mv_advanced.py
+ mv_common.py
+ mv_ddns.py
+ mv_ir.py
+ mv_misc.py
+ mv_network.py
+ mv_screensaver.py
+ mv_smolt.py
+ mv_software.py
+ mv_webuser.py
+ mv_hostype.py
+ systemconfig.py
+ myth_user_call.py
+ mythvantage.cfg)
+backup=(etc/mythvantage.cfg)
install=LinHES.install
build() {
@@ -75,17 +77,18 @@ build() {
install -m 0755 mv_config.py $MVDIR/bin/mv_config.py
install -m 0755 mv_install.py $MVDIR/bin/mv_install.py
install -m 0755 mv_advanced.py $MVDIR/bin/
- install -m 0755 mv_common.py $MVDIR/bin/
- install -m 0755 mv_ddns.py $MVDIR/bin/
- install -m 0755 mv_ir.py $MVDIR/bin/
- install -m 0755 mv_misc.py $MVDIR/bin/
- install -m 0755 mv_network.py $MVDIR/bin/
- install -m 0755 mv_screensaver.py $MVDIR/bin/
- install -m 0755 mv_smolt.py $MVDIR/bin/
- install -m 0755 mv_software.py $MVDIR/bin/
- install -m 0755 mv_webuser.py $MVDIR/bin/
- install -m 0755 mv_hostype.py $MVDIR/bin/
- install -m 0755 systemconfig.py $MVDIR/bin/
+ install -m 0755 mv_common.py $MVDIR/bin/
+ install -m 0755 mv_ddns.py $MVDIR/bin/
+ install -m 0755 mv_ir.py $MVDIR/bin/
+ install -m 0755 mv_misc.py $MVDIR/bin/
+ install -m 0755 mv_network.py $MVDIR/bin/
+ install -m 0755 mv_screensaver.py $MVDIR/bin/
+ install -m 0755 mv_smolt.py $MVDIR/bin/
+ install -m 0755 mv_software.py $MVDIR/bin/
+ install -m 0755 mv_webuser.py $MVDIR/bin/
+ install -m 0755 mv_hostype.py $MVDIR/bin/
+ install -m 0755 systemconfig.py $MVDIR/bin/
+ install -m 0755 mythvantage.cfg $startdir/pkg/etc/
#README file displayed on install
install -m 0755 README $MVDIR/README
@@ -98,3 +101,39 @@ build() {
install -m 0755 issue $startdir/pkg/etc/issue
}
+
+md5sums=('297441b8d85820698c19e7c0ad5a3dfe'
+ '1a4694fcd694b362c339bda781ed0f3e'
+ 'e36da536dd651ef182e7642337889e77'
+ '3baa23764e1b6bcb2d66d7d859096940'
+ 'd7a8cd4a0060399ae22e69f74e04eb07'
+ '7a45287a07145fde5aa664583d4f6fba'
+ 'f88d2fb88339a4bf8ec9217a3fbcdef7'
+ '8ac1cfd2eca0f641737da0d0aca416a7'
+ '9ae8d79f620c6d19973c55c32a921874'
+ '4620f6f498ef4523398635cb0bd59425'
+ '06188493e5ed79cb501d3c5694dee8ca'
+ 'e459ed069317bccb20351f037a9df3d2'
+ '5115da23daa4d57c2fce89b36e08bd3a'
+ '6aff504ed5e860adc1b7317cd0780900'
+ '55fccb1da0417a896b724f7cfc32dd5a'
+ 'ab2aa42c2947148c2b1cac0ade6d1d55'
+ 'd429b59d3cfb37b0624c6a4a71a7c2c0'
+ 'a225143e3df6f56d451c2875e54ddbae'
+ '687555968d4ca688d8f95c8f13e1d8d4'
+ '3d1e4a119f38cff0498bf8a67e94e4b3'
+ '37401edf67296d3a4467ad178958d177'
+ 'ee7c8e1f025ce1527ecfffabafb26806'
+ '41b03fb1e0a9d9ae7588e3b813212772'
+ 'a9ffe72c3ede99d505fdc97572a7c256'
+ 'df43bce1712320508d4eef8449c5d223'
+ '65d93f15ac85adf8299552581789a731'
+ '4badc3c664c55f87396a473e6c14d4bc'
+ 'e2aa772fe0bf366e26eaaf663f9257bd'
+ 'fe5e31b833cc6707209e9d656b6eb53c'
+ 'd328d63eaa4252f3d4888476c79bbff6'
+ '23d0e12b7ca1cc6ea6b993c1d7ff20b9'
+ '857a831e8627727306208f0e776b1b98'
+ 'cf35353141b70145f3ee8b0bd852c9f1'
+ 'cf60e7ba4cf3467bb5539d5c51da61b6'
+ 'a63ff9ef5250965aeabc74bfa8e43981')
diff --git a/abs/core-testing/LinHES-config/mv_advanced.py b/abs/core-testing/LinHES-config/mv_advanced.py
index d07b7cb..bc0d19e 100755
--- a/abs/core-testing/LinHES-config/mv_advanced.py
+++ b/abs/core-testing/LinHES-config/mv_advanced.py
@@ -349,6 +349,9 @@ def setup_dyndns(DDnsEnable):
def setup_advanced(systemconfig,data_config):
+ if mv_common.read_config(mv_common.module_config,"advanced") == False :
+ logging.info("____Skipping of Advanced, config disabled____")
+ return
logging.info("____Start of advanced configuration____")
create_link = False
if systemconfig["SystemType"] == "Master_backend":
diff --git a/abs/core-testing/LinHES-config/mv_common.py b/abs/core-testing/LinHES-config/mv_common.py
index 28b53d7..0272809 100755
--- a/abs/core-testing/LinHES-config/mv_common.py
+++ b/abs/core-testing/LinHES-config/mv_common.py
@@ -1,9 +1,34 @@
# -*- coding: utf-8 -*-
import logging, os, time
import commands
+import ConfigParser
config_file = "mv_config"
data_config = __import__(config_file, globals(), locals(), [])
+module_config = ConfigParser.RawConfigParser()
+try:
+ module_config.read('/etc/mythvantage.cfg')
+except:
+ logging.info("couldn't read mythvantage.cfg")
+
+
+def read_config(module_config,data):
+ rvalue = True
+ section = "mythvantage"
+ try:
+ rvalue = module_config.get(section, data)
+ if rvalue == "False":
+ rvalue = False
+ if rvalue == "no":
+ rvalue = False
+
+
+ except:
+ logging.debug("Couldn't read mythvantage.cfg")
+ rvalue = True
+
+ return rvalue
+
def runcmd(cmd):
if data_config.NOOPDEBUG=="FALSE":
pass
diff --git a/abs/core-testing/LinHES-config/mv_ddns.py b/abs/core-testing/LinHES-config/mv_ddns.py
index 7ac7d3a..9695f76 100755
--- a/abs/core-testing/LinHES-config/mv_ddns.py
+++ b/abs/core-testing/LinHES-config/mv_ddns.py
@@ -5,12 +5,15 @@ import os, re
config_file = "mv_config"
def setup_ddns(systemconfig):
+ if mv_common.read_config(mv_common.module_config,"ddns") == False :
+ logging.info("____Skipping of DDNS, config disabled____")
+ return
logging.info("____Start of setup_ddns____")
if systemconfig["DDnsEnable"] == "1":
logging.debug(" Enabling DDNS")
mv_common.pacinstall("ddclient")
- mv_common.cp_and_log("/etc/ddclient/ddclient.conf.dynamic.dyndns.sample",
+ mv_common.cp_and_log("/etc/ddclient/ddclient.conf.dynamic.dyndns.sample",
"/etc/ddclient/ddclient.conf")
cmd = ''' sed -i -e "s/your-dynamic-dyndns-login/%s/g" /etc/ddclient/ddclient.conf''' %(systemconfig["DDnslogin"])
mv_common.runcmd(cmd)
diff --git a/abs/core-testing/LinHES-config/mv_hostype.py b/abs/core-testing/LinHES-config/mv_hostype.py
index d6ec0ed..4eade73 100755
--- a/abs/core-testing/LinHES-config/mv_hostype.py
+++ b/abs/core-testing/LinHES-config/mv_hostype.py
@@ -124,6 +124,9 @@ def setup_syslog(dbhost):
return
def hostypeprint(systemconfig):
+ if mv_common.read_config(mv_common.module_config,"hostype") == False :
+ logging.info("____Skipping of hostype, config disabled____")
+ return
logging.info("______Start of hostype config_____")
mv_common.services(systemconfig)
install_list=''
@@ -212,7 +215,7 @@ def hostypeprint(systemconfig):
else:
logging.debug(" Will NOT run the frontend")
mv_common.remove_service("frontend")
- mv_common.remove_service("hal")
+ mv_common.add_service("hal")
if data_config.SYSTEMTYPE == "MythVantage":
mv_common.remove_service("ghosd")
diff --git a/abs/core-testing/LinHES-config/mv_ir.py b/abs/core-testing/LinHES-config/mv_ir.py
index bc1ae37..a5e3f3b 100755
--- a/abs/core-testing/LinHES-config/mv_ir.py
+++ b/abs/core-testing/LinHES-config/mv_ir.py
@@ -113,7 +113,7 @@ def setup_ir_remote(Remotetype,templates):
mv_common.add_service("lircd")
-def setup_ir_receiver(ReceiverType,TEMPLATES):
+def setup_ir_receiver(ReceiverType,TEMPLATES,HDHRlirc_device,myip):
logging.info(" Configuring receiver %s", ReceiverType)
if ReceiverType == "Serial":
scrub_modules("/etc/modules.mythvantage","lirc")
@@ -153,6 +153,7 @@ def setup_ir_receiver(ReceiverType,TEMPLATES):
mv_common.runcmd(cmd)
mv_common.remove_service("igdaemon")
mv_common.remove_service("tatir")
+
elif ReceiverType == "iguanaIR-usb":
scrub_modules("/etc/modules.mythvantage","lirc")
mv_common.add_service("igdaemon")
@@ -162,6 +163,12 @@ def setup_ir_receiver(ReceiverType,TEMPLATES):
scrub_modules("/etc/modules.mythvantage","lirc")
mv_common.add_service("tatir")
mv_common.remove_service("igdaemon")
+ elif ReceiverType == "SiliconDust_HDHR":
+ mv_common.remove_service("igdaemon")
+ mv_common.remove_service("tatir")
+ cmd = '''hdhomerun_config %s set /ir/target %s:5000 store''' %(HDHRlirc_device,myip)
+ print cmd
+ mv_common.runcmd(cmd)
else:
logging.debug(" didn't match receiver, using genric case")
@@ -281,7 +288,11 @@ def setup_lcd(LCDtype, TEMPLATES, Remotetype):
logging.debug("__End of setup_lcd")
def setup_ir(systemconfig, data_config):
- rc = False
+ rc = [ False , False ]
+ if mv_common.read_config(mv_common.module_config,"ir") == False :
+ logging.info("____Skipping of IR, config disabled____")
+ return rc
+
logging.info("____Start of IR____")
if systemconfig["Remotetype"] == "tinker":
logging.info(" Tinker mode detected")
@@ -304,9 +315,11 @@ def setup_ir(systemconfig, data_config):
if systemconfig["ReceiverType"]:
setup_ir_receiver(systemconfig["ReceiverType"],
- systemconfig["TEMPLATES"])
+ systemconfig["TEMPLATES"],
+ systemconfig["HDHRlirc_device"],
+ systemconfig["mythip"])
else:
- setup_ir_receiver("unknown", systemconfig["TEMPLATES"])
+ setup_ir_receiver("unknown", systemconfig["TEMPLATES"],'','127.0.0.1')
unload_all_lirc()
setup_blaster_proto(HostBlasterType,
Hostnumblaster,
diff --git a/abs/core-testing/LinHES-config/mv_network.py b/abs/core-testing/LinHES-config/mv_network.py
index b80e4cc..f256785 100755
--- a/abs/core-testing/LinHES-config/mv_network.py
+++ b/abs/core-testing/LinHES-config/mv_network.py
@@ -50,7 +50,7 @@ def get_ip(ifname):
)[20:24])
def get_default_route(iface):
- rcroute = "127.0.0.1"
+ rcroute = "127.0.0.1"
f = open ('/proc/net/route', 'r')
for line in f:
words = string.split (line)
@@ -107,7 +107,7 @@ def setup_MTYH_DNS():
for line in f:
if line.startswith("nameserver"):
print line
- returndns = line.split()[1]
+ returndns = line.split()[1]
break
except:
logging.debug(" Couldn't open /etc/resolv.conf for myth_dns")
@@ -158,7 +158,7 @@ def setup_hostname(systemconfig):
except:
logging.critical(" *Hostname could not be set")
logging.info(" Using default value of me")
- hostname = "me"
+ hostname = "diamonds"
logging.info(" Setting the hostname to %s", hostname)
cmd = ''' echo %s > /etc/hostname ''' %hostname
mv_common.runcmd(cmd)
@@ -168,7 +168,7 @@ def setup_hostname(systemconfig):
logging.debug(" not using dhcp")
cmd = ''' echo 127.0.0.1 localhost > /etc/hosts '''
mv_common.runcmd(cmd)
- cmd = ''' echo %s %s > /etc/hosts ''' %(systemconfig["mythip"], systemconfig["hostname"])
+ cmd = ''' echo %s %s >> /etc/hosts ''' %(systemconfig["mythip"], systemconfig["hostname"])
mv_common.runcmd(cmd)
else:
cmd = ''' echo 127.0.0.1 %s localhost > /etc/hosts ''' %systemconfig["hostname"]
@@ -482,6 +482,9 @@ def hostname_change_check(systemconfig):
def setup_network (systemconfig,this_is_install):
+ if mv_common.read_config(mv_common.module_config,"network") == False :
+ logging.info("____Skipping of network, config disabled____")
+ return False
logging.info("____Start of network____")
logging.info(" Setting up the network")
restartfe = hostname_change_check(systemconfig)
diff --git a/abs/core-testing/LinHES-config/mv_screensaver.py b/abs/core-testing/LinHES-config/mv_screensaver.py
index 2da970c..4068832 100755
--- a/abs/core-testing/LinHES-config/mv_screensaver.py
+++ b/abs/core-testing/LinHES-config/mv_screensaver.py
@@ -163,6 +163,9 @@ def setup_gnome_screensaver(theme,idletime):
def setup_screensaver (systemconfig,data_config):
+ if mv_common.read_config(mv_common.module_config,"screensaver") == False :
+ logging.info("____Skipping of Screensaver, config disabled____")
+ return
logging.info("____Start of screensaver configuration____")
screensavertype = systemconfig["Screensavertype"]
theme = systemconfig["Screensavertheme"]
diff --git a/abs/core-testing/LinHES-config/mv_smolt.py b/abs/core-testing/LinHES-config/mv_smolt.py
index 5fd3722..cfc697e 100755
--- a/abs/core-testing/LinHES-config/mv_smolt.py
+++ b/abs/core-testing/LinHES-config/mv_smolt.py
@@ -20,6 +20,9 @@ def read_release(stype):
def setup_smolt_type(SystemType,Remotetype,RunFrontend,mythhome,stype):
+ if mv_common.read_config(mv_common.module_config,"smolt") == False :
+ logging.info("____Skipping of smolt, config disabled____")
+ return
logging.debug("____Start of setup_smolt_type____")
releasename = read_release(stype)
diff --git a/abs/core-testing/LinHES-config/mv_software.py b/abs/core-testing/LinHES-config/mv_software.py
index 4ee2e4d..c0f5a5b 100755
--- a/abs/core-testing/LinHES-config/mv_software.py
+++ b/abs/core-testing/LinHES-config/mv_software.py
@@ -3,6 +3,10 @@ import logging, mv_common
import os, re
def setup_software(systemconfig, data_config):
+ if mv_common.read_config(mv_common.module_config,"software") == False :
+ logging.info("____Skipping of software, config disabled____")
+ return
+
logging.info("____Start of Software install____")
postfix=''
if data_config.SYSTEMTYPE == "MythVantage":
diff --git a/abs/core-testing/LinHES-config/mv_webuser.py b/abs/core-testing/LinHES-config/mv_webuser.py
index a8517a8..3e383f2 100755
--- a/abs/core-testing/LinHES-config/mv_webuser.py
+++ b/abs/core-testing/LinHES-config/mv_webuser.py
@@ -3,6 +3,10 @@ import logging, mv_common
#import os
def setup_web_auth(UseMythWEB_auth):
+ if mv_common.read_config(mv_common.module_config,"webuser") == False :
+ logging.info("____Skipping of webuser, config disabled____")
+ return
+
logging.info("____Start of setup_web_auth____")
if UseMythWEB_auth == str(1):
#enable auth
diff --git a/abs/core-testing/LinHES-config/mythvantage.cfg b/abs/core-testing/LinHES-config/mythvantage.cfg
new file mode 100644
index 0000000..eaa4865
--- /dev/null
+++ b/abs/core-testing/LinHES-config/mythvantage.cfg
@@ -0,0 +1,21 @@
+[mythvantage]
+#change any of the following to False or True
+# True will allow systemconfig to run that module
+# False will skip the module
+misc = True
+sleep = True
+hostype = True
+advanced = True
+audio = True
+network = True
+xorg = True
+webuser = True
+restartfe = True
+reloadfe = True
+ddns = True
+screensaver = True
+ir = True
+user = True
+software = True
+smolt = True
+
diff --git a/abs/core-testing/LinHES-config/restore_default_settings.sh b/abs/core-testing/LinHES-config/restore_default_settings.sh
index dcf5e23..ffd4b0d 100755
--- a/abs/core-testing/LinHES-config/restore_default_settings.sh
+++ b/abs/core-testing/LinHES-config/restore_default_settings.sh
@@ -5,7 +5,7 @@ shopt -s -o nounset
echo $@ >> /tmp/restore.out
#TEMPLATES="/usr/share/templates/settings"
TEMPLATES="$TEMPLATES/settings"
-TABLES="settings keybindings"
+TABLES="settings keybindings jumppoints"
MYTHDBUSER=mythtv
MYTHTVPASSWD=mythtv
declare -r OPTSTRING="c:e:t:d:h:s:a:z:Ho"
@@ -15,12 +15,12 @@ declare -i EVERYTHING=0
function CMD_DEFINE () {
- #add override check
+ #add override check
if [ x$Thistemplate = xsyssettings -a $OVERRIDE -eq 1 ]
then
- MYSQLCMD="mysql --local-infile -s -u$MYTHDBUSER -p$MYTHTVPASSWD -h$ovdbhost mythconverg -B --exec"
- MYSQLCMD_C="mysql -u$MYTHDBUSER -p$MYTHTVPASSWD -h$ovdbhost mythconverg -B --exec"
- MYSQLCMD_UPDATE_HOST="UPDATE settings set data='$oldhostname' where value='HostMyhostname' and hostname=\"$hostname\";"
+ MYSQLCMD="mysql --local-infile -s -u$MYTHDBUSER -p$MYTHTVPASSWD -h$ovdbhost mythconverg -B --exec"
+ MYSQLCMD_C="mysql -u$MYTHDBUSER -p$MYTHTVPASSWD -h$ovdbhost mythconverg -B --exec"
+ MYSQLCMD_UPDATE_HOST="UPDATE settings set data='$oldhostname' where value='HostMyhostname' and hostname=\"$hostname\";"
else
MYSQLCMD="mysql --local-infile -s -u$MYTHDBUSER -p$MYTHTVPASSWD -h$dbhost mythconverg -B --exec"
MYSQLCMD_C="mysql -u$MYTHDBUSER -p$MYTHTVPASSWD -h$dbhost mythconverg -B --exec"
@@ -32,21 +32,21 @@ function SQL_DEFINE () {
thostname=`echo ${hostname}|tr -C [:alpha:] _`
echo "Using $thostname for temp table postfix"
- #$1 is the table name
- if [ $1 = "settings" ]
- then
- ALTERSQL="Alter table temp_${1}_${thostname} add unique ( value )"
- else
- ALTERSQL=";"
- fi
+ #$1 is the table name
+ if [ $1 = "settings" ]
+ then
+ ALTERSQL="Alter table temp_${1}_${thostname} add unique ( value )"
+ else
+ ALTERSQL=";"
+ fi
CREATESQL="create table temp_${1}_${thostname} like $1;"
- COPY_TMP_SQL="replace into temp_${1}_${thostname} (select * from $1 where hostname=\"$hostname\");"
- INSERTSQL="LOAD DATA local INFILE '/tmp/$1.txt' REPLACE INTO TABLE temp_${1}_${thostname} FIELDS TERMINATED BY '\t';"
+ COPY_TMP_SQL="replace into temp_${1}_${thostname} (select * from $1 where hostname=\"$hostname\");"
+ INSERTSQL="LOAD DATA local INFILE '/tmp/$1.txt' REPLACE INTO TABLE temp_${1}_${thostname} FIELDS TERMINATED BY '\t';"
#INSERTSQL="LOAD DATA local INFILE '$TEMPLATES/$Thistemplate/$1.txt' REPLACE INTO TABLE temp_${1}_${hostname} FIELDS TERMINATED BY '\t';"
- DROPSQL="delete from $1 where hostname=\"$hostname\";"
- COPY_BCK_SQL="replace into $1 (select * from temp_${1}_${thostname} where hostname=\"$hostname\");"
- DROP_TABLE="Drop table temp_${1}_${thostname}"
+ DROPSQL="delete from $1 where hostname=\"$hostname\";"
+ COPY_BCK_SQL="replace into $1 (select * from temp_${1}_${thostname} where hostname=\"$hostname\");"
+ DROP_TABLE="Drop table temp_${1}_${thostname}"
}
function ARG_ERR() {
@@ -101,8 +101,8 @@ do
ARG_ERR
Thistemplate=$OPTARG
- if [ x$Thistemplate = x"syssettings" ]
- then
+ if [ x$Thistemplate = x"syssettings" ]
+ then
echo "template is syssettings"
loadhost=false
elif [ x$Thistemplate = x"hostsettings" ]
@@ -128,13 +128,13 @@ do
ARG_ERR
if [ $OVERRIDE = 1 ]
then
- oldhostname=$hostname
+ oldhostname=$hostname
hostname=$OPTARG
else
hostname=$OPTARG
- fi
+ fi
- ;;
+ ;;
s) echo "$SWITCH" "$OPTARG"
ARG_ERR
SYSTEMTYPE=$OPTARG
@@ -144,11 +144,11 @@ do
IP_ADDRESS=$OPTARG
;;
z) echo "$SWITCH" "$OPTARG"
- ARG_ERR
- ZIPCODE=$OPTARG
+ ARG_ERR
+ ZIPCODE=$OPTARG
;;
- o) OVERRIDE=1
- ;;
+ o) OVERRIDE=1
+ ;;
esac
done
@@ -175,10 +175,10 @@ fi
case $OPERATION in
- restore)
- #used to restore settings from syssettings
- if [ -d $TEMPLATES/$Thistemplate ]
- then
+ restore)
+ #used to restore settings from syssettings
+ if [ -d $TEMPLATES/$Thistemplate ]
+ then
cd $TEMPLATES/$Thistemplate
if [ $loadhost = false ]
then
@@ -213,38 +213,42 @@ case $OPERATION in
$MYSQLCMD "$COPY_BCK_SQL"
$MYSQLCMD "$DROP_TABLE "
fi
- else
- echo "couldn't find $TEMPLATES/$Thistemplate"
- fi
- ;;
+ else
+ echo "couldn't find $TEMPLATES/$Thistemplate"
+ fi
+ ;;
- save)
+ save)
+ if [ ! -d $TEMPLATES/$Thistemplate ]
+ then
+ mkdir -p $TEMPLATES/$Thistemplate
+ fi
- if [ ! -d $TEMPLATES/$Thistemplate ]
- then
- mkdir -p $TEMPLATES/$Thistemplate
- fi
+ cd $TEMPLATES/$Thistemplate
+ for i in $TABLES
+ do
+ EXTRACLAUSE=""
+ case $i in
+ settings)
+ EXTRACLAUSE="and not (value like \"BackendServerIP\") and not (value like \"locale\") order by value"
+ SQL="select value,data,'REPLACEME' as hostname from $i where hostname=\"$hostname\" "$EXTRACLAUSE" ;"
+ # SQL="select * from $i where hostname=\"$hostname\" "$EXTRACLAUSE" ;"
+ $MYSQLCMD_C "$SQL" > $TEMPLATES/$Thistemplate/$i.txt
+ ;;
+ keybindings)
+ SQL="select context,action,description,keylist,'REPLACEME' as hostname from $i where hostname=\"$hostname\" "$EXTRACLAUSE" ;"
+ $MYSQLCMD_C "$SQL" > $TEMPLATES/$Thistemplate/$i.txt
+ ;;
+ jumppoints)
+ SQL="select destination,description,keylist,'REPLACEME' as hostname from $i where hostname=\"$hostname\" "$EXTRACLAUSE" ;"
+ $MYSQLCMD_C "$SQL" > $TEMPLATES/$Thistemplate/$i.txt
- cd $TEMPLATES/$Thistemplate
- for i in $TABLES
- do
- EXTRACLAUSE=""
- case $i in
- settings)
- EXTRACLAUSE="and not (value like \"BackendServerIP\") and not (value like \"locale\") order by value"
- SQL="select value,data,'REPLACEME' as hostname from $i where hostname=\"$hostname\" "$EXTRACLAUSE" ;"
- # SQL="select * from $i where hostname=\"$hostname\" "$EXTRACLAUSE" ;"
- $MYSQLCMD_C "$SQL" > $TEMPLATES/$Thistemplate/$i.txt
- ;;
- keybindings)
- SQL="select context,action,description,keylist,'REPLACEME' as hostname from $i where hostname=\"$hostname\" "$EXTRACLAUSE" ;"
- $MYSQLCMD_C "$SQL" > $TEMPLATES/$Thistemplate/$i.txt
- ;;
- esac
- # sed -e "s/$hostname/REPLACEME/g" $i > $i.txt && rm $i
+ ;;
+ esac
+ # sed -e "s/$hostname/REPLACEME/g" $i > $i.txt && rm $i
- done
- ;;
+ done
+ ;;
load)
@@ -253,22 +257,22 @@ case $OPERATION in
do
if [ -f $TEMPLATES/$i/settings.txt ]
then
- echo $i
- for tablename in $TABLES
+ echo $i
+ for tablename in $TABLES
do
- #create table
+ #create table
CREATESQL="create table IF NOT EXISTS ${tablename}_${i} like $tablename;"
$MYSQLCMD_C "$CREATESQL"
- #truncate table
+ #truncate table
TRUNCATESQL="truncate ${tablename}_${i} "
$MYSQLCMD_C "$TRUNCATESQL"
- #load table
- INSERTSQL="LOAD DATA local INFILE '$TEMPLATES/$i/$tablename.txt' REPLACE INTO TABLE ${tablename}_${i} FIELDS TERMINATED BY '\t';"
+ #load table
+ INSERTSQL="LOAD DATA local INFILE '$TEMPLATES/$i/$tablename.txt' REPLACE INTO TABLE ${tablename}_${i} FIELDS TERMINATED BY '\t';"
$MYSQLCMD_C "$INSERTSQL"
- #update_hostname
- UPDATEHOSTNAMESQL="update ${tablename}_${i} set hostname='$i' ; "
+ #update_hostname
+ UPDATEHOSTNAMESQL="update ${tablename}_${i} set hostname='$i' ; "
$MYSQLCMD_C "$UPDATEHOSTNAMESQL"
- done
+ done
else
echo "couldn't find $TEMPLATES/$i/settings.txt template to load"
@@ -286,6 +290,14 @@ case $OPERATION in
$MYSQLCMD_C "$CREATESQL"
CREATESQL="create table IF NOT EXISTS keybindings_user3 like keybindings;"
$MYSQLCMD_C "$CREATESQL"
+
+ CREATESQL="create table IF NOT EXISTS jumppoints_user1 like jumppoints;"
+ $MYSQLCMD_C "$CREATESQL"
+ CREATESQL="create table IF NOT EXISTS jumppoints_user2 like jumppoints;"
+ $MYSQLCMD_C "$CREATESQL"
+ CREATESQL="create table IF NOT EXISTS jumppoints_user3 like jumppoints;"
+ $MYSQLCMD_C "$CREATESQL"
+
done
;;
@@ -302,14 +314,14 @@ case $OPERATION in
if [ $SYSTEMTYPE = "slave" ]
then
$MYSQLCMD_C "delete from settings where value='BackendServerIP' and hostname=\"$hostname\";"
- $MYSQLCMD_C "REPLACE INTO settings set data='${IP_ADDRESS}' , value='BackendServerIP' , hostname=\"$hostname\";"
+ $MYSQLCMD_C "REPLACE INTO settings set data='${IP_ADDRESS}' , value='BackendServerIP' , hostname=\"$hostname\";"
fi
;;
ZIP)
- $MYSQLCMD_C "delete from settings where value='locale' and hostname=\"$hostname\";"
- $MYSQLCMD_C "REPLACE INTO settings set data='$ZIPCODE' , value='locale' , hostname=\"$hostname\";"
- $MYSQLCMD_C "delete from settings where value='MythMovies.ZipCode' and hostname=\"$hostname\";"
- $MYSQLCMD_C "REPLACE INTO settings set data='$ZIPCODE', value='MythMovies.ZipCode' , hostname=\"$hostname\";"
+ $MYSQLCMD_C "delete from settings where value='locale' and hostname=\"$hostname\";"
+ $MYSQLCMD_C "REPLACE INTO settings set data='$ZIPCODE' , value='locale' , hostname=\"$hostname\";"
+ $MYSQLCMD_C "delete from settings where value='MythMovies.ZipCode' and hostname=\"$hostname\";"
+ $MYSQLCMD_C "REPLACE INTO settings set data='$ZIPCODE', value='MythMovies.ZipCode' , hostname=\"$hostname\";"
;;
MUSICFRONT)
ALSADEVICE
@@ -325,7 +337,7 @@ case $OPERATION in
$MYSQLCMD_C "delete from settings where value='MusicAudioDevice' and hostname=\"$hostname\";"
$MYSQLCMD_C "REPLACE INTO settings set data='$SoundDevice', value='MusicAudioDevice' , hostname=\"$hostname\";"
;;
- uhostname)
+ uhostname)
#used when the hostname is changed.
TABLES="settings capturecard keybindings storagegroup recorded"
for i in $TABLES
@@ -353,7 +365,7 @@ case $OPERATION in
SQL="update settings set data='0' where value='Hostaccessuser' and hostname=\"$hostname\" ;"
$MYSQLCMD_C "$SQL"
;;
- esac
+ esac
#SELECT * INTO OUTFILE 'data.txt'
# FIELDS TERMINATED BY ','
diff --git a/abs/core-testing/LinHES-config/systemconfig.py b/abs/core-testing/LinHES-config/systemconfig.py
index 28e2e7a..2e07b2f 100755
--- a/abs/core-testing/LinHES-config/systemconfig.py
+++ b/abs/core-testing/LinHES-config/systemconfig.py
@@ -36,8 +36,11 @@ def usage():
logging.info("tell people how to use this")
def setup_x(systemconfig):
- cmd = "%s/bin/xconfig.sh" %systemconfig["MVROOT"]
- mv_common.runcmd(cmd)
+ if mv_common.read_config(mv_common.module_config,"xorg") == False :
+ logging.info("____Skipping of Xorg, config disabled____")
+ else:
+ cmd = "%s/bin/xconfig.sh" %systemconfig["MVROOT"]
+ mv_common.runcmd(cmd)
def main(argv):
try:
@@ -124,23 +127,32 @@ def main(argv):
if cmdmodule["audio"] == True:
- logging.debug("______Start of Audio Configuration______")
- if not systemconfig["Audiotype"] == "tinker":
- cmd="%s/bin/soundconfig.sh -t real -i %s -d %s" %(MVROOT,systemconfig["Audiotype"],systemconfig["SoundDevice"])
- mv_common.runcmd(cmd)
+ if mv_common.read_config(mv_common.module_config,"audio") == False :
+ logging.info("____Skipping of Audio, config disabled____")
else:
- logging.debug(" Tinker mode(audio), not changing configuration")
- logging.debug("__End of audio")
+ logging.debug("______Start of Audio Configuration______")
+ if not systemconfig["Audiotype"] == "tinker":
+ cmd="%s/bin/soundconfig.sh -t real -i %s -d %s" %(MVROOT,systemconfig["Audiotype"],systemconfig["SoundDevice"])
+ mv_common.runcmd(cmd)
+ else:
+ logging.debug(" Tinker mode(audio), not changing configuration")
+ logging.debug("__End of audio")
if cmdmodule["misc"]:
- import mv_misc
- mv_misc.setup_zip(MVROOT,systemconfig["zipcode"])
- mv_misc.setup_tz(systemconfig["timezone"],systemconfig["TEMPLATES"])
- mv_misc.setup_nfs(systemconfig)
+ if mv_common.read_config(mv_common.module_config,"misc") == False :
+ logging.info("____Skipping of misc, config disabled____")
+ else:
+ import mv_misc
+ mv_misc.setup_zip(MVROOT,systemconfig["zipcode"])
+ mv_misc.setup_tz(systemconfig["timezone"],systemconfig["TEMPLATES"])
+ mv_misc.setup_nfs(systemconfig)
if cmdmodule["sleep"]:
- import mv_misc
- mv_misc.setup_sleep(systemconfig)
+ if mv_common.read_config(mv_common.module_config,"sleep") == False :
+ logging.info("____Skipping of sleep, config disabled____")
+ else:
+ import mv_misc
+ mv_misc.setup_sleep(systemconfig)
if cmdmodule["webuser"]:
import mv_webuser
@@ -163,7 +175,10 @@ def main(argv):
mv_software.setup_software(systemconfig, data_config)
if cmdmodule["advancedX"]:
- setup_x(systemconfig)
+ if mv_common.read_config(mv_common.module_config,"xorg") == False :
+ logging.info("____Skipping of advancedX, config disabled____")
+ else:
+ setup_x(systemconfig)
if cmdmodule["restartfe"]:
mv_common.restartfe(restartlcd)
diff --git a/abs/core-testing/LinHES-system/LinHES-run b/abs/core-testing/LinHES-system/LinHES-run
index f6451f5..aa2c3bd 100644
--- a/abs/core-testing/LinHES-system/LinHES-run
+++ b/abs/core-testing/LinHES-system/LinHES-run
@@ -53,6 +53,13 @@ SpecialHardwareCommands() {
esac
}
+#update apple trailers
+if [[ x$RunFrontend = x1 && -f ~/.configure ]]
+then
+ /usr/bin/php -q /usr/bin/myth_trailers_grabber > /home/mythtv/appletrailer.xml && /usr/bin/fix_aple_url.sh 2>/dev/null &
+fi
+
+
if [ ! $SystemType = "Frontend_only" ]
then
if [ -f ~/.configure ]
diff --git a/abs/core-testing/LinHES-system/PKGBUILD b/abs/core-testing/LinHES-system/PKGBUILD
index c76205a..316bcba 100644
--- a/abs/core-testing/LinHES-system/PKGBUILD
+++ b/abs/core-testing/LinHES-system/PKGBUILD
@@ -1,6 +1,6 @@
pkgname=LinHES-system
pkgver=1.1
-pkgrel=25
+pkgrel=29
arch=('i686')
MVDIR=$startdir/pkg/usr/LH
BINDIR=$startdir/pkg/usr/bin
@@ -15,66 +15,35 @@ source=(LinHES-session LinHES-profile.sh $binfiles alsa-base)
build() {
cd $startdir/src
install -m755 -D LinHES-session $startdir/pkg/etc/X11/Sessions/LinHES
- install -m755 -D LinHES-profile.sh $startdir/pkg/etc/profile.d/LinHES-profile.sh
-####### install to /usr/LH/bin
-#mkdir -p $BINDIR
+ install -m755 -D LinHES-profile.sh $startdir/pkg/etc/profile.d/LinHES-profile.sh
+ ####### install to /usr/LH/bin
+ for i in $binfiles
+ do
+ item=$i
+ install -m755 -D $item $MVDIR/bin/$item
+ echo $item
+ done
-for i in $binfiles
-do
- item=$i
- install -m755 -D $item $MVDIR/bin/$item
- echo $item
+ cd $startdir/bin
+ for i in *
+ do
+ item=$i
+ install -m755 -D $item $MVDIR/bin/$item
+ echo $item
+ done
-done
-
-cd $startdir/bin
-for i in *
-do
- item=$i
- install -m755 -D $item $MVDIR/bin/$item
- echo $item
-
-done
-install -m755 -D $startdir/src/alsa-base $startdir/pkg/etc/modprobe.d/alsa-base
-install -m755 -D $startdir/src/smolt.cron $startdir/pkg/etc/cron.weekly/smolt.cron
-mkdir $startdir/pkg/etc/logrotate.d
-cp $startdir/myth_mtc.lr $startdir/pkg/etc/logrotate.d
+ install -m755 -D $startdir/src/alsa-base $startdir/pkg/etc/modprobe.d/alsa-base
+ install -m755 -D $startdir/src/smolt.cron $startdir/pkg/etc/cron.weekly/smolt.cron
+ mkdir $startdir/pkg/etc/logrotate.d
+ cp $startdir/myth_mtc.lr $startdir/pkg/etc/logrotate.d
}
-
-md5sums=('19934a456d0e112298b8aac3279f9a16'
- '5881bdb43d578ec3a79d1f77ea58a3db'
- 'a875ee97f86e46f34a741c2bc455f894'
- 'cdcbc530224215f8fcf7ebcd93d7eb0b'
- 'c60b6c66f498809a6e5ca18a8c97d336'
- 'ccae1296ef248fa52ec3a7cb820a476e'
- '7bae998ba458a7f74c51c7268e39b28d'
- '18a884a73344ff6eb74f63b49745e0f5'
- 'dc3eef2a624754e16805d72bbe488b67'
- 'dc0be354ce77ba2b89868fc29b942c43'
- 'f1870a9522c79e6b248fcbf81dec3280'
- 'abe887472a170bd1a8e6da6a7b7e93e4'
- 'eb879fee9603a05d5420d4ce8ed9e450')
-md5sums=('19934a456d0e112298b8aac3279f9a16'
- '5881bdb43d578ec3a79d1f77ea58a3db'
- 'a875ee97f86e46f34a741c2bc455f894'
- 'cdcbc530224215f8fcf7ebcd93d7eb0b'
- 'c60b6c66f498809a6e5ca18a8c97d336'
- 'ccae1296ef248fa52ec3a7cb820a476e'
- '7bae998ba458a7f74c51c7268e39b28d'
- '18a884a73344ff6eb74f63b49745e0f5'
- 'dc3eef2a624754e16805d72bbe488b67'
- 'dc0be354ce77ba2b89868fc29b942c43'
- 'f1870a9522c79e6b248fcbf81dec3280'
- 'abe887472a170bd1a8e6da6a7b7e93e4'
- '5bced1c7b92e6190835139494c5e9905'
- 'eb879fee9603a05d5420d4ce8ed9e450')
md5sums=('19934a456d0e112298b8aac3279f9a16'
'5881bdb43d578ec3a79d1f77ea58a3db'
'a875ee97f86e46f34a741c2bc455f894'
'cdcbc530224215f8fcf7ebcd93d7eb0b'
'c60b6c66f498809a6e5ca18a8c97d336'
'ccae1296ef248fa52ec3a7cb820a476e'
- '7bae998ba458a7f74c51c7268e39b28d'
+ 'ebb35d5f685674cc86c864df760eff20'
'18a884a73344ff6eb74f63b49745e0f5'
'dc3eef2a624754e16805d72bbe488b67'
'dc0be354ce77ba2b89868fc29b942c43'
diff --git a/abs/core-testing/fluxbox/PKGBUILD b/abs/core-testing/fluxbox/PKGBUILD
index 1ec527f..9f4a438 100644
--- a/abs/core-testing/fluxbox/PKGBUILD
+++ b/abs/core-testing/fluxbox/PKGBUILD
@@ -4,7 +4,7 @@
pkgname=fluxbox
pkgver=1.1.1
-pkgrel=8
+pkgrel=10
pkgdesc="A lightweight and highly-configurable window manager"
arch=('i686' 'x86_64')
url="http://www.fluxbox.org"
@@ -13,9 +13,11 @@ depends=('libxft' 'libxpm' 'libxinerama' 'libxrandr' 'gcc-libs' 'bash' 'imlib2')
makedepends=('pkgconfig')
options=('!makeflags')
source=(http://downloads.sourceforge.net/sourceforge/${pkgname}/${pkgname}-${pkgver}.tar.bz2 \
- fluxbox.desktop keys)
+ fluxbox.desktop keys fluxbox_fullscreen_focus.patch)
build() {
+ echo "==> Patching Fluxbox with fullscreen focus patch..."
+ patch < fluxbox_fullscreen_focus.patch ${srcdir}/${pkgname}-${pkgver}/src/Window.cc || return 1
cd ${srcdir}/${pkgname}-${pkgver}
./configure --prefix=/usr \
--enable-kde --enable-gnome \
@@ -31,4 +33,5 @@ build() {
}
md5sums=('fa9fa8fe9a44f86522de5754f8b285ca'
'eeae9c88a2526ac0bd8afcd9ce97f9ed'
- '37438d3c615aec8c3335b5946923ca5f')
+ 'df8dd2ff7ec582d9a2221279d960750f'
+ '82dac089f2d42bb9592debc93291846d')
diff --git a/abs/core-testing/fluxbox/fluxbox_fullscreen_focus.patch b/abs/core-testing/fluxbox/fluxbox_fullscreen_focus.patch
new file mode 100644
index 0000000..1a8c233
--- /dev/null
+++ b/abs/core-testing/fluxbox/fluxbox_fullscreen_focus.patch
@@ -0,0 +1,12 @@
+--- src/Window.cc.orig 2010-04-12 16:45:00.750585365 -0500
++++ src/Window.cc 2010-04-12 16:45:38.719755786 -0500
+@@ -2042,8 +2042,7 @@
+ FluxboxWindow *cur = FocusControl::focusedFbWindow();
+ WinClient *client = FocusControl::focusedWindow();
+ if (ret && cur && getRootTransientFor(&from) != getRootTransientFor(client))
+- ret = !(cur->isFullscreen() && getOnHead() == cur->getOnHead()) &&
+- !cur->isTyping();
++ ret = !cur->isTyping();
+
+ if (!ret)
+ Fluxbox::instance()->attentionHandler().addAttention(from);
diff --git a/abs/core-testing/fluxbox/keys b/abs/core-testing/fluxbox/keys
index a166829..bf45b79 100644
--- a/abs/core-testing/fluxbox/keys
+++ b/abs/core-testing/fluxbox/keys
@@ -26,3 +26,4 @@ Mod1 2 :ExecCommand sudo sv stop mythbackend
Mod1 3 :ExecCommand sudo sv restart mythbackend
Mod1 h :ExecCommand MythVantage -h
Mod1 Control u :ExecCommand /usr/LH/bin/unclutter-toggle.sh
+Mod1 Escape :GotoWindow {1}
diff --git a/abs/core-testing/lighttpd/PKGBUILD b/abs/core-testing/lighttpd/PKGBUILD
index bbb0a39..0e43272 100644
--- a/abs/core-testing/lighttpd/PKGBUILD
+++ b/abs/core-testing/lighttpd/PKGBUILD
@@ -3,7 +3,7 @@
pkgname=lighttpd
pkgver=1.4.26
-pkgrel=9
+pkgrel=12
pkgdesc='a secure, fast, compliant and very flexible web-server'
license=('custom')
arch=('i686' 'x86_64')
@@ -65,13 +65,20 @@ build() {
-e 's|#server.pid-file = "/var/run/lighttpd.pid"|server.pid-file = "/var/run/lighttpd/lighttpd.pid"|' \
-e 's|/usr/local/bin/php-cgi|/usr/bin/php-cgi|' \
-e 's|"^/mythweb|"^/{1,2}mythweb|' \
+ -e 's|# "mod_proxy",| "mod_proxy",|' \
+ -e 's|# "mod_ssi",| "mod_ssi",|' \
+ -e 's|#ssi.extension = ( ".shtml" )|ssi.extension = ( ".shtml" )|' \
-i ${pkgdir}/etc/lighttpd/lighttpd.conf || return 1
+ /bin/touch $pkgdir/etc/lighttpd/{conf,html}.include || return 1
+ /bin/echo 'include "/etc/lighttpd/conf.include"' >> $pkgdir/etc/lighttpd/lighttpd.conf || return 1
+ /bin/echo 'include "/etc/lighttpd/html.include"' >> $pkgdir/etc/lighttpd/lighttpd.conf || return 1
+
install -D -m644 COPYING $pkgdir/usr/share/licenses/$pkgname/COPYING
}
md5sums=('a682c8efce47a2f4263a247ba0813c9b'
'bd690eee0d9e51857448770a151023b0'
'857e174643fd7761a2f0d8431a679f6c'
- '07b8459b54fb2e70280064c2a275b176'
+ '11fbec7ff7ca1b0d5575445681e8f60e'
'c6e361131000ceec085f40b310ef4a2c'
'84c884b8dadd724afe2bc6529e9d4485')
diff --git a/abs/core-testing/lighttpd/__changelog b/abs/core-testing/lighttpd/__changelog
index 63bc373..5c0a14f 100644
--- a/abs/core-testing/lighttpd/__changelog
+++ b/abs/core-testing/lighttpd/__changelog
@@ -6,4 +6,4 @@ upgraded to 1.4.26 to address http://linhes.org/flyspray/index.php?do=details&ta
Added -e 's|"^/mythweb|"^/{1,2}mythweb|' \ to the sed command to work around lighttpd no longer honoring // in a url and/or to work around mythweb producing url's with a // for streaming and downloading.
changed lightttpd.conf to user perl for .cgi (needed for monx)_
-
+added 404 page
diff --git a/abs/core-testing/lighttpd/lighttpd.conf b/abs/core-testing/lighttpd/lighttpd.conf
index af7d134..f437484 100644
--- a/abs/core-testing/lighttpd/lighttpd.conf
+++ b/abs/core-testing/lighttpd/lighttpd.conf
@@ -145,7 +145,7 @@ static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
#server.bind = "127.0.0.1"
## error-handler for status 404
-#server.error-handler-404 = "/error-handler.html"
+server.error-handler-404 = "/404.html"
#server.error-handler-404 = "/error-handler.php"
## to help the rc.scripts
diff --git a/abs/core-testing/linhes-scripts/PKGBUILD b/abs/core-testing/linhes-scripts/PKGBUILD
index 82cede0..6ecf501 100644
--- a/abs/core-testing/linhes-scripts/PKGBUILD
+++ b/abs/core-testing/linhes-scripts/PKGBUILD
@@ -3,7 +3,7 @@
pkgname=linhes-scripts
pkgver=1
-pkgrel=63
+pkgrel=66
pkgdesc="Various scripts that help to make LinHES, LinHES."
arch=('i686' 'x86_64')
license=('GPL2')
@@ -24,6 +24,7 @@ pause-mythcommflag.sh
myth2x264
770-wrapper.sh
mythwelcome-set-alarm.sh
+mythwelcome-config.py
pause_mythcommflag
limit-mythcommflag.sh
vdpau-detector
@@ -65,11 +66,12 @@ md5sums=('f56985b2d602e11dc1e10d3e7848b2a5'
'ac2a4a6b4100f4d7bfb9ecd9356c8c6e'
'd2b475821f902c5e081e7da43a35e6ac'
'95c092f67036a361ef7a57436f44332e'
+ 'a87e7394bfb3fcc5c2419a2f9ae9b9aa'
'3b776bbff68906ddc2f62b7e0dde3fe4'
'15f3143d2b1369da431e4268029aba40'
'3d0adf26280cde55a0c47188fff34826'
'93aaa2940e33ec9ebb305b839ac46a3e'
- '972e42e02a11575da91f5e051d4de1d2'
+ '27a8b3680f3c631a582064fd26ab8746'
'b527b01d119d3bc33b8fa69bdf1082bb'
'c537c44156d8404016cc4b405b092d45'
'4e66f302a77f1a857476e7f289d0c157'
@@ -77,90 +79,6 @@ md5sums=('f56985b2d602e11dc1e10d3e7848b2a5'
'c9dc0dd07369622879a000247ac55074'
'65629302a4d2c3adf88cdf0ebc10d493'
'ea5492d4dab8271db20cb84416c001dc'
- 'd7c7914225ec86bf3ea46104a364f977'
- '25c1baeb97a49656456ae33f7e7a9f06'
- '5713640cb516246cfd4c06b1393a7f13')
-md5sums=('f56985b2d602e11dc1e10d3e7848b2a5'
- '623b6e9ba6cc4a19771005e750f337a7'
- '9ae2cd7a0c42d57ad8b5f515d7d60196'
- '1274bad3fb7296f00acd2d44804bad14'
- 'b4f858834ea92418208ab496ca39ad32'
- '6b6e7d34a4bda6d608d150039adefd07'
- '3fe554dbbf7d09e1f9925032ba888bf5'
- '18263972b6326e140bbef0bb7dfa2da9'
- '410795ef9039e4c6c0484e706ecfd567'
- '0750d7c65109d12aa536f312a38410d1'
- 'ac2a4a6b4100f4d7bfb9ecd9356c8c6e'
- 'd2b475821f902c5e081e7da43a35e6ac'
- '95c092f67036a361ef7a57436f44332e'
- '3b776bbff68906ddc2f62b7e0dde3fe4'
- '15f3143d2b1369da431e4268029aba40'
- '3d0adf26280cde55a0c47188fff34826'
- '93aaa2940e33ec9ebb305b839ac46a3e'
- '972e42e02a11575da91f5e051d4de1d2'
- 'b527b01d119d3bc33b8fa69bdf1082bb'
- 'c537c44156d8404016cc4b405b092d45'
- '4e66f302a77f1a857476e7f289d0c157'
- 'be324dba44ae96676973a74421944853'
- 'c9dc0dd07369622879a000247ac55074'
- '65629302a4d2c3adf88cdf0ebc10d493'
- 'ea5492d4dab8271db20cb84416c001dc'
- 'd7c7914225ec86bf3ea46104a364f977'
- '25c1baeb97a49656456ae33f7e7a9f06'
- 'f77bb76ee2759195b67a2e0df8c47c44')
-md5sums=('f56985b2d602e11dc1e10d3e7848b2a5'
- '623b6e9ba6cc4a19771005e750f337a7'
- '9ae2cd7a0c42d57ad8b5f515d7d60196'
- '1274bad3fb7296f00acd2d44804bad14'
- 'b4f858834ea92418208ab496ca39ad32'
- '6b6e7d34a4bda6d608d150039adefd07'
- '3fe554dbbf7d09e1f9925032ba888bf5'
- '18263972b6326e140bbef0bb7dfa2da9'
- '410795ef9039e4c6c0484e706ecfd567'
- '0750d7c65109d12aa536f312a38410d1'
- 'ac2a4a6b4100f4d7bfb9ecd9356c8c6e'
- 'd2b475821f902c5e081e7da43a35e6ac'
- '95c092f67036a361ef7a57436f44332e'
- '3b776bbff68906ddc2f62b7e0dde3fe4'
- '15f3143d2b1369da431e4268029aba40'
- '3d0adf26280cde55a0c47188fff34826'
- '93aaa2940e33ec9ebb305b839ac46a3e'
- '972e42e02a11575da91f5e051d4de1d2'
- 'b527b01d119d3bc33b8fa69bdf1082bb'
- 'c537c44156d8404016cc4b405b092d45'
- '4e66f302a77f1a857476e7f289d0c157'
- 'be324dba44ae96676973a74421944853'
- 'c9dc0dd07369622879a000247ac55074'
- '65629302a4d2c3adf88cdf0ebc10d493'
- 'ea5492d4dab8271db20cb84416c001dc'
- 'd7c7914225ec86bf3ea46104a364f977'
- '25c1baeb97a49656456ae33f7e7a9f06'
- 'bd419fe54590925eb0bc991902dffecf')
-md5sums=('f56985b2d602e11dc1e10d3e7848b2a5'
- '623b6e9ba6cc4a19771005e750f337a7'
- '9ae2cd7a0c42d57ad8b5f515d7d60196'
- '1274bad3fb7296f00acd2d44804bad14'
- 'b4f858834ea92418208ab496ca39ad32'
- '6b6e7d34a4bda6d608d150039adefd07'
- '3fe554dbbf7d09e1f9925032ba888bf5'
- '18263972b6326e140bbef0bb7dfa2da9'
- '410795ef9039e4c6c0484e706ecfd567'
- '0750d7c65109d12aa536f312a38410d1'
- 'ac2a4a6b4100f4d7bfb9ecd9356c8c6e'
- 'd2b475821f902c5e081e7da43a35e6ac'
- '95c092f67036a361ef7a57436f44332e'
- '3b776bbff68906ddc2f62b7e0dde3fe4'
- '15f3143d2b1369da431e4268029aba40'
- '3d0adf26280cde55a0c47188fff34826'
- '93aaa2940e33ec9ebb305b839ac46a3e'
- '972e42e02a11575da91f5e051d4de1d2'
- 'b527b01d119d3bc33b8fa69bdf1082bb'
- 'c537c44156d8404016cc4b405b092d45'
- '4e66f302a77f1a857476e7f289d0c157'
- 'be324dba44ae96676973a74421944853'
- 'c9dc0dd07369622879a000247ac55074'
- '65629302a4d2c3adf88cdf0ebc10d493'
- 'ea5492d4dab8271db20cb84416c001dc'
- 'd7c7914225ec86bf3ea46104a364f977'
+ '87b0dc855181f98516acb18a7d551601'
'25c1baeb97a49656456ae33f7e7a9f06'
'2fb25aef03ffd1282414d8cca3df7056')
diff --git a/abs/core-testing/linhes-scripts/mythwelcome-config.py b/abs/core-testing/linhes-scripts/mythwelcome-config.py
new file mode 100755
index 0000000..c7bf10b
--- /dev/null
+++ b/abs/core-testing/linhes-scripts/mythwelcome-config.py
@@ -0,0 +1,27 @@
+#!/usr/bin/env python
+
+# This script will configure the myth db to allow MythWelcome to wake and shutdown the system.
+
+from socket import gethostname
+from MythTV import MythDB
+mythdb = MythDB()
+localhostname = gethostname()
+
+# mythwelcome --setup
+mythdb.settings[localhostname].MythShutdownNvramCmd = u'sudo sh -c \"/usr/LH/bin/mythwelcome-set-alarm.sh $time\"'
+mythdb.settings[localhostname].MythShutdownWakeupTimeFmt = u'time_t'
+mythdb.settings[localhostname].MythShutdownNvramRestartCmd = u''
+mythdb.settings[localhostname].MythShutdownReboot = u'sudo /sbin/reboot'
+mythdb.settings[localhostname].MythShutdownPowerOff = u'sudo /sbin/poweroff'
+mythdb.settings[localhostname].MythShutdownXTermCmd = u'xterm'
+mythdb.settings[localhostname].MythWelcomeStartFECmd = u'/usr/LH/bin/mythfrontend-start'
+
+
+# mythtv-setup Shutdown/Wakeup options
+if mythdb.settings[localhostname].idleTimeoutSecs == u'0':
+ mythdb.settings[localhostname].idleTimeoutSecs = u'40'
+
+mythdb.settings.NULL.WakeupTimeFormat = u'yyyy-MM-ddThh:mm:ss'
+mythdb.settings.NULL.SetWakeuptimeCommand = u'/usr/bin/mythshutdown --setwakeup $time'
+mythdb.settings.NULL.ServerHaltCommand = u'/usr/bin/mythshutdown --shutdown'
+mythdb.settings.NULL.preSDWUCheckCommand = u'/usr/bin/mythshutdown --check'
diff --git a/abs/core-testing/linhes-scripts/remove_php_mythvideo.sh b/abs/core-testing/linhes-scripts/remove_php_mythvideo.sh
index 5320756..d9d53a0 100644
--- a/abs/core-testing/linhes-scripts/remove_php_mythvideo.sh
+++ b/abs/core-testing/linhes-scripts/remove_php_mythvideo.sh
@@ -1,6 +1,13 @@
#!/bin/bash
+. /etc/systemconfig
+
+if [ $SystemType != Frontend_only ] && [ $SystemType != Slave_backend ] ; then
mysql mythconverg <<EOF
delete from videotypes where extension='php';
insert into videotypes(extension,f_ignore) values('php','1');
EOF
+
+else
+ exit 0
+fi
diff --git a/abs/core-testing/linhes-scripts/screenshooter.sh b/abs/core-testing/linhes-scripts/screenshooter.sh
index 94ea6fd..3bacac1 100755
--- a/abs/core-testing/linhes-scripts/screenshooter.sh
+++ b/abs/core-testing/linhes-scripts/screenshooter.sh
@@ -135,7 +135,7 @@ if [ "$EXTENSION_CHECK" == "1" ]; then
# if [ "$VERBOSE" == "1" ]; then
# echo "Importing $VIDEO_FILENAME in to database."
# fi
- # mysql -u $DBUSERNAME --password=$DBPASSWORD -h $BACKEND_HOSTNAME mythconverg -sNBe "insert into videometadata (intid, title, director, plot, rating, inetref, year, userrating, length, showlevel, filename, coverfile, childid, browse, playcommand, category) values (' ', '$VIDEO_FILENAME', 'Unknown', 'Unknown', 'NR', '00000000', 1895, 0.0, 0, 1, '$VIDEO_PATHNAME', 'No Cover', -1, 1, ' ', 0);"
+ # mysql -u $DBUSERNAME --password=$DBPASSWORD -h $BACKEND_HOSTNAME mythconverg -sNBe "insert into videometadata (intid, title, director, plot, rating, inetref, year, userrating, length, showlevel, filename, coverfile, childid, browse, playcommand, category) values (' ', '$VIDEO_FILENAME', 'Unknown', 'Unknown', 'NR', '00000000', 1895, 0.0, 0, 1, '$VIDEO_PATHNAME', '', -1, 1, ' ', 0);"
fi
fi
fi
@@ -145,7 +145,7 @@ if [ "$CLOBBER" -eq 0 ]; then
SQL_CMD="select coverfile from videometadata where filename=\"$VIDEO_PATHNAME\";"
CURRENT_COVERFILE=`mysql -u $DBUSERNAME --password=$DBPASSWORD -h $BACKEND_HOSTNAME mythconverg -B -e "$SQL_CMD" | tail -1`
- if [[ "$CURRENT_COVERFILE" != "" ]] && [[ "$CURRENT_COVERFILE" != "No Cover" ]]; then
+ if [[ "$CURRENT_COVERFILE" != "" ]] && [[ "$CURRENT_COVERFILE" != "" ]]; then
# there's already a cover file for this video
if [ "$VERBOSE" == "1" ]; then
echo "$VIDEO_FILENAME has cover file, skipping."
diff --git a/abs/core-testing/linhes-theme/PKGBUILD b/abs/core-testing/linhes-theme/PKGBUILD
index 353fefd..1d289cd 100644
--- a/abs/core-testing/linhes-theme/PKGBUILD
+++ b/abs/core-testing/linhes-theme/PKGBUILD
@@ -3,15 +3,17 @@
pkgname=linhes-theme
pkgver=1
-pkgrel=11
+pkgrel=12
pkgdesc="Default LinHES theme."
arch=('i686' 'x86_64')
license=('GPL2')
url="http://linhes.org/"
-source=(ftp://ftp.knoppmyth.net/R6/sources/linhes-theme.tar.bz2)
+source=(ftp://ftp.knoppmyth.net/R6/sources/linhes-theme-1.2.tar.bz2)
build() {
cd $startdir/src/
mkdir -p $startdir/pkg/usr/share/mythtv/themes
cp -a LinHES $startdir/pkg/usr/share/mythtv/themes
}
+
+md5sums=('805cd304b07a0020ff4990077b2f65d5')
diff --git a/abs/core-testing/linuxtv-dvb-apps/PKGBUILD b/abs/core-testing/linuxtv-dvb-apps/PKGBUILD
index 05b719b..697a786 100644
--- a/abs/core-testing/linuxtv-dvb-apps/PKGBUILD
+++ b/abs/core-testing/linuxtv-dvb-apps/PKGBUILD
@@ -4,7 +4,7 @@
pkgname=linuxtv-dvb-apps
pkgver=1.1.1
-pkgrel=1
+pkgrel=2
pkgdesc="Viewer programs for DVB cards"
arch=('i686' 'x86_64')
url="http://www.linuxtv.org/"
diff --git a/abs/core-testing/local-website/PKGBUILD b/abs/core-testing/local-website/PKGBUILD
index 5a84b2b..43a0964 100644
--- a/abs/core-testing/local-website/PKGBUILD
+++ b/abs/core-testing/local-website/PKGBUILD
@@ -1,6 +1,6 @@
pkgname=local-website
pkgver=2
-pkgrel=16
+pkgrel=25
pkgdesc="Contents of http://localhost"
arch=(i686 x86_64)
license=('GPL')
diff --git a/abs/core-testing/local-website/htdocs/404.html b/abs/core-testing/local-website/htdocs/404.html
new file mode 100755
index 0000000..41219b0
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/404.html
@@ -0,0 +1,25 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html>
+<head>
+ <meta content="text/html; charset=ISO-8859-1" http-equiv="content-type">
+ <meta content="Cecil Watson" name="author">
+ <title>LinHES 404</title>
+ <!-- Generated by: /usr/local/bin/rrd_Configure.sh -->
+ <link href="/KnoppMyth.css" rel="stylesheet" type="text/css" />
+ <p align="center"><a href="http://www.mysettopbox.tv">
+ <img src="/header.png" alt="Tux with a Remote" align="middle" border="0"></a>
+ </p>
+ <table align="center" border="0" cellpadding="5">
+ <tbody>
+ <tr>
+ <td style="vertical-align: top;">
+ <p class="headerimage" align="center"><b>The Linux Home Entertainment System Release 6</b></p>
+ <p align=center>
+<font size="+2">OOPS</font><br>
+<font size="+1"> The page you requested is missing!<br>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+</body>
+</html>
diff --git a/abs/core-testing/local-website/htdocs/index.html b/abs/core-testing/local-website/htdocs/index.html
index 9c46aac..5e6ec81 100644..100755
--- a/abs/core-testing/local-website/htdocs/index.html
+++ b/abs/core-testing/local-website/htdocs/index.html
@@ -1,125 +1,118 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html><head>
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
+<html>
+<head>
+ <base href="/linhes/">
+ <title>Welcome to LinHES!</title>
+ <meta http-equiv="content-type" content="text/html; charset=utf-8">
+ <meta name="robots" content="noindex, nofollow">
+ <script type="text/javascript" src="/linhes/js/prototype.js"></script>
+ <script type="text/javascript" src="/linhes/js/prototip/prototip.js"></script>
+ <link rel="stylesheet" type="text/css" href="/linhes/js/prototip/prototip.css">
-
- <meta content="text/html; charset=ISO-8859-1" http-equiv="content-type">
+ <script type="text/javascript" src="/linhes/js/utils.js"></script>
+ <script type="text/javascript" src="/linhes/js/AC_OETags.js"></script>
+ <script type="text/javascript" src="/linhes/js/table_sort.js"></script>
-
- <meta content="Cecil Watson" name="author">
+ <link rel="stylesheet" type="text/css" href="/linhes/default/style.css">
+ <link rel="stylesheet" type="text/css" href="/linhes/default/header.css">
+ <link rel="stylesheet" type="text/css" href="/linhes/default/menus.css">
+ <link rel="stylesheet" type="text/css" href="/linhes/default/programming.css">
-
-
-
-
- <title>LinHES R6</title><link href="KnoppMyth.css" rel="stylesheet" type="text/css"></head>
-<body>
-<p align="center"><a href="http://www.mysettopbox.tv/">
- <img src="header.png" alt="Tux with a Remote" align="middle" border="0"></a>
- </p>
-
-
-
-<table align="center" border="0" cellpadding="5">
-
- <tbody>
-
- <tr>
-
- <td style="vertical-align: top;">
-
- <p class="headerimage" align="center"><b>The Linux Home Entertainment System Release 6</b></p>
-
-
- <p><a href="mythweb/mythweb.php"><b>MythWeb</b></a>: <br>
-
- &nbsp; &nbsp; The MythWeb allows you to use a web page to control
- aspects of your MythTV system. MythWeb is a separate application,
- but it is dependent upon MythTV being installed and operational."
- </p>
-
-
- <p><a href="remote/index.html"><b>MythTV Web Virtual Remote</b></a>: <br>
-
- &nbsp; &nbsp; A web based virtual remote control for MythTV.
- &nbsp;In order for this to work, you must enable
- "Network Remote Control interface". &nbsp; See:
- <b>Utilities/Setup -&gt; Setup -&gt; General -&gt; Fourth Page</b>.
- </p>
-
-
- <p><a href="mythtv-doc/mythtv-HOWTO.html"><b>MythTV Documentation</b></a>: <br>
-
- &nbsp; &nbsp; The MythTV Installation / User's Guide.
- </p>
-
-
- <p><a href="mythtv-doc/keys.txt"><b>MythTV Keybindings</b></a>: <br>
-
- &nbsp; &nbsp; The keybindings for the normal MythTV interface.
- </p>
-
-
- <p><a href="linhes.html"><b>LinHES</b></a>: <br>
+ <link rel="stylesheet" type="text/css" href="/linhes/default/welcome.css">
+</head>
- &nbsp; &nbsp; Describes how "The Project Leader" setup multiple systems
- to form a <b>Lin</b>ux <b>H</b>ome <b>E</b>ntertainment <b>S</b>ystem.
- </p>
-
-
- <p><a href="http://fah-web.stanford.edu/cgi-bin/main.py?qtype=teampage&amp;teamnum=50975"><b>Folding@home</b></a>: <br>
-
- &nbsp; &nbsp; KnoppMyth Team status for the folding@home effort. Install via the Service Menu.
- </p>
-
- <p><a href="foldingathome/"><b>My Folding Status</b></a>: <br>
-
- &nbsp; &nbsp; Status of the folding@home work for the local user.
- </p>
-
-
- <p><a href="ipodfeed/feed.php"><b>iPod Feeds</b></a> <br>
-
- &nbsp; &nbsp; Transcodes ready for the ipod (if any). &nbsp;Additionally, you can delete unwanted files using this <a href="/ipodfeed/m2iweb.php">link</a>. &nbsp;Note: &nbsp;If you have no recordings, you will see a warning issued from PHP.</p>
-<a href="archive/feed.php"><b>XviD Feed dir</b></a> <br>
-&nbsp; &nbsp; Any programs you have transcoded to XviD.
-&nbsp;Additionally, you can delete unwanted files using this <a href="/archive/archive.php">link</a>. &nbsp;Note: &nbsp;If you have no recordings, you will see a warning issued from PHP.
- <p><a style="font-weight: bold;" href="fuppes.php"><span style="text-decoration: underline;">FUPPES</span></a><br>
-&nbsp;&nbsp;&nbsp; FUPPES - Free UPnP Entertainment Service. &nbsp;A
-UPnP to be used inplace of the UPnP server that comes with MythTV.
-&nbsp;If the UPnP that comes with MythTV doesn't work for you, you can
-try FUPPES. Install via the Service Menu.</p><p><a style="font-weight: bold;" href="mediaserv.php"><span style="text-decoration: underline;">Mediaserv</span></a><br>
-&nbsp;&nbsp;&nbsp; Mediaserv - A on-demand transcoding server for
-videos. &nbsp;Mediaserv is designed to transcode video in a format
-playable on the Nokia Internet Tablets. &nbsp;However it works well at
-transcoding and streaming&nbsp;to any device. &nbsp;As longs as the
-device will playback AVIs (think streaming to any browser!). &nbsp;By
-default, we have it set to link to
-TV recordings (pretty) and your video directory. &nbsp;Additionally if
-you want it to stream contents from a network share, it will! &nbsp;ln
--s /path/to/share /myth/mediaserv/media/ </p><p><a href="rrd/index.html"><b>RRDTool</b></a>: <br>
-
- &nbsp; &nbsp; Hardware status graphs. Install via the Service Menu.
- </p>
-
-
- <p><a href="javascript:void(0)" onclick="window.open('mythweb/data/mp3player.html','linkname','height=100, width=260,scrollbars=no')"><b>KnoppMyth Radio</b></a>: <br>
-
- &nbsp; &nbsp; Your music must be encoded as MP3 in MythMusic for this to work.</p>
-
- <p><a style="font-weight: bold;" href="zm/"><span style="text-decoration: underline;">ZoneMinder</span></a><br>
- &nbsp;&nbsp;&nbsp; Video camera security software with motion detection. Install via the Service Menu.
- </p>
- </td>
-
- </tr>
-
- <tr>
- <td style="vertical-align: top;"></td>
- </tr>
- </tbody>
-
+<body>
+<div id="page_header" style="position:relative; text-align:center;">
+ <div id="logo_box">
+ <a id="LinHES_logo" href="http://linhes.org/">
+ <img src="/header.png" alt="Tux with a Remote" class="body">
+ </a>
+ </div>
+</div>
+
+<table width="100%" border="0" cellspacing="2" cellpadding="0">
+<tr>
+ <td colspan="2" class="menu menu_border_t menu_border_b">
+ <table class="body" width="100%" border="0" cellspacing="2" cellpadding="2">
+ <td align="center">
+ <a href="http://linhes.org" <b>The Linux Home Entertainment System Release 6</b></a>
+ </td>
+ </table>
+ </td>
+</tr>
</table>
-</body></html>
+
+<script type="text/javascript">
+<!--
+
+ var visible_module = 'media';
+ function show_module_info(module) {
+ if (visible_module == module)
+ return;
+ // Change the outline on the list item
+ $('module_'+ visible_module).removeClassName('selected');
+ $('module_'+ module).addClassName('selected');
+ // Show and hide the appropriate info boxes
+ $('info_' + visible_module).hide();
+ $('info_' + visible_module).addClassName('hidden');
+ $('info_' + module).show();
+ $('info_' + module).removeClassName('hidden');
+ // Keep track of what's visible now
+ visible_module = module;
+ }
+
+// -->
+</script>
+
+<div id="modules" class="clearfix">
+
+ <div id="module_names">
+ <ul>
+ <li id="module_media" class="selected" onmouseover="show_module_info('media')">Media</li>
+ <li id="module_status" onmouseover="show_module_info('status')">Status</li>
+ <li id="module_help" onmouseover="show_module_info('help')">Help</li>
+ </ul>
+ </div>
+
+ <div id="module_info">
+ <div id="info_media">
+ <ul>
+ <li><a href="/mythweb/">MythWeb</a> - MythWeb provides a frontend for scheduling and managing recordings on your MythBox from a web browser.<br></li>
+ <li><a href="/remote/index.html">MythTV Web Virtual Remote</a> - A web based virtual remote control for MythTV. For this to work, you must enable "Network Remote Control interface" in Service Menu -> MythTV Configuration -> Setup -> General -> Remote Control.<br></li>
+ <li><a href="/ipodfeed/feed.php">iPod Feeds</a> - Transcodes ready for the iPod. If you have no recordings, you will see a warning issued from PHP.<br></li>
+ <li><a href="/ipodfeed/m2iweb.php">Delete iPod Transcodes</a><br></li>
+ <li><a href="/archive/feed.php">XviD Feeds</a> - Programs you have transcoded to XviD. If you have no recordings, you will see a warning issued from PHP.<br></li>
+ <li><a href="/archive/archive.php">Delete XviD Transcodes</a><br></li>
+ <li><a href="/fuppes.php">FUPPES</a> - Free UPnP Entertainment Service. A UPnP to be used inplace of the UPnP server that comes with MythTV. Install via the Service Menu.<br></li>
+ <li><a href="/mediaserv.php">Mediaserv</a> - A on-demand transcoding server for videos. Mediaserv is designed to transcode video in a format playable on the Nokia Internet Tablets. However it works well at transcoding and streaming to any device that will playback AVIs (think streaming to any browser!). By default, we have it set to link to TV recordings (pretty) and your video directory. Additionally if you want it to stream contents from a network share, it will! ln -s /path/to/share /myth/mediaserv/media/<br></li>
+ <li><a href="/mythweb/data/mp3player.html">Radio</a> - Music in MythMusic must be encoded as MP3s.<br></li>
+ </ul>
+ </div>
+ <div id="info_status" class="hidden">
+ <ul>
+ <li><a href="/rrd/index.html">RRDTool</a> - Hardware status graphs.</li>
+ <li><a href="/monitorix/">Monitorix</a> - A system monitoring perl script that uses rrd databases to log system data.<br></li>
+ <li><a href="http://fah-web.stanford.edu/cgi-bin/main.py?qtype=teampage&amp;teamnum=50975">KnoppMyth Folding@home Team Status</a></li>
+ <li><a href="/foldingathome/">My Folding@home Status</a></li>
+ </ul>
+ </div>
+ <div id="info_help" class="hidden">
+ <ul>
+ <li><a href="http://www.mythtv.org/docs/">MythTV Documentation</a></li>
+ <li><a href="/mythtv-doc/keys.txt">MythTV Default Keybindings</a></li>
+ <li><a href="http://www.mythtv.org/support">MythTV Support</a></li>
+ <li><a href="http://www.schedulesdirect.org/">Schedules Direct</a> - Provides U.S./Canadian TV listing data.<br></li>
+ <li><a href="/linhes.html">LinHES</a> - Describes how "The Project Leader" setup multiple systems to form a <b>Lin</b>ux <b>H</b>ome <b>E</b>ntertainment <b>S</b>ystem.<br></li>
+ <li><a href="http://linhes.org/phpBB2/">LinHES Forum</a></li>
+ <li><a href="http://www.google.com/advanced_search?q=+site:mysettopbox.tv/phpBB2&hl=en&lr=&as_qdr=all">Search LinHES Forum</a></li>
+ <li><a href="http://www.knoppmythwiki.org/">KnoppMyth Wiki</a></li>
+ <li><a href="http://linhes.org/bugs/projects/linhes/wiki">LinHES Wiki</a></li>
+ <li><a href="http://linhes.org/bugs">LinHES Bug Tracker</a></li>
+ </ul>
+ </div>
+
+</body>
+</html>
diff --git a/abs/core-testing/local-website/htdocs/layout.css b/abs/core-testing/local-website/htdocs/layout.css
deleted file mode 100644
index a91a651..0000000
--- a/abs/core-testing/local-website/htdocs/layout.css
+++ /dev/null
@@ -1,29 +0,0 @@
-/* Layout Stylesheet - Colors taken from MythWeb - arranged by md10md*/
-
-.style2 {color: #FFFFFF}
-.style3 {color: #FFFFFF}
-.header {
- font-family: Verdana, Arial, Helvetica, sans-serif;
- font-size: 10px;
- background-color: #CCCCCC;
- border: solid thin #000000;
-}
-a, a:link { color: #E0E0FF; text-decoration: none; font-size: 14px; }
-a:active { color: #990033; text-decoration: none; font-size: 14px; }
-a:visited { color: #E0E0FF; text-decoration: none; font-size: 14px; }
-a:hover { color: #F0F000; text-decoration: underline; font-size: 14px; }
-body,td,th {
- font-family: Verdana, Arial, Helvetica, sans-serif;
- font-size: 10px;
- background-color: #002650;
-}
-td,th {
- border: thin solid #000000;
- background-color: #265990;
-}
-.headerimage {
- background-color: #335555;
- border: solid thin #000000;
- font-size: 18px;
- color: #FFFFFF;
-}
diff --git a/abs/core-testing/local-website/htdocs/linhes/default/header.css b/abs/core-testing/local-website/htdocs/linhes/default/header.css
new file mode 100644
index 0000000..d4b2802
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/default/header.css
@@ -0,0 +1,123 @@
+#page_header {
+ margin: 5px;
+}
+
+#logo_box {
+}
+#mythtv_logo {
+ margin: 0px 5px;
+ padding: 5px;
+ height: 48px;
+ width: 180px;
+ float: left;
+ text-align: center;
+}
+
+#sections {
+ white-space: nowrap;
+}
+#sections a {
+ float: left;
+ margin: 0px 5px;
+ padding: 5px;
+ background-color: #347;
+ border-top: 1px solid #8ad;
+ border-right: 1px solid #003;
+ border-bottom: 1px solid #000;
+ border-left: 1px solid #79c;
+ -moz-border-radius: 8px;
+ text-align: center;
+ height: 48px;
+ width: 48px;
+}
+#sections a:hover {
+ background-color: #458;
+}
+#sections a img {
+ border: none;
+ display: inline !important;
+}
+
+#sections a.current_section {
+ background-color: #164;
+ border-top: 1px solid #7b9;
+ border-right: 1px solid #030;
+ border-bottom: 1px solid #000;
+ border-left: 1px solid #6a8;
+}
+#sections a.current_section:hover {
+ background-color: #275;
+}
+
+#tv_link {
+}
+#music_link {
+}
+#video_link {
+}
+#weather_link {
+}
+#settings_link {
+}
+
+#extra_header {
+ margin-left: 550px;
+ padding: 0px 5px;
+ height: 58px;
+}
+
+/*
+ * IE sucks: true-height is supposed to be height+padding+margin+border, but IE
+ * doesn't add in padding, so we have to create a wrapper container and use
+ * margin instead of padding to make the "padding" that we need.
+ */
+#help_wrapper {
+ height: 21px;
+ margin-bottom: 3px;
+ background-color: #247;
+ border-top: 1px solid #013;
+ border-right: 1px solid #79c;
+ border-bottom: 1px solid #68b;
+ border-left: 1px solid #002;
+ -moz-border-radius: 6px;
+ min-width: 225px;
+}
+#help_box {
+ margin: 4px 5px 2px 5px;
+ height: 15px;
+ overflow: hidden;
+ white-space: nowrap;
+}
+#search {
+ margin-top: 2px;
+ padding: 3px 5px;
+ height: 26px;
+ background-color: #247;
+ border-top: 1px solid #013;
+ border-right: 1px solid #79c;
+ border-bottom: 1px solid #68b;
+ border-left: 1px solid #002;
+ -moz-border-radius: 8px;
+ min-width: 225px;
+ white-space: nowrap;
+}
+#simple_search {
+ padding-top: 1px;
+}
+
+
+#search_text {
+ position: relative;
+ top: -1px;
+ width: 150px;
+ margin-right: 3px;
+ padding: 0px 3px;
+ font-size: 9pt;
+}
+#search_submit {
+ position: relative;
+ top: 1px;
+ width: 64px;
+ font-size: 9pt;
+}
+
diff --git a/abs/core-testing/local-website/htdocs/linhes/default/menus.css b/abs/core-testing/local-website/htdocs/linhes/default/menus.css
new file mode 100644
index 0000000..d4e793a
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/default/menus.css
@@ -0,0 +1,221 @@
+/* popup and menu classes */
+.popup {
+ font-size: 9pt;
+}
+
+.popup table {
+ font-size: 9pt;
+}
+
+.popup dl {
+ min-width: 40em;
+ color: #dedede;
+ background-color: #265990;
+ border: 2px ridge #127;
+ padding: 5px;
+}
+
+/*
+
+ This other stuff isn't used quite yet, but is here as a placeholder so I don't lose the necessary styles
+
+div.popup_menu {
+ position: absolute;
+ visibility: hidden;
+ top: 0px;
+ left: 0px;
+ color: #000036;
+ background-color: #40A0B0;
+ border-right: 2px groove #289;
+ border-bottom: 2px groove #289;
+ border-left: 1px solid #289;
+ border-top: 1px solid #289;
+ padding: 10px;
+ font-size: 13px;
+}
+div.popup_menu A, div.popup_menu A:link, div.popup_menu A:visited {
+ color: #000036;
+ text-decoration: none;
+}
+div.popup_menu A:hover, div.popup_menu_hover {
+ color: #000036;
+ text-decoration: underline;
+}
+div.popup_menu_item, div.popup_menu_item A, div.popup_menu_item A:link, div.popup_menu_item A:visited {
+ font-size: 13px;
+ color: #003040;
+ padding: 5px;
+ display: block;
+ text-decoration: none;
+}
+div.popup_menu_item A:hover, div.popup_menu_item A:active {
+ background-color: #70D0F0;
+ text-decoration: underline;
+}
+div.popup_menu_sep {
+ border-bottom: 1px ridge #208090;
+}
+
+ul.tree_item_menu {
+ width: 20px;
+ height: 20px;
+}
+
+ul.popup_menu {
+ display: block;
+ list-style-type: none;
+ margin: 0px;
+ padding: 0px;
+ font-size: 10pt;
+}
+ul.popup_menu li {
+ font-weight: bold;
+ color: #cce;
+ padding: 3px 0px 0px 4px;
+ margin: -3px 0px 0px 0px;
+ cursor: default;
+ white-space: nowrap;
+ list-style-type: none;
+ height: 20px;
+}
+ul.popup_menu.vertical li {
+ width: 20px;
+ list-style-type: none;
+}
+
+ul.popup_menu li.active {
+ background-color: #607090;
+}
+ul.popup_menu li a {
+ text-decoration: none;
+ color: #cde !important;
+}
+ul.popup_menu ul {
+ position: absolute;
+ visibility: hidden;
+ text-align: left;
+ background-color: #304060;
+ border: 1px solid #020;
+ width: 11em;
+ margin: 2px 0px 0px 0px;
+ padding: 0px;
+}
+ul.popup_menu ul li.sep {
+ border-top: 1px solid #6090d0;
+}
+ul.popup_menu ul li, ul.popup_menu.vertical ul li, ul.popup_menu.horizontal ul li {
+ margin: 0px;
+ padding: 3px 0px 0px 0px;
+ border-bottom: 1px solid #00191a;
+ border-right: none;
+ white-space: normal;
+ width: 11em;
+ height: 18px;
+}
+ul.popup_menu ul li a {
+ margin-top: -3px !important;
+ display: block;
+ width: 9em;
+ color: #cde;
+ text-decoration: none;
+ padding: 3px 1em;
+}
+ul.popup_menu ul li a:hover {
+ color: #def;
+ background-color: #205980;
+}
+
+ul.popup_menu ul li.active {
+ background-color: #105053;
+ color: white;
+}
+
+#menu {
+ display: block;
+ list-style-type: none;
+ margin: 0px 220px 0px 0px;
+ padding: 0em 0em;
+ font-size: 10pt;
+ background-color: #103949;
+ height: 20px;
+ border-bottom: 1px solid black;
+}
+#menu li {
+ font-weight: bold;
+ color: #cce;
+ padding: 0em 1em;
+ margin: 0em;
+ cursor: default;
+ white-space: nowrap;
+ list-style-type: none;
+ height: 18px;
+ padding-top: 3px;
+}
+#menu li span.subtext {
+ font-weight: normal;
+}
+#menu.horizontal li {
+ float: left;
+ border-right: 1px solid #002;
+}
+
+#menu.vertical {
+ width: 8em;
+ border-right: 1px solid #600;
+ border-top: 1px solid #600;
+}
+#menu.vertical li {
+ width: 7em;
+ border-bottom: 1px solid #600;
+ list-style-type: none;
+}
+
+#menu li.active {
+ background-color: #205060;
+}
+#menu li a {
+ text-decoration: none;
+ color: #cce;
+}
+#menu ul {
+ position: absolute;
+ visibility: hidden;
+ text-align: left;
+ background-color: #103A39;
+ border: 1px solid #020;
+ width: 13em;
+ margin: 0px;
+ padding: 0px;
+}
+#menu ul li.sep {
+ border-top: 1px solid #609A99;
+}
+#menu ul li, #menu.vertical ul li, #menu.horizontal ul li {
+ border-right: none;
+ padding: 0;
+ white-space: normal;
+ margin: 0px;
+ border-bottom: 1px solid #001A19;
+ padding-top: 3px;
+ height: 18px;
+ width: 13em;
+}
+#menu ul li a {
+ margin-top: -3px !important;
+ display: block;
+ width: 11em;
+ color: #cce;
+ text-decoration: none;
+ padding: 3px 1em;
+}
+#menu ul li a:hover {
+ color: #DDF;
+ background-color: #206A59;
+}
+
+#menu ul li.active {
+ background-color: #105350;
+ color: white;
+}
+
+*/
diff --git a/abs/core-testing/local-website/htdocs/linhes/default/programming.css b/abs/core-testing/local-website/htdocs/linhes/default/programming.css
new file mode 100644
index 0000000..60042a7
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/default/programming.css
@@ -0,0 +1,150 @@
+/*
+ *
+ * The following subclasses are used for list displays that deal with tv
+ * programming.
+ *
+/*/
+
+/* some classes for various list displays */
+ .list { background-color: #191c26 }
+ .list_separator {
+ background-color: #203670;
+ border-top: 4px;
+ }
+
+/* The category legend, and its associated popup */
+ #command_choices a {
+ white-space: nowrap;
+ }
+
+ #category_legend_popup {
+ position: absolute;
+ visibility: hidden;
+ top: 0px;
+ left: 0px;
+ padding: 2px;
+ white-space: nowrap;
+ }
+ #category_legend_popup table {
+ font-size: 9pt;
+ }
+
+/* A class for the left-cleared <dl> lists used for program details popups */
+ dl.details_list {
+ font-size: 9pt;
+ margin: .125em;
+ max-width: 41em;
+ }
+ dl.details_list dt {
+ clear: left;
+ float: left;
+ width: 9em;
+ padding-top: 3px;
+ text-align: right;
+ color: #ffe;
+ white-space: nowrap;
+ }
+ dl.details_list dd {
+ padding-top: 3px;
+ margin-left: 9.5em;
+ }
+
+/* Control the look of the text-based HDTV stamp throughout MythWeb */
+ .hdtv_icon {
+ font-size: 9pt;
+ float: right;
+ color: yellow;
+ display: inline;
+ font-weight: bold;
+ }
+
+/* a class for the the cells containing recorded programs in recorded_programs.php */
+.scheduled { background-color: #506090; }
+.conflict { background-color: #806050; }
+.duplicate { background-color: #304050; }
+.deactivated { background-color: #508060; }
+
+.will_record { border: 1px solid #00F000 !important; }
+.record_weekly { border: 1px solid #00F000 !important; }
+.record_timeslot { border: 1px solid #00F000 !important; }
+.record_once { border: 1px solid #00F000 !important; }
+.record_channel { border: 1px solid #00F000 !important; }
+.record_always { border: 1px solid #00F000 !important; }
+.record_conflicting { border: 1px solid #FF0000 !important; }
+.record_duplicate { border: 2px dashed #90B0A0 !important; }
+.record_old_duplicate { border: 1px dashed #90B0A0 !important; }
+.record_suppressed { border: 2px dotted #60B0B0 !important; }
+.record_override_suppress { border: 2px dotted #D03060 !important; }
+.record_override_record { border: 2px solid #00FF90 !important; }
+
+
+/* There should be exactly one class in the next section corresponding to
+ each possible value of RecStatus_Types as defined in
+ includes/programs.php */
+.rec_class {
+ background: transparent;
+ text-align: center;
+}
+.rec_class.WillRecord { font-weight: bold; }
+.rec_class.Recording { font-weight: bold; }
+.Recording { color: #00FF00; border-width: 2px }
+.WillRecord { color: #00FF00; }
+.PreviousRecording { color: #90B0A0; }
+.CurrentRecording { color: #90D0A0; }
+.Repeat { color: #90B0A0; }
+.EarlierShowing { color: #90FFA0; }
+.LaterShowing { color: #90FFA0; }
+.TooManyRecordings { color: #60B0B0; }
+.Cancelled { color: #60B0B0; }
+.Conflicting { color: #FF0000; }
+.LowDiskSpace { color: #60B0B0; }
+.TunerBusy { color: #60B0B0; }
+.ManualOverride { color: #D03060; }
+.Overlap { color: #FF0000; }
+
+.cat_Action { background-color: #906020; }
+.cat_Adult { background-color: #702020; }
+.cat_Animals { background-color: #609060; }
+.cat_Art_Music { background-color: #801060; }
+.cat_Business { background-color: #703010; }
+.cat_Children { background-color: #B00010; }
+.cat_Comedy { background-color: #006080; }
+.cat_Crime_Mystery { background-color: #105050; }
+.cat_Documentary { background-color: #504020; }
+.cat_Drama { background-color: #400060; }
+.cat_Educational { background-color: #606060; }
+.cat_Food { background-color: #208040; }
+.cat_Game { background-color: #701010; }
+.cat_Health_Medical { background-color: #806060; }
+.cat_History { background-color: #807020; }
+.cat_HowTo { background-color: #A0A000; }
+.cat_Horror { background-color: #101040; }
+.cat_Misc { background-color: #403060; }
+.cat_News { background-color: #606040; }
+.cat_Reality { background-color: #304040; }
+.cat_Romance { background-color: #A02050; }
+.cat_Science_Nature { background-color: #008050; }
+.cat_SciFi_Fantasy { background-color: #606090; }
+.cat_Shopping { background-color: #103010; }
+.cat_Soaps { background-color: #508080; }
+.cat_Spiritual { background-color: #804080; }
+.cat_Sports { background-color: #005030; }
+.cat_Talk { background-color: #203040; }
+.cat_Travel { background-color: #2060B0; }
+.cat_War { background-color: #B06050; }
+.cat_Western { background-color: #806040; }
+.cat_Unknown { background-color: #303030; }
+
+.cat_movie { background-color: #809090 !important; }
+.cat_series { }
+.cat_tvshow { }
+
+/* deprecated show categories that need to be integreted into the above list via regex, or have new categories created for them */
+.tv_Cine { background-color: blue; }
+.tv_Classic { background-color: gray; }
+.tv_Collectibles { background-color: #708090; }
+.tv_Magazine { background-color: #48D1CC; }
+.tv_Movies { background-color: blue; }
+.tv_Serie { background-color: #9932CC; }
+.tv_SHOW { background-color: #A0522D; }
+.tv_Tiempo { background-color: #33ff99; }
diff --git a/abs/core-testing/local-website/htdocs/style.css b/abs/core-testing/local-website/htdocs/linhes/default/style.css
index 535ffec..2fbb26e 100644
--- a/abs/core-testing/local-website/htdocs/style.css
+++ b/abs/core-testing/local-website/htdocs/linhes/default/style.css
@@ -24,7 +24,7 @@
* We should try to keep links and labels looking consistent across the app.
/*/
- a, a:link { color: #E0E0FF; text-decoration: none; }
+ a, a:link, .link { color: #E0E0FF; text-decoration: none; cursor: pointer;}
a:active { color: #990033; text-decoration: none; }
a:visited { color: #E0E0FF; text-decoration: none; }
a:hover { color: #F0F000; text-decoration: underline; }
@@ -135,7 +135,7 @@
}
textarea {
- font-family: terminal, courier, courier-new;
+ font-family: courier, courier-new;
color: #002000;
background-color: #C0D0C0;
font-size: 9pt;
@@ -225,3 +225,13 @@
.nowrap {
white-space: nowrap;
}
+
+#feed_buttons {
+ padding-top: 1em;
+ padding-bottom: 1em;
+ padding-left: 1.35em;
+}
+
+#feed_buttons a {
+ padding-right: 1em;
+}
diff --git a/abs/core-testing/local-website/htdocs/linhes/default/welcome.css b/abs/core-testing/local-website/htdocs/linhes/default/welcome.css
new file mode 100644
index 0000000..6e47ed9
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/default/welcome.css
@@ -0,0 +1,62 @@
+#modules {
+ width: 600px;
+ margin: 100px auto;
+}
+
+#module_names {
+ margin: 0px;
+ padding: 0px;
+ float: left;
+ width: 7em;
+ font-size: 2em;
+ min-height: 15em;
+}
+
+#module_names ul {
+ margin: 0px;
+ padding: 0px;
+ list-style-type: none;
+ text-align: right;
+}
+
+#module_names li {
+ position: relative;
+ z-index: 2;
+ margin: 0px -6px 0px 0px;
+ padding: 0px .5em .15em 0px;
+ border: 2px solid transparent;
+ white-space: nowrap;
+}
+#module_names li.selected {
+ background-color: #475;
+ border-top: 2px solid #48f;
+ border-right: 2px solid #688;
+ border-bottom: 2px solid #48f;
+ border-left: 2px solid #48f;
+ -moz-border-radius: 8px;
+}
+#module_names li.selected a {
+ display: block;
+}
+
+#module_info {
+ background-color: #355;
+ margin-left: 14em;
+ border: 2px solid #48f;
+ min-width: 314px;
+ height: 30em;
+ padding: .5em 1em;
+ -moz-border-radius: 8px;
+}
+
+.module_icon {
+ display: block;
+ margin: auto;
+}
+
+#mythtv_link {
+ float: left;
+ width: 14em;
+ text-align: center;
+ margin-top: -1.5em;
+}
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/AC_OETags.js b/abs/core-testing/local-website/htdocs/linhes/js/AC_OETags.js
new file mode 100644
index 0000000..f72d7e2
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/AC_OETags.js
@@ -0,0 +1,269 @@
+// Flash Player Version Detection - Rev 1.5
+// Detect Client Browser type
+// Copyright(c) 2005-2006 Adobe Macromedia Software, LLC. All rights reserved.
+var isIE = (navigator.appVersion.indexOf("MSIE") != -1) ? true : false;
+var isWin = (navigator.appVersion.toLowerCase().indexOf("win") != -1) ? true : false;
+var isOpera = (navigator.userAgent.indexOf("Opera") != -1) ? true : false;
+
+function ControlVersion()
+{
+ var version;
+ var axo;
+ var e;
+
+ // NOTE : new ActiveXObject(strFoo) throws an exception if strFoo isn't in the registry
+
+ try {
+ // version will be set for 7.X or greater players
+ axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");
+ version = axo.GetVariable("$version");
+ } catch (e) {
+ }
+
+ if (!version)
+ {
+ try {
+ // version will be set for 6.X players only
+ axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");
+
+ // installed player is some revision of 6.0
+ // GetVariable("$version") crashes for versions 6.0.22 through 6.0.29,
+ // so we have to be careful.
+
+ // default to the first public version
+ version = "WIN 6,0,21,0";
+
+ // throws if AllowScripAccess does not exist (introduced in 6.0r47)
+ axo.AllowScriptAccess = "always";
+
+ // safe to call for 6.0r47 or greater
+ version = axo.GetVariable("$version");
+
+ } catch (e) {
+ }
+ }
+
+ if (!version)
+ {
+ try {
+ // version will be set for 4.X or 5.X player
+ axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.3");
+ version = axo.GetVariable("$version");
+ } catch (e) {
+ }
+ }
+
+ if (!version)
+ {
+ try {
+ // version will be set for 3.X player
+ axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.3");
+ version = "WIN 3,0,18,0";
+ } catch (e) {
+ }
+ }
+
+ if (!version)
+ {
+ try {
+ // version will be set for 2.X player
+ axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash");
+ version = "WIN 2,0,0,11";
+ } catch (e) {
+ version = -1;
+ }
+ }
+
+ return version;
+}
+
+// JavaScript helper required to detect Flash Player PlugIn version information
+function GetSwfVer(){
+ // NS/Opera version >= 3 check for Flash plugin in plugin array
+ var flashVer = -1;
+
+ if (navigator.plugins != null && navigator.plugins.length > 0) {
+ if (navigator.plugins["Shockwave Flash 2.0"] || navigator.plugins["Shockwave Flash"]) {
+ var swVer2 = navigator.plugins["Shockwave Flash 2.0"] ? " 2.0" : "";
+ var flashDescription = navigator.plugins["Shockwave Flash" + swVer2].description;
+ var descArray = flashDescription.split(" ");
+ var tempArrayMajor = descArray[2].split(".");
+ var versionMajor = tempArrayMajor[0];
+ var versionMinor = tempArrayMajor[1];
+ if ( descArray[3] != "" ) {
+ tempArrayMinor = descArray[3].split("r");
+ } else {
+ tempArrayMinor = descArray[4].split("r");
+ }
+ var versionRevision = tempArrayMinor[1] > 0 ? tempArrayMinor[1] : 0;
+ var flashVer = versionMajor + "." + versionMinor + "." + versionRevision;
+ }
+ }
+ // MSN/WebTV 2.6 supports Flash 4
+ else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.6") != -1) flashVer = 4;
+ // WebTV 2.5 supports Flash 3
+ else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.5") != -1) flashVer = 3;
+ // older WebTV supports Flash 2
+ else if (navigator.userAgent.toLowerCase().indexOf("webtv") != -1) flashVer = 2;
+ else if ( isIE && isWin && !isOpera ) {
+ flashVer = ControlVersion();
+ }
+ return flashVer;
+}
+
+// When called with reqMajorVer, reqMinorVer, reqRevision returns true if that version or greater is available
+function DetectFlashVer(reqMajorVer, reqMinorVer, reqRevision)
+{
+ versionStr = GetSwfVer();
+ if (versionStr == -1 ) {
+ return false;
+ } else if (versionStr != 0) {
+ if(isIE && isWin && !isOpera) {
+ // Given "WIN 2,0,0,11"
+ tempArray = versionStr.split(" "); // ["WIN", "2,0,0,11"]
+ tempString = tempArray[1]; // "2,0,0,11"
+ versionArray = tempString.split(","); // ['2', '0', '0', '11']
+ } else {
+ versionArray = versionStr.split(".");
+ }
+ var versionMajor = versionArray[0];
+ var versionMinor = versionArray[1];
+ var versionRevision = versionArray[2];
+
+ // is the major.revision >= requested major.revision AND the minor version >= requested minor
+ if (versionMajor > parseFloat(reqMajorVer)) {
+ return true;
+ } else if (versionMajor == parseFloat(reqMajorVer)) {
+ if (versionMinor > parseFloat(reqMinorVer))
+ return true;
+ else if (versionMinor == parseFloat(reqMinorVer)) {
+ if (versionRevision >= parseFloat(reqRevision))
+ return true;
+ }
+ }
+ return false;
+ }
+}
+
+function AC_AddExtension(src, ext)
+{
+ if (src.indexOf('?') != -1)
+ return src.replace(/\?/, ext+'?');
+ else
+ return src + ext;
+}
+
+function AC_Generateobj(objAttrs, params, embedAttrs)
+{
+ var str = '';
+ if (isIE && isWin && !isOpera)
+ {
+ str += '<object ';
+ for (var i in objAttrs)
+ str += i + '="' + objAttrs[i] + '" ';
+ for (var i in params)
+ str += '><param name="' + i + '" value="' + params[i] + '" /> ';
+ str += '></object>';
+ } else {
+ str += '<embed ';
+ for (var i in embedAttrs)
+ str += i + '="' + embedAttrs[i] + '" ';
+ str += '> </embed>';
+ }
+
+ document.write(str);
+}
+
+function AC_FL_RunContent(){
+ var ret =
+ AC_GetArgs
+ ( arguments, ".swf", "movie", "clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"
+ , "application/x-shockwave-flash"
+ );
+ AC_Generateobj(ret.objAttrs, ret.params, ret.embedAttrs);
+}
+
+function AC_GetArgs(args, ext, srcParamName, classid, mimeType){
+ var ret = new Object();
+ ret.embedAttrs = new Object();
+ ret.params = new Object();
+ ret.objAttrs = new Object();
+ for (var i=0; i < args.length; i=i+2){
+ var currArg = args[i].toLowerCase();
+
+ switch (currArg){
+ case "classid":
+ break;
+ case "pluginspage":
+ ret.embedAttrs[args[i]] = args[i+1];
+ break;
+ case "src":
+ case "movie":
+ args[i+1] = AC_AddExtension(args[i+1], ext);
+ ret.embedAttrs["src"] = args[i+1];
+ ret.params[srcParamName] = args[i+1];
+ break;
+ case "onafterupdate":
+ case "onbeforeupdate":
+ case "onblur":
+ case "oncellchange":
+ case "onclick":
+ case "ondblClick":
+ case "ondrag":
+ case "ondragend":
+ case "ondragenter":
+ case "ondragleave":
+ case "ondragover":
+ case "ondrop":
+ case "onfinish":
+ case "onfocus":
+ case "onhelp":
+ case "onmousedown":
+ case "onmouseup":
+ case "onmouseover":
+ case "onmousemove":
+ case "onmouseout":
+ case "onkeypress":
+ case "onkeydown":
+ case "onkeyup":
+ case "onload":
+ case "onlosecapture":
+ case "onpropertychange":
+ case "onreadystatechange":
+ case "onrowsdelete":
+ case "onrowenter":
+ case "onrowexit":
+ case "onrowsinserted":
+ case "onstart":
+ case "onscroll":
+ case "onbeforeeditfocus":
+ case "onactivate":
+ case "onbeforedeactivate":
+ case "ondeactivate":
+ case "type":
+ case "codebase":
+ case "id":
+ ret.objAttrs[args[i]] = args[i+1];
+ break;
+ case "width":
+ case "height":
+ case "align":
+ case "vspace":
+ case "hspace":
+ case "class":
+ case "title":
+ case "accesskey":
+ case "name":
+ case "tabindex":
+ ret.embedAttrs[args[i]] = ret.objAttrs[args[i]] = args[i+1];
+ break;
+ default:
+ ret.embedAttrs[args[i]] = ret.params[args[i]] = args[i+1];
+ }
+ }
+ ret.objAttrs["classid"] = classid;
+ if (mimeType) ret.embedAttrs["type"] = mimeType;
+ return ret;
+}
+
+
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/flowplayer-3.1.1.min.js b/abs/core-testing/local-website/htdocs/linhes/js/flowplayer-3.1.1.min.js
new file mode 100644
index 0000000..5e14062
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/flowplayer-3.1.1.min.js
@@ -0,0 +1,24 @@
+/*
+ * flowplayer.js 3.1.1. The Flowplayer API
+ *
+ * Copyright 2009 Flowplayer Oy
+ *
+ * This file is part of Flowplayer.
+ *
+ * Flowplayer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * Flowplayer 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 Flowplayer. If not, see <http://www.gnu.org/licenses/>.
+ *
+ * Date: 2009-02-25 16:24:29 -0500 (Wed, 25 Feb 2009)
+ * Revision: 166
+ */
+(function(){function g(o){console.log("$f.fireEvent",[].slice.call(o))}function k(q){if(!q||typeof q!="object"){return q}var o=new q.constructor();for(var p in q){if(q.hasOwnProperty(p)){o[p]=k(q[p])}}return o}function m(t,q){if(!t){return}var o,p=0,r=t.length;if(r===undefined){for(o in t){if(q.call(t[o],o,t[o])===false){break}}}else{for(var s=t[0];p<r&&q.call(s,p,s)!==false;s=t[++p]){}}return t}function c(o){return document.getElementById(o)}function i(q,p,o){if(typeof p!="object"){return q}if(q&&p){m(p,function(r,s){if(!o||typeof s!="function"){q[r]=s}})}return q}function n(s){var q=s.indexOf(".");if(q!=-1){var p=s.substring(0,q)||"*";var o=s.substring(q+1,s.length);var r=[];m(document.getElementsByTagName(p),function(){if(this.className&&this.className.indexOf(o)!=-1){r.push(this)}});return r}}function f(o){o=o||window.event;if(o.preventDefault){o.stopPropagation();o.preventDefault()}else{o.returnValue=false;o.cancelBubble=true}return false}function j(q,o,p){q[o]=q[o]||[];q[o].push(p)}function e(){return"_"+(""+Math.random()).substring(2,10)}var h=function(t,r,s){var q=this;var p={};var u={};q.index=r;if(typeof t=="string"){t={url:t}}i(this,t,true);m(("Begin*,Start,Pause*,Resume*,Seek*,Stop*,Finish*,LastSecond,Update,BufferFull,BufferEmpty,BufferStop").split(","),function(){var v="on"+this;if(v.indexOf("*")!=-1){v=v.substring(0,v.length-1);var w="onBefore"+v.substring(2);q[w]=function(x){j(u,w,x);return q}}q[v]=function(x){j(u,v,x);return q};if(r==-1){if(q[w]){s[w]=q[w]}if(q[v]){s[v]=q[v]}}});i(this,{onCuepoint:function(x,w){if(arguments.length==1){p.embedded=[null,x];return q}if(typeof x=="number"){x=[x]}var v=e();p[v]=[x,w];if(s.isLoaded()){s._api().fp_addCuepoints(x,r,v)}return q},update:function(w){i(q,w);if(s.isLoaded()){s._api().fp_updateClip(w,r)}var v=s.getConfig();var x=(r==-1)?v.clip:v.playlist[r];i(x,w,true)},_fireEvent:function(v,y,w,A){if(v=="onLoad"){m(p,function(B,C){if(C[0]){s._api().fp_addCuepoints(C[0],r,B)}});return false}A=A||q;if(v=="onCuepoint"){var z=p[y];if(z){return z[1].call(s,A,w)}}if(v=="onStart"||v=="onUpdate"||v=="onResume"){i(A,y);if(!A.duration){A.duration=y.metaData.duration}else{A.fullDuration=y.metaData.duration}}var x=true;m(u[v],function(){x=this.call(s,A,y,w)});return x}});if(t.onCuepoint){var o=t.onCuepoint;q.onCuepoint.apply(q,typeof o=="function"?[o]:o);delete t.onCuepoint}m(t,function(v,w){if(typeof w=="function"){j(u,v,w);delete t[v]}});if(r==-1){s.onCuepoint=this.onCuepoint}};var l=function(p,r,q,t){var s={};var o=this;var u=false;if(t){i(s,t)}m(r,function(v,w){if(typeof w=="function"){s[v]=w;delete r[v]}});i(this,{animate:function(y,z,x){if(!y){return o}if(typeof z=="function"){x=z;z=500}if(typeof y=="string"){var w=y;y={};y[w]=z;z=500}if(x){var v=e();s[v]=x}if(z===undefined){z=500}r=q._api().fp_animate(p,y,z,v);return o},css:function(w,x){if(x!==undefined){var v={};v[w]=x;w=v}r=q._api().fp_css(p,w);i(o,r);return o},show:function(){this.display="block";q._api().fp_showPlugin(p);return o},hide:function(){this.display="none";q._api().fp_hidePlugin(p);return o},toggle:function(){this.display=q._api().fp_togglePlugin(p);return o},fadeTo:function(y,x,w){if(typeof x=="function"){w=x;x=500}if(w){var v=e();s[v]=w}this.display=q._api().fp_fadeTo(p,y,x,v);this.opacity=y;return o},fadeIn:function(w,v){return o.fadeTo(1,w,v)},fadeOut:function(w,v){return o.fadeTo(0,w,v)},getName:function(){return p},getPlayer:function(){return q},_fireEvent:function(w,v,x){if(w=="onUpdate"){var y=q._api().fp_getPlugin(p);if(!y){return}i(o,y);delete o.methods;if(!u){m(y.methods,function(){var A=""+this;o[A]=function(){var B=[].slice.call(arguments);var C=q._api().fp_invoke(p,A,B);return C=="undefined"?o:C}});u=true}}var z=s[w];if(z){z.apply(o,v);if(w.substring(0,1)=="_"){delete s[w]}}}})};function b(o,t,z){var E=this,y=null,x,u,p=[],s={},B={},r,v,w,D,A,q;i(E,{id:function(){return r},isLoaded:function(){return(y!==null)},getParent:function(){return o},hide:function(F){if(F){o.style.height="0px"}if(y){y.style.height="0px"}return E},show:function(){o.style.height=q+"px";if(y){y.style.height=A+"px"}return E},isHidden:function(){return y&&parseInt(y.style.height,10)===0},load:function(F){if(!y&&E._fireEvent("onBeforeLoad")!==false){m(a,function(){this.unload()});x=o.innerHTML;if(x&&!flashembed.isSupported(t.version)){o.innerHTML=""}flashembed(o,t,{config:z});if(F){F.cached=true;j(B,"onLoad",F)}}return E},unload:function(){try{if(!y||y.fp_isFullscreen()){return E}}catch(F){return E}if(x.replace(/\s/g,"")!==""){if(E._fireEvent("onBeforeUnload")===false){return E}y.fp_close();y=null;o.innerHTML=x;E._fireEvent("onUnload")}return E},getClip:function(F){if(F===undefined){F=D}return p[F]},getCommonClip:function(){return u},getPlaylist:function(){return p},getPlugin:function(F){var H=s[F];if(!H&&E.isLoaded()){var G=E._api().fp_getPlugin(F);if(G){H=new l(F,G,E);s[F]=H}}return H},getScreen:function(){return E.getPlugin("screen")},getControls:function(){return E.getPlugin("controls")},getConfig:function(F){return F?k(z):z},getFlashParams:function(){return t},loadPlugin:function(I,H,K,J){if(typeof K=="function"){J=K;K={}}var G=J?e():"_";E._api().fp_loadPlugin(I,H,K,G);var F={};F[G]=J;var L=new l(I,null,E,F);s[I]=L;return L},getState:function(){return y?y.fp_getState():-1},play:function(G,F){function H(){if(G!==undefined){E._api().fp_play(G,F)}else{E._api().fp_play()}}if(y){H()}else{E.load(function(){H()})}return E},getVersion:function(){var G="flowplayer.js 3.1.1";if(y){var F=y.fp_getVersion();F.push(G);return F}return G},_api:function(){if(!y){throw"Flowplayer "+E.id()+" not loaded when calling an API method"}return y},setClip:function(F){E.setPlaylist([F]);return E},getIndex:function(){return w}});m(("Click*,Load*,Unload*,Keypress*,Volume*,Mute*,Unmute*,PlaylistReplace,ClipAdd,Fullscreen*,FullscreenExit,Error").split(","),function(){var F="on"+this;if(F.indexOf("*")!=-1){F=F.substring(0,F.length-1);var G="onBefore"+F.substring(2);E[G]=function(H){j(B,G,H);return E}}E[F]=function(H){j(B,F,H);return E}});m(("pause,resume,mute,unmute,stop,toggle,seek,getStatus,getVolume,setVolume,getTime,isPaused,isPlaying,startBuffering,stopBuffering,isFullscreen,toggleFullscreen,reset,close,setPlaylist,addClip").split(","),function(){var F=this;E[F]=function(H,G){if(!y){return E}var I=null;if(H!==undefined&&G!==undefined){I=y["fp_"+F](H,G)}else{I=(H===undefined)?y["fp_"+F]():y["fp_"+F](H)}return I=="undefined"?E:I}});E._fireEvent=function(O){if(typeof O=="string"){O=[O]}var P=O[0],M=O[1],K=O[2],J=O[3],I=0;if(z.debug){g(O)}if(!y&&P=="onLoad"&&M=="player"){y=y||c(v);A=y.clientHeight;m(p,function(){this._fireEvent("onLoad")});m(s,function(Q,R){R._fireEvent("onUpdate")});u._fireEvent("onLoad")}if(P=="onLoad"&&M!="player"){return}if(P=="onError"){if(typeof M=="string"||(typeof M=="number"&&typeof K=="number")){M=K;K=J}}if(P=="onContextMenu"){m(z.contextMenu[M],function(Q,R){R.call(E)});return}if(P=="onPluginEvent"){var F=M.name||M;var G=s[F];if(G){G._fireEvent("onUpdate",M);G._fireEvent(K,O.slice(3))}return}if(P=="onPlaylistReplace"){p=[];var L=0;m(M,function(){p.push(new h(this,L++,E))})}if(P=="onClipAdd"){if(M.isInStream){return}M=new h(M,K,E);p.splice(K,0,M);for(I=K+1;I<p.length;I++){p[I].index++}}var N=true;if(typeof M=="number"&&M<p.length){D=M;var H=p[M];if(H){N=H._fireEvent(P,K,J)}if(!H||N!==false){N=u._fireEvent(P,K,J,H)}}m(B[P],function(){N=this.call(E,M,K);if(this.cached){B[P].splice(I,1)}if(N===false){return false}I++});return N};function C(){if($f(o)){$f(o).getParent().innerHTML="";w=$f(o).getIndex();a[w]=E}else{a.push(E);w=a.length-1}q=parseInt(o.style.height,10)||o.clientHeight;if(typeof t=="string"){t={src:t}}r=o.id||"fp"+e();v=t.id||r+"_api";t.id=v;z.playerId=r;if(typeof z=="string"){z={clip:{url:z}}}if(typeof z.clip=="string"){z.clip={url:z.clip}}z.clip=z.clip||{};if(o.getAttribute("href",2)&&!z.clip.url){z.clip.url=o.getAttribute("href",2)}u=new h(z.clip,-1,E);z.playlist=z.playlist||[z.clip];var F=0;m(z.playlist,function(){var H=this;if(typeof H=="object"&&H.length){H={url:""+H}}m(z.clip,function(I,J){if(J!==undefined&&H[I]===undefined&&typeof J!="function"){H[I]=J}});z.playlist[F]=H;H=new h(H,F,E);p.push(H);F++});m(z,function(H,I){if(typeof I=="function"){j(B,H,I);delete z[H]}});m(z.plugins,function(H,I){if(I){s[H]=new l(H,I,E)}});if(!z.plugins||z.plugins.controls===undefined){s.controls=new l("controls",null,E)}s.canvas=new l("canvas",null,E);t.bgcolor=t.bgcolor||"#000000";t.version=t.version||[9,0];t.expressInstall="http://www.flowplayer.org/swf/expressinstall.swf";function G(H){if(!E.isLoaded()&&E._fireEvent("onBeforeClick")!==false){E.load()}return f(H)}x=o.innerHTML;if(x.replace(/\s/g,"")!==""){if(o.addEventListener){o.addEventListener("click",G,false)}else{if(o.attachEvent){o.attachEvent("onclick",G)}}}else{if(o.addEventListener){o.addEventListener("click",f,false)}E.load()}}if(typeof o=="string"){flashembed.domReady(function(){var F=c(o);if(!F){throw"Flowplayer cannot access element: "+o}else{o=F;C()}})}else{C()}}var a=[];function d(o){this.length=o.length;this.each=function(p){m(o,p)};this.size=function(){return o.length}}window.flowplayer=window.$f=function(){var p=null;var o=arguments[0];if(!arguments.length){m(a,function(){if(this.isLoaded()){p=this;return false}});return p||a[0]}if(arguments.length==1){if(typeof o=="number"){return a[o]}else{if(o=="*"){return new d(a)}m(a,function(){if(this.id()==o.id||this.id()==o||this.getParent()==o){p=this;return false}});return p}}if(arguments.length>1){var r=arguments[1];var q=(arguments.length==3)?arguments[2]:{};if(typeof o=="string"){if(o.indexOf(".")!=-1){var t=[];m(n(o),function(){t.push(new b(this,k(r),k(q)))});return new d(t)}else{var s=c(o);return new b(s!==null?s:o,r,q)}}else{if(o){return new b(o,r,q)}}}return null};i(window.$f,{fireEvent:function(){var o=[].slice.call(arguments);var q=$f(o[0]);return q?q._fireEvent(o.slice(1)):null},addPlugin:function(o,p){b.prototype[o]=p;return $f},each:m,extend:i});if(typeof jQuery=="function"){jQuery.prototype.flowplayer=function(q,p){if(!arguments.length||typeof arguments[0]=="number"){var o=[];this.each(function(){var r=$f(this);if(r){o.push(r)}});return arguments.length?o[arguments[0]]:new d(o)}return this.each(function(){$f(this,k(q),p?k(p):{})})}}})();(function(){var e=typeof jQuery=="function";function i(){if(c.done){return false}var k=document;if(k&&k.getElementsByTagName&&k.getElementById&&k.body){clearInterval(c.timer);c.timer=null;for(var j=0;j<c.ready.length;j++){c.ready[j].call()}c.ready=null;c.done=true}}var c=e?jQuery:function(j){if(c.done){return j()}if(c.timer){c.ready.push(j)}else{c.ready=[j];c.timer=setInterval(i,13)}};function f(k,j){if(j){for(key in j){if(j.hasOwnProperty(key)){k[key]=j[key]}}}return k}function g(j){switch(h(j)){case"string":j=j.replace(new RegExp('(["\\\\])',"g"),"\\$1");j=j.replace(/^\s?(\d+)%/,"$1pct");return'"'+j+'"';case"array":return"["+b(j,function(m){return g(m)}).join(",")+"]";case"function":return'"function()"';case"object":var k=[];for(var l in j){if(j.hasOwnProperty(l)){k.push('"'+l+'":'+g(j[l]))}}return"{"+k.join(",")+"}"}return String(j).replace(/\s/g," ").replace(/\'/g,'"')}function h(k){if(k===null||k===undefined){return false}var j=typeof k;return(j=="object"&&k.push)?"array":j}if(window.attachEvent){window.attachEvent("onbeforeunload",function(){__flash_unloadHandler=function(){};__flash_savedUnloadHandler=function(){}})}function b(j,m){var l=[];for(var k in j){if(j.hasOwnProperty(k)){l[k]=m(j[k])}}return l}function a(q,s){var o=f({},q);var r=document.all;var m='<object width="'+o.width+'" height="'+o.height+'"';if(r&&!o.id){o.id="_"+(""+Math.random()).substring(9)}if(o.id){m+=' id="'+o.id+'"'}o.src+=((o.src.indexOf("?")!=-1?"&":"?")+Math.random());if(o.w3c||!r){m+=' data="'+o.src+'" type="application/x-shockwave-flash"'}else{m+=' classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'}m+=">";if(o.w3c||r){m+='<param name="movie" value="'+o.src+'" />'}o.width=o.height=o.id=o.w3c=o.src=null;for(var j in o){if(o[j]!==null){m+='<param name="'+j+'" value="'+o[j]+'" />'}}var n="";if(s){for(var l in s){if(s[l]!==null){n+=l+"="+(typeof s[l]=="object"?g(s[l]):s[l])+"&"}}n=n.substring(0,n.length-1);m+='<param name="flashvars" value=\''+n+"' />"}m+="</object>";return m}function d(l,o,k){var j=flashembed.getVersion();f(this,{getContainer:function(){return l},getConf:function(){return o},getVersion:function(){return j},getFlashvars:function(){return k},getApi:function(){return l.firstChild},getHTML:function(){return a(o,k)}});var p=o.version;var q=o.expressInstall;var n=!p||flashembed.isSupported(p);if(n){o.onFail=o.version=o.expressInstall=null;l.innerHTML=a(o,k)}else{if(p&&q&&flashembed.isSupported([6,65])){f(o,{src:q});k={MMredirectURL:location.href,MMplayerType:"PlugIn",MMdoctitle:document.title};l.innerHTML=a(o,k)}else{if(l.innerHTML.replace(/\s/g,"")!==""){}else{l.innerHTML="<h2>Flash version "+p+" or greater is required</h2><h3>"+(j[0]>0?"Your version is "+j:"You have no flash plugin installed")+"</h3>"+(l.tagName=="A"?"<p>Click here to download latest version</p>":"<p>Download latest version from <a href='http://www.adobe.com/go/getflashplayer'>here</a></p>");if(l.tagName=="A"){l.onclick=function(){location.href="http://www.adobe.com/go/getflashplayer"}}}}}if(!n&&o.onFail){var m=o.onFail.call(this);if(typeof m=="string"){l.innerHTML=m}}if(document.all){window[o.id]=document.getElementById(o.id)}}window.flashembed=function(k,l,j){if(typeof k=="string"){var m=document.getElementById(k);if(m){k=m}else{c(function(){flashembed(k,l,j)});return}}if(!k){return}var n={width:"100%",height:"100%",allowfullscreen:true,allowscriptaccess:"always",quality:"high",version:null,onFail:null,expressInstall:null,w3c:false};if(typeof l=="string"){l={src:l}}f(n,l);return new d(k,n,j)};f(window.flashembed,{getVersion:function(){var l=[0,0];if(navigator.plugins&&typeof navigator.plugins["Shockwave Flash"]=="object"){var k=navigator.plugins["Shockwave Flash"].description;if(typeof k!="undefined"){k=k.replace(/^.*\s+(\S+\s+\S+$)/,"$1");var m=parseInt(k.replace(/^(.*)\..*$/,"$1"),10);var q=/r/.test(k)?parseInt(k.replace(/^.*r(.*)$/,"$1"),10):0;l=[m,q]}}else{if(window.ActiveXObject){try{var o=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7")}catch(p){try{o=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");l=[6,0];o.AllowScriptAccess="always"}catch(j){if(l[0]==6){return}}try{o=new ActiveXObject("ShockwaveFlash.ShockwaveFlash")}catch(n){}}if(typeof o=="object"){k=o.GetVariable("$version");if(typeof k!="undefined"){k=k.replace(/^\S+\s+(.*)$/,"$1").split(",");l=[parseInt(k[0],10),parseInt(k[2],10)]}}}}return l},isSupported:function(j){var l=flashembed.getVersion();var k=(l[0]>j[0])||(l[0]==j[0]&&l[1]>=j[1]);return k},domReady:c,asString:g,getHTML:a});if(e){jQuery.tools=jQuery.tools||{version:{}};jQuery.tools.version.flashembed="1.0.2";jQuery.fn.flashembed=function(k,j){var l=null;this.each(function(){l=flashembed(this,k,j)});return k.api===false?this:l}}})(); \ No newline at end of file
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/pngbehavior.htc b/abs/core-testing/local-website/htdocs/linhes/js/pngbehavior.htc
new file mode 100644
index 0000000..4d664d9
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/pngbehavior.htc
@@ -0,0 +1,97 @@
+/**
+ * This is a slightly modified version of Eric Advidsson's pngbehavior.htc
+ * script at http://webfx.eae.net/dhtml/pngbehavior/pngbehavior.html
+ *
+ * For usage see license at http://webfx.eae.net/license.html
+ *
+ * It also includes some printing fixes from:
+ * http://www.scss.com.au/family/andrew/webdesign/pngbehavior/
+ *
+ * As well as restricting the versions of IE that it will match, since IE 7 now
+ * deals properly with transparent PNGs.
+ *
+ * @url $URL$
+ * @date $Date: 2006-11-13 18:57:43 +0000 (Mon, 13 Nov 2006) $
+ * @version $Revision: 11730 $
+ * @author $Author: xris $
+ *
+/**/
+
+<public:component>
+<public:attach event="onpropertychange" onevent="propertyChanged()" />
+<public:attach event="onbeforeprint" for="window" onevent="beforePrint()" />
+<public:attach event="onafterprint" for="window" onevent="afterPrint()" />
+
+<script type="text/javascript">
+
+// Set this to the URL of your 1x1 transparent gif
+ var blankSrc = "/skins/default/img/spacer.gif";
+
+// Only interact with valid browsers. Everything after IE 6 supports
+// transparent PNGs natively (yay!)
+ var supported = /MSIE (5\.5|6)/.test(navigator.userAgent) && navigator.platform == "Win32";
+
+/******************************************************************************/
+
+ var realSrc;
+
+ if (supported)
+ fixImage();
+
+ function propertyChanged() {
+ if (supported && event.propertyName == 'src') {
+ var i = element.src.lastIndexOf(blankSrc);
+ if (i == -1 || i != element.src.length - blankSrc.length) {
+ fixImage();
+ }
+ }
+ }
+
+ function fixImage() {
+ if (!supported) return;
+ // Don't set the image to itself (i.e. catch stupid web designer errors)
+ if (element.src == realSrc && element.runtimeStyle.filter != "") {
+ element.src = blankSrc;
+ return;
+ }
+ // Backup the old src
+ if ( ! new RegExp(blankSrc).test(element.src))
+ realSrc = element.src;
+ // Test for png
+ if ( realSrc && /\.png$/.test( realSrc.toLowerCase() ) ) {
+ // Make sure that width and height are preserved
+ var width = element.width;
+ var height = element.height;
+ // Set blank image
+ element.src = blankSrc;
+ // Set filter
+ element.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"
+ + encodeURI(realSrc) + "',sizingMethod='scale')";
+ // Restore width and height
+ element.width = width;
+ element.height = height;
+ }
+ // Otherwise, remove the filter
+ else
+ element.runtimeStyle.filter = "";
+ }
+
+ function beforePrint() {
+ if (realSrc) {
+ supported = false;
+ element.src = realSrc;
+ element.runtimeStyle.filter = '';
+ supported = true;
+ }
+ }
+
+ function afterPrint() {
+ if (realSrc) {
+ var rs = realSrc;
+ realSrc = null;
+ element.src = rs;
+ }
+ }
+
+</script>
+</public:component>
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/prototip/classic_toolbar.gif b/abs/core-testing/local-website/htdocs/linhes/js/prototip/classic_toolbar.gif
new file mode 100644
index 0000000..a8948b6
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/prototip/classic_toolbar.gif
Binary files differ
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/prototip/close.gif b/abs/core-testing/local-website/htdocs/linhes/js/prototip/close.gif
new file mode 100644
index 0000000..25b04d3
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/prototip/close.gif
Binary files differ
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/prototip/close_hover.gif b/abs/core-testing/local-website/htdocs/linhes/js/prototip/close_hover.gif
new file mode 100644
index 0000000..2a919ab
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/prototip/close_hover.gif
Binary files differ
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/prototip/close_hover_red.gif b/abs/core-testing/local-website/htdocs/linhes/js/prototip/close_hover_red.gif
new file mode 100644
index 0000000..b063bee
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/prototip/close_hover_red.gif
Binary files differ
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/prototip/prototip.css b/abs/core-testing/local-website/htdocs/linhes/js/prototip/prototip.css
new file mode 100644
index 0000000..7ef6fb5
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/prototip/prototip.css
@@ -0,0 +1,65 @@
+/* prototip.css : http://www.nickstakenburg.com/projects/prototip */
+.prototip { position: absolute; }
+.prototip .effectWrapper { position: relative; }
+.prototip .tooltip { position: relative; }
+.prototip .toolbar {
+ position: relative;
+ display: block;
+ }
+.prototip .toolbar .title {
+ display: block;
+ position: relative;
+ }
+.prototip .content { clear: both; }
+.prototip .toolbar a.close {
+ position: relative;
+ top: 15px;
+ text-decoration: none;
+ float: right;
+ width: 15px;
+ height: 15px;
+ background: transparent url(close.gif);
+ display: block;
+ line-height: 0;
+ font-size: 0px;
+ border: 0;
+ }
+.prototip .toolbar a.close:hover { background: transparent url(close_hover.gif); }
+
+.iframeShim {
+ position: absolute;
+ border: 0;
+ margin: 0;
+ padding: 0;
+ background: none;
+}
+
+/* Tooltip styles */
+.prototip .default { width: 150px; color: #fff; }
+.prototip .default .toolbar { background: #0F6788; font: italic 17px Georgia, serif; }
+.prototip .default .title { padding: 5px; }
+.prototip .default .content { background: #1E90FF; font: 11px Arial, Helvetica, sans-serif; padding: 5px;}
+
+.prototip .pinktip { border: 5px solid #a1a1a1; }
+.prototip .pinktip .toolbar { background: #ff1e53; color: #fff; font: italic 17px Georgia, serif; }
+.prototip .pinktip .title { padding: 5px; }
+.prototip .pinktip .content { background: #fff; color: #555555; font: 11px Arial, Helvetica, sans-serif; padding: 5px; }
+
+.prototip .darktip { width: 250px; border: 5px solid #a1a1a1; }
+.prototip .darktip .toolbar { background: #606060; color: #fff; font: italic 17px Georgia, serif; }
+.prototip .darktip .toolbar a.close { background: url(close_hover.gif);}
+.prototip .darktip .toolbar a.close:hover { background: url(close.gif);}
+.prototip .darktip .title { padding: 5px;}
+.prototip .darktip .content { background: #808080; color: #fff; font: 11px Arial, Helvetica, sans-serif; padding: 5px; }
+
+.prototip .silver { width: 300px; border: 5px solid #cccccc; color: #fff; font: 11px Arial, Helvetica, sans-serif;}
+.prototip .silver .toolbar { background: #2e2e2e; color: #fff; font-weight: bold; }
+.prototip .silver .toolbar a.close:hover { background: url(close_hover_red.gif);}
+.prototip .silver .title { padding: 5px; }
+.prototip .silver .content { background: #fff; color: #666666; padding: 5px;}
+
+.protoClassic { width: 300px; border: 5px solid #8c939c; }
+.protoClassic .toolbar { background: #96b8e2 url(classic_toolbar.gif) top left repeat-y; font-weight: bold; color: #fff;}
+.protoClassic .toolbar a.close:hover { background: url(close_hover_red.gif);}
+.protoClassic .title { padding: 5px; }
+.protoClassic .content { background: #fff; color: #333333; font: 11px Arial, Helvetica, sans-serif; padding: 5px; }
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/prototip/prototip.js b/abs/core-testing/local-website/htdocs/linhes/js/prototip/prototip.js
new file mode 100644
index 0000000..f386a03
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/prototip/prototip.js
@@ -0,0 +1,506 @@
+// Prototip 1.2.0_pre1 - 17-12-2007
+
+// Copyright (c) 2007 Nick Stakenburg (http://www.nickstakenburg.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+// CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+// TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+// SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+// More information on this project:
+// http://www.nickstakenburg.com/projects/prototip/
+
+var Prototip = {
+ Version: '1.2.0_pre1',
+
+ REQUIRED_Prototype: '1.6.0',
+ REQUIRED_Scriptaculous: '1.8.0',
+
+ start: function() {
+ this.require('Prototype');
+ Tips.initialize();
+ Element.observe(window, 'unload', this.unload);
+ },
+
+ require: function(library) {
+ if ((typeof window[library] == 'undefined') ||
+ (this.convertVersionString(window[library].Version) < this.convertVersionString(this['REQUIRED_' + library])))
+ throw('Prototip requires ' + library + ' >= ' + this['REQUIRED_' + library]);
+ },
+
+ convertVersionString: function(versionString) {
+ var r = versionString.split('.');
+ return parseInt(r[0])*100000 + parseInt(r[1])*1000 + parseInt(r[2]);
+ },
+
+ viewport: {
+ getDimensions: function() {
+ var dimensions = { };
+ var B = Prototype.Browser;
+ $w('width height').each(function(d) {
+ var D = d.capitalize();
+ dimensions[d] = (B.WebKit && !document.evaluate) ? self['inner' + D] :
+ (B.Opera) ? document.body['client' + D] : document.documentElement['client' + D];
+ });
+ return dimensions;
+ }
+ },
+
+ capture: function(func) {
+ if (!Prototype.Browser.IE) {
+ func = func.wrap(function(proceed, event) {
+ var rel = event.relatedTarget, cur = event.currentTarget;
+ if (rel && rel.nodeType == Node.TEXT_NODE) rel = rel.parentNode;
+ if (rel && rel != cur && rel.descendantOf && !(rel.descendantOf(cur)))
+ proceed(event);
+ });
+ }
+ return func;
+ },
+
+ unload: function() { Tips.removeAll(); }
+};
+
+var Tips = {
+ // Configuration
+ closeButtons: true,
+ zIndex: 1200,
+
+ tips : [],
+ visible : [],
+
+ initialize: function() {
+ this.zIndexTop = this.zIndex;
+ },
+
+ useEvent : (function(IE) { return {
+ 'mouseover': (IE ? 'mouseenter' : 'mouseover'),
+ 'mouseout': (IE ? 'mouseleave' : 'mouseout'),
+ 'mouseenter': (IE ? 'mouseenter' : 'mouseover'),
+ 'mouseleave': (IE ? 'mouseleave' : 'mouseout')
+ };})(Prototype.Browser.IE),
+
+ fixIE: (function(agent) {
+ var version = new RegExp('MSIE ([\\d.]+)').exec(agent);
+ return version ? (parseFloat(version[1]) <= 6) : false;
+ })(navigator.userAgent),
+
+ add: function(tip) {
+ this.tips.push(tip);
+ },
+
+ hasTip: function(element) {
+ if (this.tips.find(function(t){ return t.element == $(element); }))
+ return true;
+ return false;
+ },
+
+ showTip: function(element) {
+ var tip = this.tips.find(function(t){ return t.element == $(element); });
+ if (tip) {
+ tip.show();
+ tip.position();
+ }
+ },
+
+ hideTip: function(element) {
+ var tip = this.tips.find(function(t){ return t.element == $(element); });
+ if (tip)
+ tip.hide();
+ },
+
+ hideAll: function() {
+ this.tips.each(function(tip) { tip.hide(); }.bind(this));
+ },
+
+ remove: function(element) {
+ var tip = this.tips.find(function(t){ return t.element == $(element); });
+ if (tip) {
+ tip.deactivate();
+ if (tip.tooltip) {
+ tip.wrapper.remove();
+ if (Tips.fixIE) tip.iframeShim.remove();
+ }
+ this.tips = this.tips.without(tip);
+ }
+ },
+
+ removeAll: function() {
+ this.tips.each(function(tip) { this.remove(tip.element); }.bind(this));
+ },
+
+ raise: function(tip) {
+ if (tip.highest) return;
+ if (this.visible.length == 0) {
+ this.zIndexTop = this.zIndex;
+ for (var i=0;i<this.tips.length;i++) {
+ this.tips[i].wrapper.style.zIndex = this.zIndex;
+ }
+ }
+ tip.style.zIndex = this.zIndexTop++;
+ for (var i=0;i<this.tips.length;i++) { this.tips[i].wrapper.highest = false; };
+ tip.highest = true;
+ },
+
+ addVisibile: function(tip) {
+ this.removeVisible(tip);
+ this.visible.push(tip);
+ },
+
+ removeVisible: function(tip) {
+ this.visible = this.visible.without(tip);
+ }
+};
+Tips.initialize();
+
+var Tip = Class.create({
+ initialize: function(element, content) {
+ this.element = $(element);
+ Tips.remove(this.element);
+
+ this.content = content;
+
+ var isHooking = (arguments[2] && arguments[2].hook);
+ var isShowOnClick = (arguments[2] && arguments[2].showOn == 'click');
+
+ this.options = Object.extend({
+ className: 'default', // see css, this will lead to .prototip .default
+ closeButton: Tips.closeButtons, // true, false
+ delay: !isShowOnClick ? 0.2 : false, // seconds before tooltip appears
+ duration: 0.3, // duration of the effect
+ effect: false, // false, 'appear' or 'blind'
+ hideAfter: false, // second before hide after no hover/activity
+ hideOn: 'mouseleave', // or any other event, false
+ hook: false, // { element: topLeft|topRight|bottomLeft|bottomRight, tip: see element }
+ offset: isHooking ? {x:0, y:0} : {x:16, y:16},
+ fixed: isHooking ? true : false, // follow the mouse if false
+ showOn: 'mousemove',
+ target: this.element, // or another element
+ title: false,
+ viewport: isHooking ? false : true // keep within viewport if mouse is followed
+ }, arguments[2] || {});
+
+ this.target = $(this.options.target);
+
+ this.setup();
+
+ if (this.options.effect) {
+ Prototip.require('Scriptaculous');
+ this.queue = { position: 'end', limit: 1, scope: this.wrapper.identify() }
+ }
+
+ Tips.add(this);
+ this.activate();
+ },
+
+ setup: function() {
+ this.wrapper = new Element('div', { 'class' : 'prototip' }).setStyle({
+ display: 'none', zIndex: Tips.zIndex });
+ this.wrapper.identify();
+
+ if (Tips.fixIE) {
+ this.iframeShim = new Element('iframe', { 'class' : 'iframeShim', src: 'javascript:false;' }).setStyle({
+ display: 'none', zIndex: Tips.zIndex - 1 });
+ }
+
+ this.tip = new Element('div', { 'class' : 'content' }).insert(this.content);
+ this.tip.insert(new Element('div').setStyle({ clear: 'both' }));
+
+ if (this.options.closeButton || (this.options.hideOn.element && this.options.hideOn.element == 'closeButton'))
+ this.closeButton = new Element('a', { href: '#', 'class' : 'close' });
+ },
+
+ build: function() {
+ if (Tips.fixIE) document.body.appendChild(this.iframeShim).setOpacity(0);
+
+ // effects go smooth with extra wrapper
+ var wrapper = 'wrapper';
+ if (this.options.effect) {
+ this.effectWrapper = this.wrapper.appendChild(new Element('div', { 'class' : 'effectWrapper' }));
+ wrapper = 'effectWrapper';
+ }
+
+ this.tooltip = this[wrapper].appendChild(new Element('div', { 'class' : 'tooltip ' + this.options.className }));
+
+ if (this.options.title || this.options.closeButton) {
+ this.toolbar = this.tooltip.appendChild(new Element('div', { 'class' : 'toolbar' }));
+ this.title = this.toolbar.appendChild(new Element('div', { 'class' : 'title' }).update(this.options.title || ' '));
+ }
+
+ this.tooltip.insert(this.tip);
+ document.body.appendChild(this.wrapper);
+
+ // fixate elements for better positioning and effects
+ var fixate = (this.options.effect) ? [this.wrapper, this.effectWrapper]: [this.wrapper];
+ if (Tips.fixIE) fixate.push(this.iframeShim);
+
+ // fix width
+ var fixedWidth = this.wrapper.getWidth();
+ fixate.invoke('setStyle', { width: fixedWidth + 'px' });
+
+ // make toolbar width fixed
+ if(this.toolbar) {
+ this.wrapper.setStyle({ visibility : 'hidden' }).show();
+ this.toolbar.setStyle({ width: this.toolbar.getWidth() + 'px'});
+ this.wrapper.hide().setStyle({ visibility : 'visible' });
+ }
+
+ // add close button
+ if (this.closeButton)
+ this.title.insert({ top: this.closeButton }).insert(new Element('div').setStyle({ clear: 'both' }));
+
+ var fixedHeight = this.wrapper.getHeight();
+ fixate.invoke('setStyle', { width: fixedWidth + 'px', height: fixedHeight + 'px' });
+
+ this[this.options.effect ? wrapper : 'tooltip'].hide();
+ },
+
+ activate: function() {
+ this.eventShow = this.showDelayed.bindAsEventListener(this);
+ this.eventHide = this.hide.bindAsEventListener(this);
+
+ // if fixed use mouseover instead of mousemove for less event calls
+ if (this.options.fixed && this.options.showOn == 'mousemove') this.options.showOn = 'mouseover';
+
+ if(this.options.showOn == this.options.hideOn) {
+ this.eventToggle = this.toggle.bindAsEventListener(this);
+ this.element.observe(this.options.showOn, this.eventToggle);
+ }
+
+ var hideOptions = {
+ 'element': this.eventToggle ? [] : [this.element],
+ 'target': this.eventToggle ? [] : [this.target],
+ 'tip': this.eventToggle ? [] : [this.wrapper],
+ 'closeButton': [],
+ 'none': []
+ };
+ var el = this.options.hideOn.element;
+ this.hideElement = el || (!this.options.hideOn ? 'none' : 'element');
+ this.hideTargets = hideOptions[this.hideElement];
+ if (!this.hideTargets && el && Object.isString(el)) this.hideTargets = this.tip.select(el);
+
+ var realEvent = {'mouseenter': 'mouseover', 'mouseleave': 'mouseout'};
+ $w('show hide').each(function(e) {
+ var E = e.capitalize();
+ var event = (this.options[e + 'On'].event || this.options[e + 'On']);
+ this[e + 'Action'] = event;
+ if (['mouseenter', 'mouseleave', 'mouseover', 'mouseout'].include(event)) {
+ this[e + 'Action'] = (Tips.useEvent[event] || event);
+ this['event' + E] = Prototip.capture(this['event' + E]);
+ }
+ }.bind(this));
+
+ if (!this.eventToggle) this.element.observe(this.options.showOn, this.eventShow);
+ if (this.hideTargets) this.hideTargets.invoke('observe', this.hideAction, this.eventHide);
+
+ // add postion observer to moving showOn click tips
+ if (!this.options.fixed && this.options.showOn == 'click') {
+ this.eventPosition = this.position.bindAsEventListener(this);
+ this.element.observe('mousemove', this.eventPosition);
+ }
+
+ // close button
+ this.buttonEvent = this.hide.wrap(function(proceed, event) {
+ event.stop();
+ proceed(event);
+ }).bindAsEventListener(this);
+ if (this.closeButton) this.closeButton.observe('click', this.buttonEvent);
+
+ // delay timeout
+ if (this.options.showOn != 'click' && (this.hideElement != 'element')) {
+ this.eventCheckDelay = Prototip.capture(function() {
+ this.clearTimer('show');
+ }).bindAsEventListener(this);
+ this.element.observe(Tips.useEvent['mouseout'], this.eventCheckDelay);
+ }
+
+ // activity (hideAfter, raise)
+ var elements = [this.element, this.wrapper];
+ this.activityEnter = Prototip.capture(function() {
+ Tips.raise(this.wrapper);
+ this.cancelHideAfter();
+ }).bindAsEventListener(this);
+ this.activityLeave = Prototip.capture(this.hideAfter).bindAsEventListener(this);
+ elements.invoke('observe', Tips.useEvent['mouseover'], this.activityEnter);
+ elements.invoke('observe', Tips.useEvent['mouseout'], this.activityLeave);
+ },
+
+ deactivate: function() {
+ if(this.options.showOn == this.options.hideOn)
+ this.element.stopObserving(this.options.showOn, this.eventToggle);
+ else {
+ this.element.stopObserving(this.options.showOn, this.eventShow);
+ if (this.hideTargets) this.hideTargets.invoke('stopObserving');
+ }
+
+ if (this.eventPosition) this.element.stopObserving('mousemove', this.eventPosition);
+ if (this.closeButton) this.closeButton.stopObserving();
+ if (this.eventCheckDelay) this.element.stopObserving('mouseout', this.eventCheckDelay);
+ this.wrapper.stopObserving();
+ this.element.stopObserving(Tips.useEvent['mouseover'], this.activityEnter);
+ this.element.stopObserving(Tips.useEvent['mouseout'], this.activityLeave);
+ },
+
+ showDelayed: function(event) {
+ if (!this.tooltip) this.build();
+ this.position(event); // follow mouse
+ if (this.wrapper.visible()) return;
+
+ this.clearTimer('show');
+ this.showTimer = this.show.bind(this).delay(this.options.delay);
+ },
+
+ clearTimer: function(timer) {
+ if (this[timer + 'Timer']) clearTimeout(this[timer + 'Timer']);
+ },
+
+ show: function() {
+ if (!this.tooltip) this.build();
+ if (this.wrapper.visible() && this.options.effect != 'appear') return;
+
+ if (Tips.fixIE) this.iframeShim.show();
+ Tips.addVisibile(this.wrapper);
+ this.wrapper.show();
+ if (!this.options.effect) this.tooltip.show();
+ else {
+ if (this.activeEffect) Effect.Queues.get(this.queue.scope).remove(this.activeEffect);
+ this.activeEffect = Effect[Effect.PAIRS[this.options.effect][0]](this.effectWrapper,
+ { duration: this.options.duration, queue: this.queue});
+ }
+ },
+
+ hideAfter: function(event) {
+ if (!this.options.hideAfter) return;
+ this.cancelHideAfter();
+ this.hideAfterTimer = this.hide.bind(this).delay(this.options.hideAfter);
+ },
+
+ cancelHideAfter: function() {
+ if (this.options.hideAfter) this.clearTimer('hideAfter');
+ },
+
+ hide: function() {
+ this.clearTimer('show');
+ if(!this.wrapper.visible()) return;
+
+ if (!this.options.effect) {
+ if (Tips.fixIE) this.iframeShim.hide();
+ this.tooltip.hide();
+ this.wrapper.hide();
+ Tips.removeVisible(this.wrapper);
+ }
+ else {
+ if (this.activeEffect) Effect.Queues.get(this.queue.scope).remove(this.activeEffect);
+ this.activeEffect = Effect[Effect.PAIRS[this.options.effect][1]](this.effectWrapper,
+ { duration: this.options.duration, queue: this.queue, afterFinish: function() {
+ if (Tips.fixIE) this.iframeShim.hide();
+ this.wrapper.hide();
+ Tips.removeVisible(this.wrapper);
+ }.bind(this)});
+ }
+ },
+
+ toggle: function(event) {
+ if (this.wrapper && this.wrapper.visible()) this.hide(event);
+ else this.showDelayed(event);
+ },
+
+ position: function(event) {
+ Tips.raise(this.wrapper);
+
+ var offset = {left: this.options.offset.x, top: this.options.offset.y};
+ var targetPosition = Position.cumulativeOffset(this.target);
+ var tipd = this.wrapper.getDimensions();
+
+ if (event)
+ var pos = { left: (this.options.fixed) ? targetPosition[0] : Event.pointerX(event),
+ top: (this.options.fixed) ? targetPosition[1] : Event.pointerY(event) };
+ else
+ var pos = { left: targetPosition[0], top: targetPosition[1] };
+
+ // add offsets
+ pos.left += offset.left;
+ pos.top += offset.top;
+
+ if (this.options.hook) {
+ var dims = {target: this.target.getDimensions(), tip: tipd}
+ var hooks = {target: Position.cumulativeOffset(this.target), tip: Position.cumulativeOffset(this.target)}
+
+ for (var z in hooks) {
+ switch (this.options.hook[z]) {
+ case 'topRight':
+ hooks[z][0] += dims[z].width;
+ break;
+ case 'topMiddle':
+ hooks[z][0] += (dims[z].width / 2);
+ break;
+ case 'rightMiddle':
+ hooks[z][0] += dims[z].width;
+ hooks[z][1] += (dims[z].height / 2);
+ break;
+ case 'bottomLeft':
+ hooks[z][1] += dims[z].height;
+ break;
+ case 'bottomRight':
+ hooks[z][0] += dims[z].width;
+ hooks[z][1] += dims[z].height;
+ break;
+ case 'bottomMiddle':
+ hooks[z][0] += (dims[z].width / 2);
+ hooks[z][1] += dims[z].height;
+ break;
+ case 'leftMiddle':
+ hooks[z][1] += (dims[z].height / 2);
+ break;
+ }
+ }
+
+ // move based on hooks
+ pos.left += -1*(hooks.tip[0] - hooks.target[0]);
+ pos.top += -1*(hooks.tip[1] - hooks.target[1]);
+ }
+
+ // move tooltip when there is a different target or when we don't have a event to position to
+ if ((!this.options.fixed && this.element !== this.target) || !event) {
+ var elementPosition = Position.cumulativeOffset(this.element);
+ pos.left += -1*(elementPosition[0] - targetPosition[0]);
+ pos.top += -1*(elementPosition[1] - targetPosition[1]);
+ }
+
+ if (!this.options.fixed && this.options.viewport) {
+ var scroll = document.viewport.getScrollOffsets();
+ var viewport = Prototip.viewport.getDimensions();
+ var pair = {left: 'width', top: 'height'};
+
+ for(var z in pair) {
+ if ((pos[z] + tipd[pair[z]] - scroll[z]) > viewport[pair[z]])
+ pos[z] = pos[z] - tipd[pair[z]] - 2*offset[z];
+ }
+ }
+
+ // Ensure that the tooltip does not render off screen left edge
+ if ( pos.left < 0 ) {
+ pos.left = 0;
+ }
+
+ var setPos = { left: pos.left + 'px', top: pos.top + 'px' };
+ this.wrapper.setStyle(setPos);
+ if (Tips.fixIE) this.iframeShim.setStyle(setPos);
+ }
+});
+
+Prototip.start();
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/prototype.js b/abs/core-testing/local-website/htdocs/linhes/js/prototype.js
new file mode 100644
index 0000000..dfe8ab4
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/prototype.js
@@ -0,0 +1,4320 @@
+/* Prototype JavaScript framework, version 1.6.0.3
+ * (c) 2005-2008 Sam Stephenson
+ *
+ * Prototype is freely distributable under the terms of an MIT-style license.
+ * For details, see the Prototype web site: http://www.prototypejs.org/
+ *
+ *--------------------------------------------------------------------------*/
+
+var Prototype = {
+ Version: '1.6.0.3',
+
+ Browser: {
+ IE: !!(window.attachEvent &&
+ navigator.userAgent.indexOf('Opera') === -1),
+ Opera: navigator.userAgent.indexOf('Opera') > -1,
+ WebKit: navigator.userAgent.indexOf('AppleWebKit/') > -1,
+ Gecko: navigator.userAgent.indexOf('Gecko') > -1 &&
+ navigator.userAgent.indexOf('KHTML') === -1,
+ MobileSafari: !!navigator.userAgent.match(/Apple.*Mobile.*Safari/)
+ },
+
+ BrowserFeatures: {
+ XPath: !!document.evaluate,
+ SelectorsAPI: !!document.querySelector,
+ ElementExtensions: !!window.HTMLElement,
+ SpecificElementExtensions:
+ document.createElement('div')['__proto__'] &&
+ document.createElement('div')['__proto__'] !==
+ document.createElement('form')['__proto__']
+ },
+
+ ScriptFragment: '<script[^>]*>([\\S\\s]*?)<\/script>',
+ JSONFilter: /^\/\*-secure-([\s\S]*)\*\/\s*$/,
+
+ emptyFunction: function() { },
+ K: function(x) { return x }
+};
+
+if (Prototype.Browser.MobileSafari)
+ Prototype.BrowserFeatures.SpecificElementExtensions = false;
+
+
+/* Based on Alex Arnell's inheritance implementation. */
+var Class = {
+ create: function() {
+ var parent = null, properties = $A(arguments);
+ if (Object.isFunction(properties[0]))
+ parent = properties.shift();
+
+ function klass() {
+ this.initialize.apply(this, arguments);
+ }
+
+ Object.extend(klass, Class.Methods);
+ klass.superclass = parent;
+ klass.subclasses = [];
+
+ if (parent) {
+ var subclass = function() { };
+ subclass.prototype = parent.prototype;
+ klass.prototype = new subclass;
+ parent.subclasses.push(klass);
+ }
+
+ for (var i = 0; i < properties.length; i++)
+ klass.addMethods(properties[i]);
+
+ if (!klass.prototype.initialize)
+ klass.prototype.initialize = Prototype.emptyFunction;
+
+ klass.prototype.constructor = klass;
+
+ return klass;
+ }
+};
+
+Class.Methods = {
+ addMethods: function(source) {
+ var ancestor = this.superclass && this.superclass.prototype;
+ var properties = Object.keys(source);
+
+ if (!Object.keys({ toString: true }).length)
+ properties.push("toString", "valueOf");
+
+ for (var i = 0, length = properties.length; i < length; i++) {
+ var property = properties[i], value = source[property];
+ if (ancestor && Object.isFunction(value) &&
+ value.argumentNames().first() == "$super") {
+ var method = value;
+ value = (function(m) {
+ return function() { return ancestor[m].apply(this, arguments) };
+ })(property).wrap(method);
+
+ value.valueOf = method.valueOf.bind(method);
+ value.toString = method.toString.bind(method);
+ }
+ this.prototype[property] = value;
+ }
+
+ return this;
+ }
+};
+
+var Abstract = { };
+
+Object.extend = function(destination, source) {
+ for (var property in source)
+ destination[property] = source[property];
+ return destination;
+};
+
+Object.extend(Object, {
+ inspect: function(object) {
+ try {
+ if (Object.isUndefined(object)) return 'undefined';
+ if (object === null) return 'null';
+ return object.inspect ? object.inspect() : String(object);
+ } catch (e) {
+ if (e instanceof RangeError) return '...';
+ throw e;
+ }
+ },
+
+ toJSON: function(object) {
+ var type = typeof object;
+ switch (type) {
+ case 'undefined':
+ case 'function':
+ case 'unknown': return;
+ case 'boolean': return object.toString();
+ }
+
+ if (object === null) return 'null';
+ if (object.toJSON) return object.toJSON();
+ if (Object.isElement(object)) return;
+
+ var results = [];
+ for (var property in object) {
+ var value = Object.toJSON(object[property]);
+ if (!Object.isUndefined(value))
+ results.push(property.toJSON() + ': ' + value);
+ }
+
+ return '{' + results.join(', ') + '}';
+ },
+
+ toQueryString: function(object) {
+ return $H(object).toQueryString();
+ },
+
+ toHTML: function(object) {
+ return object && object.toHTML ? object.toHTML() : String.interpret(object);
+ },
+
+ keys: function(object) {
+ var keys = [];
+ for (var property in object)
+ keys.push(property);
+ return keys;
+ },
+
+ values: function(object) {
+ var values = [];
+ for (var property in object)
+ values.push(object[property]);
+ return values;
+ },
+
+ clone: function(object) {
+ return Object.extend({ }, object);
+ },
+
+ isElement: function(object) {
+ return !!(object && object.nodeType == 1);
+ },
+
+ isArray: function(object) {
+ return object != null && typeof object == "object" &&
+ 'splice' in object && 'join' in object;
+ },
+
+ isHash: function(object) {
+ return object instanceof Hash;
+ },
+
+ isFunction: function(object) {
+ return typeof object == "function";
+ },
+
+ isString: function(object) {
+ return typeof object == "string";
+ },
+
+ isNumber: function(object) {
+ return typeof object == "number";
+ },
+
+ isUndefined: function(object) {
+ return typeof object == "undefined";
+ }
+});
+
+Object.extend(Function.prototype, {
+ argumentNames: function() {
+ var names = this.toString().match(/^[\s\(]*function[^(]*\(([^\)]*)\)/)[1]
+ .replace(/\s+/g, '').split(',');
+ return names.length == 1 && !names[0] ? [] : names;
+ },
+
+ bind: function() {
+ if (arguments.length < 2 && Object.isUndefined(arguments[0])) return this;
+ var __method = this, args = $A(arguments), object = args.shift();
+ return function() {
+ return __method.apply(object, args.concat($A(arguments)));
+ }
+ },
+
+ bindAsEventListener: function() {
+ var __method = this, args = $A(arguments), object = args.shift();
+ return function(event) {
+ return __method.apply(object, [event || window.event].concat(args));
+ }
+ },
+
+ curry: function() {
+ if (!arguments.length) return this;
+ var __method = this, args = $A(arguments);
+ return function() {
+ return __method.apply(this, args.concat($A(arguments)));
+ }
+ },
+
+ delay: function() {
+ var __method = this, args = $A(arguments), timeout = args.shift() * 1000;
+ return window.setTimeout(function() {
+ return __method.apply(__method, args);
+ }, timeout);
+ },
+
+ defer: function() {
+ var args = [0.01].concat($A(arguments));
+ return this.delay.apply(this, args);
+ },
+
+ wrap: function(wrapper) {
+ var __method = this;
+ return function() {
+ return wrapper.apply(this, [__method.bind(this)].concat($A(arguments)));
+ }
+ },
+
+ methodize: function() {
+ if (this._methodized) return this._methodized;
+ var __method = this;
+ return this._methodized = function() {
+ return __method.apply(null, [this].concat($A(arguments)));
+ };
+ }
+});
+
+Date.prototype.toJSON = function() {
+ return '"' + this.getUTCFullYear() + '-' +
+ (this.getUTCMonth() + 1).toPaddedString(2) + '-' +
+ this.getUTCDate().toPaddedString(2) + 'T' +
+ this.getUTCHours().toPaddedString(2) + ':' +
+ this.getUTCMinutes().toPaddedString(2) + ':' +
+ this.getUTCSeconds().toPaddedString(2) + 'Z"';
+};
+
+var Try = {
+ these: function() {
+ var returnValue;
+
+ for (var i = 0, length = arguments.length; i < length; i++) {
+ var lambda = arguments[i];
+ try {
+ returnValue = lambda();
+ break;
+ } catch (e) { }
+ }
+
+ return returnValue;
+ }
+};
+
+RegExp.prototype.match = RegExp.prototype.test;
+
+RegExp.escape = function(str) {
+ return String(str).replace(/([.*+?^=!:${}()|[\]\/\\])/g, '\\$1');
+};
+
+/*--------------------------------------------------------------------------*/
+
+var PeriodicalExecuter = Class.create({
+ initialize: function(callback, frequency) {
+ this.callback = callback;
+ this.frequency = frequency;
+ this.currentlyExecuting = false;
+
+ this.registerCallback();
+ },
+
+ registerCallback: function() {
+ this.timer = setInterval(this.onTimerEvent.bind(this), this.frequency * 1000);
+ },
+
+ execute: function() {
+ this.callback(this);
+ },
+
+ stop: function() {
+ if (!this.timer) return;
+ clearInterval(this.timer);
+ this.timer = null;
+ },
+
+ onTimerEvent: function() {
+ if (!this.currentlyExecuting) {
+ try {
+ this.currentlyExecuting = true;
+ this.execute();
+ } finally {
+ this.currentlyExecuting = false;
+ }
+ }
+ }
+});
+Object.extend(String, {
+ interpret: function(value) {
+ return value == null ? '' : String(value);
+ },
+ specialChar: {
+ '\b': '\\b',
+ '\t': '\\t',
+ '\n': '\\n',
+ '\f': '\\f',
+ '\r': '\\r',
+ '\\': '\\\\'
+ }
+});
+
+Object.extend(String.prototype, {
+ gsub: function(pattern, replacement) {
+ var result = '', source = this, match;
+ replacement = arguments.callee.prepareReplacement(replacement);
+
+ while (source.length > 0) {
+ if (match = source.match(pattern)) {
+ result += source.slice(0, match.index);
+ result += String.interpret(replacement(match));
+ source = source.slice(match.index + match[0].length);
+ } else {
+ result += source, source = '';
+ }
+ }
+ return result;
+ },
+
+ sub: function(pattern, replacement, count) {
+ replacement = this.gsub.prepareReplacement(replacement);
+ count = Object.isUndefined(count) ? 1 : count;
+
+ return this.gsub(pattern, function(match) {
+ if (--count < 0) return match[0];
+ return replacement(match);
+ });
+ },
+
+ scan: function(pattern, iterator) {
+ this.gsub(pattern, iterator);
+ return String(this);
+ },
+
+ truncate: function(length, truncation) {
+ length = length || 30;
+ truncation = Object.isUndefined(truncation) ? '...' : truncation;
+ return this.length > length ?
+ this.slice(0, length - truncation.length) + truncation : String(this);
+ },
+
+ strip: function() {
+ return this.replace(/^\s+/, '').replace(/\s+$/, '');
+ },
+
+ stripTags: function() {
+ return this.replace(/<\/?[^>]+>/gi, '');
+ },
+
+ stripScripts: function() {
+ return this.replace(new RegExp(Prototype.ScriptFragment, 'img'), '');
+ },
+
+ extractScripts: function() {
+ var matchAll = new RegExp(Prototype.ScriptFragment, 'img');
+ var matchOne = new RegExp(Prototype.ScriptFragment, 'im');
+ return (this.match(matchAll) || []).map(function(scriptTag) {
+ return (scriptTag.match(matchOne) || ['', ''])[1];
+ });
+ },
+
+ evalScripts: function() {
+ return this.extractScripts().map(function(script) { return eval(script) });
+ },
+
+ escapeHTML: function() {
+ var self = arguments.callee;
+ self.text.data = this;
+ return self.div.innerHTML;
+ },
+
+ unescapeHTML: function() {
+ var div = new Element('div');
+ div.innerHTML = this.stripTags();
+ return div.childNodes[0] ? (div.childNodes.length > 1 ?
+ $A(div.childNodes).inject('', function(memo, node) { return memo+node.nodeValue }) :
+ div.childNodes[0].nodeValue) : '';
+ },
+
+ toQueryParams: function(separator) {
+ var match = this.strip().match(/([^?#]*)(#.*)?$/);
+ if (!match) return { };
+
+ return match[1].split(separator || '&').inject({ }, function(hash, pair) {
+ if ((pair = pair.split('='))[0]) {
+ var key = decodeURIComponent(pair.shift());
+ var value = pair.length > 1 ? pair.join('=') : pair[0];
+ if (value != undefined) value = decodeURIComponent(value);
+
+ if (key in hash) {
+ if (!Object.isArray(hash[key])) hash[key] = [hash[key]];
+ hash[key].push(value);
+ }
+ else hash[key] = value;
+ }
+ return hash;
+ });
+ },
+
+ toArray: function() {
+ return this.split('');
+ },
+
+ succ: function() {
+ return this.slice(0, this.length - 1) +
+ String.fromCharCode(this.charCodeAt(this.length - 1) + 1);
+ },
+
+ times: function(count) {
+ return count < 1 ? '' : new Array(count + 1).join(this);
+ },
+
+ camelize: function() {
+ var parts = this.split('-'), len = parts.length;
+ if (len == 1) return parts[0];
+
+ var camelized = this.charAt(0) == '-'
+ ? parts[0].charAt(0).toUpperCase() + parts[0].substring(1)
+ : parts[0];
+
+ for (var i = 1; i < len; i++)
+ camelized += parts[i].charAt(0).toUpperCase() + parts[i].substring(1);
+
+ return camelized;
+ },
+
+ capitalize: function() {
+ return this.charAt(0).toUpperCase() + this.substring(1).toLowerCase();
+ },
+
+ underscore: function() {
+ return this.gsub(/::/, '/').gsub(/([A-Z]+)([A-Z][a-z])/,'#{1}_#{2}').gsub(/([a-z\d])([A-Z])/,'#{1}_#{2}').gsub(/-/,'_').toLowerCase();
+ },
+
+ dasherize: function() {
+ return this.gsub(/_/,'-');
+ },
+
+ inspect: function(useDoubleQuotes) {
+ var escapedString = this.gsub(/[\x00-\x1f\\]/, function(match) {
+ var character = String.specialChar[match[0]];
+ return character ? character : '\\u00' + match[0].charCodeAt().toPaddedString(2, 16);
+ });
+ if (useDoubleQuotes) return '"' + escapedString.replace(/"/g, '\\"') + '"';
+ return "'" + escapedString.replace(/'/g, '\\\'') + "'";
+ },
+
+ toJSON: function() {
+ return this.inspect(true);
+ },
+
+ unfilterJSON: function(filter) {
+ return this.sub(filter || Prototype.JSONFilter, '#{1}');
+ },
+
+ isJSON: function() {
+ var str = this;
+ if (str.blank()) return false;
+ str = this.replace(/\\./g, '@').replace(/"[^"\\\n\r]*"/g, '');
+ return (/^[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]*$/).test(str);
+ },
+
+ evalJSON: function(sanitize) {
+ var json = this.unfilterJSON();
+ try {
+ if (!sanitize || json.isJSON()) return eval('(' + json + ')');
+ } catch (e) { }
+ throw new SyntaxError('Badly formed JSON string: ' + this.inspect());
+ },
+
+ include: function(pattern) {
+ return this.indexOf(pattern) > -1;
+ },
+
+ startsWith: function(pattern) {
+ return this.indexOf(pattern) === 0;
+ },
+
+ endsWith: function(pattern) {
+ var d = this.length - pattern.length;
+ return d >= 0 && this.lastIndexOf(pattern) === d;
+ },
+
+ empty: function() {
+ return this == '';
+ },
+
+ blank: function() {
+ return /^\s*$/.test(this);
+ },
+
+ interpolate: function(object, pattern) {
+ return new Template(this, pattern).evaluate(object);
+ }
+});
+
+if (Prototype.Browser.WebKit || Prototype.Browser.IE) Object.extend(String.prototype, {
+ escapeHTML: function() {
+ return this.replace(/&/g,'&amp;').replace(/</g,'&lt;').replace(/>/g,'&gt;');
+ },
+ unescapeHTML: function() {
+ return this.stripTags().replace(/&amp;/g,'&').replace(/&lt;/g,'<').replace(/&gt;/g,'>');
+ }
+});
+
+String.prototype.gsub.prepareReplacement = function(replacement) {
+ if (Object.isFunction(replacement)) return replacement;
+ var template = new Template(replacement);
+ return function(match) { return template.evaluate(match) };
+};
+
+String.prototype.parseQuery = String.prototype.toQueryParams;
+
+Object.extend(String.prototype.escapeHTML, {
+ div: document.createElement('div'),
+ text: document.createTextNode('')
+});
+
+String.prototype.escapeHTML.div.appendChild(String.prototype.escapeHTML.text);
+
+var Template = Class.create({
+ initialize: function(template, pattern) {
+ this.template = template.toString();
+ this.pattern = pattern || Template.Pattern;
+ },
+
+ evaluate: function(object) {
+ if (Object.isFunction(object.toTemplateReplacements))
+ object = object.toTemplateReplacements();
+
+ return this.template.gsub(this.pattern, function(match) {
+ if (object == null) return '';
+
+ var before = match[1] || '';
+ if (before == '\\') return match[2];
+
+ var ctx = object, expr = match[3];
+ var pattern = /^([^.[]+|\[((?:.*?[^\\])?)\])(\.|\[|$)/;
+ match = pattern.exec(expr);
+ if (match == null) return before;
+
+ while (match != null) {
+ var comp = match[1].startsWith('[') ? match[2].gsub('\\\\]', ']') : match[1];
+ ctx = ctx[comp];
+ if (null == ctx || '' == match[3]) break;
+ expr = expr.substring('[' == match[3] ? match[1].length : match[0].length);
+ match = pattern.exec(expr);
+ }
+
+ return before + String.interpret(ctx);
+ });
+ }
+});
+Template.Pattern = /(^|.|\r|\n)(#\{(.*?)\})/;
+
+var $break = { };
+
+var Enumerable = {
+ each: function(iterator, context) {
+ var index = 0;
+ try {
+ this._each(function(value) {
+ iterator.call(context, value, index++);
+ });
+ } catch (e) {
+ if (e != $break) throw e;
+ }
+ return this;
+ },
+
+ eachSlice: function(number, iterator, context) {
+ var index = -number, slices = [], array = this.toArray();
+ if (number < 1) return array;
+ while ((index += number) < array.length)
+ slices.push(array.slice(index, index+number));
+ return slices.collect(iterator, context);
+ },
+
+ all: function(iterator, context) {
+ iterator = iterator || Prototype.K;
+ var result = true;
+ this.each(function(value, index) {
+ result = result && !!iterator.call(context, value, index);
+ if (!result) throw $break;
+ });
+ return result;
+ },
+
+ any: function(iterator, context) {
+ iterator = iterator || Prototype.K;
+ var result = false;
+ this.each(function(value, index) {
+ if (result = !!iterator.call(context, value, index))
+ throw $break;
+ });
+ return result;
+ },
+
+ collect: function(iterator, context) {
+ iterator = iterator || Prototype.K;
+ var results = [];
+ this.each(function(value, index) {
+ results.push(iterator.call(context, value, index));
+ });
+ return results;
+ },
+
+ detect: function(iterator, context) {
+ var result;
+ this.each(function(value, index) {
+ if (iterator.call(context, value, index)) {
+ result = value;
+ throw $break;
+ }
+ });
+ return result;
+ },
+
+ findAll: function(iterator, context) {
+ var results = [];
+ this.each(function(value, index) {
+ if (iterator.call(context, value, index))
+ results.push(value);
+ });
+ return results;
+ },
+
+ grep: function(filter, iterator, context) {
+ iterator = iterator || Prototype.K;
+ var results = [];
+
+ if (Object.isString(filter))
+ filter = new RegExp(filter);
+
+ this.each(function(value, index) {
+ if (filter.match(value))
+ results.push(iterator.call(context, value, index));
+ });
+ return results;
+ },
+
+ include: function(object) {
+ if (Object.isFunction(this.indexOf))
+ if (this.indexOf(object) != -1) return true;
+
+ var found = false;
+ this.each(function(value) {
+ if (value == object) {
+ found = true;
+ throw $break;
+ }
+ });
+ return found;
+ },
+
+ inGroupsOf: function(number, fillWith) {
+ fillWith = Object.isUndefined(fillWith) ? null : fillWith;
+ return this.eachSlice(number, function(slice) {
+ while(slice.length < number) slice.push(fillWith);
+ return slice;
+ });
+ },
+
+ inject: function(memo, iterator, context) {
+ this.each(function(value, index) {
+ memo = iterator.call(context, memo, value, index);
+ });
+ return memo;
+ },
+
+ invoke: function(method) {
+ var args = $A(arguments).slice(1);
+ return this.map(function(value) {
+ return value[method].apply(value, args);
+ });
+ },
+
+ max: function(iterator, context) {
+ iterator = iterator || Prototype.K;
+ var result;
+ this.each(function(value, index) {
+ value = iterator.call(context, value, index);
+ if (result == null || value >= result)
+ result = value;
+ });
+ return result;
+ },
+
+ min: function(iterator, context) {
+ iterator = iterator || Prototype.K;
+ var result;
+ this.each(function(value, index) {
+ value = iterator.call(context, value, index);
+ if (result == null || value < result)
+ result = value;
+ });
+ return result;
+ },
+
+ partition: function(iterator, context) {
+ iterator = iterator || Prototype.K;
+ var trues = [], falses = [];
+ this.each(function(value, index) {
+ (iterator.call(context, value, index) ?
+ trues : falses).push(value);
+ });
+ return [trues, falses];
+ },
+
+ pluck: function(property) {
+ var results = [];
+ this.each(function(value) {
+ results.push(value[property]);
+ });
+ return results;
+ },
+
+ reject: function(iterator, context) {
+ var results = [];
+ this.each(function(value, index) {
+ if (!iterator.call(context, value, index))
+ results.push(value);
+ });
+ return results;
+ },
+
+ sortBy: function(iterator, context) {
+ return this.map(function(value, index) {
+ return {
+ value: value,
+ criteria: iterator.call(context, value, index)
+ };
+ }).sort(function(left, right) {
+ var a = left.criteria, b = right.criteria;
+ return a < b ? -1 : a > b ? 1 : 0;
+ }).pluck('value');
+ },
+
+ toArray: function() {
+ return this.map();
+ },
+
+ zip: function() {
+ var iterator = Prototype.K, args = $A(arguments);
+ if (Object.isFunction(args.last()))
+ iterator = args.pop();
+
+ var collections = [this].concat(args).map($A);
+ return this.map(function(value, index) {
+ return iterator(collections.pluck(index));
+ });
+ },
+
+ size: function() {
+ return this.toArray().length;
+ },
+
+ inspect: function() {
+ return '#<Enumerable:' + this.toArray().inspect() + '>';
+ }
+};
+
+Object.extend(Enumerable, {
+ map: Enumerable.collect,
+ find: Enumerable.detect,
+ select: Enumerable.findAll,
+ filter: Enumerable.findAll,
+ member: Enumerable.include,
+ entries: Enumerable.toArray,
+ every: Enumerable.all,
+ some: Enumerable.any
+});
+function $A(iterable) {
+ if (!iterable) return [];
+ if (iterable.toArray) return iterable.toArray();
+ var length = iterable.length || 0, results = new Array(length);
+ while (length--) results[length] = iterable[length];
+ return results;
+}
+
+if (Prototype.Browser.WebKit) {
+ $A = function(iterable) {
+ if (!iterable) return [];
+ // In Safari, only use the `toArray` method if it's not a NodeList.
+ // A NodeList is a function, has an function `item` property, and a numeric
+ // `length` property. Adapted from Google Doctype.
+ if (!(typeof iterable === 'function' && typeof iterable.length ===
+ 'number' && typeof iterable.item === 'function') && iterable.toArray)
+ return iterable.toArray();
+ var length = iterable.length || 0, results = new Array(length);
+ while (length--) results[length] = iterable[length];
+ return results;
+ };
+}
+
+Array.from = $A;
+
+Object.extend(Array.prototype, Enumerable);
+
+if (!Array.prototype._reverse) Array.prototype._reverse = Array.prototype.reverse;
+
+Object.extend(Array.prototype, {
+ _each: function(iterator) {
+ for (var i = 0, length = this.length; i < length; i++)
+ iterator(this[i]);
+ },
+
+ clear: function() {
+ this.length = 0;
+ return this;
+ },
+
+ first: function() {
+ return this[0];
+ },
+
+ last: function() {
+ return this[this.length - 1];
+ },
+
+ compact: function() {
+ return this.select(function(value) {
+ return value != null;
+ });
+ },
+
+ flatten: function() {
+ return this.inject([], function(array, value) {
+ return array.concat(Object.isArray(value) ?
+ value.flatten() : [value]);
+ });
+ },
+
+ without: function() {
+ var values = $A(arguments);
+ return this.select(function(value) {
+ return !values.include(value);
+ });
+ },
+
+ reverse: function(inline) {
+ return (inline !== false ? this : this.toArray())._reverse();
+ },
+
+ reduce: function() {
+ return this.length > 1 ? this : this[0];
+ },
+
+ uniq: function(sorted) {
+ return this.inject([], function(array, value, index) {
+ if (0 == index || (sorted ? array.last() != value : !array.include(value)))
+ array.push(value);
+ return array;
+ });
+ },
+
+ intersect: function(array) {
+ return this.uniq().findAll(function(item) {
+ return array.detect(function(value) { return item === value });
+ });
+ },
+
+ clone: function() {
+ return [].concat(this);
+ },
+
+ size: function() {
+ return this.length;
+ },
+
+ inspect: function() {
+ return '[' + this.map(Object.inspect).join(', ') + ']';
+ },
+
+ toJSON: function() {
+ var results = [];
+ this.each(function(object) {
+ var value = Object.toJSON(object);
+ if (!Object.isUndefined(value)) results.push(value);
+ });
+ return '[' + results.join(', ') + ']';
+ }
+});
+
+// use native browser JS 1.6 implementation if available
+if (Object.isFunction(Array.prototype.forEach))
+ Array.prototype._each = Array.prototype.forEach;
+
+if (!Array.prototype.indexOf) Array.prototype.indexOf = function(item, i) {
+ i || (i = 0);
+ var length = this.length;
+ if (i < 0) i = length + i;
+ for (; i < length; i++)
+ if (this[i] === item) return i;
+ return -1;
+};
+
+if (!Array.prototype.lastIndexOf) Array.prototype.lastIndexOf = function(item, i) {
+ i = isNaN(i) ? this.length : (i < 0 ? this.length + i : i) + 1;
+ var n = this.slice(0, i).reverse().indexOf(item);
+ return (n < 0) ? n : i - n - 1;
+};
+
+Array.prototype.toArray = Array.prototype.clone;
+
+function $w(string) {
+ if (!Object.isString(string)) return [];
+ string = string.strip();
+ return string ? string.split(/\s+/) : [];
+}
+
+if (Prototype.Browser.Opera){
+ Array.prototype.concat = function() {
+ var array = [];
+ for (var i = 0, length = this.length; i < length; i++) array.push(this[i]);
+ for (var i = 0, length = arguments.length; i < length; i++) {
+ if (Object.isArray(arguments[i])) {
+ for (var j = 0, arrayLength = arguments[i].length; j < arrayLength; j++)
+ array.push(arguments[i][j]);
+ } else {
+ array.push(arguments[i]);
+ }
+ }
+ return array;
+ };
+}
+Object.extend(Number.prototype, {
+ toColorPart: function() {
+ return this.toPaddedString(2, 16);
+ },
+
+ succ: function() {
+ return this + 1;
+ },
+
+ times: function(iterator, context) {
+ $R(0, this, true).each(iterator, context);
+ return this;
+ },
+
+ toPaddedString: function(length, radix) {
+ var string = this.toString(radix || 10);
+ return '0'.times(length - string.length) + string;
+ },
+
+ toJSON: function() {
+ return isFinite(this) ? this.toString() : 'null';
+ }
+});
+
+$w('abs round ceil floor').each(function(method){
+ Number.prototype[method] = Math[method].methodize();
+});
+function $H(object) {
+ return new Hash(object);
+};
+
+var Hash = Class.create(Enumerable, (function() {
+
+ function toQueryPair(key, value) {
+ if (Object.isUndefined(value)) return key;
+ return key + '=' + encodeURIComponent(String.interpret(value));
+ }
+
+ return {
+ initialize: function(object) {
+ this._object = Object.isHash(object) ? object.toObject() : Object.clone(object);
+ },
+
+ _each: function(iterator) {
+ for (var key in this._object) {
+ var value = this._object[key], pair = [key, value];
+ pair.key = key;
+ pair.value = value;
+ iterator(pair);
+ }
+ },
+
+ set: function(key, value) {
+ return this._object[key] = value;
+ },
+
+ get: function(key) {
+ // simulating poorly supported hasOwnProperty
+ if (this._object[key] !== Object.prototype[key])
+ return this._object[key];
+ },
+
+ unset: function(key) {
+ var value = this._object[key];
+ delete this._object[key];
+ return value;
+ },
+
+ toObject: function() {
+ return Object.clone(this._object);
+ },
+
+ keys: function() {
+ return this.pluck('key');
+ },
+
+ values: function() {
+ return this.pluck('value');
+ },
+
+ index: function(value) {
+ var match = this.detect(function(pair) {
+ return pair.value === value;
+ });
+ return match && match.key;
+ },
+
+ merge: function(object) {
+ return this.clone().update(object);
+ },
+
+ update: function(object) {
+ return new Hash(object).inject(this, function(result, pair) {
+ result.set(pair.key, pair.value);
+ return result;
+ });
+ },
+
+ toQueryString: function() {
+ return this.inject([], function(results, pair) {
+ var key = encodeURIComponent(pair.key), values = pair.value;
+
+ if (values && typeof values == 'object') {
+ if (Object.isArray(values))
+ return results.concat(values.map(toQueryPair.curry(key)));
+ } else results.push(toQueryPair(key, values));
+ return results;
+ }).join('&');
+ },
+
+ inspect: function() {
+ return '#<Hash:{' + this.map(function(pair) {
+ return pair.map(Object.inspect).join(': ');
+ }).join(', ') + '}>';
+ },
+
+ toJSON: function() {
+ return Object.toJSON(this.toObject());
+ },
+
+ clone: function() {
+ return new Hash(this);
+ }
+ }
+})());
+
+Hash.prototype.toTemplateReplacements = Hash.prototype.toObject;
+Hash.from = $H;
+var ObjectRange = Class.create(Enumerable, {
+ initialize: function(start, end, exclusive) {
+ this.start = start;
+ this.end = end;
+ this.exclusive = exclusive;
+ },
+
+ _each: function(iterator) {
+ var value = this.start;
+ while (this.include(value)) {
+ iterator(value);
+ value = value.succ();
+ }
+ },
+
+ include: function(value) {
+ if (value < this.start)
+ return false;
+ if (this.exclusive)
+ return value < this.end;
+ return value <= this.end;
+ }
+});
+
+var $R = function(start, end, exclusive) {
+ return new ObjectRange(start, end, exclusive);
+};
+
+var Ajax = {
+ getTransport: function() {
+ return Try.these(
+ function() {return new XMLHttpRequest()},
+ function() {return new ActiveXObject('Msxml2.XMLHTTP')},
+ function() {return new ActiveXObject('Microsoft.XMLHTTP')}
+ ) || false;
+ },
+
+ activeRequestCount: 0
+};
+
+Ajax.Responders = {
+ responders: [],
+
+ _each: function(iterator) {
+ this.responders._each(iterator);
+ },
+
+ register: function(responder) {
+ if (!this.include(responder))
+ this.responders.push(responder);
+ },
+
+ unregister: function(responder) {
+ this.responders = this.responders.without(responder);
+ },
+
+ dispatch: function(callback, request, transport, json) {
+ this.each(function(responder) {
+ if (Object.isFunction(responder[callback])) {
+ try {
+ responder[callback].apply(responder, [request, transport, json]);
+ } catch (e) { }
+ }
+ });
+ }
+};
+
+Object.extend(Ajax.Responders, Enumerable);
+
+Ajax.Responders.register({
+ onCreate: function() { Ajax.activeRequestCount++ },
+ onComplete: function() { Ajax.activeRequestCount-- }
+});
+
+Ajax.Base = Class.create({
+ initialize: function(options) {
+ this.options = {
+ method: 'post',
+ asynchronous: true,
+ contentType: 'application/x-www-form-urlencoded',
+ encoding: 'UTF-8',
+ parameters: '',
+ evalJSON: true,
+ evalJS: true
+ };
+ Object.extend(this.options, options || { });
+
+ this.options.method = this.options.method.toLowerCase();
+
+ if (Object.isString(this.options.parameters))
+ this.options.parameters = this.options.parameters.toQueryParams();
+ else if (Object.isHash(this.options.parameters))
+ this.options.parameters = this.options.parameters.toObject();
+ }
+});
+
+Ajax.Request = Class.create(Ajax.Base, {
+ _complete: false,
+
+ initialize: function($super, url, options) {
+ $super(options);
+ this.transport = Ajax.getTransport();
+ this.request(url);
+ },
+
+ request: function(url) {
+ this.url = url;
+ this.method = this.options.method;
+ var params = Object.clone(this.options.parameters);
+
+ if (!['get', 'post'].include(this.method)) {
+ // simulate other verbs over post
+ params['_method'] = this.method;
+ this.method = 'post';
+ }
+
+ this.parameters = params;
+
+ if (params = Object.toQueryString(params)) {
+ // when GET, append parameters to URL
+ if (this.method == 'get')
+ this.url += (this.url.include('?') ? '&' : '?') + params;
+ else if (/Konqueror|Safari|KHTML/.test(navigator.userAgent))
+ params += '&_=';
+ }
+
+ try {
+ var response = new Ajax.Response(this);
+ if (this.options.onCreate) this.options.onCreate(response);
+ Ajax.Responders.dispatch('onCreate', this, response);
+
+ this.transport.open(this.method.toUpperCase(), this.url,
+ this.options.asynchronous);
+
+ if (this.options.asynchronous) this.respondToReadyState.bind(this).defer(1);
+
+ this.transport.onreadystatechange = this.onStateChange.bind(this);
+ this.setRequestHeaders();
+
+ this.body = this.method == 'post' ? (this.options.postBody || params) : null;
+ this.transport.send(this.body);
+
+ /* Force Firefox to handle ready state 4 for synchronous requests */
+ if (!this.options.asynchronous && this.transport.overrideMimeType)
+ this.onStateChange();
+
+ }
+ catch (e) {
+ this.dispatchException(e);
+ }
+ },
+
+ onStateChange: function() {
+ var readyState = this.transport.readyState;
+ if (readyState > 1 && !((readyState == 4) && this._complete))
+ this.respondToReadyState(this.transport.readyState);
+ },
+
+ setRequestHeaders: function() {
+ var headers = {
+ 'X-Requested-With': 'XMLHttpRequest',
+ 'X-Prototype-Version': Prototype.Version,
+ 'Accept': 'text/javascript, text/html, application/xml, text/xml, */*'
+ };
+
+ if (this.method == 'post') {
+ headers['Content-type'] = this.options.contentType +
+ (this.options.encoding ? '; charset=' + this.options.encoding : '');
+
+ /* Force "Connection: close" for older Mozilla browsers to work
+ * around a bug where XMLHttpRequest sends an incorrect
+ * Content-length header. See Mozilla Bugzilla #246651.
+ */
+ if (this.transport.overrideMimeType &&
+ (navigator.userAgent.match(/Gecko\/(\d{4})/) || [0,2005])[1] < 2005)
+ headers['Connection'] = 'close';
+ }
+
+ // user-defined headers
+ if (typeof this.options.requestHeaders == 'object') {
+ var extras = this.options.requestHeaders;
+
+ if (Object.isFunction(extras.push))
+ for (var i = 0, length = extras.length; i < length; i += 2)
+ headers[extras[i]] = extras[i+1];
+ else
+ $H(extras).each(function(pair) { headers[pair.key] = pair.value });
+ }
+
+ for (var name in headers)
+ this.transport.setRequestHeader(name, headers[name]);
+ },
+
+ success: function() {
+ var status = this.getStatus();
+ return !status || (status >= 200 && status < 300);
+ },
+
+ getStatus: function() {
+ try {
+ return this.transport.status || 0;
+ } catch (e) { return 0 }
+ },
+
+ respondToReadyState: function(readyState) {
+ var state = Ajax.Request.Events[readyState], response = new Ajax.Response(this);
+
+ if (state == 'Complete') {
+ try {
+ this._complete = true;
+ (this.options['on' + response.status]
+ || this.options['on' + (this.success() ? 'Success' : 'Failure')]
+ || Prototype.emptyFunction)(response, response.headerJSON);
+ } catch (e) {
+ this.dispatchException(e);
+ }
+
+ var contentType = response.getHeader('Content-type');
+ if (this.options.evalJS == 'force'
+ || (this.options.evalJS && this.isSameOrigin() && contentType
+ && contentType.match(/^\s*(text|application)\/(x-)?(java|ecma)script(;.*)?\s*$/i)))
+ this.evalResponse();
+ }
+
+ try {
+ (this.options['on' + state] || Prototype.emptyFunction)(response, response.headerJSON);
+ Ajax.Responders.dispatch('on' + state, this, response, response.headerJSON);
+ } catch (e) {
+ this.dispatchException(e);
+ }
+
+ if (state == 'Complete') {
+ // avoid memory leak in MSIE: clean up
+ this.transport.onreadystatechange = Prototype.emptyFunction;
+ }
+ },
+
+ isSameOrigin: function() {
+ var m = this.url.match(/^\s*https?:\/\/[^\/]*/);
+ return !m || (m[0] == '#{protocol}//#{domain}#{port}'.interpolate({
+ protocol: location.protocol,
+ domain: document.domain,
+ port: location.port ? ':' + location.port : ''
+ }));
+ },
+
+ getHeader: function(name) {
+ try {
+ return this.transport.getResponseHeader(name) || null;
+ } catch (e) { return null }
+ },
+
+ evalResponse: function() {
+ try {
+ return eval((this.transport.responseText || '').unfilterJSON());
+ } catch (e) {
+ this.dispatchException(e);
+ }
+ },
+
+ dispatchException: function(exception) {
+ (this.options.onException || Prototype.emptyFunction)(this, exception);
+ Ajax.Responders.dispatch('onException', this, exception);
+ }
+});
+
+Ajax.Request.Events =
+ ['Uninitialized', 'Loading', 'Loaded', 'Interactive', 'Complete'];
+
+Ajax.Response = Class.create({
+ initialize: function(request){
+ this.request = request;
+ var transport = this.transport = request.transport,
+ readyState = this.readyState = transport.readyState;
+
+ if((readyState > 2 && !Prototype.Browser.IE) || readyState == 4) {
+ this.status = this.getStatus();
+ this.statusText = this.getStatusText();
+ this.responseText = String.interpret(transport.responseText);
+ this.headerJSON = this._getHeaderJSON();
+ }
+
+ if(readyState == 4) {
+ var xml = transport.responseXML;
+ this.responseXML = Object.isUndefined(xml) ? null : xml;
+ this.responseJSON = this._getResponseJSON();
+ }
+ },
+
+ status: 0,
+ statusText: '',
+
+ getStatus: Ajax.Request.prototype.getStatus,
+
+ getStatusText: function() {
+ try {
+ return this.transport.statusText || '';
+ } catch (e) { return '' }
+ },
+
+ getHeader: Ajax.Request.prototype.getHeader,
+
+ getAllHeaders: function() {
+ try {
+ return this.getAllResponseHeaders();
+ } catch (e) { return null }
+ },
+
+ getResponseHeader: function(name) {
+ return this.transport.getResponseHeader(name);
+ },
+
+ getAllResponseHeaders: function() {
+ return this.transport.getAllResponseHeaders();
+ },
+
+ _getHeaderJSON: function() {
+ var json = this.getHeader('X-JSON');
+ if (!json) return null;
+ json = decodeURIComponent(escape(json));
+ try {
+ return json.evalJSON(this.request.options.sanitizeJSON ||
+ !this.request.isSameOrigin());
+ } catch (e) {
+ this.request.dispatchException(e);
+ }
+ },
+
+ _getResponseJSON: function() {
+ var options = this.request.options;
+ if (!options.evalJSON || (options.evalJSON != 'force' &&
+ !(this.getHeader('Content-type') || '').include('application/json')) ||
+ this.responseText.blank())
+ return null;
+ try {
+ return this.responseText.evalJSON(options.sanitizeJSON ||
+ !this.request.isSameOrigin());
+ } catch (e) {
+ this.request.dispatchException(e);
+ }
+ }
+});
+
+Ajax.Updater = Class.create(Ajax.Request, {
+ initialize: function($super, container, url, options) {
+ this.container = {
+ success: (container.success || container),
+ failure: (container.failure || (container.success ? null : container))
+ };
+
+ options = Object.clone(options);
+ var onComplete = options.onComplete;
+ options.onComplete = (function(response, json) {
+ this.updateContent(response.responseText);
+ if (Object.isFunction(onComplete)) onComplete(response, json);
+ }).bind(this);
+
+ $super(url, options);
+ },
+
+ updateContent: function(responseText) {
+ var receiver = this.container[this.success() ? 'success' : 'failure'],
+ options = this.options;
+
+ if (!options.evalScripts) responseText = responseText.stripScripts();
+
+ if (receiver = $(receiver)) {
+ if (options.insertion) {
+ if (Object.isString(options.insertion)) {
+ var insertion = { }; insertion[options.insertion] = responseText;
+ receiver.insert(insertion);
+ }
+ else options.insertion(receiver, responseText);
+ }
+ else receiver.update(responseText);
+ }
+ }
+});
+
+Ajax.PeriodicalUpdater = Class.create(Ajax.Base, {
+ initialize: function($super, container, url, options) {
+ $super(options);
+ this.onComplete = this.options.onComplete;
+
+ this.frequency = (this.options.frequency || 2);
+ this.decay = (this.options.decay || 1);
+
+ this.updater = { };
+ this.container = container;
+ this.url = url;
+
+ this.start();
+ },
+
+ start: function() {
+ this.options.onComplete = this.updateComplete.bind(this);
+ this.onTimerEvent();
+ },
+
+ stop: function() {
+ this.updater.options.onComplete = undefined;
+ clearTimeout(this.timer);
+ (this.onComplete || Prototype.emptyFunction).apply(this, arguments);
+ },
+
+ updateComplete: function(response) {
+ if (this.options.decay) {
+ this.decay = (response.responseText == this.lastText ?
+ this.decay * this.options.decay : 1);
+
+ this.lastText = response.responseText;
+ }
+ this.timer = this.onTimerEvent.bind(this).delay(this.decay * this.frequency);
+ },
+
+ onTimerEvent: function() {
+ this.updater = new Ajax.Updater(this.container, this.url, this.options);
+ }
+});
+function $(element) {
+ if (arguments.length > 1) {
+ for (var i = 0, elements = [], length = arguments.length; i < length; i++)
+ elements.push($(arguments[i]));
+ return elements;
+ }
+ if (Object.isString(element))
+ element = document.getElementById(element);
+ return Element.extend(element);
+}
+
+if (Prototype.BrowserFeatures.XPath) {
+ document._getElementsByXPath = function(expression, parentElement) {
+ var results = [];
+ var query = document.evaluate(expression, $(parentElement) || document,
+ null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null);
+ for (var i = 0, length = query.snapshotLength; i < length; i++)
+ results.push(Element.extend(query.snapshotItem(i)));
+ return results;
+ };
+}
+
+/*--------------------------------------------------------------------------*/
+
+if (!window.Node) var Node = { };
+
+if (!Node.ELEMENT_NODE) {
+ // DOM level 2 ECMAScript Language Binding
+ Object.extend(Node, {
+ ELEMENT_NODE: 1,
+ ATTRIBUTE_NODE: 2,
+ TEXT_NODE: 3,
+ CDATA_SECTION_NODE: 4,
+ ENTITY_REFERENCE_NODE: 5,
+ ENTITY_NODE: 6,
+ PROCESSING_INSTRUCTION_NODE: 7,
+ COMMENT_NODE: 8,
+ DOCUMENT_NODE: 9,
+ DOCUMENT_TYPE_NODE: 10,
+ DOCUMENT_FRAGMENT_NODE: 11,
+ NOTATION_NODE: 12
+ });
+}
+
+(function() {
+ var element = this.Element;
+ this.Element = function(tagName, attributes) {
+ attributes = attributes || { };
+ tagName = tagName.toLowerCase();
+ var cache = Element.cache;
+ if (Prototype.Browser.IE && attributes.name) {
+ tagName = '<' + tagName + ' name="' + attributes.name + '">';
+ delete attributes.name;
+ return Element.writeAttribute(document.createElement(tagName), attributes);
+ }
+ if (!cache[tagName]) cache[tagName] = Element.extend(document.createElement(tagName));
+ return Element.writeAttribute(cache[tagName].cloneNode(false), attributes);
+ };
+ Object.extend(this.Element, element || { });
+ if (element) this.Element.prototype = element.prototype;
+}).call(window);
+
+Element.cache = { };
+
+Element.Methods = {
+ visible: function(element) {
+ return $(element).style.display != 'none';
+ },
+
+ toggle: function(element) {
+ element = $(element);
+ Element[Element.visible(element) ? 'hide' : 'show'](element);
+ return element;
+ },
+
+ hide: function(element) {
+ element = $(element);
+ element.style.display = 'none';
+ return element;
+ },
+
+ show: function(element) {
+ element = $(element);
+ element.style.display = '';
+ return element;
+ },
+
+ remove: function(element) {
+ element = $(element);
+ element.parentNode.removeChild(element);
+ return element;
+ },
+
+ update: function(element, content) {
+ element = $(element);
+ if (content && content.toElement) content = content.toElement();
+ if (Object.isElement(content)) return element.update().insert(content);
+ content = Object.toHTML(content);
+ element.innerHTML = content.stripScripts();
+ content.evalScripts.bind(content).defer();
+ return element;
+ },
+
+ replace: function(element, content) {
+ element = $(element);
+ if (content && content.toElement) content = content.toElement();
+ else if (!Object.isElement(content)) {
+ content = Object.toHTML(content);
+ var range = element.ownerDocument.createRange();
+ range.selectNode(element);
+ content.evalScripts.bind(content).defer();
+ content = range.createContextualFragment(content.stripScripts());
+ }
+ element.parentNode.replaceChild(content, element);
+ return element;
+ },
+
+ insert: function(element, insertions) {
+ element = $(element);
+
+ if (Object.isString(insertions) || Object.isNumber(insertions) ||
+ Object.isElement(insertions) || (insertions && (insertions.toElement || insertions.toHTML)))
+ insertions = {bottom:insertions};
+
+ var content, insert, tagName, childNodes;
+
+ for (var position in insertions) {
+ content = insertions[position];
+ position = position.toLowerCase();
+ insert = Element._insertionTranslations[position];
+
+ if (content && content.toElement) content = content.toElement();
+ if (Object.isElement(content)) {
+ insert(element, content);
+ continue;
+ }
+
+ content = Object.toHTML(content);
+
+ tagName = ((position == 'before' || position == 'after')
+ ? element.parentNode : element).tagName.toUpperCase();
+
+ childNodes = Element._getContentFromAnonymousElement(tagName, content.stripScripts());
+
+ if (position == 'top' || position == 'after') childNodes.reverse();
+ childNodes.each(insert.curry(element));
+
+ content.evalScripts.bind(content).defer();
+ }
+
+ return element;
+ },
+
+ wrap: function(element, wrapper, attributes) {
+ element = $(element);
+ if (Object.isElement(wrapper))
+ $(wrapper).writeAttribute(attributes || { });
+ else if (Object.isString(wrapper)) wrapper = new Element(wrapper, attributes);
+ else wrapper = new Element('div', wrapper);
+ if (element.parentNode)
+ element.parentNode.replaceChild(wrapper, element);
+ wrapper.appendChild(element);
+ return wrapper;
+ },
+
+ inspect: function(element) {
+ element = $(element);
+ var result = '<' + element.tagName.toLowerCase();
+ $H({'id': 'id', 'className': 'class'}).each(function(pair) {
+ var property = pair.first(), attribute = pair.last();
+ var value = (element[property] || '').toString();
+ if (value) result += ' ' + attribute + '=' + value.inspect(true);
+ });
+ return result + '>';
+ },
+
+ recursivelyCollect: function(element, property) {
+ element = $(element);
+ var elements = [];
+ while (element = element[property])
+ if (element.nodeType == 1)
+ elements.push(Element.extend(element));
+ return elements;
+ },
+
+ ancestors: function(element) {
+ return $(element).recursivelyCollect('parentNode');
+ },
+
+ descendants: function(element) {
+ return $(element).select("*");
+ },
+
+ firstDescendant: function(element) {
+ element = $(element).firstChild;
+ while (element && element.nodeType != 1) element = element.nextSibling;
+ return $(element);
+ },
+
+ immediateDescendants: function(element) {
+ if (!(element = $(element).firstChild)) return [];
+ while (element && element.nodeType != 1) element = element.nextSibling;
+ if (element) return [element].concat($(element).nextSiblings());
+ return [];
+ },
+
+ previousSiblings: function(element) {
+ return $(element).recursivelyCollect('previousSibling');
+ },
+
+ nextSiblings: function(element) {
+ return $(element).recursivelyCollect('nextSibling');
+ },
+
+ siblings: function(element) {
+ element = $(element);
+ return element.previousSiblings().reverse().concat(element.nextSiblings());
+ },
+
+ match: function(element, selector) {
+ if (Object.isString(selector))
+ selector = new Selector(selector);
+ return selector.match($(element));
+ },
+
+ up: function(element, expression, index) {
+ element = $(element);
+ if (arguments.length == 1) return $(element.parentNode);
+ var ancestors = element.ancestors();
+ return Object.isNumber(expression) ? ancestors[expression] :
+ Selector.findElement(ancestors, expression, index);
+ },
+
+ down: function(element, expression, index) {
+ element = $(element);
+ if (arguments.length == 1) return element.firstDescendant();
+ return Object.isNumber(expression) ? element.descendants()[expression] :
+ Element.select(element, expression)[index || 0];
+ },
+
+ previous: function(element, expression, index) {
+ element = $(element);
+ if (arguments.length == 1) return $(Selector.handlers.previousElementSibling(element));
+ var previousSiblings = element.previousSiblings();
+ return Object.isNumber(expression) ? previousSiblings[expression] :
+ Selector.findElement(previousSiblings, expression, index);
+ },
+
+ next: function(element, expression, index) {
+ element = $(element);
+ if (arguments.length == 1) return $(Selector.handlers.nextElementSibling(element));
+ var nextSiblings = element.nextSiblings();
+ return Object.isNumber(expression) ? nextSiblings[expression] :
+ Selector.findElement(nextSiblings, expression, index);
+ },
+
+ select: function() {
+ var args = $A(arguments), element = $(args.shift());
+ return Selector.findChildElements(element, args);
+ },
+
+ adjacent: function() {
+ var args = $A(arguments), element = $(args.shift());
+ return Selector.findChildElements(element.parentNode, args).without(element);
+ },
+
+ identify: function(element) {
+ element = $(element);
+ var id = element.readAttribute('id'), self = arguments.callee;
+ if (id) return id;
+ do { id = 'anonymous_element_' + self.counter++ } while ($(id));
+ element.writeAttribute('id', id);
+ return id;
+ },
+
+ readAttribute: function(element, name) {
+ element = $(element);
+ if (Prototype.Browser.IE) {
+ var t = Element._attributeTranslations.read;
+ if (t.values[name]) return t.values[name](element, name);
+ if (t.names[name]) name = t.names[name];
+ if (name.include(':')) {
+ return (!element.attributes || !element.attributes[name]) ? null :
+ element.attributes[name].value;
+ }
+ }
+ return element.getAttribute(name);
+ },
+
+ writeAttribute: function(element, name, value) {
+ element = $(element);
+ var attributes = { }, t = Element._attributeTranslations.write;
+
+ if (typeof name == 'object') attributes = name;
+ else attributes[name] = Object.isUndefined(value) ? true : value;
+
+ for (var attr in attributes) {
+ name = t.names[attr] || attr;
+ value = attributes[attr];
+ if (t.values[attr]) name = t.values[attr](element, value);
+ if (value === false || value === null)
+ element.removeAttribute(name);
+ else if (value === true)
+ element.setAttribute(name, name);
+ else element.setAttribute(name, value);
+ }
+ return element;
+ },
+
+ getHeight: function(element) {
+ return $(element).getDimensions().height;
+ },
+
+ getWidth: function(element) {
+ return $(element).getDimensions().width;
+ },
+
+ classNames: function(element) {
+ return new Element.ClassNames(element);
+ },
+
+ hasClassName: function(element, className) {
+ if (!(element = $(element))) return;
+ var elementClassName = element.className;
+ return (elementClassName.length > 0 && (elementClassName == className ||
+ new RegExp("(^|\\s)" + className + "(\\s|$)").test(elementClassName)));
+ },
+
+ addClassName: function(element, className) {
+ if (!(element = $(element))) return;
+ if (!element.hasClassName(className))
+ element.className += (element.className ? ' ' : '') + className;
+ return element;
+ },
+
+ removeClassName: function(element, className) {
+ if (!(element = $(element))) return;
+ element.className = element.className.replace(
+ new RegExp("(^|\\s+)" + className + "(\\s+|$)"), ' ').strip();
+ return element;
+ },
+
+ toggleClassName: function(element, className) {
+ if (!(element = $(element))) return;
+ return element[element.hasClassName(className) ?
+ 'removeClassName' : 'addClassName'](className);
+ },
+
+ // removes whitespace-only text node children
+ cleanWhitespace: function(element) {
+ element = $(element);
+ var node = element.firstChild;
+ while (node) {
+ var nextNode = node.nextSibling;
+ if (node.nodeType == 3 && !/\S/.test(node.nodeValue))
+ element.removeChild(node);
+ node = nextNode;
+ }
+ return element;
+ },
+
+ empty: function(element) {
+ return $(element).innerHTML.blank();
+ },
+
+ descendantOf: function(element, ancestor) {
+ element = $(element), ancestor = $(ancestor);
+
+ if (element.compareDocumentPosition)
+ return (element.compareDocumentPosition(ancestor) & 8) === 8;
+
+ if (ancestor.contains)
+ return ancestor.contains(element) && ancestor !== element;
+
+ while (element = element.parentNode)
+ if (element == ancestor) return true;
+
+ return false;
+ },
+
+ scrollTo: function(element) {
+ element = $(element);
+ var pos = element.cumulativeOffset();
+ window.scrollTo(pos[0], pos[1]);
+ return element;
+ },
+
+ getStyle: function(element, style) {
+ element = $(element);
+ style = style == 'float' ? 'cssFloat' : style.camelize();
+ var value = element.style[style];
+ if (!value || value == 'auto') {
+ var css = document.defaultView.getComputedStyle(element, null);
+ value = css ? css[style] : null;
+ }
+ if (style == 'opacity') return value ? parseFloat(value) : 1.0;
+ return value == 'auto' ? null : value;
+ },
+
+ getOpacity: function(element) {
+ return $(element).getStyle('opacity');
+ },
+
+ setStyle: function(element, styles) {
+ element = $(element);
+ var elementStyle = element.style, match;
+ if (Object.isString(styles)) {
+ element.style.cssText += ';' + styles;
+ return styles.include('opacity') ?
+ element.setOpacity(styles.match(/opacity:\s*(\d?\.?\d*)/)[1]) : element;
+ }
+ for (var property in styles)
+ if (property == 'opacity') element.setOpacity(styles[property]);
+ else
+ elementStyle[(property == 'float' || property == 'cssFloat') ?
+ (Object.isUndefined(elementStyle.styleFloat) ? 'cssFloat' : 'styleFloat') :
+ property] = styles[property];
+
+ return element;
+ },
+
+ setOpacity: function(element, value) {
+ element = $(element);
+ element.style.opacity = (value == 1 || value === '') ? '' :
+ (value < 0.00001) ? 0 : value;
+ return element;
+ },
+
+ getDimensions: function(element) {
+ element = $(element);
+ var display = element.getStyle('display');
+ if (display != 'none' && display != null) // Safari bug
+ return {width: element.offsetWidth, height: element.offsetHeight};
+
+ // All *Width and *Height properties give 0 on elements with display none,
+ // so enable the element temporarily
+ var els = element.style;
+ var originalVisibility = els.visibility;
+ var originalPosition = els.position;
+ var originalDisplay = els.display;
+ els.visibility = 'hidden';
+ els.position = 'absolute';
+ els.display = 'block';
+ var originalWidth = element.clientWidth;
+ var originalHeight = element.clientHeight;
+ els.display = originalDisplay;
+ els.position = originalPosition;
+ els.visibility = originalVisibility;
+ return {width: originalWidth, height: originalHeight};
+ },
+
+ makePositioned: function(element) {
+ element = $(element);
+ var pos = Element.getStyle(element, 'position');
+ if (pos == 'static' || !pos) {
+ element._madePositioned = true;
+ element.style.position = 'relative';
+ // Opera returns the offset relative to the positioning context, when an
+ // element is position relative but top and left have not been defined
+ if (Prototype.Browser.Opera) {
+ element.style.top = 0;
+ element.style.left = 0;
+ }
+ }
+ return element;
+ },
+
+ undoPositioned: function(element) {
+ element = $(element);
+ if (element._madePositioned) {
+ element._madePositioned = undefined;
+ element.style.position =
+ element.style.top =
+ element.style.left =
+ element.style.bottom =
+ element.style.right = '';
+ }
+ return element;
+ },
+
+ makeClipping: function(element) {
+ element = $(element);
+ if (element._overflow) return element;
+ element._overflow = Element.getStyle(element, 'overflow') || 'auto';
+ if (element._overflow !== 'hidden')
+ element.style.overflow = 'hidden';
+ return element;
+ },
+
+ undoClipping: function(element) {
+ element = $(element);
+ if (!element._overflow) return element;
+ element.style.overflow = element._overflow == 'auto' ? '' : element._overflow;
+ element._overflow = null;
+ return element;
+ },
+
+ cumulativeOffset: function(element) {
+ var valueT = 0, valueL = 0;
+ do {
+ valueT += element.offsetTop || 0;
+ valueL += element.offsetLeft || 0;
+ element = element.offsetParent;
+ } while (element);
+ return Element._returnOffset(valueL, valueT);
+ },
+
+ positionedOffset: function(element) {
+ var valueT = 0, valueL = 0;
+ do {
+ valueT += element.offsetTop || 0;
+ valueL += element.offsetLeft || 0;
+ element = element.offsetParent;
+ if (element) {
+ if (element.tagName.toUpperCase() == 'BODY') break;
+ var p = Element.getStyle(element, 'position');
+ if (p !== 'static') break;
+ }
+ } while (element);
+ return Element._returnOffset(valueL, valueT);
+ },
+
+ absolutize: function(element) {
+ element = $(element);
+ if (element.getStyle('position') == 'absolute') return element;
+ // Position.prepare(); // To be done manually by Scripty when it needs it.
+
+ var offsets = element.positionedOffset();
+ var top = offsets[1];
+ var left = offsets[0];
+ var width = element.clientWidth;
+ var height = element.clientHeight;
+
+ element._originalLeft = left - parseFloat(element.style.left || 0);
+ element._originalTop = top - parseFloat(element.style.top || 0);
+ element._originalWidth = element.style.width;
+ element._originalHeight = element.style.height;
+
+ element.style.position = 'absolute';
+ element.style.top = top + 'px';
+ element.style.left = left + 'px';
+ element.style.width = width + 'px';
+ element.style.height = height + 'px';
+ return element;
+ },
+
+ relativize: function(element) {
+ element = $(element);
+ if (element.getStyle('position') == 'relative') return element;
+ // Position.prepare(); // To be done manually by Scripty when it needs it.
+
+ element.style.position = 'relative';
+ var top = parseFloat(element.style.top || 0) - (element._originalTop || 0);
+ var left = parseFloat(element.style.left || 0) - (element._originalLeft || 0);
+
+ element.style.top = top + 'px';
+ element.style.left = left + 'px';
+ element.style.height = element._originalHeight;
+ element.style.width = element._originalWidth;
+ return element;
+ },
+
+ cumulativeScrollOffset: function(element) {
+ var valueT = 0, valueL = 0;
+ do {
+ valueT += element.scrollTop || 0;
+ valueL += element.scrollLeft || 0;
+ element = element.parentNode;
+ } while (element);
+ return Element._returnOffset(valueL, valueT);
+ },
+
+ getOffsetParent: function(element) {
+ if (element.offsetParent) return $(element.offsetParent);
+ if (element == document.body) return $(element);
+
+ while ((element = element.parentNode) && element != document.body)
+ if (Element.getStyle(element, 'position') != 'static')
+ return $(element);
+
+ return $(document.body);
+ },
+
+ viewportOffset: function(forElement) {
+ var valueT = 0, valueL = 0;
+
+ var element = forElement;
+ do {
+ valueT += element.offsetTop || 0;
+ valueL += element.offsetLeft || 0;
+
+ // Safari fix
+ if (element.offsetParent == document.body &&
+ Element.getStyle(element, 'position') == 'absolute') break;
+
+ } while (element = element.offsetParent);
+
+ element = forElement;
+ do {
+ if (!Prototype.Browser.Opera || (element.tagName && (element.tagName.toUpperCase() == 'BODY'))) {
+ valueT -= element.scrollTop || 0;
+ valueL -= element.scrollLeft || 0;
+ }
+ } while (element = element.parentNode);
+
+ return Element._returnOffset(valueL, valueT);
+ },
+
+ clonePosition: function(element, source) {
+ var options = Object.extend({
+ setLeft: true,
+ setTop: true,
+ setWidth: true,
+ setHeight: true,
+ offsetTop: 0,
+ offsetLeft: 0
+ }, arguments[2] || { });
+
+ // find page position of source
+ source = $(source);
+ var p = source.viewportOffset();
+
+ // find coordinate system to use
+ element = $(element);
+ var delta = [0, 0];
+ var parent = null;
+ // delta [0,0] will do fine with position: fixed elements,
+ // position:absolute needs offsetParent deltas
+ if (Element.getStyle(element, 'position') == 'absolute') {
+ parent = element.getOffsetParent();
+ delta = parent.viewportOffset();
+ }
+
+ // correct by body offsets (fixes Safari)
+ if (parent == document.body) {
+ delta[0] -= document.body.offsetLeft;
+ delta[1] -= document.body.offsetTop;
+ }
+
+ // set position
+ if (options.setLeft) element.style.left = (p[0] - delta[0] + options.offsetLeft) + 'px';
+ if (options.setTop) element.style.top = (p[1] - delta[1] + options.offsetTop) + 'px';
+ if (options.setWidth) element.style.width = source.offsetWidth + 'px';
+ if (options.setHeight) element.style.height = source.offsetHeight + 'px';
+ return element;
+ }
+};
+
+Element.Methods.identify.counter = 1;
+
+Object.extend(Element.Methods, {
+ getElementsBySelector: Element.Methods.select,
+ childElements: Element.Methods.immediateDescendants
+});
+
+Element._attributeTranslations = {
+ write: {
+ names: {
+ className: 'class',
+ htmlFor: 'for'
+ },
+ values: { }
+ }
+};
+
+if (Prototype.Browser.Opera) {
+ Element.Methods.getStyle = Element.Methods.getStyle.wrap(
+ function(proceed, element, style) {
+ switch (style) {
+ case 'left': case 'top': case 'right': case 'bottom':
+ if (proceed(element, 'position') === 'static') return null;
+ case 'height': case 'width':
+ // returns '0px' for hidden elements; we want it to return null
+ if (!Element.visible(element)) return null;
+
+ // returns the border-box dimensions rather than the content-box
+ // dimensions, so we subtract padding and borders from the value
+ var dim = parseInt(proceed(element, style), 10);
+
+ if (dim !== element['offset' + style.capitalize()])
+ return dim + 'px';
+
+ var properties;
+ if (style === 'height') {
+ properties = ['border-top-width', 'padding-top',
+ 'padding-bottom', 'border-bottom-width'];
+ }
+ else {
+ properties = ['border-left-width', 'padding-left',
+ 'padding-right', 'border-right-width'];
+ }
+ return properties.inject(dim, function(memo, property) {
+ var val = proceed(element, property);
+ return val === null ? memo : memo - parseInt(val, 10);
+ }) + 'px';
+ default: return proceed(element, style);
+ }
+ }
+ );
+
+ Element.Methods.readAttribute = Element.Methods.readAttribute.wrap(
+ function(proceed, element, attribute) {
+ if (attribute === 'title') return element.title;
+ return proceed(element, attribute);
+ }
+ );
+}
+
+else if (Prototype.Browser.IE) {
+ // IE doesn't report offsets correctly for static elements, so we change them
+ // to "relative" to get the values, then change them back.
+ Element.Methods.getOffsetParent = Element.Methods.getOffsetParent.wrap(
+ function(proceed, element) {
+ element = $(element);
+ // IE throws an error if element is not in document
+ try { element.offsetParent }
+ catch(e) { return $(document.body) }
+ var position = element.getStyle('position');
+ if (position !== 'static') return proceed(element);
+ element.setStyle({ position: 'relative' });
+ var value = proceed(element);
+ element.setStyle({ position: position });
+ return value;
+ }
+ );
+
+ $w('positionedOffset viewportOffset').each(function(method) {
+ Element.Methods[method] = Element.Methods[method].wrap(
+ function(proceed, element) {
+ element = $(element);
+ try { element.offsetParent }
+ catch(e) { return Element._returnOffset(0,0) }
+ var position = element.getStyle('position');
+ if (position !== 'static') return proceed(element);
+ // Trigger hasLayout on the offset parent so that IE6 reports
+ // accurate offsetTop and offsetLeft values for position: fixed.
+ var offsetParent = element.getOffsetParent();
+ if (offsetParent && offsetParent.getStyle('position') === 'fixed')
+ offsetParent.setStyle({ zoom: 1 });
+ element.setStyle({ position: 'relative' });
+ var value = proceed(element);
+ element.setStyle({ position: position });
+ return value;
+ }
+ );
+ });
+
+ Element.Methods.cumulativeOffset = Element.Methods.cumulativeOffset.wrap(
+ function(proceed, element) {
+ try { element.offsetParent }
+ catch(e) { return Element._returnOffset(0,0) }
+ return proceed(element);
+ }
+ );
+
+ Element.Methods.getStyle = function(element, style) {
+ element = $(element);
+ style = (style == 'float' || style == 'cssFloat') ? 'styleFloat' : style.camelize();
+ var value = element.style[style];
+ if (!value && element.currentStyle) value = element.currentStyle[style];
+
+ if (style == 'opacity') {
+ if (value = (element.getStyle('filter') || '').match(/alpha\(opacity=(.*)\)/))
+ if (value[1]) return parseFloat(value[1]) / 100;
+ return 1.0;
+ }
+
+ if (value == 'auto') {
+ if ((style == 'width' || style == 'height') && (element.getStyle('display') != 'none'))
+ return element['offset' + style.capitalize()] + 'px';
+ return null;
+ }
+ return value;
+ };
+
+ Element.Methods.setOpacity = function(element, value) {
+ function stripAlpha(filter){
+ return filter.replace(/alpha\([^\)]*\)/gi,'');
+ }
+ element = $(element);
+ var currentStyle = element.currentStyle;
+ if ((currentStyle && !currentStyle.hasLayout) ||
+ (!currentStyle && element.style.zoom == 'normal'))
+ element.style.zoom = 1;
+
+ var filter = element.getStyle('filter'), style = element.style;
+ if (value == 1 || value === '') {
+ (filter = stripAlpha(filter)) ?
+ style.filter = filter : style.removeAttribute('filter');
+ return element;
+ } else if (value < 0.00001) value = 0;
+ style.filter = stripAlpha(filter) +
+ 'alpha(opacity=' + (value * 100) + ')';
+ return element;
+ };
+
+ Element._attributeTranslations = {
+ read: {
+ names: {
+ 'class': 'className',
+ 'for': 'htmlFor'
+ },
+ values: {
+ _getAttr: function(element, attribute) {
+ return element.getAttribute(attribute, 2);
+ },
+ _getAttrNode: function(element, attribute) {
+ var node = element.getAttributeNode(attribute);
+ return node ? node.value : "";
+ },
+ _getEv: function(element, attribute) {
+ attribute = element.getAttribute(attribute);
+ return attribute ? attribute.toString().slice(23, -2) : null;
+ },
+ _flag: function(element, attribute) {
+ return $(element).hasAttribute(attribute) ? attribute : null;
+ },
+ style: function(element) {
+ return element.style.cssText.toLowerCase();
+ },
+ title: function(element) {
+ return element.title;
+ }
+ }
+ }
+ };
+
+ Element._attributeTranslations.write = {
+ names: Object.extend({
+ cellpadding: 'cellPadding',
+ cellspacing: 'cellSpacing'
+ }, Element._attributeTranslations.read.names),
+ values: {
+ checked: function(element, value) {
+ element.checked = !!value;
+ },
+
+ style: function(element, value) {
+ element.style.cssText = value ? value : '';
+ }
+ }
+ };
+
+ Element._attributeTranslations.has = {};
+
+ $w('colSpan rowSpan vAlign dateTime accessKey tabIndex ' +
+ 'encType maxLength readOnly longDesc frameBorder').each(function(attr) {
+ Element._attributeTranslations.write.names[attr.toLowerCase()] = attr;
+ Element._attributeTranslations.has[attr.toLowerCase()] = attr;
+ });
+
+ (function(v) {
+ Object.extend(v, {
+ href: v._getAttr,
+ src: v._getAttr,
+ type: v._getAttr,
+ action: v._getAttrNode,
+ disabled: v._flag,
+ checked: v._flag,
+ readonly: v._flag,
+ multiple: v._flag,
+ onload: v._getEv,
+ onunload: v._getEv,
+ onclick: v._getEv,
+ ondblclick: v._getEv,
+ onmousedown: v._getEv,
+ onmouseup: v._getEv,
+ onmouseover: v._getEv,
+ onmousemove: v._getEv,
+ onmouseout: v._getEv,
+ onfocus: v._getEv,
+ onblur: v._getEv,
+ onkeypress: v._getEv,
+ onkeydown: v._getEv,
+ onkeyup: v._getEv,
+ onsubmit: v._getEv,
+ onreset: v._getEv,
+ onselect: v._getEv,
+ onchange: v._getEv
+ });
+ })(Element._attributeTranslations.read.values);
+}
+
+else if (Prototype.Browser.Gecko && /rv:1\.8\.0/.test(navigator.userAgent)) {
+ Element.Methods.setOpacity = function(element, value) {
+ element = $(element);
+ element.style.opacity = (value == 1) ? 0.999999 :
+ (value === '') ? '' : (value < 0.00001) ? 0 : value;
+ return element;
+ };
+}
+
+else if (Prototype.Browser.WebKit) {
+ Element.Methods.setOpacity = function(element, value) {
+ element = $(element);
+ element.style.opacity = (value == 1 || value === '') ? '' :
+ (value < 0.00001) ? 0 : value;
+
+ if (value == 1)
+ if(element.tagName.toUpperCase() == 'IMG' && element.width) {
+ element.width++; element.width--;
+ } else try {
+ var n = document.createTextNode(' ');
+ element.appendChild(n);
+ element.removeChild(n);
+ } catch (e) { }
+
+ return element;
+ };
+
+ // Safari returns margins on body which is incorrect if the child is absolutely
+ // positioned. For performance reasons, redefine Element#cumulativeOffset for
+ // KHTML/WebKit only.
+ Element.Methods.cumulativeOffset = function(element) {
+ var valueT = 0, valueL = 0;
+ do {
+ valueT += element.offsetTop || 0;
+ valueL += element.offsetLeft || 0;
+ if (element.offsetParent == document.body)
+ if (Element.getStyle(element, 'position') == 'absolute') break;
+
+ element = element.offsetParent;
+ } while (element);
+
+ return Element._returnOffset(valueL, valueT);
+ };
+}
+
+if (Prototype.Browser.IE || Prototype.Browser.Opera) {
+ // IE and Opera are missing .innerHTML support for TABLE-related and SELECT elements
+ Element.Methods.update = function(element, content) {
+ element = $(element);
+
+ if (content && content.toElement) content = content.toElement();
+ if (Object.isElement(content)) return element.update().insert(content);
+
+ content = Object.toHTML(content);
+ var tagName = element.tagName.toUpperCase();
+
+ if (tagName in Element._insertionTranslations.tags) {
+ $A(element.childNodes).each(function(node) { element.removeChild(node) });
+ Element._getContentFromAnonymousElement(tagName, content.stripScripts())
+ .each(function(node) { element.appendChild(node) });
+ }
+ else element.innerHTML = content.stripScripts();
+
+ content.evalScripts.bind(content).defer();
+ return element;
+ };
+}
+
+if ('outerHTML' in document.createElement('div')) {
+ Element.Methods.replace = function(element, content) {
+ element = $(element);
+
+ if (content && content.toElement) content = content.toElement();
+ if (Object.isElement(content)) {
+ element.parentNode.replaceChild(content, element);
+ return element;
+ }
+
+ content = Object.toHTML(content);
+ var parent = element.parentNode, tagName = parent.tagName.toUpperCase();
+
+ if (Element._insertionTranslations.tags[tagName]) {
+ var nextSibling = element.next();
+ var fragments = Element._getContentFromAnonymousElement(tagName, content.stripScripts());
+ parent.removeChild(element);
+ if (nextSibling)
+ fragments.each(function(node) { parent.insertBefore(node, nextSibling) });
+ else
+ fragments.each(function(node) { parent.appendChild(node) });
+ }
+ else element.outerHTML = content.stripScripts();
+
+ content.evalScripts.bind(content).defer();
+ return element;
+ };
+}
+
+Element._returnOffset = function(l, t) {
+ var result = [l, t];
+ result.left = l;
+ result.top = t;
+ return result;
+};
+
+Element._getContentFromAnonymousElement = function(tagName, html) {
+ var div = new Element('div'), t = Element._insertionTranslations.tags[tagName];
+ if (t) {
+ div.innerHTML = t[0] + html + t[1];
+ t[2].times(function() { div = div.firstChild });
+ } else div.innerHTML = html;
+ return $A(div.childNodes);
+};
+
+Element._insertionTranslations = {
+ before: function(element, node) {
+ element.parentNode.insertBefore(node, element);
+ },
+ top: function(element, node) {
+ element.insertBefore(node, element.firstChild);
+ },
+ bottom: function(element, node) {
+ element.appendChild(node);
+ },
+ after: function(element, node) {
+ element.parentNode.insertBefore(node, element.nextSibling);
+ },
+ tags: {
+ TABLE: ['<table>', '</table>', 1],
+ TBODY: ['<table><tbody>', '</tbody></table>', 2],
+ TR: ['<table><tbody><tr>', '</tr></tbody></table>', 3],
+ TD: ['<table><tbody><tr><td>', '</td></tr></tbody></table>', 4],
+ SELECT: ['<select>', '</select>', 1]
+ }
+};
+
+(function() {
+ Object.extend(this.tags, {
+ THEAD: this.tags.TBODY,
+ TFOOT: this.tags.TBODY,
+ TH: this.tags.TD
+ });
+}).call(Element._insertionTranslations);
+
+Element.Methods.Simulated = {
+ hasAttribute: function(element, attribute) {
+ attribute = Element._attributeTranslations.has[attribute] || attribute;
+ var node = $(element).getAttributeNode(attribute);
+ return !!(node && node.specified);
+ }
+};
+
+Element.Methods.ByTag = { };
+
+Object.extend(Element, Element.Methods);
+
+if (!Prototype.BrowserFeatures.ElementExtensions &&
+ document.createElement('div')['__proto__']) {
+ window.HTMLElement = { };
+ window.HTMLElement.prototype = document.createElement('div')['__proto__'];
+ Prototype.BrowserFeatures.ElementExtensions = true;
+}
+
+Element.extend = (function() {
+ if (Prototype.BrowserFeatures.SpecificElementExtensions)
+ return Prototype.K;
+
+ var Methods = { }, ByTag = Element.Methods.ByTag;
+
+ var extend = Object.extend(function(element) {
+ if (!element || element._extendedByPrototype ||
+ element.nodeType != 1 || element == window) return element;
+
+ var methods = Object.clone(Methods),
+ tagName = element.tagName.toUpperCase(), property, value;
+
+ // extend methods for specific tags
+ if (ByTag[tagName]) Object.extend(methods, ByTag[tagName]);
+
+ for (property in methods) {
+ value = methods[property];
+ if (Object.isFunction(value) && !(property in element))
+ element[property] = value.methodize();
+ }
+
+ element._extendedByPrototype = Prototype.emptyFunction;
+ return element;
+
+ }, {
+ refresh: function() {
+ // extend methods for all tags (Safari doesn't need this)
+ if (!Prototype.BrowserFeatures.ElementExtensions) {
+ Object.extend(Methods, Element.Methods);
+ Object.extend(Methods, Element.Methods.Simulated);
+ }
+ }
+ });
+
+ extend.refresh();
+ return extend;
+})();
+
+Element.hasAttribute = function(element, attribute) {
+ if (element.hasAttribute) return element.hasAttribute(attribute);
+ return Element.Methods.Simulated.hasAttribute(element, attribute);
+};
+
+Element.addMethods = function(methods) {
+ var F = Prototype.BrowserFeatures, T = Element.Methods.ByTag;
+
+ if (!methods) {
+ Object.extend(Form, Form.Methods);
+ Object.extend(Form.Element, Form.Element.Methods);
+ Object.extend(Element.Methods.ByTag, {
+ "FORM": Object.clone(Form.Methods),
+ "INPUT": Object.clone(Form.Element.Methods),
+ "SELECT": Object.clone(Form.Element.Methods),
+ "TEXTAREA": Object.clone(Form.Element.Methods)
+ });
+ }
+
+ if (arguments.length == 2) {
+ var tagName = methods;
+ methods = arguments[1];
+ }
+
+ if (!tagName) Object.extend(Element.Methods, methods || { });
+ else {
+ if (Object.isArray(tagName)) tagName.each(extend);
+ else extend(tagName);
+ }
+
+ function extend(tagName) {
+ tagName = tagName.toUpperCase();
+ if (!Element.Methods.ByTag[tagName])
+ Element.Methods.ByTag[tagName] = { };
+ Object.extend(Element.Methods.ByTag[tagName], methods);
+ }
+
+ function copy(methods, destination, onlyIfAbsent) {
+ onlyIfAbsent = onlyIfAbsent || false;
+ for (var property in methods) {
+ var value = methods[property];
+ if (!Object.isFunction(value)) continue;
+ if (!onlyIfAbsent || !(property in destination))
+ destination[property] = value.methodize();
+ }
+ }
+
+ function findDOMClass(tagName) {
+ var klass;
+ var trans = {
+ "OPTGROUP": "OptGroup", "TEXTAREA": "TextArea", "P": "Paragraph",
+ "FIELDSET": "FieldSet", "UL": "UList", "OL": "OList", "DL": "DList",
+ "DIR": "Directory", "H1": "Heading", "H2": "Heading", "H3": "Heading",
+ "H4": "Heading", "H5": "Heading", "H6": "Heading", "Q": "Quote",
+ "INS": "Mod", "DEL": "Mod", "A": "Anchor", "IMG": "Image", "CAPTION":
+ "TableCaption", "COL": "TableCol", "COLGROUP": "TableCol", "THEAD":
+ "TableSection", "TFOOT": "TableSection", "TBODY": "TableSection", "TR":
+ "TableRow", "TH": "TableCell", "TD": "TableCell", "FRAMESET":
+ "FrameSet", "IFRAME": "IFrame"
+ };
+ if (trans[tagName]) klass = 'HTML' + trans[tagName] + 'Element';
+ if (window[klass]) return window[klass];
+ klass = 'HTML' + tagName + 'Element';
+ if (window[klass]) return window[klass];
+ klass = 'HTML' + tagName.capitalize() + 'Element';
+ if (window[klass]) return window[klass];
+
+ window[klass] = { };
+ window[klass].prototype = document.createElement(tagName)['__proto__'];
+ return window[klass];
+ }
+
+ if (F.ElementExtensions) {
+ copy(Element.Methods, HTMLElement.prototype);
+ copy(Element.Methods.Simulated, HTMLElement.prototype, true);
+ }
+
+ if (F.SpecificElementExtensions) {
+ for (var tag in Element.Methods.ByTag) {
+ var klass = findDOMClass(tag);
+ if (Object.isUndefined(klass)) continue;
+ copy(T[tag], klass.prototype);
+ }
+ }
+
+ Object.extend(Element, Element.Methods);
+ delete Element.ByTag;
+
+ if (Element.extend.refresh) Element.extend.refresh();
+ Element.cache = { };
+};
+
+document.viewport = {
+ getDimensions: function() {
+ var dimensions = { }, B = Prototype.Browser;
+ $w('width height').each(function(d) {
+ var D = d.capitalize();
+ if (B.WebKit && !document.evaluate) {
+ // Safari <3.0 needs self.innerWidth/Height
+ dimensions[d] = self['inner' + D];
+ } else if (B.Opera && parseFloat(window.opera.version()) < 9.5) {
+ // Opera <9.5 needs document.body.clientWidth/Height
+ dimensions[d] = document.body['client' + D]
+ } else {
+ dimensions[d] = document.documentElement['client' + D];
+ }
+ });
+ return dimensions;
+ },
+
+ getWidth: function() {
+ return this.getDimensions().width;
+ },
+
+ getHeight: function() {
+ return this.getDimensions().height;
+ },
+
+ getScrollOffsets: function() {
+ return Element._returnOffset(
+ window.pageXOffset || document.documentElement.scrollLeft || document.body.scrollLeft,
+ window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop);
+ }
+};
+/* Portions of the Selector class are derived from Jack Slocum's DomQuery,
+ * part of YUI-Ext version 0.40, distributed under the terms of an MIT-style
+ * license. Please see http://www.yui-ext.com/ for more information. */
+
+var Selector = Class.create({
+ initialize: function(expression) {
+ this.expression = expression.strip();
+
+ if (this.shouldUseSelectorsAPI()) {
+ this.mode = 'selectorsAPI';
+ } else if (this.shouldUseXPath()) {
+ this.mode = 'xpath';
+ this.compileXPathMatcher();
+ } else {
+ this.mode = "normal";
+ this.compileMatcher();
+ }
+
+ },
+
+ shouldUseXPath: function() {
+ if (!Prototype.BrowserFeatures.XPath) return false;
+
+ var e = this.expression;
+
+ // Safari 3 chokes on :*-of-type and :empty
+ if (Prototype.Browser.WebKit &&
+ (e.include("-of-type") || e.include(":empty")))
+ return false;
+
+ // XPath can't do namespaced attributes, nor can it read
+ // the "checked" property from DOM nodes
+ if ((/(\[[\w-]*?:|:checked)/).test(e))
+ return false;
+
+ return true;
+ },
+
+ shouldUseSelectorsAPI: function() {
+ if (!Prototype.BrowserFeatures.SelectorsAPI) return false;
+
+ if (!Selector._div) Selector._div = new Element('div');
+
+ // Make sure the browser treats the selector as valid. Test on an
+ // isolated element to minimize cost of this check.
+ try {
+ Selector._div.querySelector(this.expression);
+ } catch(e) {
+ return false;
+ }
+
+ return true;
+ },
+
+ compileMatcher: function() {
+ var e = this.expression, ps = Selector.patterns, h = Selector.handlers,
+ c = Selector.criteria, le, p, m;
+
+ if (Selector._cache[e]) {
+ this.matcher = Selector._cache[e];
+ return;
+ }
+
+ this.matcher = ["this.matcher = function(root) {",
+ "var r = root, h = Selector.handlers, c = false, n;"];
+
+ while (e && le != e && (/\S/).test(e)) {
+ le = e;
+ for (var i in ps) {
+ p = ps[i];
+ if (m = e.match(p)) {
+ this.matcher.push(Object.isFunction(c[i]) ? c[i](m) :
+ new Template(c[i]).evaluate(m));
+ e = e.replace(m[0], '');
+ break;
+ }
+ }
+ }
+
+ this.matcher.push("return h.unique(n);\n}");
+ eval(this.matcher.join('\n'));
+ Selector._cache[this.expression] = this.matcher;
+ },
+
+ compileXPathMatcher: function() {
+ var e = this.expression, ps = Selector.patterns,
+ x = Selector.xpath, le, m;
+
+ if (Selector._cache[e]) {
+ this.xpath = Selector._cache[e]; return;
+ }
+
+ this.matcher = ['.//*'];
+ while (e && le != e && (/\S/).test(e)) {
+ le = e;
+ for (var i in ps) {
+ if (m = e.match(ps[i])) {
+ this.matcher.push(Object.isFunction(x[i]) ? x[i](m) :
+ new Template(x[i]).evaluate(m));
+ e = e.replace(m[0], '');
+ break;
+ }
+ }
+ }
+
+ this.xpath = this.matcher.join('');
+ Selector._cache[this.expression] = this.xpath;
+ },
+
+ findElements: function(root) {
+ root = root || document;
+ var e = this.expression, results;
+
+ switch (this.mode) {
+ case 'selectorsAPI':
+ // querySelectorAll queries document-wide, then filters to descendants
+ // of the context element. That's not what we want.
+ // Add an explicit context to the selector if necessary.
+ if (root !== document) {
+ var oldId = root.id, id = $(root).identify();
+ e = "#" + id + " " + e;
+ }
+
+ results = $A(root.querySelectorAll(e)).map(Element.extend);
+ root.id = oldId;
+
+ return results;
+ case 'xpath':
+ return document._getElementsByXPath(this.xpath, root);
+ default:
+ return this.matcher(root);
+ }
+ },
+
+ match: function(element) {
+ this.tokens = [];
+
+ var e = this.expression, ps = Selector.patterns, as = Selector.assertions;
+ var le, p, m;
+
+ while (e && le !== e && (/\S/).test(e)) {
+ le = e;
+ for (var i in ps) {
+ p = ps[i];
+ if (m = e.match(p)) {
+ // use the Selector.assertions methods unless the selector
+ // is too complex.
+ if (as[i]) {
+ this.tokens.push([i, Object.clone(m)]);
+ e = e.replace(m[0], '');
+ } else {
+ // reluctantly do a document-wide search
+ // and look for a match in the array
+ return this.findElements(document).include(element);
+ }
+ }
+ }
+ }
+
+ var match = true, name, matches;
+ for (var i = 0, token; token = this.tokens[i]; i++) {
+ name = token[0], matches = token[1];
+ if (!Selector.assertions[name](element, matches)) {
+ match = false; break;
+ }
+ }
+
+ return match;
+ },
+
+ toString: function() {
+ return this.expression;
+ },
+
+ inspect: function() {
+ return "#<Selector:" + this.expression.inspect() + ">";
+ }
+});
+
+Object.extend(Selector, {
+ _cache: { },
+
+ xpath: {
+ descendant: "//*",
+ child: "/*",
+ adjacent: "/following-sibling::*[1]",
+ laterSibling: '/following-sibling::*',
+ tagName: function(m) {
+ if (m[1] == '*') return '';
+ return "[local-name()='" + m[1].toLowerCase() +
+ "' or local-name()='" + m[1].toUpperCase() + "']";
+ },
+ className: "[contains(concat(' ', @class, ' '), ' #{1} ')]",
+ id: "[@id='#{1}']",
+ attrPresence: function(m) {
+ m[1] = m[1].toLowerCase();
+ return new Template("[@#{1}]").evaluate(m);
+ },
+ attr: function(m) {
+ m[1] = m[1].toLowerCase();
+ m[3] = m[5] || m[6];
+ return new Template(Selector.xpath.operators[m[2]]).evaluate(m);
+ },
+ pseudo: function(m) {
+ var h = Selector.xpath.pseudos[m[1]];
+ if (!h) return '';
+ if (Object.isFunction(h)) return h(m);
+ return new Template(Selector.xpath.pseudos[m[1]]).evaluate(m);
+ },
+ operators: {
+ '=': "[@#{1}='#{3}']",
+ '!=': "[@#{1}!='#{3}']",
+ '^=': "[starts-with(@#{1}, '#{3}')]",
+ '$=': "[substring(@#{1}, (string-length(@#{1}) - string-length('#{3}') + 1))='#{3}']",
+ '*=': "[contains(@#{1}, '#{3}')]",
+ '~=': "[contains(concat(' ', @#{1}, ' '), ' #{3} ')]",
+ '|=': "[contains(concat('-', @#{1}, '-'), '-#{3}-')]"
+ },
+ pseudos: {
+ 'first-child': '[not(preceding-sibling::*)]',
+ 'last-child': '[not(following-sibling::*)]',
+ 'only-child': '[not(preceding-sibling::* or following-sibling::*)]',
+ 'empty': "[count(*) = 0 and (count(text()) = 0)]",
+ 'checked': "[@checked]",
+ 'disabled': "[(@disabled) and (@type!='hidden')]",
+ 'enabled': "[not(@disabled) and (@type!='hidden')]",
+ 'not': function(m) {
+ var e = m[6], p = Selector.patterns,
+ x = Selector.xpath, le, v;
+
+ var exclusion = [];
+ while (e && le != e && (/\S/).test(e)) {
+ le = e;
+ for (var i in p) {
+ if (m = e.match(p[i])) {
+ v = Object.isFunction(x[i]) ? x[i](m) : new Template(x[i]).evaluate(m);
+ exclusion.push("(" + v.substring(1, v.length - 1) + ")");
+ e = e.replace(m[0], '');
+ break;
+ }
+ }
+ }
+ return "[not(" + exclusion.join(" and ") + ")]";
+ },
+ 'nth-child': function(m) {
+ return Selector.xpath.pseudos.nth("(count(./preceding-sibling::*) + 1) ", m);
+ },
+ 'nth-last-child': function(m) {
+ return Selector.xpath.pseudos.nth("(count(./following-sibling::*) + 1) ", m);
+ },
+ 'nth-of-type': function(m) {
+ return Selector.xpath.pseudos.nth("position() ", m);
+ },
+ 'nth-last-of-type': function(m) {
+ return Selector.xpath.pseudos.nth("(last() + 1 - position()) ", m);
+ },
+ 'first-of-type': function(m) {
+ m[6] = "1"; return Selector.xpath.pseudos['nth-of-type'](m);
+ },
+ 'last-of-type': function(m) {
+ m[6] = "1"; return Selector.xpath.pseudos['nth-last-of-type'](m);
+ },
+ 'only-of-type': function(m) {
+ var p = Selector.xpath.pseudos; return p['first-of-type'](m) + p['last-of-type'](m);
+ },
+ nth: function(fragment, m) {
+ var mm, formula = m[6], predicate;
+ if (formula == 'even') formula = '2n+0';
+ if (formula == 'odd') formula = '2n+1';
+ if (mm = formula.match(/^(\d+)$/)) // digit only
+ return '[' + fragment + "= " + mm[1] + ']';
+ if (mm = formula.match(/^(-?\d*)?n(([+-])(\d+))?/)) { // an+b
+ if (mm[1] == "-") mm[1] = -1;
+ var a = mm[1] ? Number(mm[1]) : 1;
+ var b = mm[2] ? Number(mm[2]) : 0;
+ predicate = "[((#{fragment} - #{b}) mod #{a} = 0) and " +
+ "((#{fragment} - #{b}) div #{a} >= 0)]";
+ return new Template(predicate).evaluate({
+ fragment: fragment, a: a, b: b });
+ }
+ }
+ }
+ },
+
+ criteria: {
+ tagName: 'n = h.tagName(n, r, "#{1}", c); c = false;',
+ className: 'n = h.className(n, r, "#{1}", c); c = false;',
+ id: 'n = h.id(n, r, "#{1}", c); c = false;',
+ attrPresence: 'n = h.attrPresence(n, r, "#{1}", c); c = false;',
+ attr: function(m) {
+ m[3] = (m[5] || m[6]);
+ return new Template('n = h.attr(n, r, "#{1}", "#{3}", "#{2}", c); c = false;').evaluate(m);
+ },
+ pseudo: function(m) {
+ if (m[6]) m[6] = m[6].replace(/"/g, '\\"');
+ return new Template('n = h.pseudo(n, "#{1}", "#{6}", r, c); c = false;').evaluate(m);
+ },
+ descendant: 'c = "descendant";',
+ child: 'c = "child";',
+ adjacent: 'c = "adjacent";',
+ laterSibling: 'c = "laterSibling";'
+ },
+
+ patterns: {
+ // combinators must be listed first
+ // (and descendant needs to be last combinator)
+ laterSibling: /^\s*~\s*/,
+ child: /^\s*>\s*/,
+ adjacent: /^\s*\+\s*/,
+ descendant: /^\s/,
+
+ // selectors follow
+ tagName: /^\s*(\*|[\w\-]+)(\b|$)?/,
+ id: /^#([\w\-\*]+)(\b|$)/,
+ className: /^\.([\w\-\*]+)(\b|$)/,
+ pseudo:
+/^:((first|last|nth|nth-last|only)(-child|-of-type)|empty|checked|(en|dis)abled|not)(\((.*?)\))?(\b|$|(?=\s|[:+~>]))/,
+ attrPresence: /^\[((?:[\w]+:)?[\w]+)\]/,
+ attr: /\[((?:[\w-]*:)?[\w-]+)\s*(?:([!^$*~|]?=)\s*((['"])([^\4]*?)\4|([^'"][^\]]*?)))?\]/
+ },
+
+ // for Selector.match and Element#match
+ assertions: {
+ tagName: function(element, matches) {
+ return matches[1].toUpperCase() == element.tagName.toUpperCase();
+ },
+
+ className: function(element, matches) {
+ return Element.hasClassName(element, matches[1]);
+ },
+
+ id: function(element, matches) {
+ return element.id === matches[1];
+ },
+
+ attrPresence: function(element, matches) {
+ return Element.hasAttribute(element, matches[1]);
+ },
+
+ attr: function(element, matches) {
+ var nodeValue = Element.readAttribute(element, matches[1]);
+ return nodeValue && Selector.operators[matches[2]](nodeValue, matches[5] || matches[6]);
+ }
+ },
+
+ handlers: {
+ // UTILITY FUNCTIONS
+ // joins two collections
+ concat: function(a, b) {
+ for (var i = 0, node; node = b[i]; i++)
+ a.push(node);
+ return a;
+ },
+
+ // marks an array of nodes for counting
+ mark: function(nodes) {
+ var _true = Prototype.emptyFunction;
+ for (var i = 0, node; node = nodes[i]; i++)
+ node._countedByPrototype = _true;
+ return nodes;
+ },
+
+ unmark: function(nodes) {
+ for (var i = 0, node; node = nodes[i]; i++)
+ node._countedByPrototype = undefined;
+ return nodes;
+ },
+
+ // mark each child node with its position (for nth calls)
+ // "ofType" flag indicates whether we're indexing for nth-of-type
+ // rather than nth-child
+ index: function(parentNode, reverse, ofType) {
+ parentNode._countedByPrototype = Prototype.emptyFunction;
+ if (reverse) {
+ for (var nodes = parentNode.childNodes, i = nodes.length - 1, j = 1; i >= 0; i--) {
+ var node = nodes[i];
+ if (node.nodeType == 1 && (!ofType || node._countedByPrototype)) node.nodeIndex = j++;
+ }
+ } else {
+ for (var i = 0, j = 1, nodes = parentNode.childNodes; node = nodes[i]; i++)
+ if (node.nodeType == 1 && (!ofType || node._countedByPrototype)) node.nodeIndex = j++;
+ }
+ },
+
+ // filters out duplicates and extends all nodes
+ unique: function(nodes) {
+ if (nodes.length == 0) return nodes;
+ var results = [], n;
+ for (var i = 0, l = nodes.length; i < l; i++)
+ if (!(n = nodes[i])._countedByPrototype) {
+ n._countedByPrototype = Prototype.emptyFunction;
+ results.push(Element.extend(n));
+ }
+ return Selector.handlers.unmark(results);
+ },
+
+ // COMBINATOR FUNCTIONS
+ descendant: function(nodes) {
+ var h = Selector.handlers;
+ for (var i = 0, results = [], node; node = nodes[i]; i++)
+ h.concat(results, node.getElementsByTagName('*'));
+ return results;
+ },
+
+ child: function(nodes) {
+ var h = Selector.handlers;
+ for (var i = 0, results = [], node; node = nodes[i]; i++) {
+ for (var j = 0, child; child = node.childNodes[j]; j++)
+ if (child.nodeType == 1 && child.tagName != '!') results.push(child);
+ }
+ return results;
+ },
+
+ adjacent: function(nodes) {
+ for (var i = 0, results = [], node; node = nodes[i]; i++) {
+ var next = this.nextElementSibling(node);
+ if (next) results.push(next);
+ }
+ return results;
+ },
+
+ laterSibling: function(nodes) {
+ var h = Selector.handlers;
+ for (var i = 0, results = [], node; node = nodes[i]; i++)
+ h.concat(results, Element.nextSiblings(node));
+ return results;
+ },
+
+ nextElementSibling: function(node) {
+ while (node = node.nextSibling)
+ if (node.nodeType == 1) return node;
+ return null;
+ },
+
+ previousElementSibling: function(node) {
+ while (node = node.previousSibling)
+ if (node.nodeType == 1) return node;
+ return null;
+ },
+
+ // TOKEN FUNCTIONS
+ tagName: function(nodes, root, tagName, combinator) {
+ var uTagName = tagName.toUpperCase();
+ var results = [], h = Selector.handlers;
+ if (nodes) {
+ if (combinator) {
+ // fastlane for ordinary descendant combinators
+ if (combinator == "descendant") {
+ for (var i = 0, node; node = nodes[i]; i++)
+ h.concat(results, node.getElementsByTagName(tagName));
+ return results;
+ } else nodes = this[combinator](nodes);
+ if (tagName == "*") return nodes;
+ }
+ for (var i = 0, node; node = nodes[i]; i++)
+ if (node.tagName.toUpperCase() === uTagName) results.push(node);
+ return results;
+ } else return root.getElementsByTagName(tagName);
+ },
+
+ id: function(nodes, root, id, combinator) {
+ var targetNode = $(id), h = Selector.handlers;
+ if (!targetNode) return [];
+ if (!nodes && root == document) return [targetNode];
+ if (nodes) {
+ if (combinator) {
+ if (combinator == 'child') {
+ for (var i = 0, node; node = nodes[i]; i++)
+ if (targetNode.parentNode == node) return [targetNode];
+ } else if (combinator == 'descendant') {
+ for (var i = 0, node; node = nodes[i]; i++)
+ if (Element.descendantOf(targetNode, node)) return [targetNode];
+ } else if (combinator == 'adjacent') {
+ for (var i = 0, node; node = nodes[i]; i++)
+ if (Selector.handlers.previousElementSibling(targetNode) == node)
+ return [targetNode];
+ } else nodes = h[combinator](nodes);
+ }
+ for (var i = 0, node; node = nodes[i]; i++)
+ if (node == targetNode) return [targetNode];
+ return [];
+ }
+ return (targetNode && Element.descendantOf(targetNode, root)) ? [targetNode] : [];
+ },
+
+ className: function(nodes, root, className, combinator) {
+ if (nodes && combinator) nodes = this[combinator](nodes);
+ return Selector.handlers.byClassName(nodes, root, className);
+ },
+
+ byClassName: function(nodes, root, className) {
+ if (!nodes) nodes = Selector.handlers.descendant([root]);
+ var needle = ' ' + className + ' ';
+ for (var i = 0, results = [], node, nodeClassName; node = nodes[i]; i++) {
+ nodeClassName = node.className;
+ if (nodeClassName.length == 0) continue;
+ if (nodeClassName == className || (' ' + nodeClassName + ' ').include(needle))
+ results.push(node);
+ }
+ return results;
+ },
+
+ attrPresence: function(nodes, root, attr, combinator) {
+ if (!nodes) nodes = root.getElementsByTagName("*");
+ if (nodes && combinator) nodes = this[combinator](nodes);
+ var results = [];
+ for (var i = 0, node; node = nodes[i]; i++)
+ if (Element.hasAttribute(node, attr)) results.push(node);
+ return results;
+ },
+
+ attr: function(nodes, root, attr, value, operator, combinator) {
+ if (!nodes) nodes = root.getElementsByTagName("*");
+ if (nodes && combinator) nodes = this[combinator](nodes);
+ var handler = Selector.operators[operator], results = [];
+ for (var i = 0, node; node = nodes[i]; i++) {
+ var nodeValue = Element.readAttribute(node, attr);
+ if (nodeValue === null) continue;
+ if (handler(nodeValue, value)) results.push(node);
+ }
+ return results;
+ },
+
+ pseudo: function(nodes, name, value, root, combinator) {
+ if (nodes && combinator) nodes = this[combinator](nodes);
+ if (!nodes) nodes = root.getElementsByTagName("*");
+ return Selector.pseudos[name](nodes, value, root);
+ }
+ },
+
+ pseudos: {
+ 'first-child': function(nodes, value, root) {
+ for (var i = 0, results = [], node; node = nodes[i]; i++) {
+ if (Selector.handlers.previousElementSibling(node)) continue;
+ results.push(node);
+ }
+ return results;
+ },
+ 'last-child': function(nodes, value, root) {
+ for (var i = 0, results = [], node; node = nodes[i]; i++) {
+ if (Selector.handlers.nextElementSibling(node)) continue;
+ results.push(node);
+ }
+ return results;
+ },
+ 'only-child': function(nodes, value, root) {
+ var h = Selector.handlers;
+ for (var i = 0, results = [], node; node = nodes[i]; i++)
+ if (!h.previousElementSibling(node) && !h.nextElementSibling(node))
+ results.push(node);
+ return results;
+ },
+ 'nth-child': function(nodes, formula, root) {
+ return Selector.pseudos.nth(nodes, formula, root);
+ },
+ 'nth-last-child': function(nodes, formula, root) {
+ return Selector.pseudos.nth(nodes, formula, root, true);
+ },
+ 'nth-of-type': function(nodes, formula, root) {
+ return Selector.pseudos.nth(nodes, formula, root, false, true);
+ },
+ 'nth-last-of-type': function(nodes, formula, root) {
+ return Selector.pseudos.nth(nodes, formula, root, true, true);
+ },
+ 'first-of-type': function(nodes, formula, root) {
+ return Selector.pseudos.nth(nodes, "1", root, false, true);
+ },
+ 'last-of-type': function(nodes, formula, root) {
+ return Selector.pseudos.nth(nodes, "1", root, true, true);
+ },
+ 'only-of-type': function(nodes, formula, root) {
+ var p = Selector.pseudos;
+ return p['last-of-type'](p['first-of-type'](nodes, formula, root), formula, root);
+ },
+
+ // handles the an+b logic
+ getIndices: function(a, b, total) {
+ if (a == 0) return b > 0 ? [b] : [];
+ return $R(1, total).inject([], function(memo, i) {
+ if (0 == (i - b) % a && (i - b) / a >= 0) memo.push(i);
+ return memo;
+ });
+ },
+
+ // handles nth(-last)-child, nth(-last)-of-type, and (first|last)-of-type
+ nth: function(nodes, formula, root, reverse, ofType) {
+ if (nodes.length == 0) return [];
+ if (formula == 'even') formula = '2n+0';
+ if (formula == 'odd') formula = '2n+1';
+ var h = Selector.handlers, results = [], indexed = [], m;
+ h.mark(nodes);
+ for (var i = 0, node; node = nodes[i]; i++) {
+ if (!node.parentNode._countedByPrototype) {
+ h.index(node.parentNode, reverse, ofType);
+ indexed.push(node.parentNode);
+ }
+ }
+ if (formula.match(/^\d+$/)) { // just a number
+ formula = Number(formula);
+ for (var i = 0, node; node = nodes[i]; i++)
+ if (node.nodeIndex == formula) results.push(node);
+ } else if (m = formula.match(/^(-?\d*)?n(([+-])(\d+))?/)) { // an+b
+ if (m[1] == "-") m[1] = -1;
+ var a = m[1] ? Number(m[1]) : 1;
+ var b = m[2] ? Number(m[2]) : 0;
+ var indices = Selector.pseudos.getIndices(a, b, nodes.length);
+ for (var i = 0, node, l = indices.length; node = nodes[i]; i++) {
+ for (var j = 0; j < l; j++)
+ if (node.nodeIndex == indices[j]) results.push(node);
+ }
+ }
+ h.unmark(nodes);
+ h.unmark(indexed);
+ return results;
+ },
+
+ 'empty': function(nodes, value, root) {
+ for (var i = 0, results = [], node; node = nodes[i]; i++) {
+ // IE treats comments as element nodes
+ if (node.tagName == '!' || node.firstChild) continue;
+ results.push(node);
+ }
+ return results;
+ },
+
+ 'not': function(nodes, selector, root) {
+ var h = Selector.handlers, selectorType, m;
+ var exclusions = new Selector(selector).findElements(root);
+ h.mark(exclusions);
+ for (var i = 0, results = [], node; node = nodes[i]; i++)
+ if (!node._countedByPrototype) results.push(node);
+ h.unmark(exclusions);
+ return results;
+ },
+
+ 'enabled': function(nodes, value, root) {
+ for (var i = 0, results = [], node; node = nodes[i]; i++)
+ if (!node.disabled && (!node.type || node.type !== 'hidden'))
+ results.push(node);
+ return results;
+ },
+
+ 'disabled': function(nodes, value, root) {
+ for (var i = 0, results = [], node; node = nodes[i]; i++)
+ if (node.disabled) results.push(node);
+ return results;
+ },
+
+ 'checked': function(nodes, value, root) {
+ for (var i = 0, results = [], node; node = nodes[i]; i++)
+ if (node.checked) results.push(node);
+ return results;
+ }
+ },
+
+ operators: {
+ '=': function(nv, v) { return nv == v; },
+ '!=': function(nv, v) { return nv != v; },
+ '^=': function(nv, v) { return nv == v || nv && nv.startsWith(v); },
+ '$=': function(nv, v) { return nv == v || nv && nv.endsWith(v); },
+ '*=': function(nv, v) { return nv == v || nv && nv.include(v); },
+ '$=': function(nv, v) { return nv.endsWith(v); },
+ '*=': function(nv, v) { return nv.include(v); },
+ '~=': function(nv, v) { return (' ' + nv + ' ').include(' ' + v + ' '); },
+ '|=': function(nv, v) { return ('-' + (nv || "").toUpperCase() +
+ '-').include('-' + (v || "").toUpperCase() + '-'); }
+ },
+
+ split: function(expression) {
+ var expressions = [];
+ expression.scan(/(([\w#:.~>+()\s-]+|\*|\[.*?\])+)\s*(,|$)/, function(m) {
+ expressions.push(m[1].strip());
+ });
+ return expressions;
+ },
+
+ matchElements: function(elements, expression) {
+ var matches = $$(expression), h = Selector.handlers;
+ h.mark(matches);
+ for (var i = 0, results = [], element; element = elements[i]; i++)
+ if (element._countedByPrototype) results.push(element);
+ h.unmark(matches);
+ return results;
+ },
+
+ findElement: function(elements, expression, index) {
+ if (Object.isNumber(expression)) {
+ index = expression; expression = false;
+ }
+ return Selector.matchElements(elements, expression || '*')[index || 0];
+ },
+
+ findChildElements: function(element, expressions) {
+ expressions = Selector.split(expressions.join(','));
+ var results = [], h = Selector.handlers;
+ for (var i = 0, l = expressions.length, selector; i < l; i++) {
+ selector = new Selector(expressions[i].strip());
+ h.concat(results, selector.findElements(element));
+ }
+ return (l > 1) ? h.unique(results) : results;
+ }
+});
+
+if (Prototype.Browser.IE) {
+ Object.extend(Selector.handlers, {
+ // IE returns comment nodes on getElementsByTagName("*").
+ // Filter them out.
+ concat: function(a, b) {
+ for (var i = 0, node; node = b[i]; i++)
+ if (node.tagName !== "!") a.push(node);
+ return a;
+ },
+
+ // IE improperly serializes _countedByPrototype in (inner|outer)HTML.
+ unmark: function(nodes) {
+ for (var i = 0, node; node = nodes[i]; i++)
+ node.removeAttribute('_countedByPrototype');
+ return nodes;
+ }
+ });
+}
+
+function $$() {
+ return Selector.findChildElements(document, $A(arguments));
+}
+var Form = {
+ reset: function(form) {
+ $(form).reset();
+ return form;
+ },
+
+ serializeElements: function(elements, options) {
+ if (typeof options != 'object') options = { hash: !!options };
+ else if (Object.isUndefined(options.hash)) options.hash = true;
+ var key, value, submitted = false, submit = options.submit;
+
+ var data = elements.inject({ }, function(result, element) {
+ if (!element.disabled && element.name) {
+ key = element.name; value = $(element).getValue();
+ if (value != null && element.type != 'file' && (element.type != 'submit' || (!submitted &&
+ submit !== false && (!submit || key == submit) && (submitted = true)))) {
+ if (key in result) {
+ // a key is already present; construct an array of values
+ if (!Object.isArray(result[key])) result[key] = [result[key]];
+ result[key].push(value);
+ }
+ else result[key] = value;
+ }
+ }
+ return result;
+ });
+
+ return options.hash ? data : Object.toQueryString(data);
+ }
+};
+
+Form.Methods = {
+ serialize: function(form, options) {
+ return Form.serializeElements(Form.getElements(form), options);
+ },
+
+ getElements: function(form) {
+ return $A($(form).getElementsByTagName('*')).inject([],
+ function(elements, child) {
+ if (Form.Element.Serializers[child.tagName.toLowerCase()])
+ elements.push(Element.extend(child));
+ return elements;
+ }
+ );
+ },
+
+ getInputs: function(form, typeName, name) {
+ form = $(form);
+ var inputs = form.getElementsByTagName('input');
+
+ if (!typeName && !name) return $A(inputs).map(Element.extend);
+
+ for (var i = 0, matchingInputs = [], length = inputs.length; i < length; i++) {
+ var input = inputs[i];
+ if ((typeName && input.type != typeName) || (name && input.name != name))
+ continue;
+ matchingInputs.push(Element.extend(input));
+ }
+
+ return matchingInputs;
+ },
+
+ disable: function(form) {
+ form = $(form);
+ Form.getElements(form).invoke('disable');
+ return form;
+ },
+
+ enable: function(form) {
+ form = $(form);
+ Form.getElements(form).invoke('enable');
+ return form;
+ },
+
+ findFirstElement: function(form) {
+ var elements = $(form).getElements().findAll(function(element) {
+ return 'hidden' != element.type && !element.disabled;
+ });
+ var firstByIndex = elements.findAll(function(element) {
+ return element.hasAttribute('tabIndex') && element.tabIndex >= 0;
+ }).sortBy(function(element) { return element.tabIndex }).first();
+
+ return firstByIndex ? firstByIndex : elements.find(function(element) {
+ return ['input', 'select', 'textarea'].include(element.tagName.toLowerCase());
+ });
+ },
+
+ focusFirstElement: function(form) {
+ form = $(form);
+ form.findFirstElement().activate();
+ return form;
+ },
+
+ request: function(form, options) {
+ form = $(form), options = Object.clone(options || { });
+
+ var params = options.parameters, action = form.readAttribute('action') || '';
+ if (action.blank()) action = window.location.href;
+ options.parameters = form.serialize(true);
+
+ if (params) {
+ if (Object.isString(params)) params = params.toQueryParams();
+ Object.extend(options.parameters, params);
+ }
+
+ if (form.hasAttribute('method') && !options.method)
+ options.method = form.method;
+
+ return new Ajax.Request(action, options);
+ }
+};
+
+/*--------------------------------------------------------------------------*/
+
+Form.Element = {
+ focus: function(element) {
+ $(element).focus();
+ return element;
+ },
+
+ select: function(element) {
+ $(element).select();
+ return element;
+ }
+};
+
+Form.Element.Methods = {
+ serialize: function(element) {
+ element = $(element);
+ if (!element.disabled && element.name) {
+ var value = element.getValue();
+ if (value != undefined) {
+ var pair = { };
+ pair[element.name] = value;
+ return Object.toQueryString(pair);
+ }
+ }
+ return '';
+ },
+
+ getValue: function(element) {
+ element = $(element);
+ var method = element.tagName.toLowerCase();
+ return Form.Element.Serializers[method](element);
+ },
+
+ setValue: function(element, value) {
+ element = $(element);
+ var method = element.tagName.toLowerCase();
+ Form.Element.Serializers[method](element, value);
+ return element;
+ },
+
+ clear: function(element) {
+ $(element).value = '';
+ return element;
+ },
+
+ present: function(element) {
+ return $(element).value != '';
+ },
+
+ activate: function(element) {
+ element = $(element);
+ try {
+ element.focus();
+ if (element.select && (element.tagName.toLowerCase() != 'input' ||
+ !['button', 'reset', 'submit'].include(element.type)))
+ element.select();
+ } catch (e) { }
+ return element;
+ },
+
+ disable: function(element) {
+ element = $(element);
+ element.disabled = true;
+ return element;
+ },
+
+ enable: function(element) {
+ element = $(element);
+ element.disabled = false;
+ return element;
+ }
+};
+
+/*--------------------------------------------------------------------------*/
+
+var Field = Form.Element;
+var $F = Form.Element.Methods.getValue;
+
+/*--------------------------------------------------------------------------*/
+
+Form.Element.Serializers = {
+ input: function(element, value) {
+ switch (element.type.toLowerCase()) {
+ case 'checkbox':
+ case 'radio':
+ return Form.Element.Serializers.inputSelector(element, value);
+ default:
+ return Form.Element.Serializers.textarea(element, value);
+ }
+ },
+
+ inputSelector: function(element, value) {
+ if (Object.isUndefined(value)) return element.checked ? element.value : null;
+ else element.checked = !!value;
+ },
+
+ textarea: function(element, value) {
+ if (Object.isUndefined(value)) return element.value;
+ else element.value = value;
+ },
+
+ select: function(element, value) {
+ if (Object.isUndefined(value))
+ return this[element.type == 'select-one' ?
+ 'selectOne' : 'selectMany'](element);
+ else {
+ var opt, currentValue, single = !Object.isArray(value);
+ for (var i = 0, length = element.length; i < length; i++) {
+ opt = element.options[i];
+ currentValue = this.optionValue(opt);
+ if (single) {
+ if (currentValue == value) {
+ opt.selected = true;
+ return;
+ }
+ }
+ else opt.selected = value.include(currentValue);
+ }
+ }
+ },
+
+ selectOne: function(element) {
+ var index = element.selectedIndex;
+ return index >= 0 ? this.optionValue(element.options[index]) : null;
+ },
+
+ selectMany: function(element) {
+ var values, length = element.length;
+ if (!length) return null;
+
+ for (var i = 0, values = []; i < length; i++) {
+ var opt = element.options[i];
+ if (opt.selected) values.push(this.optionValue(opt));
+ }
+ return values;
+ },
+
+ optionValue: function(opt) {
+ // extend element because hasAttribute may not be native
+ return Element.extend(opt).hasAttribute('value') ? opt.value : opt.text;
+ }
+};
+
+/*--------------------------------------------------------------------------*/
+
+Abstract.TimedObserver = Class.create(PeriodicalExecuter, {
+ initialize: function($super, element, frequency, callback) {
+ $super(callback, frequency);
+ this.element = $(element);
+ this.lastValue = this.getValue();
+ },
+
+ execute: function() {
+ var value = this.getValue();
+ if (Object.isString(this.lastValue) && Object.isString(value) ?
+ this.lastValue != value : String(this.lastValue) != String(value)) {
+ this.callback(this.element, value);
+ this.lastValue = value;
+ }
+ }
+});
+
+Form.Element.Observer = Class.create(Abstract.TimedObserver, {
+ getValue: function() {
+ return Form.Element.getValue(this.element);
+ }
+});
+
+Form.Observer = Class.create(Abstract.TimedObserver, {
+ getValue: function() {
+ return Form.serialize(this.element);
+ }
+});
+
+/*--------------------------------------------------------------------------*/
+
+Abstract.EventObserver = Class.create({
+ initialize: function(element, callback) {
+ this.element = $(element);
+ this.callback = callback;
+
+ this.lastValue = this.getValue();
+ if (this.element.tagName.toLowerCase() == 'form')
+ this.registerFormCallbacks();
+ else
+ this.registerCallback(this.element);
+ },
+
+ onElementEvent: function() {
+ var value = this.getValue();
+ if (this.lastValue != value) {
+ this.callback(this.element, value);
+ this.lastValue = value;
+ }
+ },
+
+ registerFormCallbacks: function() {
+ Form.getElements(this.element).each(this.registerCallback, this);
+ },
+
+ registerCallback: function(element) {
+ if (element.type) {
+ switch (element.type.toLowerCase()) {
+ case 'checkbox':
+ case 'radio':
+ Event.observe(element, 'click', this.onElementEvent.bind(this));
+ break;
+ default:
+ Event.observe(element, 'change', this.onElementEvent.bind(this));
+ break;
+ }
+ }
+ }
+});
+
+Form.Element.EventObserver = Class.create(Abstract.EventObserver, {
+ getValue: function() {
+ return Form.Element.getValue(this.element);
+ }
+});
+
+Form.EventObserver = Class.create(Abstract.EventObserver, {
+ getValue: function() {
+ return Form.serialize(this.element);
+ }
+});
+if (!window.Event) var Event = { };
+
+Object.extend(Event, {
+ KEY_BACKSPACE: 8,
+ KEY_TAB: 9,
+ KEY_RETURN: 13,
+ KEY_ESC: 27,
+ KEY_LEFT: 37,
+ KEY_UP: 38,
+ KEY_RIGHT: 39,
+ KEY_DOWN: 40,
+ KEY_DELETE: 46,
+ KEY_HOME: 36,
+ KEY_END: 35,
+ KEY_PAGEUP: 33,
+ KEY_PAGEDOWN: 34,
+ KEY_INSERT: 45,
+
+ cache: { },
+
+ relatedTarget: function(event) {
+ var element;
+ switch(event.type) {
+ case 'mouseover': element = event.fromElement; break;
+ case 'mouseout': element = event.toElement; break;
+ default: return null;
+ }
+ return Element.extend(element);
+ }
+});
+
+Event.Methods = (function() {
+ var isButton;
+
+ if (Prototype.Browser.IE) {
+ var buttonMap = { 0: 1, 1: 4, 2: 2 };
+ isButton = function(event, code) {
+ return event.button == buttonMap[code];
+ };
+
+ } else if (Prototype.Browser.WebKit) {
+ isButton = function(event, code) {
+ switch (code) {
+ case 0: return event.which == 1 && !event.metaKey;
+ case 1: return event.which == 1 && event.metaKey;
+ default: return false;
+ }
+ };
+
+ } else {
+ isButton = function(event, code) {
+ return event.which ? (event.which === code + 1) : (event.button === code);
+ };
+ }
+
+ return {
+ isLeftClick: function(event) { return isButton(event, 0) },
+ isMiddleClick: function(event) { return isButton(event, 1) },
+ isRightClick: function(event) { return isButton(event, 2) },
+
+ element: function(event) {
+ event = Event.extend(event);
+
+ var node = event.target,
+ type = event.type,
+ currentTarget = event.currentTarget;
+
+ if (currentTarget && currentTarget.tagName) {
+ // Firefox screws up the "click" event when moving between radio buttons
+ // via arrow keys. It also screws up the "load" and "error" events on images,
+ // reporting the document as the target instead of the original image.
+ if (type === 'load' || type === 'error' ||
+ (type === 'click' && currentTarget.tagName.toLowerCase() === 'input'
+ && currentTarget.type === 'radio'))
+ node = currentTarget;
+ }
+ if (node.nodeType == Node.TEXT_NODE) node = node.parentNode;
+ return Element.extend(node);
+ },
+
+ findElement: function(event, expression) {
+ var element = Event.element(event);
+ if (!expression) return element;
+ var elements = [element].concat(element.ancestors());
+ return Selector.findElement(elements, expression, 0);
+ },
+
+ pointer: function(event) {
+ var docElement = document.documentElement,
+ body = document.body || { scrollLeft: 0, scrollTop: 0 };
+ return {
+ x: event.pageX || (event.clientX +
+ (docElement.scrollLeft || body.scrollLeft) -
+ (docElement.clientLeft || 0)),
+ y: event.pageY || (event.clientY +
+ (docElement.scrollTop || body.scrollTop) -
+ (docElement.clientTop || 0))
+ };
+ },
+
+ pointerX: function(event) { return Event.pointer(event).x },
+ pointerY: function(event) { return Event.pointer(event).y },
+
+ stop: function(event) {
+ Event.extend(event);
+ event.preventDefault();
+ event.stopPropagation();
+ event.stopped = true;
+ }
+ };
+})();
+
+Event.extend = (function() {
+ var methods = Object.keys(Event.Methods).inject({ }, function(m, name) {
+ m[name] = Event.Methods[name].methodize();
+ return m;
+ });
+
+ if (Prototype.Browser.IE) {
+ Object.extend(methods, {
+ stopPropagation: function() { this.cancelBubble = true },
+ preventDefault: function() { this.returnValue = false },
+ inspect: function() { return "[object Event]" }
+ });
+
+ return function(event) {
+ if (!event) return false;
+ if (event._extendedByPrototype) return event;
+
+ event._extendedByPrototype = Prototype.emptyFunction;
+ var pointer = Event.pointer(event);
+ Object.extend(event, {
+ target: event.srcElement,
+ relatedTarget: Event.relatedTarget(event),
+ pageX: pointer.x,
+ pageY: pointer.y
+ });
+ return Object.extend(event, methods);
+ };
+
+ } else {
+ Event.prototype = Event.prototype || document.createEvent("HTMLEvents")['__proto__'];
+ Object.extend(Event.prototype, methods);
+ return Prototype.K;
+ }
+})();
+
+Object.extend(Event, (function() {
+ var cache = Event.cache;
+
+ function getEventID(element) {
+ if (element._prototypeEventID) return element._prototypeEventID[0];
+ arguments.callee.id = arguments.callee.id || 1;
+ return element._prototypeEventID = [++arguments.callee.id];
+ }
+
+ function getDOMEventName(eventName) {
+ if (eventName && eventName.include(':')) return "dataavailable";
+ return eventName;
+ }
+
+ function getCacheForID(id) {
+ return cache[id] = cache[id] || { };
+ }
+
+ function getWrappersForEventName(id, eventName) {
+ var c = getCacheForID(id);
+ return c[eventName] = c[eventName] || [];
+ }
+
+ function createWrapper(element, eventName, handler) {
+ var id = getEventID(element);
+ var c = getWrappersForEventName(id, eventName);
+ if (c.pluck("handler").include(handler)) return false;
+
+ var wrapper = function(event) {
+ if (!Event || !Event.extend ||
+ (event.eventName && event.eventName != eventName))
+ return false;
+
+ Event.extend(event);
+ handler.call(element, event);
+ };
+
+ wrapper.handler = handler;
+ c.push(wrapper);
+ return wrapper;
+ }
+
+ function findWrapper(id, eventName, handler) {
+ var c = getWrappersForEventName(id, eventName);
+ return c.find(function(wrapper) { return wrapper.handler == handler });
+ }
+
+ function destroyWrapper(id, eventName, handler) {
+ var c = getCacheForID(id);
+ if (!c[eventName]) return false;
+ c[eventName] = c[eventName].without(findWrapper(id, eventName, handler));
+ }
+
+ function destroyCache() {
+ for (var id in cache)
+ for (var eventName in cache[id])
+ cache[id][eventName] = null;
+ }
+
+
+ // Internet Explorer needs to remove event handlers on page unload
+ // in order to avoid memory leaks.
+ if (window.attachEvent) {
+ window.attachEvent("onunload", destroyCache);
+ }
+
+ // Safari has a dummy event handler on page unload so that it won't
+ // use its bfcache. Safari <= 3.1 has an issue with restoring the "document"
+ // object when page is returned to via the back button using its bfcache.
+ if (Prototype.Browser.WebKit) {
+ window.addEventListener('unload', Prototype.emptyFunction, false);
+ }
+
+ return {
+ observe: function(element, eventName, handler) {
+ element = $(element);
+ var name = getDOMEventName(eventName);
+
+ var wrapper = createWrapper(element, eventName, handler);
+ if (!wrapper) return element;
+
+ if (element.addEventListener) {
+ element.addEventListener(name, wrapper, false);
+ } else {
+ element.attachEvent("on" + name, wrapper);
+ }
+
+ return element;
+ },
+
+ stopObserving: function(element, eventName, handler) {
+ element = $(element);
+ var id = getEventID(element), name = getDOMEventName(eventName);
+
+ if (!handler && eventName) {
+ getWrappersForEventName(id, eventName).each(function(wrapper) {
+ element.stopObserving(eventName, wrapper.handler);
+ });
+ return element;
+
+ } else if (!eventName) {
+ Object.keys(getCacheForID(id)).each(function(eventName) {
+ element.stopObserving(eventName);
+ });
+ return element;
+ }
+
+ var wrapper = findWrapper(id, eventName, handler);
+ if (!wrapper) return element;
+
+ if (element.removeEventListener) {
+ element.removeEventListener(name, wrapper, false);
+ } else {
+ element.detachEvent("on" + name, wrapper);
+ }
+
+ destroyWrapper(id, eventName, handler);
+
+ return element;
+ },
+
+ fire: function(element, eventName, memo) {
+ element = $(element);
+ if (element == document && document.createEvent && !element.dispatchEvent)
+ element = document.documentElement;
+
+ var event;
+ if (document.createEvent) {
+ event = document.createEvent("HTMLEvents");
+ event.initEvent("dataavailable", true, true);
+ } else {
+ event = document.createEventObject();
+ event.eventType = "ondataavailable";
+ }
+
+ event.eventName = eventName;
+ event.memo = memo || { };
+
+ if (document.createEvent) {
+ element.dispatchEvent(event);
+ } else {
+ element.fireEvent(event.eventType, event);
+ }
+
+ return Event.extend(event);
+ }
+ };
+})());
+
+Object.extend(Event, Event.Methods);
+
+Element.addMethods({
+ fire: Event.fire,
+ observe: Event.observe,
+ stopObserving: Event.stopObserving
+});
+
+Object.extend(document, {
+ fire: Element.Methods.fire.methodize(),
+ observe: Element.Methods.observe.methodize(),
+ stopObserving: Element.Methods.stopObserving.methodize(),
+ loaded: false
+});
+
+(function() {
+ /* Support for the DOMContentLoaded event is based on work by Dan Webb,
+ Matthias Miller, Dean Edwards and John Resig. */
+
+ var timer;
+
+ function fireContentLoadedEvent() {
+ if (document.loaded) return;
+ if (timer) window.clearInterval(timer);
+ document.fire("dom:loaded");
+ document.loaded = true;
+ }
+
+ if (document.addEventListener) {
+ if (Prototype.Browser.WebKit) {
+ timer = window.setInterval(function() {
+ if (/loaded|complete/.test(document.readyState))
+ fireContentLoadedEvent();
+ }, 0);
+
+ Event.observe(window, "load", fireContentLoadedEvent);
+
+ } else {
+ document.addEventListener("DOMContentLoaded",
+ fireContentLoadedEvent, false);
+ }
+
+ } else {
+ document.write("<script id=__onDOMContentLoaded defer src=//:><\/script>");
+ $("__onDOMContentLoaded").onreadystatechange = function() {
+ if (this.readyState == "complete") {
+ this.onreadystatechange = null;
+ fireContentLoadedEvent();
+ }
+ };
+ }
+})();
+/*------------------------------- DEPRECATED -------------------------------*/
+
+Hash.toQueryString = Object.toQueryString;
+
+var Toggle = { display: Element.toggle };
+
+Element.Methods.childOf = Element.Methods.descendantOf;
+
+var Insertion = {
+ Before: function(element, content) {
+ return Element.insert(element, {before:content});
+ },
+
+ Top: function(element, content) {
+ return Element.insert(element, {top:content});
+ },
+
+ Bottom: function(element, content) {
+ return Element.insert(element, {bottom:content});
+ },
+
+ After: function(element, content) {
+ return Element.insert(element, {after:content});
+ }
+};
+
+var $continue = new Error('"throw $continue" is deprecated, use "return" instead');
+
+// This should be moved to script.aculo.us; notice the deprecated methods
+// further below, that map to the newer Element methods.
+var Position = {
+ // set to true if needed, warning: firefox performance problems
+ // NOT neeeded for page scrolling, only if draggable contained in
+ // scrollable elements
+ includeScrollOffsets: false,
+
+ // must be called before calling withinIncludingScrolloffset, every time the
+ // page is scrolled
+ prepare: function() {
+ this.deltaX = window.pageXOffset
+ || document.documentElement.scrollLeft
+ || document.body.scrollLeft
+ || 0;
+ this.deltaY = window.pageYOffset
+ || document.documentElement.scrollTop
+ || document.body.scrollTop
+ || 0;
+ },
+
+ // caches x/y coordinate pair to use with overlap
+ within: function(element, x, y) {
+ if (this.includeScrollOffsets)
+ return this.withinIncludingScrolloffsets(element, x, y);
+ this.xcomp = x;
+ this.ycomp = y;
+ this.offset = Element.cumulativeOffset(element);
+
+ return (y >= this.offset[1] &&
+ y < this.offset[1] + element.offsetHeight &&
+ x >= this.offset[0] &&
+ x < this.offset[0] + element.offsetWidth);
+ },
+
+ withinIncludingScrolloffsets: function(element, x, y) {
+ var offsetcache = Element.cumulativeScrollOffset(element);
+
+ this.xcomp = x + offsetcache[0] - this.deltaX;
+ this.ycomp = y + offsetcache[1] - this.deltaY;
+ this.offset = Element.cumulativeOffset(element);
+
+ return (this.ycomp >= this.offset[1] &&
+ this.ycomp < this.offset[1] + element.offsetHeight &&
+ this.xcomp >= this.offset[0] &&
+ this.xcomp < this.offset[0] + element.offsetWidth);
+ },
+
+ // within must be called directly before
+ overlap: function(mode, element) {
+ if (!mode) return 0;
+ if (mode == 'vertical')
+ return ((this.offset[1] + element.offsetHeight) - this.ycomp) /
+ element.offsetHeight;
+ if (mode == 'horizontal')
+ return ((this.offset[0] + element.offsetWidth) - this.xcomp) /
+ element.offsetWidth;
+ },
+
+ // Deprecation layer -- use newer Element methods now (1.5.2).
+
+ cumulativeOffset: Element.Methods.cumulativeOffset,
+
+ positionedOffset: Element.Methods.positionedOffset,
+
+ absolutize: function(element) {
+ Position.prepare();
+ return Element.absolutize(element);
+ },
+
+ relativize: function(element) {
+ Position.prepare();
+ return Element.relativize(element);
+ },
+
+ realOffset: Element.Methods.cumulativeScrollOffset,
+
+ offsetParent: Element.Methods.getOffsetParent,
+
+ page: Element.Methods.viewportOffset,
+
+ clone: function(source, target, options) {
+ options = options || { };
+ return Element.clonePosition(target, source, options);
+ }
+};
+
+/*--------------------------------------------------------------------------*/
+
+if (!document.getElementsByClassName) document.getElementsByClassName = function(instanceMethods){
+ function iter(name) {
+ return name.blank() ? null : "[contains(concat(' ', @class, ' '), ' " + name + " ')]";
+ }
+
+ instanceMethods.getElementsByClassName = Prototype.BrowserFeatures.XPath ?
+ function(element, className) {
+ className = className.toString().strip();
+ var cond = /\s/.test(className) ? $w(className).map(iter).join('') : iter(className);
+ return cond ? document._getElementsByXPath('.//*' + cond, element) : [];
+ } : function(element, className) {
+ className = className.toString().strip();
+ var elements = [], classNames = (/\s/.test(className) ? $w(className) : null);
+ if (!classNames && !className) return elements;
+
+ var nodes = $(element).getElementsByTagName('*');
+ className = ' ' + className + ' ';
+
+ for (var i = 0, child, cn; child = nodes[i]; i++) {
+ if (child.className && (cn = ' ' + child.className + ' ') && (cn.include(className) ||
+ (classNames && classNames.all(function(name) {
+ return !name.toString().blank() && cn.include(' ' + name + ' ');
+ }))))
+ elements.push(Element.extend(child));
+ }
+ return elements;
+ };
+
+ return function(className, parentElement) {
+ return $(parentElement || document.body).getElementsByClassName(className);
+ };
+}(Element.Methods);
+
+/*--------------------------------------------------------------------------*/
+
+Element.ClassNames = Class.create();
+Element.ClassNames.prototype = {
+ initialize: function(element) {
+ this.element = $(element);
+ },
+
+ _each: function(iterator) {
+ this.element.className.split(/\s+/).select(function(name) {
+ return name.length > 0;
+ })._each(iterator);
+ },
+
+ set: function(className) {
+ this.element.className = className;
+ },
+
+ add: function(classNameToAdd) {
+ if (this.include(classNameToAdd)) return;
+ this.set($A(this).concat(classNameToAdd).join(' '));
+ },
+
+ remove: function(classNameToRemove) {
+ if (!this.include(classNameToRemove)) return;
+ this.set($A(this).without(classNameToRemove).join(' '));
+ },
+
+ toString: function() {
+ return $A(this).join(' ');
+ }
+};
+
+Object.extend(Element.ClassNames.prototype, Enumerable);
+
+/*--------------------------------------------------------------------------*/
+
+Element.addMethods(); \ No newline at end of file
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/builder.js b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/builder.js
new file mode 100644
index 0000000..dba8bec
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/builder.js
@@ -0,0 +1,136 @@
+// script.aculo.us builder.js v1.8.2, Tue Nov 18 18:30:58 +0100 2008
+
+// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+//
+// script.aculo.us is freely distributable under the terms of an MIT-style license.
+// For details, see the script.aculo.us web site: http://script.aculo.us/
+
+var Builder = {
+ NODEMAP: {
+ AREA: 'map',
+ CAPTION: 'table',
+ COL: 'table',
+ COLGROUP: 'table',
+ LEGEND: 'fieldset',
+ OPTGROUP: 'select',
+ OPTION: 'select',
+ PARAM: 'object',
+ TBODY: 'table',
+ TD: 'table',
+ TFOOT: 'table',
+ TH: 'table',
+ THEAD: 'table',
+ TR: 'table'
+ },
+ // note: For Firefox < 1.5, OPTION and OPTGROUP tags are currently broken,
+ // due to a Firefox bug
+ node: function(elementName) {
+ elementName = elementName.toUpperCase();
+
+ // try innerHTML approach
+ var parentTag = this.NODEMAP[elementName] || 'div';
+ var parentElement = document.createElement(parentTag);
+ try { // prevent IE "feature": http://dev.rubyonrails.org/ticket/2707
+ parentElement.innerHTML = "<" + elementName + "></" + elementName + ">";
+ } catch(e) {}
+ var element = parentElement.firstChild || null;
+
+ // see if browser added wrapping tags
+ if(element && (element.tagName.toUpperCase() != elementName))
+ element = element.getElementsByTagName(elementName)[0];
+
+ // fallback to createElement approach
+ if(!element) element = document.createElement(elementName);
+
+ // abort if nothing could be created
+ if(!element) return;
+
+ // attributes (or text)
+ if(arguments[1])
+ if(this._isStringOrNumber(arguments[1]) ||
+ (arguments[1] instanceof Array) ||
+ arguments[1].tagName) {
+ this._children(element, arguments[1]);
+ } else {
+ var attrs = this._attributes(arguments[1]);
+ if(attrs.length) {
+ try { // prevent IE "feature": http://dev.rubyonrails.org/ticket/2707
+ parentElement.innerHTML = "<" +elementName + " " +
+ attrs + "></" + elementName + ">";
+ } catch(e) {}
+ element = parentElement.firstChild || null;
+ // workaround firefox 1.0.X bug
+ if(!element) {
+ element = document.createElement(elementName);
+ for(attr in arguments[1])
+ element[attr == 'class' ? 'className' : attr] = arguments[1][attr];
+ }
+ if(element.tagName.toUpperCase() != elementName)
+ element = parentElement.getElementsByTagName(elementName)[0];
+ }
+ }
+
+ // text, or array of children
+ if(arguments[2])
+ this._children(element, arguments[2]);
+
+ return $(element);
+ },
+ _text: function(text) {
+ return document.createTextNode(text);
+ },
+
+ ATTR_MAP: {
+ 'className': 'class',
+ 'htmlFor': 'for'
+ },
+
+ _attributes: function(attributes) {
+ var attrs = [];
+ for(attribute in attributes)
+ attrs.push((attribute in this.ATTR_MAP ? this.ATTR_MAP[attribute] : attribute) +
+ '="' + attributes[attribute].toString().escapeHTML().gsub(/"/,'&quot;') + '"');
+ return attrs.join(" ");
+ },
+ _children: function(element, children) {
+ if(children.tagName) {
+ element.appendChild(children);
+ return;
+ }
+ if(typeof children=='object') { // array can hold nodes and text
+ children.flatten().each( function(e) {
+ if(typeof e=='object')
+ element.appendChild(e);
+ else
+ if(Builder._isStringOrNumber(e))
+ element.appendChild(Builder._text(e));
+ });
+ } else
+ if(Builder._isStringOrNumber(children))
+ element.appendChild(Builder._text(children));
+ },
+ _isStringOrNumber: function(param) {
+ return(typeof param=='string' || typeof param=='number');
+ },
+ build: function(html) {
+ var element = this.node('div');
+ $(element).update(html.strip());
+ return element.down();
+ },
+ dump: function(scope) {
+ if(typeof scope != 'object' && typeof scope != 'function') scope = window; //global scope
+
+ var tags = ("A ABBR ACRONYM ADDRESS APPLET AREA B BASE BASEFONT BDO BIG BLOCKQUOTE BODY " +
+ "BR BUTTON CAPTION CENTER CITE CODE COL COLGROUP DD DEL DFN DIR DIV DL DT EM FIELDSET " +
+ "FONT FORM FRAME FRAMESET H1 H2 H3 H4 H5 H6 HEAD HR HTML I IFRAME IMG INPUT INS ISINDEX "+
+ "KBD LABEL LEGEND LI LINK MAP MENU META NOFRAMES NOSCRIPT OBJECT OL OPTGROUP OPTION P "+
+ "PARAM PRE Q S SAMP SCRIPT SELECT SMALL SPAN STRIKE STRONG STYLE SUB SUP TABLE TBODY TD "+
+ "TEXTAREA TFOOT TH THEAD TITLE TR TT U UL VAR").split(/\s+/);
+
+ tags.each( function(tag){
+ scope[tag] = function() {
+ return Builder.node.apply(Builder, [tag].concat($A(arguments)));
+ };
+ });
+ }
+}; \ No newline at end of file
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/controls.js b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/controls.js
new file mode 100644
index 0000000..c56ccb7
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/controls.js
@@ -0,0 +1,965 @@
+// script.aculo.us controls.js v1.8.2, Tue Nov 18 18:30:58 +0100 2008
+
+// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+// (c) 2005-2008 Ivan Krstic (http://blogs.law.harvard.edu/ivan)
+// (c) 2005-2008 Jon Tirsen (http://www.tirsen.com)
+// Contributors:
+// Richard Livsey
+// Rahul Bhargava
+// Rob Wills
+//
+// script.aculo.us is freely distributable under the terms of an MIT-style license.
+// For details, see the script.aculo.us web site: http://script.aculo.us/
+
+// Autocompleter.Base handles all the autocompletion functionality
+// that's independent of the data source for autocompletion. This
+// includes drawing the autocompletion menu, observing keyboard
+// and mouse events, and similar.
+//
+// Specific autocompleters need to provide, at the very least,
+// a getUpdatedChoices function that will be invoked every time
+// the text inside the monitored textbox changes. This method
+// should get the text for which to provide autocompletion by
+// invoking this.getToken(), NOT by directly accessing
+// this.element.value. This is to allow incremental tokenized
+// autocompletion. Specific auto-completion logic (AJAX, etc)
+// belongs in getUpdatedChoices.
+//
+// Tokenized incremental autocompletion is enabled automatically
+// when an autocompleter is instantiated with the 'tokens' option
+// in the options parameter, e.g.:
+// new Ajax.Autocompleter('id','upd', '/url/', { tokens: ',' });
+// will incrementally autocomplete with a comma as the token.
+// Additionally, ',' in the above example can be replaced with
+// a token array, e.g. { tokens: [',', '\n'] } which
+// enables autocompletion on multiple tokens. This is most
+// useful when one of the tokens is \n (a newline), as it
+// allows smart autocompletion after linebreaks.
+
+if(typeof Effect == 'undefined')
+ throw("controls.js requires including script.aculo.us' effects.js library");
+
+var Autocompleter = { };
+Autocompleter.Base = Class.create({
+ baseInitialize: function(element, update, options) {
+ element = $(element);
+ this.element = element;
+ this.update = $(update);
+ this.hasFocus = false;
+ this.changed = false;
+ this.active = false;
+ this.index = 0;
+ this.entryCount = 0;
+ this.oldElementValue = this.element.value;
+
+ if(this.setOptions)
+ this.setOptions(options);
+ else
+ this.options = options || { };
+
+ this.options.paramName = this.options.paramName || this.element.name;
+ this.options.tokens = this.options.tokens || [];
+ this.options.frequency = this.options.frequency || 0.4;
+ this.options.minChars = this.options.minChars || 1;
+ this.options.onShow = this.options.onShow ||
+ function(element, update){
+ if(!update.style.position || update.style.position=='absolute') {
+ update.style.position = 'absolute';
+ Position.clone(element, update, {
+ setHeight: false,
+ offsetTop: element.offsetHeight
+ });
+ }
+ Effect.Appear(update,{duration:0.15});
+ };
+ this.options.onHide = this.options.onHide ||
+ function(element, update){ new Effect.Fade(update,{duration:0.15}) };
+
+ if(typeof(this.options.tokens) == 'string')
+ this.options.tokens = new Array(this.options.tokens);
+ // Force carriage returns as token delimiters anyway
+ if (!this.options.tokens.include('\n'))
+ this.options.tokens.push('\n');
+
+ this.observer = null;
+
+ this.element.setAttribute('autocomplete','off');
+
+ Element.hide(this.update);
+
+ Event.observe(this.element, 'blur', this.onBlur.bindAsEventListener(this));
+ Event.observe(this.element, 'keydown', this.onKeyPress.bindAsEventListener(this));
+ },
+
+ show: function() {
+ if(Element.getStyle(this.update, 'display')=='none') this.options.onShow(this.element, this.update);
+ if(!this.iefix &&
+ (Prototype.Browser.IE) &&
+ (Element.getStyle(this.update, 'position')=='absolute')) {
+ new Insertion.After(this.update,
+ '<iframe id="' + this.update.id + '_iefix" '+
+ 'style="display:none;position:absolute;filter:progid:DXImageTransform.Microsoft.Alpha(opacity=0);" ' +
+ 'src="javascript:false;" frameborder="0" scrolling="no"></iframe>');
+ this.iefix = $(this.update.id+'_iefix');
+ }
+ if(this.iefix) setTimeout(this.fixIEOverlapping.bind(this), 50);
+ },
+
+ fixIEOverlapping: function() {
+ Position.clone(this.update, this.iefix, {setTop:(!this.update.style.height)});
+ this.iefix.style.zIndex = 1;
+ this.update.style.zIndex = 2;
+ Element.show(this.iefix);
+ },
+
+ hide: function() {
+ this.stopIndicator();
+ if(Element.getStyle(this.update, 'display')!='none') this.options.onHide(this.element, this.update);
+ if(this.iefix) Element.hide(this.iefix);
+ },
+
+ startIndicator: function() {
+ if(this.options.indicator) Element.show(this.options.indicator);
+ },
+
+ stopIndicator: function() {
+ if(this.options.indicator) Element.hide(this.options.indicator);
+ },
+
+ onKeyPress: function(event) {
+ if(this.active)
+ switch(event.keyCode) {
+ case Event.KEY_TAB:
+ case Event.KEY_RETURN:
+ this.selectEntry();
+ Event.stop(event);
+ case Event.KEY_ESC:
+ this.hide();
+ this.active = false;
+ Event.stop(event);
+ return;
+ case Event.KEY_LEFT:
+ case Event.KEY_RIGHT:
+ return;
+ case Event.KEY_UP:
+ this.markPrevious();
+ this.render();
+ Event.stop(event);
+ return;
+ case Event.KEY_DOWN:
+ this.markNext();
+ this.render();
+ Event.stop(event);
+ return;
+ }
+ else
+ if(event.keyCode==Event.KEY_TAB || event.keyCode==Event.KEY_RETURN ||
+ (Prototype.Browser.WebKit > 0 && event.keyCode == 0)) return;
+
+ this.changed = true;
+ this.hasFocus = true;
+
+ if(this.observer) clearTimeout(this.observer);
+ this.observer =
+ setTimeout(this.onObserverEvent.bind(this), this.options.frequency*1000);
+ },
+
+ activate: function() {
+ this.changed = false;
+ this.hasFocus = true;
+ this.getUpdatedChoices();
+ },
+
+ onHover: function(event) {
+ var element = Event.findElement(event, 'LI');
+ if(this.index != element.autocompleteIndex)
+ {
+ this.index = element.autocompleteIndex;
+ this.render();
+ }
+ Event.stop(event);
+ },
+
+ onClick: function(event) {
+ var element = Event.findElement(event, 'LI');
+ this.index = element.autocompleteIndex;
+ this.selectEntry();
+ this.hide();
+ },
+
+ onBlur: function(event) {
+ // needed to make click events working
+ setTimeout(this.hide.bind(this), 250);
+ this.hasFocus = false;
+ this.active = false;
+ },
+
+ render: function() {
+ if(this.entryCount > 0) {
+ for (var i = 0; i < this.entryCount; i++)
+ this.index==i ?
+ Element.addClassName(this.getEntry(i),"selected") :
+ Element.removeClassName(this.getEntry(i),"selected");
+ if(this.hasFocus) {
+ this.show();
+ this.active = true;
+ }
+ } else {
+ this.active = false;
+ this.hide();
+ }
+ },
+
+ markPrevious: function() {
+ if(this.index > 0) this.index--;
+ else this.index = this.entryCount-1;
+ this.getEntry(this.index).scrollIntoView(true);
+ },
+
+ markNext: function() {
+ if(this.index < this.entryCount-1) this.index++;
+ else this.index = 0;
+ this.getEntry(this.index).scrollIntoView(false);
+ },
+
+ getEntry: function(index) {
+ return this.update.firstChild.childNodes[index];
+ },
+
+ getCurrentEntry: function() {
+ return this.getEntry(this.index);
+ },
+
+ selectEntry: function() {
+ this.active = false;
+ this.updateElement(this.getCurrentEntry());
+ },
+
+ updateElement: function(selectedElement) {
+ if (this.options.updateElement) {
+ this.options.updateElement(selectedElement);
+ return;
+ }
+ var value = '';
+ if (this.options.select) {
+ var nodes = $(selectedElement).select('.' + this.options.select) || [];
+ if(nodes.length>0) value = Element.collectTextNodes(nodes[0], this.options.select);
+ } else
+ value = Element.collectTextNodesIgnoreClass(selectedElement, 'informal');
+
+ var bounds = this.getTokenBounds();
+ if (bounds[0] != -1) {
+ var newValue = this.element.value.substr(0, bounds[0]);
+ var whitespace = this.element.value.substr(bounds[0]).match(/^\s+/);
+ if (whitespace)
+ newValue += whitespace[0];
+ this.element.value = newValue + value + this.element.value.substr(bounds[1]);
+ } else {
+ this.element.value = value;
+ }
+ this.oldElementValue = this.element.value;
+ this.element.focus();
+
+ if (this.options.afterUpdateElement)
+ this.options.afterUpdateElement(this.element, selectedElement);
+ },
+
+ updateChoices: function(choices) {
+ if(!this.changed && this.hasFocus) {
+ this.update.innerHTML = choices;
+ Element.cleanWhitespace(this.update);
+ Element.cleanWhitespace(this.update.down());
+
+ if(this.update.firstChild && this.update.down().childNodes) {
+ this.entryCount =
+ this.update.down().childNodes.length;
+ for (var i = 0; i < this.entryCount; i++) {
+ var entry = this.getEntry(i);
+ entry.autocompleteIndex = i;
+ this.addObservers(entry);
+ }
+ } else {
+ this.entryCount = 0;
+ }
+
+ this.stopIndicator();
+ this.index = 0;
+
+ if(this.entryCount==1 && this.options.autoSelect) {
+ this.selectEntry();
+ this.hide();
+ } else {
+ this.render();
+ }
+ }
+ },
+
+ addObservers: function(element) {
+ Event.observe(element, "mouseover", this.onHover.bindAsEventListener(this));
+ Event.observe(element, "click", this.onClick.bindAsEventListener(this));
+ },
+
+ onObserverEvent: function() {
+ this.changed = false;
+ this.tokenBounds = null;
+ if(this.getToken().length>=this.options.minChars) {
+ this.getUpdatedChoices();
+ } else {
+ this.active = false;
+ this.hide();
+ }
+ this.oldElementValue = this.element.value;
+ },
+
+ getToken: function() {
+ var bounds = this.getTokenBounds();
+ return this.element.value.substring(bounds[0], bounds[1]).strip();
+ },
+
+ getTokenBounds: function() {
+ if (null != this.tokenBounds) return this.tokenBounds;
+ var value = this.element.value;
+ if (value.strip().empty()) return [-1, 0];
+ var diff = arguments.callee.getFirstDifferencePos(value, this.oldElementValue);
+ var offset = (diff == this.oldElementValue.length ? 1 : 0);
+ var prevTokenPos = -1, nextTokenPos = value.length;
+ var tp;
+ for (var index = 0, l = this.options.tokens.length; index < l; ++index) {
+ tp = value.lastIndexOf(this.options.tokens[index], diff + offset - 1);
+ if (tp > prevTokenPos) prevTokenPos = tp;
+ tp = value.indexOf(this.options.tokens[index], diff + offset);
+ if (-1 != tp && tp < nextTokenPos) nextTokenPos = tp;
+ }
+ return (this.tokenBounds = [prevTokenPos + 1, nextTokenPos]);
+ }
+});
+
+Autocompleter.Base.prototype.getTokenBounds.getFirstDifferencePos = function(newS, oldS) {
+ var boundary = Math.min(newS.length, oldS.length);
+ for (var index = 0; index < boundary; ++index)
+ if (newS[index] != oldS[index])
+ return index;
+ return boundary;
+};
+
+Ajax.Autocompleter = Class.create(Autocompleter.Base, {
+ initialize: function(element, update, url, options) {
+ this.baseInitialize(element, update, options);
+ this.options.asynchronous = true;
+ this.options.onComplete = this.onComplete.bind(this);
+ this.options.defaultParams = this.options.parameters || null;
+ this.url = url;
+ },
+
+ getUpdatedChoices: function() {
+ this.startIndicator();
+
+ var entry = encodeURIComponent(this.options.paramName) + '=' +
+ encodeURIComponent(this.getToken());
+
+ this.options.parameters = this.options.callback ?
+ this.options.callback(this.element, entry) : entry;
+
+ if(this.options.defaultParams)
+ this.options.parameters += '&' + this.options.defaultParams;
+
+ new Ajax.Request(this.url, this.options);
+ },
+
+ onComplete: function(request) {
+ this.updateChoices(request.responseText);
+ }
+});
+
+// The local array autocompleter. Used when you'd prefer to
+// inject an array of autocompletion options into the page, rather
+// than sending out Ajax queries, which can be quite slow sometimes.
+//
+// The constructor takes four parameters. The first two are, as usual,
+// the id of the monitored textbox, and id of the autocompletion menu.
+// The third is the array you want to autocomplete from, and the fourth
+// is the options block.
+//
+// Extra local autocompletion options:
+// - choices - How many autocompletion choices to offer
+//
+// - partialSearch - If false, the autocompleter will match entered
+// text only at the beginning of strings in the
+// autocomplete array. Defaults to true, which will
+// match text at the beginning of any *word* in the
+// strings in the autocomplete array. If you want to
+// search anywhere in the string, additionally set
+// the option fullSearch to true (default: off).
+//
+// - fullSsearch - Search anywhere in autocomplete array strings.
+//
+// - partialChars - How many characters to enter before triggering
+// a partial match (unlike minChars, which defines
+// how many characters are required to do any match
+// at all). Defaults to 2.
+//
+// - ignoreCase - Whether to ignore case when autocompleting.
+// Defaults to true.
+//
+// It's possible to pass in a custom function as the 'selector'
+// option, if you prefer to write your own autocompletion logic.
+// In that case, the other options above will not apply unless
+// you support them.
+
+Autocompleter.Local = Class.create(Autocompleter.Base, {
+ initialize: function(element, update, array, options) {
+ this.baseInitialize(element, update, options);
+ this.options.array = array;
+ },
+
+ getUpdatedChoices: function() {
+ this.updateChoices(this.options.selector(this));
+ },
+
+ setOptions: function(options) {
+ this.options = Object.extend({
+ choices: 10,
+ partialSearch: true,
+ partialChars: 2,
+ ignoreCase: true,
+ fullSearch: false,
+ selector: function(instance) {
+ var ret = []; // Beginning matches
+ var partial = []; // Inside matches
+ var entry = instance.getToken();
+ var count = 0;
+
+ for (var i = 0; i < instance.options.array.length &&
+ ret.length < instance.options.choices ; i++) {
+
+ var elem = instance.options.array[i];
+ var foundPos = instance.options.ignoreCase ?
+ elem.toLowerCase().indexOf(entry.toLowerCase()) :
+ elem.indexOf(entry);
+
+ while (foundPos != -1) {
+ if (foundPos == 0 && elem.length != entry.length) {
+ ret.push("<li><strong>" + elem.substr(0, entry.length) + "</strong>" +
+ elem.substr(entry.length) + "</li>");
+ break;
+ } else if (entry.length >= instance.options.partialChars &&
+ instance.options.partialSearch && foundPos != -1) {
+ if (instance.options.fullSearch || /\s/.test(elem.substr(foundPos-1,1))) {
+ partial.push("<li>" + elem.substr(0, foundPos) + "<strong>" +
+ elem.substr(foundPos, entry.length) + "</strong>" + elem.substr(
+ foundPos + entry.length) + "</li>");
+ break;
+ }
+ }
+
+ foundPos = instance.options.ignoreCase ?
+ elem.toLowerCase().indexOf(entry.toLowerCase(), foundPos + 1) :
+ elem.indexOf(entry, foundPos + 1);
+
+ }
+ }
+ if (partial.length)
+ ret = ret.concat(partial.slice(0, instance.options.choices - ret.length));
+ return "<ul>" + ret.join('') + "</ul>";
+ }
+ }, options || { });
+ }
+});
+
+// AJAX in-place editor and collection editor
+// Full rewrite by Christophe Porteneuve <tdd@tddsworld.com> (April 2007).
+
+// Use this if you notice weird scrolling problems on some browsers,
+// the DOM might be a bit confused when this gets called so do this
+// waits 1 ms (with setTimeout) until it does the activation
+Field.scrollFreeActivate = function(field) {
+ setTimeout(function() {
+ Field.activate(field);
+ }, 1);
+};
+
+Ajax.InPlaceEditor = Class.create({
+ initialize: function(element, url, options) {
+ this.url = url;
+ this.element = element = $(element);
+ this.prepareOptions();
+ this._controls = { };
+ arguments.callee.dealWithDeprecatedOptions(options); // DEPRECATION LAYER!!!
+ Object.extend(this.options, options || { });
+ if (!this.options.formId && this.element.id) {
+ this.options.formId = this.element.id + '-inplaceeditor';
+ if ($(this.options.formId))
+ this.options.formId = '';
+ }
+ if (this.options.externalControl)
+ this.options.externalControl = $(this.options.externalControl);
+ if (!this.options.externalControl)
+ this.options.externalControlOnly = false;
+ this._originalBackground = this.element.getStyle('background-color') || 'transparent';
+ this.element.title = this.options.clickToEditText;
+ this._boundCancelHandler = this.handleFormCancellation.bind(this);
+ this._boundComplete = (this.options.onComplete || Prototype.emptyFunction).bind(this);
+ this._boundFailureHandler = this.handleAJAXFailure.bind(this);
+ this._boundSubmitHandler = this.handleFormSubmission.bind(this);
+ this._boundWrapperHandler = this.wrapUp.bind(this);
+ this.registerListeners();
+ },
+ checkForEscapeOrReturn: function(e) {
+ if (!this._editing || e.ctrlKey || e.altKey || e.shiftKey) return;
+ if (Event.KEY_ESC == e.keyCode)
+ this.handleFormCancellation(e);
+ else if (Event.KEY_RETURN == e.keyCode)
+ this.handleFormSubmission(e);
+ },
+ createControl: function(mode, handler, extraClasses) {
+ var control = this.options[mode + 'Control'];
+ var text = this.options[mode + 'Text'];
+ if ('button' == control) {
+ var btn = document.createElement('input');
+ btn.type = 'submit';
+ btn.value = text;
+ btn.className = 'editor_' + mode + '_button';
+ if ('cancel' == mode)
+ btn.onclick = this._boundCancelHandler;
+ this._form.appendChild(btn);
+ this._controls[mode] = btn;
+ } else if ('link' == control) {
+ var link = document.createElement('a');
+ link.href = '#';
+ link.appendChild(document.createTextNode(text));
+ link.onclick = 'cancel' == mode ? this._boundCancelHandler : this._boundSubmitHandler;
+ link.className = 'editor_' + mode + '_link';
+ if (extraClasses)
+ link.className += ' ' + extraClasses;
+ this._form.appendChild(link);
+ this._controls[mode] = link;
+ }
+ },
+ createEditField: function() {
+ var text = (this.options.loadTextURL ? this.options.loadingText : this.getText());
+ var fld;
+ if (1 >= this.options.rows && !/\r|\n/.test(this.getText())) {
+ fld = document.createElement('input');
+ fld.type = 'text';
+ var size = this.options.size || this.options.cols || 0;
+ if (0 < size) fld.size = size;
+ } else {
+ fld = document.createElement('textarea');
+ fld.rows = (1 >= this.options.rows ? this.options.autoRows : this.options.rows);
+ fld.cols = this.options.cols || 40;
+ }
+ fld.name = this.options.paramName;
+ fld.value = text; // No HTML breaks conversion anymore
+ fld.className = 'editor_field';
+ if (this.options.submitOnBlur)
+ fld.onblur = this._boundSubmitHandler;
+ this._controls.editor = fld;
+ if (this.options.loadTextURL)
+ this.loadExternalText();
+ this._form.appendChild(this._controls.editor);
+ },
+ createForm: function() {
+ var ipe = this;
+ function addText(mode, condition) {
+ var text = ipe.options['text' + mode + 'Controls'];
+ if (!text || condition === false) return;
+ ipe._form.appendChild(document.createTextNode(text));
+ };
+ this._form = $(document.createElement('form'));
+ this._form.id = this.options.formId;
+ this._form.addClassName(this.options.formClassName);
+ this._form.onsubmit = this._boundSubmitHandler;
+ this.createEditField();
+ if ('textarea' == this._controls.editor.tagName.toLowerCase())
+ this._form.appendChild(document.createElement('br'));
+ if (this.options.onFormCustomization)
+ this.options.onFormCustomization(this, this._form);
+ addText('Before', this.options.okControl || this.options.cancelControl);
+ this.createControl('ok', this._boundSubmitHandler);
+ addText('Between', this.options.okControl && this.options.cancelControl);
+ this.createControl('cancel', this._boundCancelHandler, 'editor_cancel');
+ addText('After', this.options.okControl || this.options.cancelControl);
+ },
+ destroy: function() {
+ if (this._oldInnerHTML)
+ this.element.innerHTML = this._oldInnerHTML;
+ this.leaveEditMode();
+ this.unregisterListeners();
+ },
+ enterEditMode: function(e) {
+ if (this._saving || this._editing) return;
+ this._editing = true;
+ this.triggerCallback('onEnterEditMode');
+ if (this.options.externalControl)
+ this.options.externalControl.hide();
+ this.element.hide();
+ this.createForm();
+ this.element.parentNode.insertBefore(this._form, this.element);
+ if (!this.options.loadTextURL)
+ this.postProcessEditField();
+ if (e) Event.stop(e);
+ },
+ enterHover: function(e) {
+ if (this.options.hoverClassName)
+ this.element.addClassName(this.options.hoverClassName);
+ if (this._saving) return;
+ this.triggerCallback('onEnterHover');
+ },
+ getText: function() {
+ return this.element.innerHTML.unescapeHTML();
+ },
+ handleAJAXFailure: function(transport) {
+ this.triggerCallback('onFailure', transport);
+ if (this._oldInnerHTML) {
+ this.element.innerHTML = this._oldInnerHTML;
+ this._oldInnerHTML = null;
+ }
+ },
+ handleFormCancellation: function(e) {
+ this.wrapUp();
+ if (e) Event.stop(e);
+ },
+ handleFormSubmission: function(e) {
+ var form = this._form;
+ var value = $F(this._controls.editor);
+ this.prepareSubmission();
+ var params = this.options.callback(form, value) || '';
+ if (Object.isString(params))
+ params = params.toQueryParams();
+ params.editorId = this.element.id;
+ if (this.options.htmlResponse) {
+ var options = Object.extend({ evalScripts: true }, this.options.ajaxOptions);
+ Object.extend(options, {
+ parameters: params,
+ onComplete: this._boundWrapperHandler,
+ onFailure: this._boundFailureHandler
+ });
+ new Ajax.Updater({ success: this.element }, this.url, options);
+ } else {
+ var options = Object.extend({ method: 'get' }, this.options.ajaxOptions);
+ Object.extend(options, {
+ parameters: params,
+ onComplete: this._boundWrapperHandler,
+ onFailure: this._boundFailureHandler
+ });
+ new Ajax.Request(this.url, options);
+ }
+ if (e) Event.stop(e);
+ },
+ leaveEditMode: function() {
+ this.element.removeClassName(this.options.savingClassName);
+ this.removeForm();
+ this.leaveHover();
+ this.element.style.backgroundColor = this._originalBackground;
+ this.element.show();
+ if (this.options.externalControl)
+ this.options.externalControl.show();
+ this._saving = false;
+ this._editing = false;
+ this._oldInnerHTML = null;
+ this.triggerCallback('onLeaveEditMode');
+ },
+ leaveHover: function(e) {
+ if (this.options.hoverClassName)
+ this.element.removeClassName(this.options.hoverClassName);
+ if (this._saving) return;
+ this.triggerCallback('onLeaveHover');
+ },
+ loadExternalText: function() {
+ this._form.addClassName(this.options.loadingClassName);
+ this._controls.editor.disabled = true;
+ var options = Object.extend({ method: 'get' }, this.options.ajaxOptions);
+ Object.extend(options, {
+ parameters: 'editorId=' + encodeURIComponent(this.element.id),
+ onComplete: Prototype.emptyFunction,
+ onSuccess: function(transport) {
+ this._form.removeClassName(this.options.loadingClassName);
+ var text = transport.responseText;
+ if (this.options.stripLoadedTextTags)
+ text = text.stripTags();
+ this._controls.editor.value = text;
+ this._controls.editor.disabled = false;
+ this.postProcessEditField();
+ }.bind(this),
+ onFailure: this._boundFailureHandler
+ });
+ new Ajax.Request(this.options.loadTextURL, options);
+ },
+ postProcessEditField: function() {
+ var fpc = this.options.fieldPostCreation;
+ if (fpc)
+ $(this._controls.editor)['focus' == fpc ? 'focus' : 'activate']();
+ },
+ prepareOptions: function() {
+ this.options = Object.clone(Ajax.InPlaceEditor.DefaultOptions);
+ Object.extend(this.options, Ajax.InPlaceEditor.DefaultCallbacks);
+ [this._extraDefaultOptions].flatten().compact().each(function(defs) {
+ Object.extend(this.options, defs);
+ }.bind(this));
+ },
+ prepareSubmission: function() {
+ this._saving = true;
+ this.removeForm();
+ this.leaveHover();
+ this.showSaving();
+ },
+ registerListeners: function() {
+ this._listeners = { };
+ var listener;
+ $H(Ajax.InPlaceEditor.Listeners).each(function(pair) {
+ listener = this[pair.value].bind(this);
+ this._listeners[pair.key] = listener;
+ if (!this.options.externalControlOnly)
+ this.element.observe(pair.key, listener);
+ if (this.options.externalControl)
+ this.options.externalControl.observe(pair.key, listener);
+ }.bind(this));
+ },
+ removeForm: function() {
+ if (!this._form) return;
+ this._form.remove();
+ this._form = null;
+ this._controls = { };
+ },
+ showSaving: function() {
+ this._oldInnerHTML = this.element.innerHTML;
+ this.element.innerHTML = this.options.savingText;
+ this.element.addClassName(this.options.savingClassName);
+ this.element.style.backgroundColor = this._originalBackground;
+ this.element.show();
+ },
+ triggerCallback: function(cbName, arg) {
+ if ('function' == typeof this.options[cbName]) {
+ this.options[cbName](this, arg);
+ }
+ },
+ unregisterListeners: function() {
+ $H(this._listeners).each(function(pair) {
+ if (!this.options.externalControlOnly)
+ this.element.stopObserving(pair.key, pair.value);
+ if (this.options.externalControl)
+ this.options.externalControl.stopObserving(pair.key, pair.value);
+ }.bind(this));
+ },
+ wrapUp: function(transport) {
+ this.leaveEditMode();
+ // Can't use triggerCallback due to backward compatibility: requires
+ // binding + direct element
+ this._boundComplete(transport, this.element);
+ }
+});
+
+Object.extend(Ajax.InPlaceEditor.prototype, {
+ dispose: Ajax.InPlaceEditor.prototype.destroy
+});
+
+Ajax.InPlaceCollectionEditor = Class.create(Ajax.InPlaceEditor, {
+ initialize: function($super, element, url, options) {
+ this._extraDefaultOptions = Ajax.InPlaceCollectionEditor.DefaultOptions;
+ $super(element, url, options);
+ },
+
+ createEditField: function() {
+ var list = document.createElement('select');
+ list.name = this.options.paramName;
+ list.size = 1;
+ this._controls.editor = list;
+ this._collection = this.options.collection || [];
+ if (this.options.loadCollectionURL)
+ this.loadCollection();
+ else
+ this.checkForExternalText();
+ this._form.appendChild(this._controls.editor);
+ },
+
+ loadCollection: function() {
+ this._form.addClassName(this.options.loadingClassName);
+ this.showLoadingText(this.options.loadingCollectionText);
+ var options = Object.extend({ method: 'get' }, this.options.ajaxOptions);
+ Object.extend(options, {
+ parameters: 'editorId=' + encodeURIComponent(this.element.id),
+ onComplete: Prototype.emptyFunction,
+ onSuccess: function(transport) {
+ var js = transport.responseText.strip();
+ if (!/^\[.*\]$/.test(js)) // TODO: improve sanity check
+ throw('Server returned an invalid collection representation.');
+ this._collection = eval(js);
+ this.checkForExternalText();
+ }.bind(this),
+ onFailure: this.onFailure
+ });
+ new Ajax.Request(this.options.loadCollectionURL, options);
+ },
+
+ showLoadingText: function(text) {
+ this._controls.editor.disabled = true;
+ var tempOption = this._controls.editor.firstChild;
+ if (!tempOption) {
+ tempOption = document.createElement('option');
+ tempOption.value = '';
+ this._controls.editor.appendChild(tempOption);
+ tempOption.selected = true;
+ }
+ tempOption.update((text || '').stripScripts().stripTags());
+ },
+
+ checkForExternalText: function() {
+ this._text = this.getText();
+ if (this.options.loadTextURL)
+ this.loadExternalText();
+ else
+ this.buildOptionList();
+ },
+
+ loadExternalText: function() {
+ this.showLoadingText(this.options.loadingText);
+ var options = Object.extend({ method: 'get' }, this.options.ajaxOptions);
+ Object.extend(options, {
+ parameters: 'editorId=' + encodeURIComponent(this.element.id),
+ onComplete: Prototype.emptyFunction,
+ onSuccess: function(transport) {
+ this._text = transport.responseText.strip();
+ this.buildOptionList();
+ }.bind(this),
+ onFailure: this.onFailure
+ });
+ new Ajax.Request(this.options.loadTextURL, options);
+ },
+
+ buildOptionList: function() {
+ this._form.removeClassName(this.options.loadingClassName);
+ this._collection = this._collection.map(function(entry) {
+ return 2 === entry.length ? entry : [entry, entry].flatten();
+ });
+ var marker = ('value' in this.options) ? this.options.value : this._text;
+ var textFound = this._collection.any(function(entry) {
+ return entry[0] == marker;
+ }.bind(this));
+ this._controls.editor.update('');
+ var option;
+ this._collection.each(function(entry, index) {
+ option = document.createElement('option');
+ option.value = entry[0];
+ option.selected = textFound ? entry[0] == marker : 0 == index;
+ option.appendChild(document.createTextNode(entry[1]));
+ this._controls.editor.appendChild(option);
+ }.bind(this));
+ this._controls.editor.disabled = false;
+ Field.scrollFreeActivate(this._controls.editor);
+ }
+});
+
+//**** DEPRECATION LAYER FOR InPlace[Collection]Editor! ****
+//**** This only exists for a while, in order to let ****
+//**** users adapt to the new API. Read up on the new ****
+//**** API and convert your code to it ASAP! ****
+
+Ajax.InPlaceEditor.prototype.initialize.dealWithDeprecatedOptions = function(options) {
+ if (!options) return;
+ function fallback(name, expr) {
+ if (name in options || expr === undefined) return;
+ options[name] = expr;
+ };
+ fallback('cancelControl', (options.cancelLink ? 'link' : (options.cancelButton ? 'button' :
+ options.cancelLink == options.cancelButton == false ? false : undefined)));
+ fallback('okControl', (options.okLink ? 'link' : (options.okButton ? 'button' :
+ options.okLink == options.okButton == false ? false : undefined)));
+ fallback('highlightColor', options.highlightcolor);
+ fallback('highlightEndColor', options.highlightendcolor);
+};
+
+Object.extend(Ajax.InPlaceEditor, {
+ DefaultOptions: {
+ ajaxOptions: { },
+ autoRows: 3, // Use when multi-line w/ rows == 1
+ cancelControl: 'link', // 'link'|'button'|false
+ cancelText: 'cancel',
+ clickToEditText: 'Click to edit',
+ externalControl: null, // id|elt
+ externalControlOnly: false,
+ fieldPostCreation: 'activate', // 'activate'|'focus'|false
+ formClassName: 'inplaceeditor-form',
+ formId: null, // id|elt
+ highlightColor: '#ffff99',
+ highlightEndColor: '#ffffff',
+ hoverClassName: '',
+ htmlResponse: true,
+ loadingClassName: 'inplaceeditor-loading',
+ loadingText: 'Loading...',
+ okControl: 'button', // 'link'|'button'|false
+ okText: 'ok',
+ paramName: 'value',
+ rows: 1, // If 1 and multi-line, uses autoRows
+ savingClassName: 'inplaceeditor-saving',
+ savingText: 'Saving...',
+ size: 0,
+ stripLoadedTextTags: false,
+ submitOnBlur: false,
+ textAfterControls: '',
+ textBeforeControls: '',
+ textBetweenControls: ''
+ },
+ DefaultCallbacks: {
+ callback: function(form) {
+ return Form.serialize(form);
+ },
+ onComplete: function(transport, element) {
+ // For backward compatibility, this one is bound to the IPE, and passes
+ // the element directly. It was too often customized, so we don't break it.
+ new Effect.Highlight(element, {
+ startcolor: this.options.highlightColor, keepBackgroundImage: true });
+ },
+ onEnterEditMode: null,
+ onEnterHover: function(ipe) {
+ ipe.element.style.backgroundColor = ipe.options.highlightColor;
+ if (ipe._effect)
+ ipe._effect.cancel();
+ },
+ onFailure: function(transport, ipe) {
+ alert('Error communication with the server: ' + transport.responseText.stripTags());
+ },
+ onFormCustomization: null, // Takes the IPE and its generated form, after editor, before controls.
+ onLeaveEditMode: null,
+ onLeaveHover: function(ipe) {
+ ipe._effect = new Effect.Highlight(ipe.element, {
+ startcolor: ipe.options.highlightColor, endcolor: ipe.options.highlightEndColor,
+ restorecolor: ipe._originalBackground, keepBackgroundImage: true
+ });
+ }
+ },
+ Listeners: {
+ click: 'enterEditMode',
+ keydown: 'checkForEscapeOrReturn',
+ mouseover: 'enterHover',
+ mouseout: 'leaveHover'
+ }
+});
+
+Ajax.InPlaceCollectionEditor.DefaultOptions = {
+ loadingCollectionText: 'Loading options...'
+};
+
+// Delayed observer, like Form.Element.Observer,
+// but waits for delay after last key input
+// Ideal for live-search fields
+
+Form.Element.DelayedObserver = Class.create({
+ initialize: function(element, delay, callback) {
+ this.delay = delay || 0.5;
+ this.element = $(element);
+ this.callback = callback;
+ this.timer = null;
+ this.lastValue = $F(this.element);
+ Event.observe(this.element,'keyup',this.delayedListener.bindAsEventListener(this));
+ },
+ delayedListener: function(event) {
+ if(this.lastValue == $F(this.element)) return;
+ if(this.timer) clearTimeout(this.timer);
+ this.timer = setTimeout(this.onTimerEvent.bind(this), this.delay * 1000);
+ this.lastValue = $F(this.element);
+ },
+ onTimerEvent: function() {
+ this.timer = null;
+ this.callback(this.element, $F(this.element));
+ }
+}); \ No newline at end of file
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/dragdrop.js b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/dragdrop.js
new file mode 100644
index 0000000..07c98e2
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/dragdrop.js
@@ -0,0 +1,975 @@
+// script.aculo.us dragdrop.js v1.8.2, Tue Nov 18 18:30:58 +0100 2008
+
+// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+// (c) 2005-2008 Sammi Williams (http://www.oriontransfer.co.nz, sammi@oriontransfer.co.nz)
+//
+// script.aculo.us is freely distributable under the terms of an MIT-style license.
+// For details, see the script.aculo.us web site: http://script.aculo.us/
+
+if(Object.isUndefined(Effect))
+ throw("dragdrop.js requires including script.aculo.us' effects.js library");
+
+var Droppables = {
+ drops: [],
+
+ remove: function(element) {
+ this.drops = this.drops.reject(function(d) { return d.element==$(element) });
+ },
+
+ add: function(element) {
+ element = $(element);
+ var options = Object.extend({
+ greedy: true,
+ hoverclass: null,
+ tree: false
+ }, arguments[1] || { });
+
+ // cache containers
+ if(options.containment) {
+ options._containers = [];
+ var containment = options.containment;
+ if(Object.isArray(containment)) {
+ containment.each( function(c) { options._containers.push($(c)) });
+ } else {
+ options._containers.push($(containment));
+ }
+ }
+
+ if(options.accept) options.accept = [options.accept].flatten();
+
+ Element.makePositioned(element); // fix IE
+ options.element = element;
+
+ this.drops.push(options);
+ },
+
+ findDeepestChild: function(drops) {
+ deepest = drops[0];
+
+ for (i = 1; i < drops.length; ++i)
+ if (Element.isParent(drops[i].element, deepest.element))
+ deepest = drops[i];
+
+ return deepest;
+ },
+
+ isContained: function(element, drop) {
+ var containmentNode;
+ if(drop.tree) {
+ containmentNode = element.treeNode;
+ } else {
+ containmentNode = element.parentNode;
+ }
+ return drop._containers.detect(function(c) { return containmentNode == c });
+ },
+
+ isAffected: function(point, element, drop) {
+ return (
+ (drop.element!=element) &&
+ ((!drop._containers) ||
+ this.isContained(element, drop)) &&
+ ((!drop.accept) ||
+ (Element.classNames(element).detect(
+ function(v) { return drop.accept.include(v) } ) )) &&
+ Position.within(drop.element, point[0], point[1]) );
+ },
+
+ deactivate: function(drop) {
+ if(drop.hoverclass)
+ Element.removeClassName(drop.element, drop.hoverclass);
+ this.last_active = null;
+ },
+
+ activate: function(drop) {
+ if(drop.hoverclass)
+ Element.addClassName(drop.element, drop.hoverclass);
+ this.last_active = drop;
+ },
+
+ show: function(point, element) {
+ if(!this.drops.length) return;
+ var drop, affected = [];
+
+ this.drops.each( function(drop) {
+ if(Droppables.isAffected(point, element, drop))
+ affected.push(drop);
+ });
+
+ if(affected.length>0)
+ drop = Droppables.findDeepestChild(affected);
+
+ if(this.last_active && this.last_active != drop) this.deactivate(this.last_active);
+ if (drop) {
+ Position.within(drop.element, point[0], point[1]);
+ if(drop.onHover)
+ drop.onHover(element, drop.element, Position.overlap(drop.overlap, drop.element));
+
+ if (drop != this.last_active) Droppables.activate(drop);
+ }
+ },
+
+ fire: function(event, element) {
+ if(!this.last_active) return;
+ Position.prepare();
+
+ if (this.isAffected([Event.pointerX(event), Event.pointerY(event)], element, this.last_active))
+ if (this.last_active.onDrop) {
+ this.last_active.onDrop(element, this.last_active.element, event);
+ return true;
+ }
+ },
+
+ reset: function() {
+ if(this.last_active)
+ this.deactivate(this.last_active);
+ }
+};
+
+var Draggables = {
+ drags: [],
+ observers: [],
+
+ register: function(draggable) {
+ if(this.drags.length == 0) {
+ this.eventMouseUp = this.endDrag.bindAsEventListener(this);
+ this.eventMouseMove = this.updateDrag.bindAsEventListener(this);
+ this.eventKeypress = this.keyPress.bindAsEventListener(this);
+
+ Event.observe(document, "mouseup", this.eventMouseUp);
+ Event.observe(document, "mousemove", this.eventMouseMove);
+ Event.observe(document, "keypress", this.eventKeypress);
+ }
+ this.drags.push(draggable);
+ },
+
+ unregister: function(draggable) {
+ this.drags = this.drags.reject(function(d) { return d==draggable });
+ if(this.drags.length == 0) {
+ Event.stopObserving(document, "mouseup", this.eventMouseUp);
+ Event.stopObserving(document, "mousemove", this.eventMouseMove);
+ Event.stopObserving(document, "keypress", this.eventKeypress);
+ }
+ },
+
+ activate: function(draggable) {
+ if(draggable.options.delay) {
+ this._timeout = setTimeout(function() {
+ Draggables._timeout = null;
+ window.focus();
+ Draggables.activeDraggable = draggable;
+ }.bind(this), draggable.options.delay);
+ } else {
+ window.focus(); // allows keypress events if window isn't currently focused, fails for Safari
+ this.activeDraggable = draggable;
+ }
+ },
+
+ deactivate: function() {
+ this.activeDraggable = null;
+ },
+
+ updateDrag: function(event) {
+ if(!this.activeDraggable) return;
+ var pointer = [Event.pointerX(event), Event.pointerY(event)];
+ // Mozilla-based browsers fire successive mousemove events with
+ // the same coordinates, prevent needless redrawing (moz bug?)
+ if(this._lastPointer && (this._lastPointer.inspect() == pointer.inspect())) return;
+ this._lastPointer = pointer;
+
+ this.activeDraggable.updateDrag(event, pointer);
+ },
+
+ endDrag: function(event) {
+ if(this._timeout) {
+ clearTimeout(this._timeout);
+ this._timeout = null;
+ }
+ if(!this.activeDraggable) return;
+ this._lastPointer = null;
+ this.activeDraggable.endDrag(event);
+ this.activeDraggable = null;
+ },
+
+ keyPress: function(event) {
+ if(this.activeDraggable)
+ this.activeDraggable.keyPress(event);
+ },
+
+ addObserver: function(observer) {
+ this.observers.push(observer);
+ this._cacheObserverCallbacks();
+ },
+
+ removeObserver: function(element) { // element instead of observer fixes mem leaks
+ this.observers = this.observers.reject( function(o) { return o.element==element });
+ this._cacheObserverCallbacks();
+ },
+
+ notify: function(eventName, draggable, event) { // 'onStart', 'onEnd', 'onDrag'
+ if(this[eventName+'Count'] > 0)
+ this.observers.each( function(o) {
+ if(o[eventName]) o[eventName](eventName, draggable, event);
+ });
+ if(draggable.options[eventName]) draggable.options[eventName](draggable, event);
+ },
+
+ _cacheObserverCallbacks: function() {
+ ['onStart','onEnd','onDrag'].each( function(eventName) {
+ Draggables[eventName+'Count'] = Draggables.observers.select(
+ function(o) { return o[eventName]; }
+ ).length;
+ });
+ }
+};
+
+/*--------------------------------------------------------------------------*/
+
+var Draggable = Class.create({
+ initialize: function(element) {
+ var defaults = {
+ handle: false,
+ reverteffect: function(element, top_offset, left_offset) {
+ var dur = Math.sqrt(Math.abs(top_offset^2)+Math.abs(left_offset^2))*0.02;
+ new Effect.Move(element, { x: -left_offset, y: -top_offset, duration: dur,
+ queue: {scope:'_draggable', position:'end'}
+ });
+ },
+ endeffect: function(element) {
+ var toOpacity = Object.isNumber(element._opacity) ? element._opacity : 1.0;
+ new Effect.Opacity(element, {duration:0.2, from:0.7, to:toOpacity,
+ queue: {scope:'_draggable', position:'end'},
+ afterFinish: function(){
+ Draggable._dragging[element] = false
+ }
+ });
+ },
+ zindex: 1000,
+ revert: false,
+ quiet: false,
+ scroll: false,
+ scrollSensitivity: 20,
+ scrollSpeed: 15,
+ snap: false, // false, or xy or [x,y] or function(x,y){ return [x,y] }
+ delay: 0
+ };
+
+ if(!arguments[1] || Object.isUndefined(arguments[1].endeffect))
+ Object.extend(defaults, {
+ starteffect: function(element) {
+ element._opacity = Element.getOpacity(element);
+ Draggable._dragging[element] = true;
+ new Effect.Opacity(element, {duration:0.2, from:element._opacity, to:0.7});
+ }
+ });
+
+ var options = Object.extend(defaults, arguments[1] || { });
+
+ this.element = $(element);
+
+ if(options.handle && Object.isString(options.handle))
+ this.handle = this.element.down('.'+options.handle, 0);
+
+ if(!this.handle) this.handle = $(options.handle);
+ if(!this.handle) this.handle = this.element;
+
+ if(options.scroll && !options.scroll.scrollTo && !options.scroll.outerHTML) {
+ options.scroll = $(options.scroll);
+ this._isScrollChild = Element.childOf(this.element, options.scroll);
+ }
+
+ Element.makePositioned(this.element); // fix IE
+
+ this.options = options;
+ this.dragging = false;
+
+ this.eventMouseDown = this.initDrag.bindAsEventListener(this);
+ Event.observe(this.handle, "mousedown", this.eventMouseDown);
+
+ Draggables.register(this);
+ },
+
+ destroy: function() {
+ Event.stopObserving(this.handle, "mousedown", this.eventMouseDown);
+ Draggables.unregister(this);
+ },
+
+ currentDelta: function() {
+ return([
+ parseInt(Element.getStyle(this.element,'left') || '0'),
+ parseInt(Element.getStyle(this.element,'top') || '0')]);
+ },
+
+ initDrag: function(event) {
+ if(!Object.isUndefined(Draggable._dragging[this.element]) &&
+ Draggable._dragging[this.element]) return;
+ if(Event.isLeftClick(event)) {
+ // abort on form elements, fixes a Firefox issue
+ var src = Event.element(event);
+ if((tag_name = src.tagName.toUpperCase()) && (
+ tag_name=='INPUT' ||
+ tag_name=='SELECT' ||
+ tag_name=='OPTION' ||
+ tag_name=='BUTTON' ||
+ tag_name=='TEXTAREA')) return;
+
+ var pointer = [Event.pointerX(event), Event.pointerY(event)];
+ var pos = Position.cumulativeOffset(this.element);
+ this.offset = [0,1].map( function(i) { return (pointer[i] - pos[i]) });
+
+ Draggables.activate(this);
+ Event.stop(event);
+ }
+ },
+
+ startDrag: function(event) {
+ this.dragging = true;
+ if(!this.delta)
+ this.delta = this.currentDelta();
+
+ if(this.options.zindex) {
+ this.originalZ = parseInt(Element.getStyle(this.element,'z-index') || 0);
+ this.element.style.zIndex = this.options.zindex;
+ }
+
+ if(this.options.ghosting) {
+ this._clone = this.element.cloneNode(true);
+ this._originallyAbsolute = (this.element.getStyle('position') == 'absolute');
+ if (!this._originallyAbsolute)
+ Position.absolutize(this.element);
+ this.element.parentNode.insertBefore(this._clone, this.element);
+ }
+
+ if(this.options.scroll) {
+ if (this.options.scroll == window) {
+ var where = this._getWindowScroll(this.options.scroll);
+ this.originalScrollLeft = where.left;
+ this.originalScrollTop = where.top;
+ } else {
+ this.originalScrollLeft = this.options.scroll.scrollLeft;
+ this.originalScrollTop = this.options.scroll.scrollTop;
+ }
+ }
+
+ Draggables.notify('onStart', this, event);
+
+ if(this.options.starteffect) this.options.starteffect(this.element);
+ },
+
+ updateDrag: function(event, pointer) {
+ if(!this.dragging) this.startDrag(event);
+
+ if(!this.options.quiet){
+ Position.prepare();
+ Droppables.show(pointer, this.element);
+ }
+
+ Draggables.notify('onDrag', this, event);
+
+ this.draw(pointer);
+ if(this.options.change) this.options.change(this);
+
+ if(this.options.scroll) {
+ this.stopScrolling();
+
+ var p;
+ if (this.options.scroll == window) {
+ with(this._getWindowScroll(this.options.scroll)) { p = [ left, top, left+width, top+height ]; }
+ } else {
+ p = Position.page(this.options.scroll);
+ p[0] += this.options.scroll.scrollLeft + Position.deltaX;
+ p[1] += this.options.scroll.scrollTop + Position.deltaY;
+ p.push(p[0]+this.options.scroll.offsetWidth);
+ p.push(p[1]+this.options.scroll.offsetHeight);
+ }
+ var speed = [0,0];
+ if(pointer[0] < (p[0]+this.options.scrollSensitivity)) speed[0] = pointer[0]-(p[0]+this.options.scrollSensitivity);
+ if(pointer[1] < (p[1]+this.options.scrollSensitivity)) speed[1] = pointer[1]-(p[1]+this.options.scrollSensitivity);
+ if(pointer[0] > (p[2]-this.options.scrollSensitivity)) speed[0] = pointer[0]-(p[2]-this.options.scrollSensitivity);
+ if(pointer[1] > (p[3]-this.options.scrollSensitivity)) speed[1] = pointer[1]-(p[3]-this.options.scrollSensitivity);
+ this.startScrolling(speed);
+ }
+
+ // fix AppleWebKit rendering
+ if(Prototype.Browser.WebKit) window.scrollBy(0,0);
+
+ Event.stop(event);
+ },
+
+ finishDrag: function(event, success) {
+ this.dragging = false;
+
+ if(this.options.quiet){
+ Position.prepare();
+ var pointer = [Event.pointerX(event), Event.pointerY(event)];
+ Droppables.show(pointer, this.element);
+ }
+
+ if(this.options.ghosting) {
+ if (!this._originallyAbsolute)
+ Position.relativize(this.element);
+ delete this._originallyAbsolute;
+ Element.remove(this._clone);
+ this._clone = null;
+ }
+
+ var dropped = false;
+ if(success) {
+ dropped = Droppables.fire(event, this.element);
+ if (!dropped) dropped = false;
+ }
+ if(dropped && this.options.onDropped) this.options.onDropped(this.element);
+ Draggables.notify('onEnd', this, event);
+
+ var revert = this.options.revert;
+ if(revert && Object.isFunction(revert)) revert = revert(this.element);
+
+ var d = this.currentDelta();
+ if(revert && this.options.reverteffect) {
+ if (dropped == 0 || revert != 'failure')
+ this.options.reverteffect(this.element,
+ d[1]-this.delta[1], d[0]-this.delta[0]);
+ } else {
+ this.delta = d;
+ }
+
+ if(this.options.zindex)
+ this.element.style.zIndex = this.originalZ;
+
+ if(this.options.endeffect)
+ this.options.endeffect(this.element);
+
+ Draggables.deactivate(this);
+ Droppables.reset();
+ },
+
+ keyPress: function(event) {
+ if(event.keyCode!=Event.KEY_ESC) return;
+ this.finishDrag(event, false);
+ Event.stop(event);
+ },
+
+ endDrag: function(event) {
+ if(!this.dragging) return;
+ this.stopScrolling();
+ this.finishDrag(event, true);
+ Event.stop(event);
+ },
+
+ draw: function(point) {
+ var pos = Position.cumulativeOffset(this.element);
+ if(this.options.ghosting) {
+ var r = Position.realOffset(this.element);
+ pos[0] += r[0] - Position.deltaX; pos[1] += r[1] - Position.deltaY;
+ }
+
+ var d = this.currentDelta();
+ pos[0] -= d[0]; pos[1] -= d[1];
+
+ if(this.options.scroll && (this.options.scroll != window && this._isScrollChild)) {
+ pos[0] -= this.options.scroll.scrollLeft-this.originalScrollLeft;
+ pos[1] -= this.options.scroll.scrollTop-this.originalScrollTop;
+ }
+
+ var p = [0,1].map(function(i){
+ return (point[i]-pos[i]-this.offset[i])
+ }.bind(this));
+
+ if(this.options.snap) {
+ if(Object.isFunction(this.options.snap)) {
+ p = this.options.snap(p[0],p[1],this);
+ } else {
+ if(Object.isArray(this.options.snap)) {
+ p = p.map( function(v, i) {
+ return (v/this.options.snap[i]).round()*this.options.snap[i] }.bind(this));
+ } else {
+ p = p.map( function(v) {
+ return (v/this.options.snap).round()*this.options.snap }.bind(this));
+ }
+ }}
+
+ var style = this.element.style;
+ if((!this.options.constraint) || (this.options.constraint=='horizontal'))
+ style.left = p[0] + "px";
+ if((!this.options.constraint) || (this.options.constraint=='vertical'))
+ style.top = p[1] + "px";
+
+ if(style.visibility=="hidden") style.visibility = ""; // fix gecko rendering
+ },
+
+ stopScrolling: function() {
+ if(this.scrollInterval) {
+ clearInterval(this.scrollInterval);
+ this.scrollInterval = null;
+ Draggables._lastScrollPointer = null;
+ }
+ },
+
+ startScrolling: function(speed) {
+ if(!(speed[0] || speed[1])) return;
+ this.scrollSpeed = [speed[0]*this.options.scrollSpeed,speed[1]*this.options.scrollSpeed];
+ this.lastScrolled = new Date();
+ this.scrollInterval = setInterval(this.scroll.bind(this), 10);
+ },
+
+ scroll: function() {
+ var current = new Date();
+ var delta = current - this.lastScrolled;
+ this.lastScrolled = current;
+ if(this.options.scroll == window) {
+ with (this._getWindowScroll(this.options.scroll)) {
+ if (this.scrollSpeed[0] || this.scrollSpeed[1]) {
+ var d = delta / 1000;
+ this.options.scroll.scrollTo( left + d*this.scrollSpeed[0], top + d*this.scrollSpeed[1] );
+ }
+ }
+ } else {
+ this.options.scroll.scrollLeft += this.scrollSpeed[0] * delta / 1000;
+ this.options.scroll.scrollTop += this.scrollSpeed[1] * delta / 1000;
+ }
+
+ Position.prepare();
+ Droppables.show(Draggables._lastPointer, this.element);
+ Draggables.notify('onDrag', this);
+ if (this._isScrollChild) {
+ Draggables._lastScrollPointer = Draggables._lastScrollPointer || $A(Draggables._lastPointer);
+ Draggables._lastScrollPointer[0] += this.scrollSpeed[0] * delta / 1000;
+ Draggables._lastScrollPointer[1] += this.scrollSpeed[1] * delta / 1000;
+ if (Draggables._lastScrollPointer[0] < 0)
+ Draggables._lastScrollPointer[0] = 0;
+ if (Draggables._lastScrollPointer[1] < 0)
+ Draggables._lastScrollPointer[1] = 0;
+ this.draw(Draggables._lastScrollPointer);
+ }
+
+ if(this.options.change) this.options.change(this);
+ },
+
+ _getWindowScroll: function(w) {
+ var T, L, W, H;
+ with (w.document) {
+ if (w.document.documentElement && documentElement.scrollTop) {
+ T = documentElement.scrollTop;
+ L = documentElement.scrollLeft;
+ } else if (w.document.body) {
+ T = body.scrollTop;
+ L = body.scrollLeft;
+ }
+ if (w.innerWidth) {
+ W = w.innerWidth;
+ H = w.innerHeight;
+ } else if (w.document.documentElement && documentElement.clientWidth) {
+ W = documentElement.clientWidth;
+ H = documentElement.clientHeight;
+ } else {
+ W = body.offsetWidth;
+ H = body.offsetHeight;
+ }
+ }
+ return { top: T, left: L, width: W, height: H };
+ }
+});
+
+Draggable._dragging = { };
+
+/*--------------------------------------------------------------------------*/
+
+var SortableObserver = Class.create({
+ initialize: function(element, observer) {
+ this.element = $(element);
+ this.observer = observer;
+ this.lastValue = Sortable.serialize(this.element);
+ },
+
+ onStart: function() {
+ this.lastValue = Sortable.serialize(this.element);
+ },
+
+ onEnd: function() {
+ Sortable.unmark();
+ if(this.lastValue != Sortable.serialize(this.element))
+ this.observer(this.element)
+ }
+});
+
+var Sortable = {
+ SERIALIZE_RULE: /^[^_\-](?:[A-Za-z0-9\-\_]*)[_](.*)$/,
+
+ sortables: { },
+
+ _findRootElement: function(element) {
+ while (element.tagName.toUpperCase() != "BODY") {
+ if(element.id && Sortable.sortables[element.id]) return element;
+ element = element.parentNode;
+ }
+ },
+
+ options: function(element) {
+ element = Sortable._findRootElement($(element));
+ if(!element) return;
+ return Sortable.sortables[element.id];
+ },
+
+ destroy: function(element){
+ element = $(element);
+ var s = Sortable.sortables[element.id];
+
+ if(s) {
+ Draggables.removeObserver(s.element);
+ s.droppables.each(function(d){ Droppables.remove(d) });
+ s.draggables.invoke('destroy');
+
+ delete Sortable.sortables[s.element.id];
+ }
+ },
+
+ create: function(element) {
+ element = $(element);
+ var options = Object.extend({
+ element: element,
+ tag: 'li', // assumes li children, override with tag: 'tagname'
+ dropOnEmpty: false,
+ tree: false,
+ treeTag: 'ul',
+ overlap: 'vertical', // one of 'vertical', 'horizontal'
+ constraint: 'vertical', // one of 'vertical', 'horizontal', false
+ containment: element, // also takes array of elements (or id's); or false
+ handle: false, // or a CSS class
+ only: false,
+ delay: 0,
+ hoverclass: null,
+ ghosting: false,
+ quiet: false,
+ scroll: false,
+ scrollSensitivity: 20,
+ scrollSpeed: 15,
+ format: this.SERIALIZE_RULE,
+
+ // these take arrays of elements or ids and can be
+ // used for better initialization performance
+ elements: false,
+ handles: false,
+
+ onChange: Prototype.emptyFunction,
+ onUpdate: Prototype.emptyFunction
+ }, arguments[1] || { });
+
+ // clear any old sortable with same element
+ this.destroy(element);
+
+ // build options for the draggables
+ var options_for_draggable = {
+ revert: true,
+ quiet: options.quiet,
+ scroll: options.scroll,
+ scrollSpeed: options.scrollSpeed,
+ scrollSensitivity: options.scrollSensitivity,
+ delay: options.delay,
+ ghosting: options.ghosting,
+ constraint: options.constraint,
+ handle: options.handle };
+
+ if(options.starteffect)
+ options_for_draggable.starteffect = options.starteffect;
+
+ if(options.reverteffect)
+ options_for_draggable.reverteffect = options.reverteffect;
+ else
+ if(options.ghosting) options_for_draggable.reverteffect = function(element) {
+ element.style.top = 0;
+ element.style.left = 0;
+ };
+
+ if(options.endeffect)
+ options_for_draggable.endeffect = options.endeffect;
+
+ if(options.zindex)
+ options_for_draggable.zindex = options.zindex;
+
+ // build options for the droppables
+ var options_for_droppable = {
+ overlap: options.overlap,
+ containment: options.containment,
+ tree: options.tree,
+ hoverclass: options.hoverclass,
+ onHover: Sortable.onHover
+ };
+
+ var options_for_tree = {
+ onHover: Sortable.onEmptyHover,
+ overlap: options.overlap,
+ containment: options.containment,
+ hoverclass: options.hoverclass
+ };
+
+ // fix for gecko engine
+ Element.cleanWhitespace(element);
+
+ options.draggables = [];
+ options.droppables = [];
+
+ // drop on empty handling
+ if(options.dropOnEmpty || options.tree) {
+ Droppables.add(element, options_for_tree);
+ options.droppables.push(element);
+ }
+
+ (options.elements || this.findElements(element, options) || []).each( function(e,i) {
+ var handle = options.handles ? $(options.handles[i]) :
+ (options.handle ? $(e).select('.' + options.handle)[0] : e);
+ options.draggables.push(
+ new Draggable(e, Object.extend(options_for_draggable, { handle: handle })));
+ Droppables.add(e, options_for_droppable);
+ if(options.tree) e.treeNode = element;
+ options.droppables.push(e);
+ });
+
+ if(options.tree) {
+ (Sortable.findTreeElements(element, options) || []).each( function(e) {
+ Droppables.add(e, options_for_tree);
+ e.treeNode = element;
+ options.droppables.push(e);
+ });
+ }
+
+ // keep reference
+ this.sortables[element.id] = options;
+
+ // for onupdate
+ Draggables.addObserver(new SortableObserver(element, options.onUpdate));
+
+ },
+
+ // return all suitable-for-sortable elements in a guaranteed order
+ findElements: function(element, options) {
+ return Element.findChildren(
+ element, options.only, options.tree ? true : false, options.tag);
+ },
+
+ findTreeElements: function(element, options) {
+ return Element.findChildren(
+ element, options.only, options.tree ? true : false, options.treeTag);
+ },
+
+ onHover: function(element, dropon, overlap) {
+ if(Element.isParent(dropon, element)) return;
+
+ if(overlap > .33 && overlap < .66 && Sortable.options(dropon).tree) {
+ return;
+ } else if(overlap>0.5) {
+ Sortable.mark(dropon, 'before');
+ if(dropon.previousSibling != element) {
+ var oldParentNode = element.parentNode;
+ element.style.visibility = "hidden"; // fix gecko rendering
+ dropon.parentNode.insertBefore(element, dropon);
+ if(dropon.parentNode!=oldParentNode)
+ Sortable.options(oldParentNode).onChange(element);
+ Sortable.options(dropon.parentNode).onChange(element);
+ }
+ } else {
+ Sortable.mark(dropon, 'after');
+ var nextElement = dropon.nextSibling || null;
+ if(nextElement != element) {
+ var oldParentNode = element.parentNode;
+ element.style.visibility = "hidden"; // fix gecko rendering
+ dropon.parentNode.insertBefore(element, nextElement);
+ if(dropon.parentNode!=oldParentNode)
+ Sortable.options(oldParentNode).onChange(element);
+ Sortable.options(dropon.parentNode).onChange(element);
+ }
+ }
+ },
+
+ onEmptyHover: function(element, dropon, overlap) {
+ var oldParentNode = element.parentNode;
+ var droponOptions = Sortable.options(dropon);
+
+ if(!Element.isParent(dropon, element)) {
+ var index;
+
+ var children = Sortable.findElements(dropon, {tag: droponOptions.tag, only: droponOptions.only});
+ var child = null;
+
+ if(children) {
+ var offset = Element.offsetSize(dropon, droponOptions.overlap) * (1.0 - overlap);
+
+ for (index = 0; index < children.length; index += 1) {
+ if (offset - Element.offsetSize (children[index], droponOptions.overlap) >= 0) {
+ offset -= Element.offsetSize (children[index], droponOptions.overlap);
+ } else if (offset - (Element.offsetSize (children[index], droponOptions.overlap) / 2) >= 0) {
+ child = index + 1 < children.length ? children[index + 1] : null;
+ break;
+ } else {
+ child = children[index];
+ break;
+ }
+ }
+ }
+
+ dropon.insertBefore(element, child);
+
+ Sortable.options(oldParentNode).onChange(element);
+ droponOptions.onChange(element);
+ }
+ },
+
+ unmark: function() {
+ if(Sortable._marker) Sortable._marker.hide();
+ },
+
+ mark: function(dropon, position) {
+ // mark on ghosting only
+ var sortable = Sortable.options(dropon.parentNode);
+ if(sortable && !sortable.ghosting) return;
+
+ if(!Sortable._marker) {
+ Sortable._marker =
+ ($('dropmarker') || Element.extend(document.createElement('DIV'))).
+ hide().addClassName('dropmarker').setStyle({position:'absolute'});
+ document.getElementsByTagName("body").item(0).appendChild(Sortable._marker);
+ }
+ var offsets = Position.cumulativeOffset(dropon);
+ Sortable._marker.setStyle({left: offsets[0]+'px', top: offsets[1] + 'px'});
+
+ if(position=='after')
+ if(sortable.overlap == 'horizontal')
+ Sortable._marker.setStyle({left: (offsets[0]+dropon.clientWidth) + 'px'});
+ else
+ Sortable._marker.setStyle({top: (offsets[1]+dropon.clientHeight) + 'px'});
+
+ Sortable._marker.show();
+ },
+
+ _tree: function(element, options, parent) {
+ var children = Sortable.findElements(element, options) || [];
+
+ for (var i = 0; i < children.length; ++i) {
+ var match = children[i].id.match(options.format);
+
+ if (!match) continue;
+
+ var child = {
+ id: encodeURIComponent(match ? match[1] : null),
+ element: element,
+ parent: parent,
+ children: [],
+ position: parent.children.length,
+ container: $(children[i]).down(options.treeTag)
+ };
+
+ /* Get the element containing the children and recurse over it */
+ if (child.container)
+ this._tree(child.container, options, child);
+
+ parent.children.push (child);
+ }
+
+ return parent;
+ },
+
+ tree: function(element) {
+ element = $(element);
+ var sortableOptions = this.options(element);
+ var options = Object.extend({
+ tag: sortableOptions.tag,
+ treeTag: sortableOptions.treeTag,
+ only: sortableOptions.only,
+ name: element.id,
+ format: sortableOptions.format
+ }, arguments[1] || { });
+
+ var root = {
+ id: null,
+ parent: null,
+ children: [],
+ container: element,
+ position: 0
+ };
+
+ return Sortable._tree(element, options, root);
+ },
+
+ /* Construct a [i] index for a particular node */
+ _constructIndex: function(node) {
+ var index = '';
+ do {
+ if (node.id) index = '[' + node.position + ']' + index;
+ } while ((node = node.parent) != null);
+ return index;
+ },
+
+ sequence: function(element) {
+ element = $(element);
+ var options = Object.extend(this.options(element), arguments[1] || { });
+
+ return $(this.findElements(element, options) || []).map( function(item) {
+ return item.id.match(options.format) ? item.id.match(options.format)[1] : '';
+ });
+ },
+
+ setSequence: function(element, new_sequence) {
+ element = $(element);
+ var options = Object.extend(this.options(element), arguments[2] || { });
+
+ var nodeMap = { };
+ this.findElements(element, options).each( function(n) {
+ if (n.id.match(options.format))
+ nodeMap[n.id.match(options.format)[1]] = [n, n.parentNode];
+ n.parentNode.removeChild(n);
+ });
+
+ new_sequence.each(function(ident) {
+ var n = nodeMap[ident];
+ if (n) {
+ n[1].appendChild(n[0]);
+ delete nodeMap[ident];
+ }
+ });
+ },
+
+ serialize: function(element) {
+ element = $(element);
+ var options = Object.extend(Sortable.options(element), arguments[1] || { });
+ var name = encodeURIComponent(
+ (arguments[1] && arguments[1].name) ? arguments[1].name : element.id);
+
+ if (options.tree) {
+ return Sortable.tree(element, arguments[1]).children.map( function (item) {
+ return [name + Sortable._constructIndex(item) + "[id]=" +
+ encodeURIComponent(item.id)].concat(item.children.map(arguments.callee));
+ }).flatten().join('&');
+ } else {
+ return Sortable.sequence(element, arguments[1]).map( function(item) {
+ return name + "[]=" + encodeURIComponent(item);
+ }).join('&');
+ }
+ }
+};
+
+// Returns true if child is contained within element
+Element.isParent = function(child, element) {
+ if (!child.parentNode || child == element) return false;
+ if (child.parentNode == element) return true;
+ return Element.isParent(child.parentNode, element);
+};
+
+Element.findChildren = function(element, only, recursive, tagName) {
+ if(!element.hasChildNodes()) return null;
+ tagName = tagName.toUpperCase();
+ if(only) only = [only].flatten();
+ var elements = [];
+ $A(element.childNodes).each( function(e) {
+ if(e.tagName && e.tagName.toUpperCase()==tagName &&
+ (!only || (Element.classNames(e).detect(function(v) { return only.include(v) }))))
+ elements.push(e);
+ if(recursive) {
+ var grandchildren = Element.findChildren(e, only, recursive, tagName);
+ if(grandchildren) elements.push(grandchildren);
+ }
+ });
+
+ return (elements.length>0 ? elements.flatten() : []);
+};
+
+Element.offsetSize = function (element, type) {
+ return element['offset' + ((type=='vertical' || type=='height') ? 'Height' : 'Width')];
+}; \ No newline at end of file
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/effects.js b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/effects.js
new file mode 100644
index 0000000..f31a81a
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/effects.js
@@ -0,0 +1,1130 @@
+// script.aculo.us effects.js v1.8.2, Tue Nov 18 18:30:58 +0100 2008
+
+// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+// Contributors:
+// Justin Palmer (http://encytemedia.com/)
+// Mark Pilgrim (http://diveintomark.org/)
+// Martin Bialasinki
+//
+// script.aculo.us is freely distributable under the terms of an MIT-style license.
+// For details, see the script.aculo.us web site: http://script.aculo.us/
+
+// converts rgb() and #xxx to #xxxxxx format,
+// returns self (or first argument) if not convertable
+String.prototype.parseColor = function() {
+ var color = '#';
+ if (this.slice(0,4) == 'rgb(') {
+ var cols = this.slice(4,this.length-1).split(',');
+ var i=0; do { color += parseInt(cols[i]).toColorPart() } while (++i<3);
+ } else {
+ if (this.slice(0,1) == '#') {
+ if (this.length==4) for(var i=1;i<4;i++) color += (this.charAt(i) + this.charAt(i)).toLowerCase();
+ if (this.length==7) color = this.toLowerCase();
+ }
+ }
+ return (color.length==7 ? color : (arguments[0] || this));
+};
+
+/*--------------------------------------------------------------------------*/
+
+Element.collectTextNodes = function(element) {
+ return $A($(element).childNodes).collect( function(node) {
+ return (node.nodeType==3 ? node.nodeValue :
+ (node.hasChildNodes() ? Element.collectTextNodes(node) : ''));
+ }).flatten().join('');
+};
+
+Element.collectTextNodesIgnoreClass = function(element, className) {
+ return $A($(element).childNodes).collect( function(node) {
+ return (node.nodeType==3 ? node.nodeValue :
+ ((node.hasChildNodes() && !Element.hasClassName(node,className)) ?
+ Element.collectTextNodesIgnoreClass(node, className) : ''));
+ }).flatten().join('');
+};
+
+Element.setContentZoom = function(element, percent) {
+ element = $(element);
+ element.setStyle({fontSize: (percent/100) + 'em'});
+ if (Prototype.Browser.WebKit) window.scrollBy(0,0);
+ return element;
+};
+
+Element.getInlineOpacity = function(element){
+ return $(element).style.opacity || '';
+};
+
+Element.forceRerendering = function(element) {
+ try {
+ element = $(element);
+ var n = document.createTextNode(' ');
+ element.appendChild(n);
+ element.removeChild(n);
+ } catch(e) { }
+};
+
+/*--------------------------------------------------------------------------*/
+
+var Effect = {
+ _elementDoesNotExistError: {
+ name: 'ElementDoesNotExistError',
+ message: 'The specified DOM element does not exist, but is required for this effect to operate'
+ },
+ Transitions: {
+ linear: Prototype.K,
+ sinoidal: function(pos) {
+ return (-Math.cos(pos*Math.PI)/2) + .5;
+ },
+ reverse: function(pos) {
+ return 1-pos;
+ },
+ flicker: function(pos) {
+ var pos = ((-Math.cos(pos*Math.PI)/4) + .75) + Math.random()/4;
+ return pos > 1 ? 1 : pos;
+ },
+ wobble: function(pos) {
+ return (-Math.cos(pos*Math.PI*(9*pos))/2) + .5;
+ },
+ pulse: function(pos, pulses) {
+ return (-Math.cos((pos*((pulses||5)-.5)*2)*Math.PI)/2) + .5;
+ },
+ spring: function(pos) {
+ return 1 - (Math.cos(pos * 4.5 * Math.PI) * Math.exp(-pos * 6));
+ },
+ none: function(pos) {
+ return 0;
+ },
+ full: function(pos) {
+ return 1;
+ }
+ },
+ DefaultOptions: {
+ duration: 1.0, // seconds
+ fps: 100, // 100= assume 66fps max.
+ sync: false, // true for combining
+ from: 0.0,
+ to: 1.0,
+ delay: 0.0,
+ queue: 'parallel'
+ },
+ tagifyText: function(element) {
+ var tagifyStyle = 'position:relative';
+ if (Prototype.Browser.IE) tagifyStyle += ';zoom:1';
+
+ element = $(element);
+ $A(element.childNodes).each( function(child) {
+ if (child.nodeType==3) {
+ child.nodeValue.toArray().each( function(character) {
+ element.insertBefore(
+ new Element('span', {style: tagifyStyle}).update(
+ character == ' ' ? String.fromCharCode(160) : character),
+ child);
+ });
+ Element.remove(child);
+ }
+ });
+ },
+ multiple: function(element, effect) {
+ var elements;
+ if (((typeof element == 'object') ||
+ Object.isFunction(element)) &&
+ (element.length))
+ elements = element;
+ else
+ elements = $(element).childNodes;
+
+ var options = Object.extend({
+ speed: 0.1,
+ delay: 0.0
+ }, arguments[2] || { });
+ var masterDelay = options.delay;
+
+ $A(elements).each( function(element, index) {
+ new effect(element, Object.extend(options, { delay: index * options.speed + masterDelay }));
+ });
+ },
+ PAIRS: {
+ 'slide': ['SlideDown','SlideUp'],
+ 'blind': ['BlindDown','BlindUp'],
+ 'appear': ['Appear','Fade']
+ },
+ toggle: function(element, effect) {
+ element = $(element);
+ effect = (effect || 'appear').toLowerCase();
+ var options = Object.extend({
+ queue: { position:'end', scope:(element.id || 'global'), limit: 1 }
+ }, arguments[2] || { });
+ Effect[element.visible() ?
+ Effect.PAIRS[effect][1] : Effect.PAIRS[effect][0]](element, options);
+ }
+};
+
+Effect.DefaultOptions.transition = Effect.Transitions.sinoidal;
+
+/* ------------- core effects ------------- */
+
+Effect.ScopedQueue = Class.create(Enumerable, {
+ initialize: function() {
+ this.effects = [];
+ this.interval = null;
+ },
+ _each: function(iterator) {
+ this.effects._each(iterator);
+ },
+ add: function(effect) {
+ var timestamp = new Date().getTime();
+
+ var position = Object.isString(effect.options.queue) ?
+ effect.options.queue : effect.options.queue.position;
+
+ switch(position) {
+ case 'front':
+ // move unstarted effects after this effect
+ this.effects.findAll(function(e){ return e.state=='idle' }).each( function(e) {
+ e.startOn += effect.finishOn;
+ e.finishOn += effect.finishOn;
+ });
+ break;
+ case 'with-last':
+ timestamp = this.effects.pluck('startOn').max() || timestamp;
+ break;
+ case 'end':
+ // start effect after last queued effect has finished
+ timestamp = this.effects.pluck('finishOn').max() || timestamp;
+ break;
+ }
+
+ effect.startOn += timestamp;
+ effect.finishOn += timestamp;
+
+ if (!effect.options.queue.limit || (this.effects.length < effect.options.queue.limit))
+ this.effects.push(effect);
+
+ if (!this.interval)
+ this.interval = setInterval(this.loop.bind(this), 15);
+ },
+ remove: function(effect) {
+ this.effects = this.effects.reject(function(e) { return e==effect });
+ if (this.effects.length == 0) {
+ clearInterval(this.interval);
+ this.interval = null;
+ }
+ },
+ loop: function() {
+ var timePos = new Date().getTime();
+ for(var i=0, len=this.effects.length;i<len;i++)
+ this.effects[i] && this.effects[i].loop(timePos);
+ }
+});
+
+Effect.Queues = {
+ instances: $H(),
+ get: function(queueName) {
+ if (!Object.isString(queueName)) return queueName;
+
+ return this.instances.get(queueName) ||
+ this.instances.set(queueName, new Effect.ScopedQueue());
+ }
+};
+Effect.Queue = Effect.Queues.get('global');
+
+Effect.Base = Class.create({
+ position: null,
+ start: function(options) {
+ function codeForEvent(options,eventName){
+ return (
+ (options[eventName+'Internal'] ? 'this.options.'+eventName+'Internal(this);' : '') +
+ (options[eventName] ? 'this.options.'+eventName+'(this);' : '')
+ );
+ }
+ if (options && options.transition === false) options.transition = Effect.Transitions.linear;
+ this.options = Object.extend(Object.extend({ },Effect.DefaultOptions), options || { });
+ this.currentFrame = 0;
+ this.state = 'idle';
+ this.startOn = this.options.delay*1000;
+ this.finishOn = this.startOn+(this.options.duration*1000);
+ this.fromToDelta = this.options.to-this.options.from;
+ this.totalTime = this.finishOn-this.startOn;
+ this.totalFrames = this.options.fps*this.options.duration;
+
+ this.render = (function() {
+ function dispatch(effect, eventName) {
+ if (effect.options[eventName + 'Internal'])
+ effect.options[eventName + 'Internal'](effect);
+ if (effect.options[eventName])
+ effect.options[eventName](effect);
+ }
+
+ return function(pos) {
+ if (this.state === "idle") {
+ this.state = "running";
+ dispatch(this, 'beforeSetup');
+ if (this.setup) this.setup();
+ dispatch(this, 'afterSetup');
+ }
+ if (this.state === "running") {
+ pos = (this.options.transition(pos) * this.fromToDelta) + this.options.from;
+ this.position = pos;
+ dispatch(this, 'beforeUpdate');
+ if (this.update) this.update(pos);
+ dispatch(this, 'afterUpdate');
+ }
+ };
+ })();
+
+ this.event('beforeStart');
+ if (!this.options.sync)
+ Effect.Queues.get(Object.isString(this.options.queue) ?
+ 'global' : this.options.queue.scope).add(this);
+ },
+ loop: function(timePos) {
+ if (timePos >= this.startOn) {
+ if (timePos >= this.finishOn) {
+ this.render(1.0);
+ this.cancel();
+ this.event('beforeFinish');
+ if (this.finish) this.finish();
+ this.event('afterFinish');
+ return;
+ }
+ var pos = (timePos - this.startOn) / this.totalTime,
+ frame = (pos * this.totalFrames).round();
+ if (frame > this.currentFrame) {
+ this.render(pos);
+ this.currentFrame = frame;
+ }
+ }
+ },
+ cancel: function() {
+ if (!this.options.sync)
+ Effect.Queues.get(Object.isString(this.options.queue) ?
+ 'global' : this.options.queue.scope).remove(this);
+ this.state = 'finished';
+ },
+ event: function(eventName) {
+ if (this.options[eventName + 'Internal']) this.options[eventName + 'Internal'](this);
+ if (this.options[eventName]) this.options[eventName](this);
+ },
+ inspect: function() {
+ var data = $H();
+ for(property in this)
+ if (!Object.isFunction(this[property])) data.set(property, this[property]);
+ return '#<Effect:' + data.inspect() + ',options:' + $H(this.options).inspect() + '>';
+ }
+});
+
+Effect.Parallel = Class.create(Effect.Base, {
+ initialize: function(effects) {
+ this.effects = effects || [];
+ this.start(arguments[1]);
+ },
+ update: function(position) {
+ this.effects.invoke('render', position);
+ },
+ finish: function(position) {
+ this.effects.each( function(effect) {
+ effect.render(1.0);
+ effect.cancel();
+ effect.event('beforeFinish');
+ if (effect.finish) effect.finish(position);
+ effect.event('afterFinish');
+ });
+ }
+});
+
+Effect.Tween = Class.create(Effect.Base, {
+ initialize: function(object, from, to) {
+ object = Object.isString(object) ? $(object) : object;
+ var args = $A(arguments), method = args.last(),
+ options = args.length == 5 ? args[3] : null;
+ this.method = Object.isFunction(method) ? method.bind(object) :
+ Object.isFunction(object[method]) ? object[method].bind(object) :
+ function(value) { object[method] = value };
+ this.start(Object.extend({ from: from, to: to }, options || { }));
+ },
+ update: function(position) {
+ this.method(position);
+ }
+});
+
+Effect.Event = Class.create(Effect.Base, {
+ initialize: function() {
+ this.start(Object.extend({ duration: 0 }, arguments[0] || { }));
+ },
+ update: Prototype.emptyFunction
+});
+
+Effect.Opacity = Class.create(Effect.Base, {
+ initialize: function(element) {
+ this.element = $(element);
+ if (!this.element) throw(Effect._elementDoesNotExistError);
+ // make this work on IE on elements without 'layout'
+ if (Prototype.Browser.IE && (!this.element.currentStyle.hasLayout))
+ this.element.setStyle({zoom: 1});
+ var options = Object.extend({
+ from: this.element.getOpacity() || 0.0,
+ to: 1.0
+ }, arguments[1] || { });
+ this.start(options);
+ },
+ update: function(position) {
+ this.element.setOpacity(position);
+ }
+});
+
+Effect.Move = Class.create(Effect.Base, {
+ initialize: function(element) {
+ this.element = $(element);
+ if (!this.element) throw(Effect._elementDoesNotExistError);
+ var options = Object.extend({
+ x: 0,
+ y: 0,
+ mode: 'relative'
+ }, arguments[1] || { });
+ this.start(options);
+ },
+ setup: function() {
+ this.element.makePositioned();
+ this.originalLeft = parseFloat(this.element.getStyle('left') || '0');
+ this.originalTop = parseFloat(this.element.getStyle('top') || '0');
+ if (this.options.mode == 'absolute') {
+ this.options.x = this.options.x - this.originalLeft;
+ this.options.y = this.options.y - this.originalTop;
+ }
+ },
+ update: function(position) {
+ this.element.setStyle({
+ left: (this.options.x * position + this.originalLeft).round() + 'px',
+ top: (this.options.y * position + this.originalTop).round() + 'px'
+ });
+ }
+});
+
+// for backwards compatibility
+Effect.MoveBy = function(element, toTop, toLeft) {
+ return new Effect.Move(element,
+ Object.extend({ x: toLeft, y: toTop }, arguments[3] || { }));
+};
+
+Effect.Scale = Class.create(Effect.Base, {
+ initialize: function(element, percent) {
+ this.element = $(element);
+ if (!this.element) throw(Effect._elementDoesNotExistError);
+ var options = Object.extend({
+ scaleX: true,
+ scaleY: true,
+ scaleContent: true,
+ scaleFromCenter: false,
+ scaleMode: 'box', // 'box' or 'contents' or { } with provided values
+ scaleFrom: 100.0,
+ scaleTo: percent
+ }, arguments[2] || { });
+ this.start(options);
+ },
+ setup: function() {
+ this.restoreAfterFinish = this.options.restoreAfterFinish || false;
+ this.elementPositioning = this.element.getStyle('position');
+
+ this.originalStyle = { };
+ ['top','left','width','height','fontSize'].each( function(k) {
+ this.originalStyle[k] = this.element.style[k];
+ }.bind(this));
+
+ this.originalTop = this.element.offsetTop;
+ this.originalLeft = this.element.offsetLeft;
+
+ var fontSize = this.element.getStyle('font-size') || '100%';
+ ['em','px','%','pt'].each( function(fontSizeType) {
+ if (fontSize.indexOf(fontSizeType)>0) {
+ this.fontSize = parseFloat(fontSize);
+ this.fontSizeType = fontSizeType;
+ }
+ }.bind(this));
+
+ this.factor = (this.options.scaleTo - this.options.scaleFrom)/100;
+
+ this.dims = null;
+ if (this.options.scaleMode=='box')
+ this.dims = [this.element.offsetHeight, this.element.offsetWidth];
+ if (/^content/.test(this.options.scaleMode))
+ this.dims = [this.element.scrollHeight, this.element.scrollWidth];
+ if (!this.dims)
+ this.dims = [this.options.scaleMode.originalHeight,
+ this.options.scaleMode.originalWidth];
+ },
+ update: function(position) {
+ var currentScale = (this.options.scaleFrom/100.0) + (this.factor * position);
+ if (this.options.scaleContent && this.fontSize)
+ this.element.setStyle({fontSize: this.fontSize * currentScale + this.fontSizeType });
+ this.setDimensions(this.dims[0] * currentScale, this.dims[1] * currentScale);
+ },
+ finish: function(position) {
+ if (this.restoreAfterFinish) this.element.setStyle(this.originalStyle);
+ },
+ setDimensions: function(height, width) {
+ var d = { };
+ if (this.options.scaleX) d.width = width.round() + 'px';
+ if (this.options.scaleY) d.height = height.round() + 'px';
+ if (this.options.scaleFromCenter) {
+ var topd = (height - this.dims[0])/2;
+ var leftd = (width - this.dims[1])/2;
+ if (this.elementPositioning == 'absolute') {
+ if (this.options.scaleY) d.top = this.originalTop-topd + 'px';
+ if (this.options.scaleX) d.left = this.originalLeft-leftd + 'px';
+ } else {
+ if (this.options.scaleY) d.top = -topd + 'px';
+ if (this.options.scaleX) d.left = -leftd + 'px';
+ }
+ }
+ this.element.setStyle(d);
+ }
+});
+
+Effect.Highlight = Class.create(Effect.Base, {
+ initialize: function(element) {
+ this.element = $(element);
+ if (!this.element) throw(Effect._elementDoesNotExistError);
+ var options = Object.extend({ startcolor: '#ffff99' }, arguments[1] || { });
+ this.start(options);
+ },
+ setup: function() {
+ // Prevent executing on elements not in the layout flow
+ if (this.element.getStyle('display')=='none') { this.cancel(); return; }
+ // Disable background image during the effect
+ this.oldStyle = { };
+ if (!this.options.keepBackgroundImage) {
+ this.oldStyle.backgroundImage = this.element.getStyle('background-image');
+ this.element.setStyle({backgroundImage: 'none'});
+ }
+ if (!this.options.endcolor)
+ this.options.endcolor = this.element.getStyle('background-color').parseColor('#ffffff');
+ if (!this.options.restorecolor)
+ this.options.restorecolor = this.element.getStyle('background-color');
+ // init color calculations
+ this._base = $R(0,2).map(function(i){ return parseInt(this.options.startcolor.slice(i*2+1,i*2+3),16) }.bind(this));
+ this._delta = $R(0,2).map(function(i){ return parseInt(this.options.endcolor.slice(i*2+1,i*2+3),16)-this._base[i] }.bind(this));
+ },
+ update: function(position) {
+ this.element.setStyle({backgroundColor: $R(0,2).inject('#',function(m,v,i){
+ return m+((this._base[i]+(this._delta[i]*position)).round().toColorPart()); }.bind(this)) });
+ },
+ finish: function() {
+ this.element.setStyle(Object.extend(this.oldStyle, {
+ backgroundColor: this.options.restorecolor
+ }));
+ }
+});
+
+Effect.ScrollTo = function(element) {
+ var options = arguments[1] || { },
+ scrollOffsets = document.viewport.getScrollOffsets(),
+ elementOffsets = $(element).cumulativeOffset();
+
+ if (options.offset) elementOffsets[1] += options.offset;
+
+ return new Effect.Tween(null,
+ scrollOffsets.top,
+ elementOffsets[1],
+ options,
+ function(p){ scrollTo(scrollOffsets.left, p.round()); }
+ );
+};
+
+/* ------------- combination effects ------------- */
+
+Effect.Fade = function(element) {
+ element = $(element);
+ var oldOpacity = element.getInlineOpacity();
+ var options = Object.extend({
+ from: element.getOpacity() || 1.0,
+ to: 0.0,
+ afterFinishInternal: function(effect) {
+ if (effect.options.to!=0) return;
+ effect.element.hide().setStyle({opacity: oldOpacity});
+ }
+ }, arguments[1] || { });
+ return new Effect.Opacity(element,options);
+};
+
+Effect.Appear = function(element) {
+ element = $(element);
+ var options = Object.extend({
+ from: (element.getStyle('display') == 'none' ? 0.0 : element.getOpacity() || 0.0),
+ to: 1.0,
+ // force Safari to render floated elements properly
+ afterFinishInternal: function(effect) {
+ effect.element.forceRerendering();
+ },
+ beforeSetup: function(effect) {
+ effect.element.setOpacity(effect.options.from).show();
+ }}, arguments[1] || { });
+ return new Effect.Opacity(element,options);
+};
+
+Effect.Puff = function(element) {
+ element = $(element);
+ var oldStyle = {
+ opacity: element.getInlineOpacity(),
+ position: element.getStyle('position'),
+ top: element.style.top,
+ left: element.style.left,
+ width: element.style.width,
+ height: element.style.height
+ };
+ return new Effect.Parallel(
+ [ new Effect.Scale(element, 200,
+ { sync: true, scaleFromCenter: true, scaleContent: true, restoreAfterFinish: true }),
+ new Effect.Opacity(element, { sync: true, to: 0.0 } ) ],
+ Object.extend({ duration: 1.0,
+ beforeSetupInternal: function(effect) {
+ Position.absolutize(effect.effects[0].element);
+ },
+ afterFinishInternal: function(effect) {
+ effect.effects[0].element.hide().setStyle(oldStyle); }
+ }, arguments[1] || { })
+ );
+};
+
+Effect.BlindUp = function(element) {
+ element = $(element);
+ element.makeClipping();
+ return new Effect.Scale(element, 0,
+ Object.extend({ scaleContent: false,
+ scaleX: false,
+ restoreAfterFinish: true,
+ afterFinishInternal: function(effect) {
+ effect.element.hide().undoClipping();
+ }
+ }, arguments[1] || { })
+ );
+};
+
+Effect.BlindDown = function(element) {
+ element = $(element);
+ var elementDimensions = element.getDimensions();
+ return new Effect.Scale(element, 100, Object.extend({
+ scaleContent: false,
+ scaleX: false,
+ scaleFrom: 0,
+ scaleMode: {originalHeight: elementDimensions.height, originalWidth: elementDimensions.width},
+ restoreAfterFinish: true,
+ afterSetup: function(effect) {
+ effect.element.makeClipping().setStyle({height: '0px'}).show();
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.undoClipping();
+ }
+ }, arguments[1] || { }));
+};
+
+Effect.SwitchOff = function(element) {
+ element = $(element);
+ var oldOpacity = element.getInlineOpacity();
+ return new Effect.Appear(element, Object.extend({
+ duration: 0.4,
+ from: 0,
+ transition: Effect.Transitions.flicker,
+ afterFinishInternal: function(effect) {
+ new Effect.Scale(effect.element, 1, {
+ duration: 0.3, scaleFromCenter: true,
+ scaleX: false, scaleContent: false, restoreAfterFinish: true,
+ beforeSetup: function(effect) {
+ effect.element.makePositioned().makeClipping();
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.hide().undoClipping().undoPositioned().setStyle({opacity: oldOpacity});
+ }
+ });
+ }
+ }, arguments[1] || { }));
+};
+
+Effect.DropOut = function(element) {
+ element = $(element);
+ var oldStyle = {
+ top: element.getStyle('top'),
+ left: element.getStyle('left'),
+ opacity: element.getInlineOpacity() };
+ return new Effect.Parallel(
+ [ new Effect.Move(element, {x: 0, y: 100, sync: true }),
+ new Effect.Opacity(element, { sync: true, to: 0.0 }) ],
+ Object.extend(
+ { duration: 0.5,
+ beforeSetup: function(effect) {
+ effect.effects[0].element.makePositioned();
+ },
+ afterFinishInternal: function(effect) {
+ effect.effects[0].element.hide().undoPositioned().setStyle(oldStyle);
+ }
+ }, arguments[1] || { }));
+};
+
+Effect.Shake = function(element) {
+ element = $(element);
+ var options = Object.extend({
+ distance: 20,
+ duration: 0.5
+ }, arguments[1] || {});
+ var distance = parseFloat(options.distance);
+ var split = parseFloat(options.duration) / 10.0;
+ var oldStyle = {
+ top: element.getStyle('top'),
+ left: element.getStyle('left') };
+ return new Effect.Move(element,
+ { x: distance, y: 0, duration: split, afterFinishInternal: function(effect) {
+ new Effect.Move(effect.element,
+ { x: -distance*2, y: 0, duration: split*2, afterFinishInternal: function(effect) {
+ new Effect.Move(effect.element,
+ { x: distance*2, y: 0, duration: split*2, afterFinishInternal: function(effect) {
+ new Effect.Move(effect.element,
+ { x: -distance*2, y: 0, duration: split*2, afterFinishInternal: function(effect) {
+ new Effect.Move(effect.element,
+ { x: distance*2, y: 0, duration: split*2, afterFinishInternal: function(effect) {
+ new Effect.Move(effect.element,
+ { x: -distance, y: 0, duration: split, afterFinishInternal: function(effect) {
+ effect.element.undoPositioned().setStyle(oldStyle);
+ }}); }}); }}); }}); }}); }});
+};
+
+Effect.SlideDown = function(element) {
+ element = $(element).cleanWhitespace();
+ // SlideDown need to have the content of the element wrapped in a container element with fixed height!
+ var oldInnerBottom = element.down().getStyle('bottom');
+ var elementDimensions = element.getDimensions();
+ return new Effect.Scale(element, 100, Object.extend({
+ scaleContent: false,
+ scaleX: false,
+ scaleFrom: window.opera ? 0 : 1,
+ scaleMode: {originalHeight: elementDimensions.height, originalWidth: elementDimensions.width},
+ restoreAfterFinish: true,
+ afterSetup: function(effect) {
+ effect.element.makePositioned();
+ effect.element.down().makePositioned();
+ if (window.opera) effect.element.setStyle({top: ''});
+ effect.element.makeClipping().setStyle({height: '0px'}).show();
+ },
+ afterUpdateInternal: function(effect) {
+ effect.element.down().setStyle({bottom:
+ (effect.dims[0] - effect.element.clientHeight) + 'px' });
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.undoClipping().undoPositioned();
+ effect.element.down().undoPositioned().setStyle({bottom: oldInnerBottom}); }
+ }, arguments[1] || { })
+ );
+};
+
+Effect.SlideUp = function(element) {
+ element = $(element).cleanWhitespace();
+ var oldInnerBottom = element.down().getStyle('bottom');
+ var elementDimensions = element.getDimensions();
+ return new Effect.Scale(element, window.opera ? 0 : 1,
+ Object.extend({ scaleContent: false,
+ scaleX: false,
+ scaleMode: 'box',
+ scaleFrom: 100,
+ scaleMode: {originalHeight: elementDimensions.height, originalWidth: elementDimensions.width},
+ restoreAfterFinish: true,
+ afterSetup: function(effect) {
+ effect.element.makePositioned();
+ effect.element.down().makePositioned();
+ if (window.opera) effect.element.setStyle({top: ''});
+ effect.element.makeClipping().show();
+ },
+ afterUpdateInternal: function(effect) {
+ effect.element.down().setStyle({bottom:
+ (effect.dims[0] - effect.element.clientHeight) + 'px' });
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.hide().undoClipping().undoPositioned();
+ effect.element.down().undoPositioned().setStyle({bottom: oldInnerBottom});
+ }
+ }, arguments[1] || { })
+ );
+};
+
+// Bug in opera makes the TD containing this element expand for a instance after finish
+Effect.Squish = function(element) {
+ return new Effect.Scale(element, window.opera ? 1 : 0, {
+ restoreAfterFinish: true,
+ beforeSetup: function(effect) {
+ effect.element.makeClipping();
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.hide().undoClipping();
+ }
+ });
+};
+
+Effect.Grow = function(element) {
+ element = $(element);
+ var options = Object.extend({
+ direction: 'center',
+ moveTransition: Effect.Transitions.sinoidal,
+ scaleTransition: Effect.Transitions.sinoidal,
+ opacityTransition: Effect.Transitions.full
+ }, arguments[1] || { });
+ var oldStyle = {
+ top: element.style.top,
+ left: element.style.left,
+ height: element.style.height,
+ width: element.style.width,
+ opacity: element.getInlineOpacity() };
+
+ var dims = element.getDimensions();
+ var initialMoveX, initialMoveY;
+ var moveX, moveY;
+
+ switch (options.direction) {
+ case 'top-left':
+ initialMoveX = initialMoveY = moveX = moveY = 0;
+ break;
+ case 'top-right':
+ initialMoveX = dims.width;
+ initialMoveY = moveY = 0;
+ moveX = -dims.width;
+ break;
+ case 'bottom-left':
+ initialMoveX = moveX = 0;
+ initialMoveY = dims.height;
+ moveY = -dims.height;
+ break;
+ case 'bottom-right':
+ initialMoveX = dims.width;
+ initialMoveY = dims.height;
+ moveX = -dims.width;
+ moveY = -dims.height;
+ break;
+ case 'center':
+ initialMoveX = dims.width / 2;
+ initialMoveY = dims.height / 2;
+ moveX = -dims.width / 2;
+ moveY = -dims.height / 2;
+ break;
+ }
+
+ return new Effect.Move(element, {
+ x: initialMoveX,
+ y: initialMoveY,
+ duration: 0.01,
+ beforeSetup: function(effect) {
+ effect.element.hide().makeClipping().makePositioned();
+ },
+ afterFinishInternal: function(effect) {
+ new Effect.Parallel(
+ [ new Effect.Opacity(effect.element, { sync: true, to: 1.0, from: 0.0, transition: options.opacityTransition }),
+ new Effect.Move(effect.element, { x: moveX, y: moveY, sync: true, transition: options.moveTransition }),
+ new Effect.Scale(effect.element, 100, {
+ scaleMode: { originalHeight: dims.height, originalWidth: dims.width },
+ sync: true, scaleFrom: window.opera ? 1 : 0, transition: options.scaleTransition, restoreAfterFinish: true})
+ ], Object.extend({
+ beforeSetup: function(effect) {
+ effect.effects[0].element.setStyle({height: '0px'}).show();
+ },
+ afterFinishInternal: function(effect) {
+ effect.effects[0].element.undoClipping().undoPositioned().setStyle(oldStyle);
+ }
+ }, options)
+ );
+ }
+ });
+};
+
+Effect.Shrink = function(element) {
+ element = $(element);
+ var options = Object.extend({
+ direction: 'center',
+ moveTransition: Effect.Transitions.sinoidal,
+ scaleTransition: Effect.Transitions.sinoidal,
+ opacityTransition: Effect.Transitions.none
+ }, arguments[1] || { });
+ var oldStyle = {
+ top: element.style.top,
+ left: element.style.left,
+ height: element.style.height,
+ width: element.style.width,
+ opacity: element.getInlineOpacity() };
+
+ var dims = element.getDimensions();
+ var moveX, moveY;
+
+ switch (options.direction) {
+ case 'top-left':
+ moveX = moveY = 0;
+ break;
+ case 'top-right':
+ moveX = dims.width;
+ moveY = 0;
+ break;
+ case 'bottom-left':
+ moveX = 0;
+ moveY = dims.height;
+ break;
+ case 'bottom-right':
+ moveX = dims.width;
+ moveY = dims.height;
+ break;
+ case 'center':
+ moveX = dims.width / 2;
+ moveY = dims.height / 2;
+ break;
+ }
+
+ return new Effect.Parallel(
+ [ new Effect.Opacity(element, { sync: true, to: 0.0, from: 1.0, transition: options.opacityTransition }),
+ new Effect.Scale(element, window.opera ? 1 : 0, { sync: true, transition: options.scaleTransition, restoreAfterFinish: true}),
+ new Effect.Move(element, { x: moveX, y: moveY, sync: true, transition: options.moveTransition })
+ ], Object.extend({
+ beforeStartInternal: function(effect) {
+ effect.effects[0].element.makePositioned().makeClipping();
+ },
+ afterFinishInternal: function(effect) {
+ effect.effects[0].element.hide().undoClipping().undoPositioned().setStyle(oldStyle); }
+ }, options)
+ );
+};
+
+Effect.Pulsate = function(element) {
+ element = $(element);
+ var options = arguments[1] || { },
+ oldOpacity = element.getInlineOpacity(),
+ transition = options.transition || Effect.Transitions.linear,
+ reverser = function(pos){
+ return 1 - transition((-Math.cos((pos*(options.pulses||5)*2)*Math.PI)/2) + .5);
+ };
+
+ return new Effect.Opacity(element,
+ Object.extend(Object.extend({ duration: 2.0, from: 0,
+ afterFinishInternal: function(effect) { effect.element.setStyle({opacity: oldOpacity}); }
+ }, options), {transition: reverser}));
+};
+
+Effect.Fold = function(element) {
+ element = $(element);
+ var oldStyle = {
+ top: element.style.top,
+ left: element.style.left,
+ width: element.style.width,
+ height: element.style.height };
+ element.makeClipping();
+ return new Effect.Scale(element, 5, Object.extend({
+ scaleContent: false,
+ scaleX: false,
+ afterFinishInternal: function(effect) {
+ new Effect.Scale(element, 1, {
+ scaleContent: false,
+ scaleY: false,
+ afterFinishInternal: function(effect) {
+ effect.element.hide().undoClipping().setStyle(oldStyle);
+ } });
+ }}, arguments[1] || { }));
+};
+
+Effect.Morph = Class.create(Effect.Base, {
+ initialize: function(element) {
+ this.element = $(element);
+ if (!this.element) throw(Effect._elementDoesNotExistError);
+ var options = Object.extend({
+ style: { }
+ }, arguments[1] || { });
+
+ if (!Object.isString(options.style)) this.style = $H(options.style);
+ else {
+ if (options.style.include(':'))
+ this.style = options.style.parseStyle();
+ else {
+ this.element.addClassName(options.style);
+ this.style = $H(this.element.getStyles());
+ this.element.removeClassName(options.style);
+ var css = this.element.getStyles();
+ this.style = this.style.reject(function(style) {
+ return style.value == css[style.key];
+ });
+ options.afterFinishInternal = function(effect) {
+ effect.element.addClassName(effect.options.style);
+ effect.transforms.each(function(transform) {
+ effect.element.style[transform.style] = '';
+ });
+ };
+ }
+ }
+ this.start(options);
+ },
+
+ setup: function(){
+ function parseColor(color){
+ if (!color || ['rgba(0, 0, 0, 0)','transparent'].include(color)) color = '#ffffff';
+ color = color.parseColor();
+ return $R(0,2).map(function(i){
+ return parseInt( color.slice(i*2+1,i*2+3), 16 );
+ });
+ }
+ this.transforms = this.style.map(function(pair){
+ var property = pair[0], value = pair[1], unit = null;
+
+ if (value.parseColor('#zzzzzz') != '#zzzzzz') {
+ value = value.parseColor();
+ unit = 'color';
+ } else if (property == 'opacity') {
+ value = parseFloat(value);
+ if (Prototype.Browser.IE && (!this.element.currentStyle.hasLayout))
+ this.element.setStyle({zoom: 1});
+ } else if (Element.CSS_LENGTH.test(value)) {
+ var components = value.match(/^([\+\-]?[0-9\.]+)(.*)$/);
+ value = parseFloat(components[1]);
+ unit = (components.length == 3) ? components[2] : null;
+ }
+
+ var originalValue = this.element.getStyle(property);
+ return {
+ style: property.camelize(),
+ originalValue: unit=='color' ? parseColor(originalValue) : parseFloat(originalValue || 0),
+ targetValue: unit=='color' ? parseColor(value) : value,
+ unit: unit
+ };
+ }.bind(this)).reject(function(transform){
+ return (
+ (transform.originalValue == transform.targetValue) ||
+ (
+ transform.unit != 'color' &&
+ (isNaN(transform.originalValue) || isNaN(transform.targetValue))
+ )
+ );
+ });
+ },
+ update: function(position) {
+ var style = { }, transform, i = this.transforms.length;
+ while(i--)
+ style[(transform = this.transforms[i]).style] =
+ transform.unit=='color' ? '#'+
+ (Math.round(transform.originalValue[0]+
+ (transform.targetValue[0]-transform.originalValue[0])*position)).toColorPart() +
+ (Math.round(transform.originalValue[1]+
+ (transform.targetValue[1]-transform.originalValue[1])*position)).toColorPart() +
+ (Math.round(transform.originalValue[2]+
+ (transform.targetValue[2]-transform.originalValue[2])*position)).toColorPart() :
+ (transform.originalValue +
+ (transform.targetValue - transform.originalValue) * position).toFixed(3) +
+ (transform.unit === null ? '' : transform.unit);
+ this.element.setStyle(style, true);
+ }
+});
+
+Effect.Transform = Class.create({
+ initialize: function(tracks){
+ this.tracks = [];
+ this.options = arguments[1] || { };
+ this.addTracks(tracks);
+ },
+ addTracks: function(tracks){
+ tracks.each(function(track){
+ track = $H(track);
+ var data = track.values().first();
+ this.tracks.push($H({
+ ids: track.keys().first(),
+ effect: Effect.Morph,
+ options: { style: data }
+ }));
+ }.bind(this));
+ return this;
+ },
+ play: function(){
+ return new Effect.Parallel(
+ this.tracks.map(function(track){
+ var ids = track.get('ids'), effect = track.get('effect'), options = track.get('options');
+ var elements = [$(ids) || $$(ids)].flatten();
+ return elements.map(function(e){ return new effect(e, Object.extend({ sync:true }, options)) });
+ }).flatten(),
+ this.options
+ );
+ }
+});
+
+Element.CSS_PROPERTIES = $w(
+ 'backgroundColor backgroundPosition borderBottomColor borderBottomStyle ' +
+ 'borderBottomWidth borderLeftColor borderLeftStyle borderLeftWidth ' +
+ 'borderRightColor borderRightStyle borderRightWidth borderSpacing ' +
+ 'borderTopColor borderTopStyle borderTopWidth bottom clip color ' +
+ 'fontSize fontWeight height left letterSpacing lineHeight ' +
+ 'marginBottom marginLeft marginRight marginTop markerOffset maxHeight '+
+ 'maxWidth minHeight minWidth opacity outlineColor outlineOffset ' +
+ 'outlineWidth paddingBottom paddingLeft paddingRight paddingTop ' +
+ 'right textIndent top width wordSpacing zIndex');
+
+Element.CSS_LENGTH = /^(([\+\-]?[0-9\.]+)(em|ex|px|in|cm|mm|pt|pc|\%))|0$/;
+
+String.__parseStyleElement = document.createElement('div');
+String.prototype.parseStyle = function(){
+ var style, styleRules = $H();
+ if (Prototype.Browser.WebKit)
+ style = new Element('div',{style:this}).style;
+ else {
+ String.__parseStyleElement.innerHTML = '<div style="' + this + '"></div>';
+ style = String.__parseStyleElement.childNodes[0].style;
+ }
+
+ Element.CSS_PROPERTIES.each(function(property){
+ if (style[property]) styleRules.set(property, style[property]);
+ });
+
+ if (Prototype.Browser.IE && this.include('opacity'))
+ styleRules.set('opacity', this.match(/opacity:\s*((?:0|1)?(?:\.\d*)?)/)[1]);
+
+ return styleRules;
+};
+
+if (document.defaultView && document.defaultView.getComputedStyle) {
+ Element.getStyles = function(element) {
+ var css = document.defaultView.getComputedStyle($(element), null);
+ return Element.CSS_PROPERTIES.inject({ }, function(styles, property) {
+ styles[property] = css[property];
+ return styles;
+ });
+ };
+} else {
+ Element.getStyles = function(element) {
+ element = $(element);
+ var css = element.currentStyle, styles;
+ styles = Element.CSS_PROPERTIES.inject({ }, function(results, property) {
+ results[property] = css[property];
+ return results;
+ });
+ if (!styles.opacity) styles.opacity = element.getOpacity();
+ return styles;
+ };
+}
+
+Effect.Methods = {
+ morph: function(element, style) {
+ element = $(element);
+ new Effect.Morph(element, Object.extend({ style: style }, arguments[2] || { }));
+ return element;
+ },
+ visualEffect: function(element, effect, options) {
+ element = $(element);
+ var s = effect.dasherize().camelize(), klass = s.charAt(0).toUpperCase() + s.substring(1);
+ new Effect[klass](element, options);
+ return element;
+ },
+ highlight: function(element, options) {
+ element = $(element);
+ new Effect.Highlight(element, options);
+ return element;
+ }
+};
+
+$w('fade appear grow shrink fold blindUp blindDown slideUp slideDown '+
+ 'pulsate shake puff squish switchOff dropOut').each(
+ function(effect) {
+ Effect.Methods[effect] = function(element, options){
+ element = $(element);
+ Effect[effect.charAt(0).toUpperCase() + effect.substring(1)](element, options);
+ return element;
+ };
+ }
+);
+
+$w('getInlineOpacity forceRerendering setContentZoom collectTextNodes collectTextNodesIgnoreClass getStyles').each(
+ function(f) { Effect.Methods[f] = Element[f]; }
+);
+
+Element.addMethods(Effect.Methods); \ No newline at end of file
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/jw_effects.js b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/jw_effects.js
new file mode 100644
index 0000000..640c9b1
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/jw_effects.js
@@ -0,0 +1,750 @@
+/*
+ FYI:
+ "restoreAfterFinish" is only used by Scale and all its subclasses and puts the element
+ back where it was the size that it was.
+
+ Bugs:
+ SlideLeftIn still doesn't work on IE ???
+
+ 'delete' does not work on IE
+
+ Cannot set styles of table items in Builder.node due to IE bug
+
+ stray commas after last item in lists causes IE to fail
+
+
+ Effect.toggle on these effects doesn't seem to work quite right
+ ( Effect.toggle('demo-effect-curtainopen','slideleft') )
+
+ Not allowing Effect.Curtain* to finish before clicking again causes a problem.
+
+ Not allowing MOST effects to finish before clicking again causes a problem.
+*/
+
+
+/* This declaration doesn't show up correctly when using Firebug */
+/*
+ Also, these toggles don't seem to work right either
+ OK: slideup, slidedown, slideright
+ NOT: slideleft, curtain
+*/
+Effect.PAIRS = Object.extend(
+ Effect.PAIRS, {
+ 'slidedown': ['SlideDownIn', 'SlideDownOut'],
+ 'slideup': ['SlideUpIn', 'SlideUpOut'],
+ 'slideleft': ['SlideLeftIn', 'SlideLeftOut'],
+ 'slideright': ['SlideRightIn', 'SlideRightOut'],
+ 'curtain': ['CurtainClose', 'CurtainOpen']
+ }
+);
+
+
+Object.extend(
+ Effect, {
+ _elementIsNotAListError: {
+ name: 'ElementIsNotAListError',
+ message: 'The specified DOM element is not a list exist, but is required to be for this effect to operate'
+ }
+ }
+);
+
+
+Effect.PulseList = Class.create();
+Object.extend(Object.extend(Effect.PulseList.prototype, Effect.Base.prototype), {
+ initialize: function(element) {
+ this.element = $(element);
+ if(!this.element) throw(Effect._elementDoesNotExistError);
+// if( (this.element.tagName != "UL") && (this.element.tagName != "OL") )
+ if( ! ['UL','OL'].include(this.element.tagName) )
+ throw(Effect._elementIsNotAListError);
+ if ( ! this.element.effectOn ) {
+ this.element.effectOn = true;
+ var options = Object.extend({
+ _pulse: 1,
+ direction: "down", // up or down
+ pulses: 1,
+ continuous: false,
+ bounce: false,
+ duration: 2,
+ min_opacity: 0.1
+ }, arguments[1] || {});
+ this.start(options);
+ }
+ },
+ setup: function() {
+ var num_items = this.element.immediateDescendants().size();
+ var i = 1;
+ var self = this;
+ this.element.immediateDescendants().each( function(myitem){
+ var mydelay = (self.options.direction == "down" )
+ ? (i++ - 1)/num_items
+ : (num_items - i++)/num_items;
+ var reverser = function(pos){ return Effect.Transitions.sinoidal(1-Effect.Transitions.pulse(pos, 1)) }
+ new Effect.Opacity(myitem,
+ Object.extend(Object.extend({
+ delay: mydelay,
+ duration: self.options.duration,
+ from: self.options.min_opacity,
+ afterFinishInternal: function(effect) {
+ if ( ! ( self.options.direction == 'down' ? myitem.next() : myitem.previous() ) ) {
+ if ( ( self.options.continuous ) || ( self.options._pulse++ < self.options.pulses ) ){
+ if ( self.options.bounce)
+ self.options.direction = ( self.options.direction == 'up' ) ? 'down' : 'up';
+ new Effect.PulseList(effect.element.parentNode, self.options || {} );
+ }
+ }
+ }
+ }, {}), {transition: reverser})
+ );
+ });
+ },
+ finish: function() {
+// delete(this.element.effectOn);
+ this.element.effectOn = false;
+ }
+});
+
+
+Effect.Gradient = Class.create();
+Object.extend(Object.extend(Effect.Gradient.prototype, Effect.Base.prototype), {
+ initialize: function(element) {
+ this.element = $(element);
+ if(!this.element) throw(Effect._elementDoesNotExistError);
+ var options = Object.extend({
+ duration: 5,
+ rows: 10,
+ cols: 10,
+ type: 'diagonal', /* vertical, horizontal, diagonal */
+ colors: [ 'black', 'white', 'white', 'black' ]
+ }, arguments[1] || {});
+ if (options.type == 'horizontal') options.rows = 1;
+ else if (options.type == 'vertical') options.cols = 1;
+
+ dims = this.element.getDimensions();
+ cellwidth = dims.width / options.cols;
+ cellheight = dims.height / options.rows;
+ this.cellids = [];
+ var self = this;
+ this.table = Builder.node('table', {
+ border: 0, cellpadding: 0, cellspacing: 0,
+ style:"margin: 0px; padding: 0px;"
+ });
+ tbody = Builder.node('tbody');
+ $(tbody).setStyle({ margin: 0, padding: 0 });
+ $R(1,options.rows).each( function(row){
+ tr = Builder.node('tr');
+ $(tr).setStyle({ margin: 0, padding: 0 });
+ if (options.type == 'vertical') {
+ cellcolor = Color.shade(
+ Color.string2hex(options.colors[0]),
+ Color.string2hex(options.colors[1]),
+ (row-1)/(options.rows-1)
+ );
+ }
+ $R(1,options.cols).each( function(col){
+ cellid = "grcell-"+row+"-"+col;
+ if (options.type == 'diagonal') {
+ cellcolor = Color.shade(
+ Color.shade(
+ Color.string2hex(options.colors[0]),
+ Color.string2hex(options.colors[1]),
+ (col-1)/(options.cols-1)
+ ),
+ Color.shade(
+ Color.string2hex(options.colors[2]),
+ Color.string2hex(options.colors[3]),
+ (col-1)/(options.cols-1)
+ ),
+ (row-1)/(options.rows-1)
+ );
+ } else if (options.type == 'horizontal') {
+ cellcolor = Color.shade(
+ Color.string2hex(options.colors[0]),
+ Color.string2hex(options.colors[1]),
+ (col-1)/(options.cols-1)
+ );
+ }
+ td = Builder.node('td',{
+ id: cellid
+ }, "" );
+ $(td).setStyle({ margin: '0px', padding: '0px',
+ height: cellheight+'px',
+ width: cellwidth+'px',
+ backgroundColor: cellcolor
+ });
+ tr.appendChild(td);
+ self.cellids.push(cellid);
+ });
+ tbody.appendChild(tr);
+ });
+ this.table.appendChild(tbody);
+
+ this.start(options);
+ },
+ setup: function(){
+ Position.absolutize(this.element);
+ this.element.parentNode.appendChild(this.table);
+ Position.absolutize(this.table);
+ },
+ finish: function(){
+ new Effect.Fade( this.table , {
+ afterFinish: function(effect) {
+ effect.element.parentNode.removeChild(effect.element);
+ }
+ });
+ }
+});
+
+Effect.ORIGGradient = Class.create();
+Object.extend(Object.extend(Effect.ORIGGradient.prototype, Effect.Base.prototype), {
+ initialize: function(element) {
+ this.element = $(element);
+ if(!this.element) throw(Effect._elementDoesNotExistError);
+ var options = Object.extend({
+ duration: 5,
+ rows: 10,
+ cols: 10,
+ type: 'diagonal', /* vertical, horizontal, diagonal */
+ colors: [ 'black', 'white', 'white', 'black' ]
+ }, arguments[1] || {});
+ if (options.type == 'horizontal') options.rows = 1;
+ else if (options.type == 'vertical') options.cols = 1;
+
+ dims = this.element.getDimensions();
+ cellwidth = dims.width / options.cols;
+ cellheight = dims.height / options.rows;
+ this.cellids = [];
+ var self = this;
+ this.table = Builder.node('table', {
+ border: 0, cellpadding: 0, cellspacing: 0,
+ style:"margin: 0px; padding: 0px;"
+ });
+ tbody = Builder.node('tbody', { style:"margin: 0px; padding: 0px;" });
+ $R(1,options.rows).each( function(row){
+ tr = Builder.node('tr', { style:"margin: 0px; padding: 0px;" });
+ if (options.type == 'vertical') {
+ cellcolor = Color.shade(
+ Color.string2hex(options.colors[0]),
+ Color.string2hex(options.colors[1]),
+ (row-1)/(options.rows-1)
+ );
+ }
+ $R(1,options.cols).each( function(col){
+ cellid = "grcell-"+row+"-"+col;
+ if (options.type == 'diagonal') {
+ cellcolor = Color.shade(
+ Color.shade(
+ Color.string2hex(options.colors[0]),
+ Color.string2hex(options.colors[1]),
+ (col-1)/(options.cols-1)
+ ),
+ Color.shade(
+ Color.string2hex(options.colors[2]),
+ Color.string2hex(options.colors[3]),
+ (col-1)/(options.cols-1)
+ ),
+ (row-1)/(options.rows-1)
+ );
+ } else if (options.type == 'horizontal') {
+ cellcolor = Color.shade(
+ Color.string2hex(options.colors[0]),
+ Color.string2hex(options.colors[1]),
+ (col-1)/(options.cols-1)
+ );
+ }
+ td = Builder.node('td',{
+ id: cellid,
+ style:"margin: 0px; padding: 0px; "
+ +"height: "+cellheight+"px; "
+ +"width: "+cellwidth+"px; "
+ +"background-color: "+cellcolor
+ }, "" );
+ tr.appendChild(td);
+ self.cellids.push(cellid);
+ });
+ tbody.appendChild(tr);
+ });
+ this.table.appendChild(tbody);
+
+ Position.absolutize(this.element);
+ this.element.parentNode.appendChild(this.table);
+ Position.absolutize(this.table);
+ this.start(options);
+ },
+ finish: function(){
+ new Effect.Fade( this.table , {
+ afterFinish: function(effect) {
+ effect.element.parentNode.removeChild(effect.element);
+ }
+ });
+ }
+});
+
+
+Effect.Pixelate = Class.create();
+Object.extend(Object.extend(Effect.Pixelate.prototype, Effect.Base.prototype), {
+ initialize: function(element) {
+ this.element = $(element);
+ if(!this.element) throw(Effect._elementDoesNotExistError);
+ var options = Object.extend({
+ duration: 5,
+ rows: 30,
+ cols: 30,
+ startcolor: 'transparent',
+ endcolor: 'white'
+ }, arguments[1] || {});
+ options.cells = options.rows * options.cols;
+
+ dims = this.element.getDimensions();
+ cellwidth = dims.width / options.cols;
+ cellheight = dims.height / options.rows;
+ this.cellids = [];
+ this.table = Builder.node('table', {
+ border: 0, cellpadding: 0, cellspacing: 0,
+ style:"margin: 0px; padding: 0px;"
+ });
+ /* Cannot set styles of table items in Builder.node due to IE bug */
+ var self = this;
+ tbody = Builder.node('tbody');
+ $(tbody).setStyle({ margin: 0, padding: 0 });
+ $R(1,options.rows).each( function(row){
+ tr = Builder.node('tr');
+ $(tr).setStyle({ margin: '0px', padding: '0px' });
+ $R(1,options.cols).each( function(col){
+ cellid = "pxcell-"+row+"-"+col;
+ td = Builder.node('td',{
+ id: cellid
+ }, '');
+ $(td).setStyle({ margin: '0px', padding: '0px',
+ height: cellheight+'px',
+ width: cellwidth+'px',
+ backgroundColor: options.startcolor
+ });
+ tr.appendChild(td);
+ self.cellids.push(cellid);
+ });
+ tbody.appendChild(tr);
+ });
+ this.cellids.sort( function(a,b){return (0.5 - Math.random());} );
+ this.table.appendChild(tbody);
+ this.start(options);
+ },
+ setup: function() {
+ Position.absolutize(this.element);
+ this.element.parentNode.appendChild(this.table);
+ Position.absolutize(this.table);
+ },
+ update: function(position) {
+ while ( this.cellids.size() && (this.cellids.size()/this.options.cells) > (1-position) ) {
+ $(this.cellids.pop()).setStyle({ backgroundColor: this.options.endcolor });
+ }
+ },
+ finish: function(){
+ new Effect.Fade( this.table , {
+ afterFinish: function(effect) {
+ effect.element.parentNode.removeChild(effect.element);
+ }
+ });
+ }
+});
+
+
+
+Effect.Duplicate = Class.create();
+Object.extend(Object.extend(Effect.Duplicate.prototype, Effect.Base.prototype), {
+ initialize: function(element) {
+ this.element = $(element);
+ if(!this.element) throw(Effect._elementDoesNotExistError);
+
+ this.element.makePositioned();
+ this.elecopy = this.element.cloneNode(true);
+ this.elecopy.setStyle({ color: 'red', backgroundColor: 'red', backgroundImage: '' });
+ this.elecopy.id = element.id + '-copy';
+ this.element.parentNode.appendChild(this.elecopy);
+ Position.relativize(this.element);
+ Position.relativize(this.elecopy);
+ Position.absolutize(this.element);
+ Position.absolutize(this.elecopy);
+
+ var options = Object.extend({
+ }, arguments[1] || {});
+ this.start(options);
+ },
+ asetup: function() {
+ return new Effect.Parallel ( [
+ new Effect.SlideRightIn(this.element, { sync:true }),
+ new Effect.SlideLeftIn( this.elecopy, { sync:true })
+ ], Object.extend({
+ duration: 2
+ }, arguments[1] || {})
+ );
+ },
+ update: function(position) {
+ },
+ finish: function() {
+ this.elecopy.undoClipping().undoPositioned().remove();
+ }
+});
+
+Effect.Flicker = Class.create();
+Object.extend(Object.extend(Effect.Flicker.prototype, Effect.Base.prototype), {
+ initialize: function(element) {
+ this.element = $(element);
+ if(!this.element) throw(Effect._elementDoesNotExistError);
+ if ( ! this.element.effectOn ) {
+ this.element.effectOn = true;
+ var options = Object.extend({
+ threshold: 0.5,
+ endvisibility: "visible"
+ }, arguments[1] || {});
+ this.start(options);
+ }
+ },
+ update: function(position) {
+ var visibility = ( Math.random() < this.options.threshold ) ? "hidden" : "visible";
+ this.element.setStyle({
+ visibility: visibility
+ });
+ },
+ finish: function() {
+ this.element.setStyle({
+ visibility: this.options.endvisibility
+ });
+// delete(this.element.effectOn);
+ this.element.effectOn = false;
+ }
+});
+
+
+Effect.CurtainClose = function(element) {
+/*
+ CurtainClose need to have the content of the element wrapped in a container element with fixed width AND height!
+*/
+ element = $(element).cleanWhitespace();
+ var elementDimensions = element.getDimensions();
+
+ element.makeClipping().makePositioned();
+ element.parentNode.makeClipping(); // stops SlideLeftIn flicker
+ elecopy = $(element.cloneNode(true));
+ elecopy.setStyle({ top: '0px', left: '0px' });
+ elecopy.id = element.id + '-copy';
+ element.parentNode.appendChild(elecopy);
+ elecopy.makeClipping().makePositioned();
+ Position.absolutize(element);
+
+ return new Effect.Parallel ( [
+ new Effect.SlideRightIn(element, { sync:true }),
+ new Effect.SlideLeftIn( elecopy, { sync:true })
+ ], Object.extend({
+ duration: 2,
+ afterFinishInternal: function(effect){
+ elecopy.undoClipping().undoPositioned().remove();
+/* why does the above work and the below does not? */
+// effect.effects[1].element.undoClipping().undoPositioned().remove();
+ effect.effects[0].element.parentNode.undoClipping();
+ }
+ }, arguments[1] || {})
+ );
+}
+
+Effect.CurtainOpen = function(element) {
+/*
+ CurtainOpen need to have the content of the element wrapped in a container element with fixed width AND height!
+*/
+ element = $(element).cleanWhitespace();
+
+ element.makeClipping().makePositioned();
+ element.parentNode.makeClipping();
+ elecopy = element.cloneNode(true);
+ elecopy.setStyle({ top: '0px' });
+ elecopy.id = element.id + '-copy';
+ element.parentNode.appendChild(elecopy);
+ Position.absolutize(element);
+ Position.absolutize(elecopy);
+
+ var elementDimensions = element.getDimensions();
+ return new Effect.Parallel ( [
+ new Effect.SlideRightOut(element, { sync:true }),
+ new Effect.SlideLeftOut( elecopy, { sync:true })
+ ], Object.extend({
+ duration: 2,
+ beforeSetup: function(effect){
+ effect.effects[1].element.makeClipping().makePositioned().show();
+ },
+ afterFinishInternal: function(effect){
+ element.undoClipping().undoPositioned();
+/* why does the above work and the below does not? */
+// effect.effects[0].element.undoClipping().undoPositioned();
+ effect.effects[1].element.parentNode.undoClipping();
+ effect.effects[1].element.undoClipping().undoPositioned().remove();
+ }
+ }, arguments[1] || {})
+ );
+}
+
+
+Effect.SlideLeftIn = function(element) {
+/*
+ SlideLeftIn need to have the content of the element wrapped in a container element with fixed width!
+*/
+ element = $(element).cleanWhitespace();
+ if ( ! element.effectOn ) {
+ element.effectOn = true;
+ var elementDimensions = element.getDimensions();
+ return new Effect.Parallel ( [
+ new Effect.Move(element,
+ Object.extend({
+ x: -(elementDimensions.width),
+ sync: true,
+ mode: 'relative',
+ beforeStartInternal: function(effect) {
+ if(window.opera) effect.element.setStyle({left: ''});
+ effect.element.setStyle({left: elementDimensions.width + 'px' });
+ effect.element.show();
+ }
+ }, arguments[1] || {})
+ ),
+ new Effect.Scale(element, 100,
+ Object.extend({ scaleContent: false,
+ /* why does the use of sync: true make this flicker? */
+ scaleY: false,
+ scaleFrom: window.opera ? 0 : 1
+ }, arguments[1] || {})
+ )
+ ], Object.extend({
+ beforeSetup: function(effect){
+ effect.effects[0].element.parentNode.makeClipping();
+ effect.effects[0].element.makeClipping();
+ },
+ afterFinishInternal: function(effect){
+ effect.effects[0].element.parentNode.undoClipping();
+ effect.effects[0].element.undoClipping();
+ },
+ afterFinish: function(effect){
+// delete(effect.effects[0].element.effectOn);
+ effect.effects[0].element.effectOn = false;
+ }
+ }, arguments[1] || {})
+ );
+ }
+}
+
+
+Effect.SlideRightOut = function(element) {
+/*
+ SlideRightOut need to have the content of the element wrapped in a container element with fixed width!
+*/
+ element = $(element).cleanWhitespace();
+ var elementDimensions = element.getDimensions();
+ return new Effect.Parallel ( [
+ new Effect.Move(element, { x: element.getWidth(), sync: true, mode: 'relative' }),
+ new Effect.Scale(element, window.opera ? 0 : 1, {
+ sync: true,
+ scaleContent: false,
+ scaleY: false,
+ scaleFrom: 100,
+ restoreAfterFinish: true
+ })
+ ], Object.extend({
+ beforeSetup: function(effect){
+ effect.effects[0].element.makeClipping();
+ },
+ afterFinishInternal: function(effect){
+ effect.effects[0].element.undoClipping().hide();
+ }
+ }, arguments[1] || {})
+ );
+}
+
+
+
+/* from SlideUp */
+Effect.SlideLeftOut = function(element) {
+/*
+ SlideLeftOut needs to have the content of the element wrapped in a container element with fixed width
+ otherwise any text or images begin to wrap in stange ways!
+*/
+ element = $(element).cleanWhitespace();
+ return new Effect.Scale(element, window.opera ? 0 : 1,
+ Object.extend({
+ scaleContent: false,
+ scaleY: false,
+ scaleMode: 'box',
+ scaleFrom: 100,
+ restoreAfterFinish: true,
+ beforeStartInternal: function(effect) {
+ effect.element.makePositioned();
+ effect.element.down().makePositioned();
+ if(window.opera) effect.element.setStyle({left: ''});
+ effect.element.makeClipping().show();
+ },
+ afterUpdateInternal: function(effect) {
+ effect.element.down().setStyle(
+ {right: (effect.dims[1] - effect.element.clientWidth) + 'px' }
+ );
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.hide().undoClipping().undoPositioned();
+ effect.element.down().undoPositioned();
+ }
+ }, arguments[1] || {})
+ );
+}
+
+
+/* from SlideDown */
+Effect.SlideRightIn = function(element) {
+/*
+ SlideRightIn needs to have the content of the element wrapped in a container element with fixed width!
+*/
+ element = $(element).cleanWhitespace();
+ var elementDimensions = element.getDimensions();
+ return new Effect.Scale(element, 100,
+ Object.extend({
+ scaleContent: false,
+ scaleY: false,
+ scaleFrom: window.opera ? 0 : 1,
+ scaleMode: {originalHeight: elementDimensions.height, originalWidth: elementDimensions.width},
+ restoreAfterFinish: true,
+ afterSetup: function(effect) {
+ effect.element.makePositioned();
+ effect.element.down().makePositioned();
+ if(window.opera) effect.element.setStyle({left: ''});
+ effect.element.makeClipping().setStyle({width: '0px'}).show();
+ },
+ afterUpdateInternal: function(effect) {
+ effect.element.down().setStyle({right: (effect.dims[1] - effect.element.clientWidth) + 'px' });
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.undoClipping().undoPositioned();
+ effect.element.down().undoPositioned();
+ }
+ }, arguments[1] || {})
+ );
+}
+
+
+
+Effect.SlideUpIn = function(element) {
+/*
+ SlideUpIn need to have the content of the element wrapped in a container element with fixed height!
+*/
+ element = $(element).cleanWhitespace();
+ var elementDimensions = element.getDimensions();
+ return new Effect.Parallel ( [
+ new Effect.Move(element, { y: -(element.getHeight()), sync: true, mode: 'relative' }),
+ new Effect.Scale(element, 100,
+ Object.extend({
+ sync: true,
+ scaleContent: false,
+ scaleX: false,
+ scaleFrom: 0,
+ scaleMode: {originalHeight: elementDimensions.height, originalWidth: elementDimensions.width},
+ beforeSetup: function(effect) {
+ effect.element.hide();
+ },
+ afterSetup: function(effect) {
+ effect.element.makeClipping().setStyle({height: '0px'}).show();
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.undoClipping();
+ }
+ }, arguments[1] || {})
+ )
+ ], Object.extend({
+ afterSetup: function(effect) {
+ effect.effects[0].element.setStyle({top: elementDimensions.height + 'px' });
+ }
+ }, arguments[1] || {}));
+}
+
+
+Effect.SlideDownOut = function(element) {
+/*
+ SlideDown need to have the content of the element wrapped in a container element with fixed height!
+*/
+ element = $(element).cleanWhitespace();
+ var elementDimensions = element.getDimensions();
+ return new Effect.Parallel ( [
+ new Effect.Move(element, { y: element.getHeight(), sync: true, mode: 'relative' }),
+ new Effect.Scale(element, 0,
+ Object.extend({
+ sync: true,
+ scaleContent: false,
+ scaleX: false,
+ restoreAfterFinish: true,
+ beforeSetup: function(effect){
+ effect.element.makeClipping();
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.hide().undoClipping();
+ }
+ }, arguments[1] || {})
+ )
+ ], Object.extend({
+ }, arguments[1] || {}));
+}
+
+
+
+/* this is the original SlideDown */
+Effect.SlideDownIn = function(element) {
+ element = $(element).cleanWhitespace();
+ // SlideDown need to have the content of the element wrapped in a container element with fixed height!
+ var oldInnerBottom = element.down().getStyle('bottom');
+ var elementDimensions = element.getDimensions();
+ return new Effect.Scale(element, 100,
+ Object.extend({
+ scaleContent: false,
+ scaleX: false,
+ scaleFrom: window.opera ? 0 : 1,
+ scaleMode: {originalHeight: elementDimensions.height, originalWidth: elementDimensions.width},
+ restoreAfterFinish: true,
+ afterSetup: function(effect) {
+ effect.element.makePositioned();
+ effect.element.down().makePositioned();
+ if(window.opera) effect.element.setStyle({top: ''});
+ effect.element.makeClipping().setStyle({height: '0px'}).show();
+ },
+ afterUpdateInternal: function(effect) {
+ effect.element.down().setStyle({bottom:
+ (effect.dims[0] - effect.element.clientHeight) + 'px' });
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.undoClipping().undoPositioned();
+ effect.element.down().undoPositioned().setStyle({bottom: oldInnerBottom});
+ }
+ }, arguments[1] || {})
+ );
+}
+
+/* this is the original SlideUp */
+Effect.SlideUpOut = function(element) {
+ element = $(element).cleanWhitespace();
+ var oldInnerBottom = element.down().getStyle('bottom');
+ return new Effect.Scale(element, window.opera ? 0 : 1,
+ Object.extend({
+ scaleContent: false,
+ scaleX: false,
+ scaleMode: 'box',
+ scaleFrom: 100,
+ restoreAfterFinish: true,
+ beforeStartInternal: function(effect) {
+ effect.element.makePositioned();
+ effect.element.down().makePositioned();
+ if(window.opera) effect.element.setStyle({top: ''});
+ effect.element.makeClipping().show();
+ },
+ afterUpdateInternal: function(effect) {
+ effect.element.down().setStyle({bottom:
+ (effect.dims[0] - effect.element.clientHeight) + 'px' });
+ },
+ afterFinishInternal: function(effect) {
+ effect.element.hide().undoClipping().undoPositioned().setStyle({bottom: oldInnerBottom});
+ effect.element.down().undoPositioned();
+ }
+ }, arguments[1] || {})
+ );
+}
+
+
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/scriptaculous.js b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/scriptaculous.js
new file mode 100644
index 0000000..3e5543b
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/scriptaculous.js
@@ -0,0 +1,60 @@
+// script.aculo.us scriptaculous.js v1.8.2, Tue Nov 18 18:30:58 +0100 2008
+
+// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+// For details, see the script.aculo.us web site: http://script.aculo.us/
+
+var Scriptaculous = {
+ Version: '1.8.2',
+ require: function(libraryName) {
+ // inserting via DOM fails in Safari 2.0, so brute force approach
+ document.write('<script type="text/javascript" src="'+libraryName+'"><\/script>');
+ },
+ REQUIRED_PROTOTYPE: '1.6.0.3',
+ load: function() {
+ function convertVersionString(versionString) {
+ var v = versionString.replace(/_.*|\./g, '');
+ v = parseInt(v + '0'.times(4-v.length));
+ return versionString.indexOf('_') > -1 ? v-1 : v;
+ }
+
+ if((typeof Prototype=='undefined') ||
+ (typeof Element == 'undefined') ||
+ (typeof Element.Methods=='undefined') ||
+ (convertVersionString(Prototype.Version) <
+ convertVersionString(Scriptaculous.REQUIRED_PROTOTYPE)))
+ throw("script.aculo.us requires the Prototype JavaScript framework >= " +
+ Scriptaculous.REQUIRED_PROTOTYPE);
+
+ var js = /scriptaculous\.js(\?.*)?$/;
+ $$('head script[src]').findAll(function(s) {
+ return s.src.match(js);
+ }).each(function(s) {
+ var path = s.src.replace(js, ''),
+ includes = s.src.match(/\?.*load=([a-z,]*)/);
+ (includes ? includes[1] : 'builder,effects,dragdrop,controls,slider,sound').split(',').each(
+ function(include) { Scriptaculous.require(path+include+'.js') });
+ });
+ }
+};
+
+Scriptaculous.load(); \ No newline at end of file
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/slider.js b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/slider.js
new file mode 100644
index 0000000..40b7371
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/slider.js
@@ -0,0 +1,275 @@
+// script.aculo.us slider.js v1.8.2, Tue Nov 18 18:30:58 +0100 2008
+
+// Copyright (c) 2005-2008 Marty Haught, Thomas Fuchs
+//
+// script.aculo.us is freely distributable under the terms of an MIT-style license.
+// For details, see the script.aculo.us web site: http://script.aculo.us/
+
+if (!Control) var Control = { };
+
+// options:
+// axis: 'vertical', or 'horizontal' (default)
+//
+// callbacks:
+// onChange(value)
+// onSlide(value)
+Control.Slider = Class.create({
+ initialize: function(handle, track, options) {
+ var slider = this;
+
+ if (Object.isArray(handle)) {
+ this.handles = handle.collect( function(e) { return $(e) });
+ } else {
+ this.handles = [$(handle)];
+ }
+
+ this.track = $(track);
+ this.options = options || { };
+
+ this.axis = this.options.axis || 'horizontal';
+ this.increment = this.options.increment || 1;
+ this.step = parseInt(this.options.step || '1');
+ this.range = this.options.range || $R(0,1);
+
+ this.value = 0; // assure backwards compat
+ this.values = this.handles.map( function() { return 0 });
+ this.spans = this.options.spans ? this.options.spans.map(function(s){ return $(s) }) : false;
+ this.options.startSpan = $(this.options.startSpan || null);
+ this.options.endSpan = $(this.options.endSpan || null);
+
+ this.restricted = this.options.restricted || false;
+
+ this.maximum = this.options.maximum || this.range.end;
+ this.minimum = this.options.minimum || this.range.start;
+
+ // Will be used to align the handle onto the track, if necessary
+ this.alignX = parseInt(this.options.alignX || '0');
+ this.alignY = parseInt(this.options.alignY || '0');
+
+ this.trackLength = this.maximumOffset() - this.minimumOffset();
+
+ this.handleLength = this.isVertical() ?
+ (this.handles[0].offsetHeight != 0 ?
+ this.handles[0].offsetHeight : this.handles[0].style.height.replace(/px$/,"")) :
+ (this.handles[0].offsetWidth != 0 ? this.handles[0].offsetWidth :
+ this.handles[0].style.width.replace(/px$/,""));
+
+ this.active = false;
+ this.dragging = false;
+ this.disabled = false;
+
+ if (this.options.disabled) this.setDisabled();
+
+ // Allowed values array
+ this.allowedValues = this.options.values ? this.options.values.sortBy(Prototype.K) : false;
+ if (this.allowedValues) {
+ this.minimum = this.allowedValues.min();
+ this.maximum = this.allowedValues.max();
+ }
+
+ this.eventMouseDown = this.startDrag.bindAsEventListener(this);
+ this.eventMouseUp = this.endDrag.bindAsEventListener(this);
+ this.eventMouseMove = this.update.bindAsEventListener(this);
+
+ // Initialize handles in reverse (make sure first handle is active)
+ this.handles.each( function(h,i) {
+ i = slider.handles.length-1-i;
+ slider.setValue(parseFloat(
+ (Object.isArray(slider.options.sliderValue) ?
+ slider.options.sliderValue[i] : slider.options.sliderValue) ||
+ slider.range.start), i);
+ h.makePositioned().observe("mousedown", slider.eventMouseDown);
+ });
+
+ this.track.observe("mousedown", this.eventMouseDown);
+ document.observe("mouseup", this.eventMouseUp);
+ document.observe("mousemove", this.eventMouseMove);
+
+ this.initialized = true;
+ },
+ dispose: function() {
+ var slider = this;
+ Event.stopObserving(this.track, "mousedown", this.eventMouseDown);
+ Event.stopObserving(document, "mouseup", this.eventMouseUp);
+ Event.stopObserving(document, "mousemove", this.eventMouseMove);
+ this.handles.each( function(h) {
+ Event.stopObserving(h, "mousedown", slider.eventMouseDown);
+ });
+ },
+ setDisabled: function(){
+ this.disabled = true;
+ },
+ setEnabled: function(){
+ this.disabled = false;
+ },
+ getNearestValue: function(value){
+ if (this.allowedValues){
+ if (value >= this.allowedValues.max()) return(this.allowedValues.max());
+ if (value <= this.allowedValues.min()) return(this.allowedValues.min());
+
+ var offset = Math.abs(this.allowedValues[0] - value);
+ var newValue = this.allowedValues[0];
+ this.allowedValues.each( function(v) {
+ var currentOffset = Math.abs(v - value);
+ if (currentOffset <= offset){
+ newValue = v;
+ offset = currentOffset;
+ }
+ });
+ return newValue;
+ }
+ if (value > this.range.end) return this.range.end;
+ if (value < this.range.start) return this.range.start;
+ return value;
+ },
+ setValue: function(sliderValue, handleIdx){
+ if (!this.active) {
+ this.activeHandleIdx = handleIdx || 0;
+ this.activeHandle = this.handles[this.activeHandleIdx];
+ this.updateStyles();
+ }
+ handleIdx = handleIdx || this.activeHandleIdx || 0;
+ if (this.initialized && this.restricted) {
+ if ((handleIdx>0) && (sliderValue<this.values[handleIdx-1]))
+ sliderValue = this.values[handleIdx-1];
+ if ((handleIdx < (this.handles.length-1)) && (sliderValue>this.values[handleIdx+1]))
+ sliderValue = this.values[handleIdx+1];
+ }
+ sliderValue = this.getNearestValue(sliderValue);
+ this.values[handleIdx] = sliderValue;
+ this.value = this.values[0]; // assure backwards compat
+
+ this.handles[handleIdx].style[this.isVertical() ? 'top' : 'left'] =
+ this.translateToPx(sliderValue);
+
+ this.drawSpans();
+ if (!this.dragging || !this.event) this.updateFinished();
+ },
+ setValueBy: function(delta, handleIdx) {
+ this.setValue(this.values[handleIdx || this.activeHandleIdx || 0] + delta,
+ handleIdx || this.activeHandleIdx || 0);
+ },
+ translateToPx: function(value) {
+ return Math.round(
+ ((this.trackLength-this.handleLength)/(this.range.end-this.range.start)) *
+ (value - this.range.start)) + "px";
+ },
+ translateToValue: function(offset) {
+ return ((offset/(this.trackLength-this.handleLength) *
+ (this.range.end-this.range.start)) + this.range.start);
+ },
+ getRange: function(range) {
+ var v = this.values.sortBy(Prototype.K);
+ range = range || 0;
+ return $R(v[range],v[range+1]);
+ },
+ minimumOffset: function(){
+ return(this.isVertical() ? this.alignY : this.alignX);
+ },
+ maximumOffset: function(){
+ return(this.isVertical() ?
+ (this.track.offsetHeight != 0 ? this.track.offsetHeight :
+ this.track.style.height.replace(/px$/,"")) - this.alignY :
+ (this.track.offsetWidth != 0 ? this.track.offsetWidth :
+ this.track.style.width.replace(/px$/,"")) - this.alignX);
+ },
+ isVertical: function(){
+ return (this.axis == 'vertical');
+ },
+ drawSpans: function() {
+ var slider = this;
+ if (this.spans)
+ $R(0, this.spans.length-1).each(function(r) { slider.setSpan(slider.spans[r], slider.getRange(r)) });
+ if (this.options.startSpan)
+ this.setSpan(this.options.startSpan,
+ $R(0, this.values.length>1 ? this.getRange(0).min() : this.value ));
+ if (this.options.endSpan)
+ this.setSpan(this.options.endSpan,
+ $R(this.values.length>1 ? this.getRange(this.spans.length-1).max() : this.value, this.maximum));
+ },
+ setSpan: function(span, range) {
+ if (this.isVertical()) {
+ span.style.top = this.translateToPx(range.start);
+ span.style.height = this.translateToPx(range.end - range.start + this.range.start);
+ } else {
+ span.style.left = this.translateToPx(range.start);
+ span.style.width = this.translateToPx(range.end - range.start + this.range.start);
+ }
+ },
+ updateStyles: function() {
+ this.handles.each( function(h){ Element.removeClassName(h, 'selected') });
+ Element.addClassName(this.activeHandle, 'selected');
+ },
+ startDrag: function(event) {
+ if (Event.isLeftClick(event)) {
+ if (!this.disabled){
+ this.active = true;
+
+ var handle = Event.element(event);
+ var pointer = [Event.pointerX(event), Event.pointerY(event)];
+ var track = handle;
+ if (track==this.track) {
+ var offsets = Position.cumulativeOffset(this.track);
+ this.event = event;
+ this.setValue(this.translateToValue(
+ (this.isVertical() ? pointer[1]-offsets[1] : pointer[0]-offsets[0])-(this.handleLength/2)
+ ));
+ var offsets = Position.cumulativeOffset(this.activeHandle);
+ this.offsetX = (pointer[0] - offsets[0]);
+ this.offsetY = (pointer[1] - offsets[1]);
+ } else {
+ // find the handle (prevents issues with Safari)
+ while((this.handles.indexOf(handle) == -1) && handle.parentNode)
+ handle = handle.parentNode;
+
+ if (this.handles.indexOf(handle)!=-1) {
+ this.activeHandle = handle;
+ this.activeHandleIdx = this.handles.indexOf(this.activeHandle);
+ this.updateStyles();
+
+ var offsets = Position.cumulativeOffset(this.activeHandle);
+ this.offsetX = (pointer[0] - offsets[0]);
+ this.offsetY = (pointer[1] - offsets[1]);
+ }
+ }
+ }
+ Event.stop(event);
+ }
+ },
+ update: function(event) {
+ if (this.active) {
+ if (!this.dragging) this.dragging = true;
+ this.draw(event);
+ if (Prototype.Browser.WebKit) window.scrollBy(0,0);
+ Event.stop(event);
+ }
+ },
+ draw: function(event) {
+ var pointer = [Event.pointerX(event), Event.pointerY(event)];
+ var offsets = Position.cumulativeOffset(this.track);
+ pointer[0] -= this.offsetX + offsets[0];
+ pointer[1] -= this.offsetY + offsets[1];
+ this.event = event;
+ this.setValue(this.translateToValue( this.isVertical() ? pointer[1] : pointer[0] ));
+ if (this.initialized && this.options.onSlide)
+ this.options.onSlide(this.values.length>1 ? this.values : this.value, this);
+ },
+ endDrag: function(event) {
+ if (this.active && this.dragging) {
+ this.finishDrag(event, true);
+ Event.stop(event);
+ }
+ this.active = false;
+ this.dragging = false;
+ },
+ finishDrag: function(event, success) {
+ this.active = false;
+ this.dragging = false;
+ this.updateFinished();
+ },
+ updateFinished: function() {
+ if (this.initialized && this.options.onChange)
+ this.options.onChange(this.values.length>1 ? this.values : this.value, this);
+ this.event = null;
+ }
+}); \ No newline at end of file
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/sound.js b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/sound.js
new file mode 100644
index 0000000..e2487cd
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/sound.js
@@ -0,0 +1,55 @@
+// script.aculo.us sound.js v1.8.2, Tue Nov 18 18:30:58 +0100 2008
+
+// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+//
+// Based on code created by Jules Gravinese (http://www.webveteran.com/)
+//
+// script.aculo.us is freely distributable under the terms of an MIT-style license.
+// For details, see the script.aculo.us web site: http://script.aculo.us/
+
+Sound = {
+ tracks: {},
+ _enabled: true,
+ template:
+ new Template('<embed style="height:0" id="sound_#{track}_#{id}" src="#{url}" loop="false" autostart="true" hidden="true"/>'),
+ enable: function(){
+ Sound._enabled = true;
+ },
+ disable: function(){
+ Sound._enabled = false;
+ },
+ play: function(url){
+ if(!Sound._enabled) return;
+ var options = Object.extend({
+ track: 'global', url: url, replace: false
+ }, arguments[1] || {});
+
+ if(options.replace && this.tracks[options.track]) {
+ $R(0, this.tracks[options.track].id).each(function(id){
+ var sound = $('sound_'+options.track+'_'+id);
+ sound.Stop && sound.Stop();
+ sound.remove();
+ });
+ this.tracks[options.track] = null;
+ }
+
+ if(!this.tracks[options.track])
+ this.tracks[options.track] = { id: 0 };
+ else
+ this.tracks[options.track].id++;
+
+ options.id = this.tracks[options.track].id;
+ $$('body')[0].insert(
+ Prototype.Browser.IE ? new Element('bgsound',{
+ id: 'sound_'+options.track+'_'+options.id,
+ src: options.url, loop: 1, autostart: true
+ }) : Sound.template.evaluate(options));
+ }
+};
+
+if(Prototype.Browser.Gecko && navigator.userAgent.indexOf("Win") > 0){
+ if(navigator.plugins && $A(navigator.plugins).detect(function(p){ return p.name.indexOf('QuickTime') != -1 }))
+ Sound.template = new Template('<object id="sound_#{track}_#{id}" width="0" height="0" type="audio/mpeg" data="#{url}"/>');
+ else
+ Sound.play = function(){};
+} \ No newline at end of file
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/unittest.js b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/unittest.js
new file mode 100644
index 0000000..446097e
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/scriptaculous/unittest.js
@@ -0,0 +1,568 @@
+// script.aculo.us unittest.js v1.8.2, Tue Nov 18 18:30:58 +0100 2008
+
+// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+// (c) 2005-2008 Jon Tirsen (http://www.tirsen.com)
+// (c) 2005-2008 Michael Schuerig (http://www.schuerig.de/michael/)
+//
+// script.aculo.us is freely distributable under the terms of an MIT-style license.
+// For details, see the script.aculo.us web site: http://script.aculo.us/
+
+// experimental, Firefox-only
+Event.simulateMouse = function(element, eventName) {
+ var options = Object.extend({
+ pointerX: 0,
+ pointerY: 0,
+ buttons: 0,
+ ctrlKey: false,
+ altKey: false,
+ shiftKey: false,
+ metaKey: false
+ }, arguments[2] || {});
+ var oEvent = document.createEvent("MouseEvents");
+ oEvent.initMouseEvent(eventName, true, true, document.defaultView,
+ options.buttons, options.pointerX, options.pointerY, options.pointerX, options.pointerY,
+ options.ctrlKey, options.altKey, options.shiftKey, options.metaKey, 0, $(element));
+
+ if(this.mark) Element.remove(this.mark);
+ this.mark = document.createElement('div');
+ this.mark.appendChild(document.createTextNode(" "));
+ document.body.appendChild(this.mark);
+ this.mark.style.position = 'absolute';
+ this.mark.style.top = options.pointerY + "px";
+ this.mark.style.left = options.pointerX + "px";
+ this.mark.style.width = "5px";
+ this.mark.style.height = "5px;";
+ this.mark.style.borderTop = "1px solid red;";
+ this.mark.style.borderLeft = "1px solid red;";
+
+ if(this.step)
+ alert('['+new Date().getTime().toString()+'] '+eventName+'/'+Test.Unit.inspect(options));
+
+ $(element).dispatchEvent(oEvent);
+};
+
+// Note: Due to a fix in Firefox 1.0.5/6 that probably fixed "too much", this doesn't work in 1.0.6 or DP2.
+// You need to downgrade to 1.0.4 for now to get this working
+// See https://bugzilla.mozilla.org/show_bug.cgi?id=289940 for the fix that fixed too much
+Event.simulateKey = function(element, eventName) {
+ var options = Object.extend({
+ ctrlKey: false,
+ altKey: false,
+ shiftKey: false,
+ metaKey: false,
+ keyCode: 0,
+ charCode: 0
+ }, arguments[2] || {});
+
+ var oEvent = document.createEvent("KeyEvents");
+ oEvent.initKeyEvent(eventName, true, true, window,
+ options.ctrlKey, options.altKey, options.shiftKey, options.metaKey,
+ options.keyCode, options.charCode );
+ $(element).dispatchEvent(oEvent);
+};
+
+Event.simulateKeys = function(element, command) {
+ for(var i=0; i<command.length; i++) {
+ Event.simulateKey(element,'keypress',{charCode:command.charCodeAt(i)});
+ }
+};
+
+var Test = {};
+Test.Unit = {};
+
+// security exception workaround
+Test.Unit.inspect = Object.inspect;
+
+Test.Unit.Logger = Class.create();
+Test.Unit.Logger.prototype = {
+ initialize: function(log) {
+ this.log = $(log);
+ if (this.log) {
+ this._createLogTable();
+ }
+ },
+ start: function(testName) {
+ if (!this.log) return;
+ this.testName = testName;
+ this.lastLogLine = document.createElement('tr');
+ this.statusCell = document.createElement('td');
+ this.nameCell = document.createElement('td');
+ this.nameCell.className = "nameCell";
+ this.nameCell.appendChild(document.createTextNode(testName));
+ this.messageCell = document.createElement('td');
+ this.lastLogLine.appendChild(this.statusCell);
+ this.lastLogLine.appendChild(this.nameCell);
+ this.lastLogLine.appendChild(this.messageCell);
+ this.loglines.appendChild(this.lastLogLine);
+ },
+ finish: function(status, summary) {
+ if (!this.log) return;
+ this.lastLogLine.className = status;
+ this.statusCell.innerHTML = status;
+ this.messageCell.innerHTML = this._toHTML(summary);
+ this.addLinksToResults();
+ },
+ message: function(message) {
+ if (!this.log) return;
+ this.messageCell.innerHTML = this._toHTML(message);
+ },
+ summary: function(summary) {
+ if (!this.log) return;
+ this.logsummary.innerHTML = this._toHTML(summary);
+ },
+ _createLogTable: function() {
+ this.log.innerHTML =
+ '<div id="logsummary"></div>' +
+ '<table id="logtable">' +
+ '<thead><tr><th>Status</th><th>Test</th><th>Message</th></tr></thead>' +
+ '<tbody id="loglines"></tbody>' +
+ '</table>';
+ this.logsummary = $('logsummary');
+ this.loglines = $('loglines');
+ },
+ _toHTML: function(txt) {
+ return txt.escapeHTML().replace(/\n/g,"<br/>");
+ },
+ addLinksToResults: function(){
+ $$("tr.failed .nameCell").each( function(td){ // todo: limit to children of this.log
+ td.title = "Run only this test";
+ Event.observe(td, 'click', function(){ window.location.search = "?tests=" + td.innerHTML;});
+ });
+ $$("tr.passed .nameCell").each( function(td){ // todo: limit to children of this.log
+ td.title = "Run all tests";
+ Event.observe(td, 'click', function(){ window.location.search = "";});
+ });
+ }
+};
+
+Test.Unit.Runner = Class.create();
+Test.Unit.Runner.prototype = {
+ initialize: function(testcases) {
+ this.options = Object.extend({
+ testLog: 'testlog'
+ }, arguments[1] || {});
+ this.options.resultsURL = this.parseResultsURLQueryParameter();
+ this.options.tests = this.parseTestsQueryParameter();
+ if (this.options.testLog) {
+ this.options.testLog = $(this.options.testLog) || null;
+ }
+ if(this.options.tests) {
+ this.tests = [];
+ for(var i = 0; i < this.options.tests.length; i++) {
+ if(/^test/.test(this.options.tests[i])) {
+ this.tests.push(new Test.Unit.Testcase(this.options.tests[i], testcases[this.options.tests[i]], testcases["setup"], testcases["teardown"]));
+ }
+ }
+ } else {
+ if (this.options.test) {
+ this.tests = [new Test.Unit.Testcase(this.options.test, testcases[this.options.test], testcases["setup"], testcases["teardown"])];
+ } else {
+ this.tests = [];
+ for(var testcase in testcases) {
+ if(/^test/.test(testcase)) {
+ this.tests.push(
+ new Test.Unit.Testcase(
+ this.options.context ? ' -> ' + this.options.titles[testcase] : testcase,
+ testcases[testcase], testcases["setup"], testcases["teardown"]
+ ));
+ }
+ }
+ }
+ }
+ this.currentTest = 0;
+ this.logger = new Test.Unit.Logger(this.options.testLog);
+ setTimeout(this.runTests.bind(this), 1000);
+ },
+ parseResultsURLQueryParameter: function() {
+ return window.location.search.parseQuery()["resultsURL"];
+ },
+ parseTestsQueryParameter: function(){
+ if (window.location.search.parseQuery()["tests"]){
+ return window.location.search.parseQuery()["tests"].split(',');
+ };
+ },
+ // Returns:
+ // "ERROR" if there was an error,
+ // "FAILURE" if there was a failure, or
+ // "SUCCESS" if there was neither
+ getResult: function() {
+ var hasFailure = false;
+ for(var i=0;i<this.tests.length;i++) {
+ if (this.tests[i].errors > 0) {
+ return "ERROR";
+ }
+ if (this.tests[i].failures > 0) {
+ hasFailure = true;
+ }
+ }
+ if (hasFailure) {
+ return "FAILURE";
+ } else {
+ return "SUCCESS";
+ }
+ },
+ postResults: function() {
+ if (this.options.resultsURL) {
+ new Ajax.Request(this.options.resultsURL,
+ { method: 'get', parameters: 'result=' + this.getResult(), asynchronous: false });
+ }
+ },
+ runTests: function() {
+ var test = this.tests[this.currentTest];
+ if (!test) {
+ // finished!
+ this.postResults();
+ this.logger.summary(this.summary());
+ return;
+ }
+ if(!test.isWaiting) {
+ this.logger.start(test.name);
+ }
+ test.run();
+ if(test.isWaiting) {
+ this.logger.message("Waiting for " + test.timeToWait + "ms");
+ setTimeout(this.runTests.bind(this), test.timeToWait || 1000);
+ } else {
+ this.logger.finish(test.status(), test.summary());
+ this.currentTest++;
+ // tail recursive, hopefully the browser will skip the stackframe
+ this.runTests();
+ }
+ },
+ summary: function() {
+ var assertions = 0;
+ var failures = 0;
+ var errors = 0;
+ var messages = [];
+ for(var i=0;i<this.tests.length;i++) {
+ assertions += this.tests[i].assertions;
+ failures += this.tests[i].failures;
+ errors += this.tests[i].errors;
+ }
+ return (
+ (this.options.context ? this.options.context + ': ': '') +
+ this.tests.length + " tests, " +
+ assertions + " assertions, " +
+ failures + " failures, " +
+ errors + " errors");
+ }
+};
+
+Test.Unit.Assertions = Class.create();
+Test.Unit.Assertions.prototype = {
+ initialize: function() {
+ this.assertions = 0;
+ this.failures = 0;
+ this.errors = 0;
+ this.messages = [];
+ },
+ summary: function() {
+ return (
+ this.assertions + " assertions, " +
+ this.failures + " failures, " +
+ this.errors + " errors" + "\n" +
+ this.messages.join("\n"));
+ },
+ pass: function() {
+ this.assertions++;
+ },
+ fail: function(message) {
+ this.failures++;
+ this.messages.push("Failure: " + message);
+ },
+ info: function(message) {
+ this.messages.push("Info: " + message);
+ },
+ error: function(error) {
+ this.errors++;
+ this.messages.push(error.name + ": "+ error.message + "(" + Test.Unit.inspect(error) +")");
+ },
+ status: function() {
+ if (this.failures > 0) return 'failed';
+ if (this.errors > 0) return 'error';
+ return 'passed';
+ },
+ assert: function(expression) {
+ var message = arguments[1] || 'assert: got "' + Test.Unit.inspect(expression) + '"';
+ try { expression ? this.pass() :
+ this.fail(message); }
+ catch(e) { this.error(e); }
+ },
+ assertEqual: function(expected, actual) {
+ var message = arguments[2] || "assertEqual";
+ try { (expected == actual) ? this.pass() :
+ this.fail(message + ': expected "' + Test.Unit.inspect(expected) +
+ '", actual "' + Test.Unit.inspect(actual) + '"'); }
+ catch(e) { this.error(e); }
+ },
+ assertInspect: function(expected, actual) {
+ var message = arguments[2] || "assertInspect";
+ try { (expected == actual.inspect()) ? this.pass() :
+ this.fail(message + ': expected "' + Test.Unit.inspect(expected) +
+ '", actual "' + Test.Unit.inspect(actual) + '"'); }
+ catch(e) { this.error(e); }
+ },
+ assertEnumEqual: function(expected, actual) {
+ var message = arguments[2] || "assertEnumEqual";
+ try { $A(expected).length == $A(actual).length &&
+ expected.zip(actual).all(function(pair) { return pair[0] == pair[1] }) ?
+ this.pass() : this.fail(message + ': expected ' + Test.Unit.inspect(expected) +
+ ', actual ' + Test.Unit.inspect(actual)); }
+ catch(e) { this.error(e); }
+ },
+ assertNotEqual: function(expected, actual) {
+ var message = arguments[2] || "assertNotEqual";
+ try { (expected != actual) ? this.pass() :
+ this.fail(message + ': got "' + Test.Unit.inspect(actual) + '"'); }
+ catch(e) { this.error(e); }
+ },
+ assertIdentical: function(expected, actual) {
+ var message = arguments[2] || "assertIdentical";
+ try { (expected === actual) ? this.pass() :
+ this.fail(message + ': expected "' + Test.Unit.inspect(expected) +
+ '", actual "' + Test.Unit.inspect(actual) + '"'); }
+ catch(e) { this.error(e); }
+ },
+ assertNotIdentical: function(expected, actual) {
+ var message = arguments[2] || "assertNotIdentical";
+ try { !(expected === actual) ? this.pass() :
+ this.fail(message + ': expected "' + Test.Unit.inspect(expected) +
+ '", actual "' + Test.Unit.inspect(actual) + '"'); }
+ catch(e) { this.error(e); }
+ },
+ assertNull: function(obj) {
+ var message = arguments[1] || 'assertNull';
+ try { (obj==null) ? this.pass() :
+ this.fail(message + ': got "' + Test.Unit.inspect(obj) + '"'); }
+ catch(e) { this.error(e); }
+ },
+ assertMatch: function(expected, actual) {
+ var message = arguments[2] || 'assertMatch';
+ var regex = new RegExp(expected);
+ try { (regex.exec(actual)) ? this.pass() :
+ this.fail(message + ' : regex: "' + Test.Unit.inspect(expected) + ' did not match: ' + Test.Unit.inspect(actual) + '"'); }
+ catch(e) { this.error(e); }
+ },
+ assertHidden: function(element) {
+ var message = arguments[1] || 'assertHidden';
+ this.assertEqual("none", element.style.display, message);
+ },
+ assertNotNull: function(object) {
+ var message = arguments[1] || 'assertNotNull';
+ this.assert(object != null, message);
+ },
+ assertType: function(expected, actual) {
+ var message = arguments[2] || 'assertType';
+ try {
+ (actual.constructor == expected) ? this.pass() :
+ this.fail(message + ': expected "' + Test.Unit.inspect(expected) +
+ '", actual "' + (actual.constructor) + '"'); }
+ catch(e) { this.error(e); }
+ },
+ assertNotOfType: function(expected, actual) {
+ var message = arguments[2] || 'assertNotOfType';
+ try {
+ (actual.constructor != expected) ? this.pass() :
+ this.fail(message + ': expected "' + Test.Unit.inspect(expected) +
+ '", actual "' + (actual.constructor) + '"'); }
+ catch(e) { this.error(e); }
+ },
+ assertInstanceOf: function(expected, actual) {
+ var message = arguments[2] || 'assertInstanceOf';
+ try {
+ (actual instanceof expected) ? this.pass() :
+ this.fail(message + ": object was not an instance of the expected type"); }
+ catch(e) { this.error(e); }
+ },
+ assertNotInstanceOf: function(expected, actual) {
+ var message = arguments[2] || 'assertNotInstanceOf';
+ try {
+ !(actual instanceof expected) ? this.pass() :
+ this.fail(message + ": object was an instance of the not expected type"); }
+ catch(e) { this.error(e); }
+ },
+ assertRespondsTo: function(method, obj) {
+ var message = arguments[2] || 'assertRespondsTo';
+ try {
+ (obj[method] && typeof obj[method] == 'function') ? this.pass() :
+ this.fail(message + ": object doesn't respond to [" + method + "]"); }
+ catch(e) { this.error(e); }
+ },
+ assertReturnsTrue: function(method, obj) {
+ var message = arguments[2] || 'assertReturnsTrue';
+ try {
+ var m = obj[method];
+ if(!m) m = obj['is'+method.charAt(0).toUpperCase()+method.slice(1)];
+ m() ? this.pass() :
+ this.fail(message + ": method returned false"); }
+ catch(e) { this.error(e); }
+ },
+ assertReturnsFalse: function(method, obj) {
+ var message = arguments[2] || 'assertReturnsFalse';
+ try {
+ var m = obj[method];
+ if(!m) m = obj['is'+method.charAt(0).toUpperCase()+method.slice(1)];
+ !m() ? this.pass() :
+ this.fail(message + ": method returned true"); }
+ catch(e) { this.error(e); }
+ },
+ assertRaise: function(exceptionName, method) {
+ var message = arguments[2] || 'assertRaise';
+ try {
+ method();
+ this.fail(message + ": exception expected but none was raised"); }
+ catch(e) {
+ ((exceptionName == null) || (e.name==exceptionName)) ? this.pass() : this.error(e);
+ }
+ },
+ assertElementsMatch: function() {
+ var expressions = $A(arguments), elements = $A(expressions.shift());
+ if (elements.length != expressions.length) {
+ this.fail('assertElementsMatch: size mismatch: ' + elements.length + ' elements, ' + expressions.length + ' expressions');
+ return false;
+ }
+ elements.zip(expressions).all(function(pair, index) {
+ var element = $(pair.first()), expression = pair.last();
+ if (element.match(expression)) return true;
+ this.fail('assertElementsMatch: (in index ' + index + ') expected ' + expression.inspect() + ' but got ' + element.inspect());
+ }.bind(this)) && this.pass();
+ },
+ assertElementMatches: function(element, expression) {
+ this.assertElementsMatch([element], expression);
+ },
+ benchmark: function(operation, iterations) {
+ var startAt = new Date();
+ (iterations || 1).times(operation);
+ var timeTaken = ((new Date())-startAt);
+ this.info((arguments[2] || 'Operation') + ' finished ' +
+ iterations + ' iterations in ' + (timeTaken/1000)+'s' );
+ return timeTaken;
+ },
+ _isVisible: function(element) {
+ element = $(element);
+ if(!element.parentNode) return true;
+ this.assertNotNull(element);
+ if(element.style && Element.getStyle(element, 'display') == 'none')
+ return false;
+
+ return this._isVisible(element.parentNode);
+ },
+ assertNotVisible: function(element) {
+ this.assert(!this._isVisible(element), Test.Unit.inspect(element) + " was not hidden and didn't have a hidden parent either. " + ("" || arguments[1]));
+ },
+ assertVisible: function(element) {
+ this.assert(this._isVisible(element), Test.Unit.inspect(element) + " was not visible. " + ("" || arguments[1]));
+ },
+ benchmark: function(operation, iterations) {
+ var startAt = new Date();
+ (iterations || 1).times(operation);
+ var timeTaken = ((new Date())-startAt);
+ this.info((arguments[2] || 'Operation') + ' finished ' +
+ iterations + ' iterations in ' + (timeTaken/1000)+'s' );
+ return timeTaken;
+ }
+};
+
+Test.Unit.Testcase = Class.create();
+Object.extend(Object.extend(Test.Unit.Testcase.prototype, Test.Unit.Assertions.prototype), {
+ initialize: function(name, test, setup, teardown) {
+ Test.Unit.Assertions.prototype.initialize.bind(this)();
+ this.name = name;
+
+ if(typeof test == 'string') {
+ test = test.gsub(/(\.should[^\(]+\()/,'#{0}this,');
+ test = test.gsub(/(\.should[^\(]+)\(this,\)/,'#{1}(this)');
+ this.test = function() {
+ eval('with(this){'+test+'}');
+ }
+ } else {
+ this.test = test || function() {};
+ }
+
+ this.setup = setup || function() {};
+ this.teardown = teardown || function() {};
+ this.isWaiting = false;
+ this.timeToWait = 1000;
+ },
+ wait: function(time, nextPart) {
+ this.isWaiting = true;
+ this.test = nextPart;
+ this.timeToWait = time;
+ },
+ run: function() {
+ try {
+ try {
+ if (!this.isWaiting) this.setup.bind(this)();
+ this.isWaiting = false;
+ this.test.bind(this)();
+ } finally {
+ if(!this.isWaiting) {
+ this.teardown.bind(this)();
+ }
+ }
+ }
+ catch(e) { this.error(e); }
+ }
+});
+
+// *EXPERIMENTAL* BDD-style testing to please non-technical folk
+// This draws many ideas from RSpec http://rspec.rubyforge.org/
+
+Test.setupBDDExtensionMethods = function(){
+ var METHODMAP = {
+ shouldEqual: 'assertEqual',
+ shouldNotEqual: 'assertNotEqual',
+ shouldEqualEnum: 'assertEnumEqual',
+ shouldBeA: 'assertType',
+ shouldNotBeA: 'assertNotOfType',
+ shouldBeAn: 'assertType',
+ shouldNotBeAn: 'assertNotOfType',
+ shouldBeNull: 'assertNull',
+ shouldNotBeNull: 'assertNotNull',
+
+ shouldBe: 'assertReturnsTrue',
+ shouldNotBe: 'assertReturnsFalse',
+ shouldRespondTo: 'assertRespondsTo'
+ };
+ var makeAssertion = function(assertion, args, object) {
+ this[assertion].apply(this,(args || []).concat([object]));
+ };
+
+ Test.BDDMethods = {};
+ $H(METHODMAP).each(function(pair) {
+ Test.BDDMethods[pair.key] = function() {
+ var args = $A(arguments);
+ var scope = args.shift();
+ makeAssertion.apply(scope, [pair.value, args, this]); };
+ });
+
+ [Array.prototype, String.prototype, Number.prototype, Boolean.prototype].each(
+ function(p){ Object.extend(p, Test.BDDMethods) }
+ );
+};
+
+Test.context = function(name, spec, log){
+ Test.setupBDDExtensionMethods();
+
+ var compiledSpec = {};
+ var titles = {};
+ for(specName in spec) {
+ switch(specName){
+ case "setup":
+ case "teardown":
+ compiledSpec[specName] = spec[specName];
+ break;
+ default:
+ var testName = 'test'+specName.gsub(/\s+/,'-').camelize();
+ var body = spec[specName].toString().split('\n').slice(1);
+ if(/^\{/.test(body[0])) body = body.slice(1);
+ body.pop();
+ body = body.map(function(statement){
+ return statement.strip()
+ });
+ compiledSpec[testName] = body.join('\n');
+ titles[testName] = specName;
+ }
+ }
+ new Test.Unit.Runner(compiledSpec, { titles: titles, testLog: log || 'testlog', context: name });
+}; \ No newline at end of file
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/table_sort.js b/abs/core-testing/local-website/htdocs/linhes/js/table_sort.js
new file mode 100644
index 0000000..26208b1
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/table_sort.js
@@ -0,0 +1,569 @@
+/**
+ * Javascript Table sorting lib
+ *
+ * @url $URL: http://cvs.mythtv.org/svn/branches/release-0-22-fixes/mythplugins/mythweb/js/table_sort.js $
+ * @date $Date: 2008-06-22 02:21:08 +0000 (Sun, 22 Jun 2008) $
+ * @version $Revision: 17560 $
+ * @author $Author: kormoc $
+ * @license LGPL
+ *
+/**/
+
+document.observe('dom:loaded', function () {
+// Not a dom v3 supported browser?
+ if (typeof document.body.textContent == 'undefined') {
+ // Let's work around for IE
+ if (typeof document.body.innerText != 'undefined') {
+ HTMLElement.prototype.__defineGetter__('textContent', function () {
+ return this.innerText;
+ });
+ }
+ // And now Safari
+ else {
+ HTMLElement.prototype.__defineGetter__('textContent', function () {
+ return this.innerHTML;
+ });
+ }
+ }
+});
+
+var SortableTables = {
+ tables: [],
+ callback_presort: null,
+ callback_postsort: null,
+ callback_preload: null,
+ callback_postload: null,
+
+ currently_sorting_table: null,
+
+ start: function () {
+ $$('table[sortable=true]').each(SortableTables.setupTable);
+ },
+
+ setupTable: function (table) {
+ if (this.callback_preload)
+ this.callback_preload(table);
+ // We require a unique id
+ if (table.id == '' || ( this.tables && this.tables[table.id] ))
+ return;
+ SortableTables.tables[table.id] = new SortableTable(table);
+ if (this.callback_postload)
+ this.callback_postload(table);
+ },
+
+ sort: function (table_id, header_index) {
+ // 25% speed boost on large tables (900 rows+) by not allowing multiple sorts at the same time.
+ if (this.currently_sorting_table != null)
+ return;
+ if (this.callback_presort)
+ this.callback_presort(table_id, heder_index);
+ if (this.tables[table_id].callback_presort)
+ this.tables[table_id].callback_presort(table_id, header_index);
+ this.tables[table_id].sort(header_index);
+ if (this.tables[table_id].callback_postsort)
+ this.tables[table_id].callback_postsort(table_id, header_index);
+ if (this.callback_postsort)
+ this.callback_postsort(table_id, header_index);
+ }
+};
+
+document.observe('dom:loaded', SortableTables.start);
+
+var SortableTable = Class.create({
+ initialize: function (table) {
+ // Class vars
+ this.table = null;
+ this.header = null;
+ this.body = null;
+ this.rows = null;
+
+ this.cache_sort_functions = new Array();
+ this.cache_has_attribute = new Array();
+ this.cache_sorted_index = null;
+ this.cache_previous_sorts = new Array();
+ this.cache_sort_hash = new Array();
+ this.cache_sort_direction = false;
+
+ this.multisort = false;
+ this.zebra_stripe = false;
+
+ this.sort_cell_index = null;
+ this.sort_header_index = null;
+
+ this.callback_presort = null;
+ this.callback_postsort = null;
+
+ // Make sure the table is valid for sorting
+ if (table.tBodies[0].rows.length < 2)
+ return;
+
+ this.table = $(table);
+ this.header = this.table.tHead.rows[table.tHead.rows.length-1];
+ this.body = this.table.tBodies[0]
+ this.rows = this.body.rows;
+
+ this.multisort = this.table.readAttribute('multisort');
+
+ if (this.rows[0].className.match(/even/) || this.rows[0].className.match(/odd/))
+ this.zebra_stripe = true;
+
+ // Setup the header with links
+ var cells = this.header.cells;
+ var cells_count = cells.length;
+ var cell_coloffset = 0;
+ for (var i = 0; i < cells_count; i++) {
+ var cell = cells[i];
+ var cell_colspan = 1;
+ var cell_index = i + cell_coloffset;
+ var header_index = i;
+ this.cache_sort_hash[i] = cell_index;
+ // Handle colspans...
+ if (cell.hasAttribute('colspan'))
+ cell_coloffset += cell.readAttribute('colspan')-1;
+
+ if (cell.readAttribute('sortable') == 'false')
+ continue;
+ // This should fix a bug with safari (as of version 2.0.2 at least), which does not understand cellIndex correctly
+ cell.setAttribute('onclick','SortableTables.sort("'+this.table.id+'","'+header_index+'");return false;');
+ cell.addClassName('link');
+ // Heat the cache...
+ this.cache_has_attribute[cell_index] = false;
+ // Precache the sort function...
+ this.cache_sort_functions[cell_index] = this.getSortFunction(header_index, cell_index);
+ }
+ },
+
+ getSortFunction: function (header_index) {
+ var cell_index = this.cache_sort_hash[header_index];
+ // Default sort function to use
+ var sort_function = 'sortCaseInsensitive';
+ // Do we have sort_values?
+ this.cache_has_attribute[header_index] = this.rows[0].cells[cell_index].hasAttribute('sort_value');
+ if (this.header.cells[header_index].hasAttribute('sort_hint'))
+ sort_function = this.header.cells[header_index].readAttribute('sort_hint');
+ else {
+ if (this.cache_has_attribute[header_index])
+ var value = this.rows[0].cells[cell_index].readAttribute('sort_value');
+ else
+ var value = this.rows[0].cells[cell_index].textContent;
+
+ // Figure out the function to use...
+ if (value.match(/^\w+ \d+[,] \d\d\d\d/))
+ sort_function = 'sortEnglishDate';
+ else if (value.match(/^\w+[,] \w+ \d+[,] \d+[:]\d+ \w+$/))
+ sort_function = 'sortLongEnglishDate';
+ else if (value.match(/^\d+ days$/) || value=='Today' || value=='Tomorrow' || value=='Yesterday')
+ sort_function = 'sortExpiration';
+ else if (value.match(/^\d\d[\/-]\d\d[\/-]\d\d\d\d$/))
+ sort_function = 'sortDate';
+ else if (value.match(/^\d\d[\/-]\d\d[\/-]\d\d$/))
+ sort_function = 'sortDate';
+ else if (value.match(/^\W+ \d+$/))
+ sort_function = 'sortMonthDay';
+ else if (value.match(/^[\d\.]+[%]*$/))
+ sort_function = 'sortNumeric';
+ else if (value.match(/^[£$]/))
+ sort_function = 'sortCurrency';
+ }
+ return eval('SortableTableSorts.'+sort_function);
+ },
+
+ sort: function (header_index) {
+ this.sort_header_index = header_index;
+ this.sort_cell_index = this.cache_sort_hash[header_index]
+
+ // Spawn into an array
+ var row_length = this.rows.length;
+ var rows = new Array();
+ for (var i=0; i<row_length; i++)
+ rows.push(this.rows[i]);
+
+ // Check to see if we're already sorted, and if so, just invert it
+ if (this.cache_previous_sorts.last() == this.sort_cell_index)
+ rows.reverse();
+ else {
+ SortableTables.currently_sorting_table = this;
+ var sort_function = SortableTables.tables[this.table.id].doSort;
+ rows.sort(sort_function);
+ SortableTables.currently_sorting_table = null;
+ }
+
+ // Move back to the table...
+ for (var i=0; i<row_length; i++)
+ this.body.appendChild(rows[i]);
+
+ // Setup the arrows...
+ this.doHeaderArrows();
+ // Fix any zebra striping
+ this.fixZebraStripes();
+ // Remove the current index fromt he previous sorts and make sure it's uniq
+ this.cache_previous_sorts = this.cache_previous_sorts.without(this.sort_cell_index).uniq();
+ // Add in the sorted col
+ this.cache_previous_sorts.push(this.sort_cell_index);
+ },
+
+ doSort: function (a, b, cell_index) {
+ // Are we overriding the cell index (for multisort)
+ if (!cell_index)
+ cell_index = SortableTables.currently_sorting_table.sort_cell_index;
+
+ // Use the sort hint?
+ if (SortableTables.currently_sorting_table.cache_has_attribute[cell_index]) {
+ var value_a = a.cells[cell_index].readAttribute('sort_value');
+ var value_b = b.cells[cell_index].readAttribute('sort_value');
+ }
+ else {
+ var value_a = a.cells[cell_index].textContent;
+ var value_b = b.cells[cell_index].textContent;
+ }
+
+ if ( value_a != value_b)
+ var comparison = SortableTables.currently_sorting_table.cache_sort_functions[cell_index](value_a,value_b);
+ else
+ var comparison = 0;
+
+ if (SortableTables.currently_sorting_table.multisort && !comparison && SortableTables.currently_sorting_table.cache_previous_sorts.length) {
+ var multisort_index = SortableTables.currently_sorting_table.cache_previous_sorts.pop();
+ comparison = SortableTables.currently_sorting_table.doSort(a, b, multisort_index);
+ SortableTables.currently_sorting_table.cache_previous_sorts.push(multisort_index);
+ }
+ return comparison;
+ },
+
+ doHeaderArrows: function () {
+ // Remove any current span arrows
+ $$('#'+this.table.id+' thead span.sortArrow').each(function (span) {span.update('&nbsp;&nbsp;&nbsp;');});
+ var arrow_span = this.header.cells[this.sort_header_index].select('span.sortArrow').reduce();
+ if (!arrow_span) {
+ arrow_span = new Element('span', { 'class': 'sortArrow'});
+ this.header.cells[this.sort_header_index].insert(arrow_span);
+ }
+ if (this.cache_previous_sorts.last() == this.sort_cell_index && this.cache_sort_direction) {
+ arrow_span.update('&nbsp;&nbsp;&uarr;');
+ this.cache_sort_direction = false;
+ }
+ else {
+ arrow_span.update('&nbsp;&nbsp;&darr;');
+ this.cache_sort_direction = true;
+ }
+ },
+
+ fixZebraStripes: function () {
+ if (!this.zebra_stripe)
+ return;
+ var length = this.rows.length;
+ var even = false;
+ for (var i=0; i<length; i++) {
+ var row = this.rows[i];
+ if (even)
+ row.className = row.className.replace(/odd/g, 'even');
+ else
+ row.className = row.className.replace(/even/g, 'odd');
+ even = !even;
+ }
+ }
+});
+
+var SortableTableSorts = {
+// Sort: DD-MM-YY or DD-MM-YYYY
+// y2k notes: two digit years less than 50 are treated as 20XX, greater than 50 are treated as 19XX
+ sortDate: function (a,b) {
+ if (a.length == 10)
+ dt1 = a.substr(6,4)+a.substr(3,2)+a.substr(0,2);
+ else {
+ yr = a.substr(6,2);
+ if (parseInt(yr) < 50)
+ yr = '20'+yr;
+ else
+ yr = '19'+yr;
+ dt1 = yr+a.substr(3,2)+a.substr(0,2);
+ }
+ if (b.length == 10)
+ dt2 = b.substr(6,4)+b.substr(3,2)+b.substr(0,2);
+ else {
+ yr = b.substr(6,2);
+ if (parseInt(yr) < 50)
+ yr = '20'+yr;
+ else
+ yr = '19'+yr;
+ dt2 = yr+b.substr(3,2)+b.substr(0,2);
+ }
+ if (dt1==dt2)
+ return 0;
+ if (dt1<dt2)
+ return -1;
+ return 1;
+ },
+
+// Sort MM-DD-YY or MM-DD-YYYY
+// y2k notes: two digit years less than 50 are treated as 20XX, greater than 50 are treated as 19XX
+ sortDateUs: function (a,b) {
+ if (a.length == 10)
+ dt1 = a.substr(6,4)+a.substr(0,2)+a.substr(3,2);
+ else {
+ yr = a.substr(6,2);
+ if (parseInt(yr) < 50)
+ yr = '20'+yr;
+ else
+ yr = '19'+yr;
+ dt1 = yr+a.substr(0,2)+a.substr(3,2);
+ }
+ if (b.length == 10)
+ dt2 = b.substr(6,4)+b.substr(0,2)+b.substr(3,2);
+ else {
+ yr = b.substr(6,2);
+ if (parseInt(yr) < 50)
+ yr = '20'+yr;
+ else
+ yr = '19'+yr;
+ dt2 = yr+b.substr(0,2)+b.substr(3,2);
+ }
+ if (dt1 == dt2)
+ return 0;
+ if (dt1 < dt2)
+ return -1;
+ return 1;
+ },
+
+// This function handles Mon day, year sorting
+// Falls back to alpha-comparison, if date-comparison can't make a decision.
+ sortEnglishDate: function (a,b) {
+ if (a == 'none' || a.length == 0)
+ return -1;
+ if (b == 'none' || b.length == 0)
+ return 1;
+
+ var aa_mon = SortableTableSorts.englishMonthToNumber (a.substr(0,3));
+ aa = a.substr(4);
+ var aa_year = parseFloat(aa.substr(aa.length-4));
+ var aa_day = parseFloat(aa.substr(0, aa.length-6));
+
+ var bb_mon = SortableTableSorts.englishMonthToNumber (b.substr(0,3));
+ bb = b.substr(4);
+ var bb_year = parseFloat(bb.substr(bb.length-4));
+ var bb_day = parseFloat(bb.substr(0, bb.length-6));
+ if (!aa_year || !aa_mon || !aa_day || !bb_year || !bb_mon || !bb_day)
+ return SortableTableSorts.sortCaseSensitive(a,b);
+ if (aa_year < bb_year)
+ return -1;
+ if (aa_year > bb_year)
+ return 1;
+ if (aa_mon < bb_mon)
+ return -1;
+ if (aa_mon > bb_mon)
+ return 1;
+ if (aa_day < bb_day)
+ return -1;
+ return 1;
+ },
+
+// This function handles Mon day, year sorting
+// Jan 21, 2006
+ sortEnglishDateInvert: function (a,b) {
+ return SortableTableSorts.sortEnglishDate(b,a);
+ },
+
+// This function sorts based on month day format
+// Jan 21
+ sortMonthDay: function (a, b) {
+ if (a.length == 0)
+ return -1;
+ if (b.length == 0)
+ return 1;
+
+ var a_mon = SortableTableSorts.englishMonthToNumber (a.substr(0,3));
+ a = parseFloat(a.substr(4));
+ var b_mon = SortableTableSorts.englishMonthToNumber (b.substr(0,3));
+ b = parseFloat(b.substr(4));
+ if (a_mon < b_mon)
+ return -1;
+ if (a_mon > b_mon)
+ return 1;
+ if (a < b)
+ return -1;
+ return 1;
+ },
+
+// This function handles DDD, Mon Day, Hour:Min A/PM
+// we also assume it's the same year, as we can't figure it out otherwise
+ sortLongEnglishDate: function (a,b) {
+ var aa = a.substr(5).split(/,/);
+ var bb = b.substr(5).split(/,/);
+ var aatmp = aa[1].split(/:/);
+ var aa_hour = aatmp[0];
+ var aa_min = aatmp[1].substr(0,2);
+ if (aatmp[1].substr(3).toLowerCase() == 'pm')
+ aa_hour += 12;
+ var bbtmp = bb[1].split(/:/);
+ var bb_hour = bbtmp[0];
+ var bb_min = bbtmp[1].substr(0,2);
+ if (bbtmp[1].substr(3).toLowerCase() == 'pm')
+ bb_hour += 12;
+ aa = aa[0];
+ bb = bb[0];
+ if (aa == bb)
+ return 0;
+ if (aa == 'none' || aa.length == 0)
+ return -1;
+ if (bb == 'none' || bb.length == 0)
+ return 1;
+ var aa_mon = SortableTableSorts.englishMonthToNumber (aa.substr(0,3));
+ var aa_day = aa.substr(4);
+ var bb_mon = SortableTableSorts.englishMonthToNumber (bb.substr(0,3));
+ var bb_day = bb.substr(4);
+ if (!aa_mon || !aa_day || !bb_mon || !bb_day)
+ return -1;
+ if (aa_mon < bb_mon)
+ return -1;
+ if (aa_mon > bb_mon)
+ return 1;
+ if (aa_day < bb_day)
+ return -1;
+ if (aa_day > bb_day)
+ return 1;
+ if (aa_hour < bb_hour)
+ return -1;
+ if (aa_hour > bb_hour)
+ return 1;
+ if (aa_minute < bb_minute)
+ return -1;
+ return 1;
+ },
+
+// This function sorts expiration dates, such as in the quote list
+ sortExpiration: function (a,b) {
+ a = a.split(/ /)[0];
+ b = b.split(/ /)[0];
+ switch (a) {
+ case 'Yesterday': a = -1; break;
+ case 'Today': a = 0; break;
+ case 'Tomorrow': a = 1; break;
+ default: a = parseFloat(a);
+ }
+ switch (b) {
+ case 'Yesterday': b = -1; break;
+ case 'Today': b = 0; break;
+ case 'Tomorrow': b = 1; break;
+ default: b = parseFloat(b);
+ }
+
+ if (a > b)
+ return 1;
+ if (a < b)
+ return -1;
+ return 0;
+ },
+
+ englishMonthToNumber: function (mon) {
+ switch (mon.toLowerCase()) {
+ case 'jan' : return 1;
+ case 'feb' : return 2;
+ case 'mar' : return 3;
+ case 'apr' : return 4;
+ case 'may' : return 5;
+ case 'jun' : return 6;
+ case 'jul' : return 7;
+ case 'aug' : return 8;
+ case 'sep' : return 9;
+ case 'oct' : return 10;
+ case 'nov' : return 11;
+ case 'dec' : return 12;
+ }
+ return 0;
+ },
+
+ sortCurrency: function (a,b) {
+ return parseFloat(a.replace(/[^0-9.]/g,'')) - parseFloat(b.replace(/[^0-9.]/g,''));
+ },
+
+// A non number or a blank is always less then a number.
+ sortNumeric: function (a,b) {
+ b = parseFloat(b);
+ if (isNaN(b))
+ return 1;
+ a = parseFloat(a);
+ if (isNaN(a))
+ return -1;
+ return a-b;
+ },
+
+// A non number or a blank is always less then a number.
+ sortNumericInvert: function (a,b) {
+ return SortableTableSorts.sortNumeric(b,a);
+ },
+
+ sortCaseInsensitive: function (a,b) {
+ a = a.toLowerCase();
+ b = b.toLowerCase();
+
+ if (a > b)
+ return 1;
+ if (a < b)
+ return -1;
+ return 0;
+ },
+
+ sortCaseSensitive: function (a,b) {
+ if (a > b)
+ return 1;
+ if (a < b)
+ return -1;
+ return 0;
+ },
+
+ sortMythwebPlayTime: function (a,b) {
+ if (a == b)
+ return 0;
+
+ var a_hrs = a.match(/([0-9]*) hr/);
+ var a_min = a.match(/([0-9]*) min/);
+ var a_val = 0;
+ if (a_hrs)
+ a_val += a_hrs[1]*60;
+ if (a_min)
+ a_val += a_min[1]*1;
+
+ var b_hrs = b.match(/([0-9]*) hr/);
+ var b_min = b.match(/([0-9]*) min/);
+ var b_val = 0;
+ if (b_hrs)
+ b_val += b_hrs[1]*60;
+ if (b_min)
+ b_val += b_min[1]*1;
+
+ return SortableTableSorts.sortNumeric(a_val, b_val);
+ },
+
+ sortMythwebChannel: function (a,b) {
+ if (a == b)
+ return 0;
+ var a_channel = a.match(/([0-9]*) -/);
+
+ if (a_channel)
+ a_channel = a_channel[1];
+ else
+ a_channel = 0;
+
+ var b_channel = b.match(/([0-9]*) -/);
+
+ if (b_channel)
+ b_channel = b_channel[1];
+ else
+ b_channel = 0;
+
+ return SortableTableSorts.sortNumeric(a_channel, b_channel);
+ },
+
+// Some compat wrappers
+ date_us: function (a,b) {
+ return SortableTableSorts.sortDateUs(a,b);
+ },
+
+ numeric: function (a,b) {
+ return SortableTableSorts.sortNumeric(a,b);
+ },
+
+ numeric_invert: function (a,b) {
+ return SortableTableSorts.sortNumericInvert(a,b);
+ }
+};
diff --git a/abs/core-testing/local-website/htdocs/linhes/js/utils.js b/abs/core-testing/local-website/htdocs/linhes/js/utils.js
new file mode 100644
index 0000000..e6c0605
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/linhes/js/utils.js
@@ -0,0 +1,173 @@
+/**
+ * A random assortment of javascript utility routines
+ *
+ * @url $URL: http://cvs.mythtv.org/svn/branches/release-0-22-fixes/mythplugins/mythweb/js/utils.js $
+ * @date $Date: 2008-02-22 22:15:51 +0000 (Fri, 22 Feb 2008) $
+ * @version $Revision: 16207 $
+ * @author $Author: xris $
+ * @license LGPL
+ *
+/**/
+
+// For some reason, calling "value" from within onclick doesn't work
+// Seems to be a name conflict somewhere, but I can't find it.
+ function set_field(id, val) {
+ value(id, val);
+ }
+
+// Pass in value to change, otherwise it returns the value of the "e" element
+ function value(e, new_value) {
+ e = $(e);
+ if (!e)
+ return '';
+ // A <select>
+ if (e.options)
+ return value(e.options[e.selectedIndex]);
+ // Just an html element? (or in IE, an option element with no value="" specified)
+ else if (e.value == null || e.tagName.toLowerCase() == 'option' && e.value == '') {
+ if (new_value != null)
+ e.innerHTML = new_value;
+ return e.innerHTML;
+ }
+ // Form field
+ if (new_value != null)
+ e.value = new_value;
+ return e.value;
+ }
+
+// Overwrite the href attribute of all <a> tags with a js_href attribute
+ Event.observe(window, 'load', add_js_attributes);
+ function add_js_attributes() {
+ // Get all links in this form
+ var links = $$('a');
+ for (var i=0; i<links.length; i++) {
+ // js_href
+ var js_href = links[i].getAttribute('js_href');
+ if (js_href && js_href.length)
+ links[i].href = js_href;
+ }
+ }
+
+// Image Preloader
+ var img_on = new Array();
+ var img_off = new Array();
+ function preload_image(id, on, off) {
+ img_on[id] = new Image();
+ img_on[id].src = on;
+ if (off) {
+ img_off[id] = new Image();
+ img_off[id].src = off;
+ }
+ }
+
+// Functions to swap on/off states of images
+ function on(which) {
+ var img = $(which);
+ img.src=img_on[which].src;
+ }
+ function off(which) {
+ var img = $(which);
+ img.src=img_off[which].src;
+ }
+
+// Submit a form
+ function submit_form(newvar, val, form, confirm_str) {
+ // Confirm?
+ if (confirm_str && !confirm(confirm_str))
+ return;
+ // Find the form we want to submit
+ form = $(form ? form : 'form');
+ if (!form)
+ form = document.form ? document.form : document.forms[0];
+ // Create a new variable?
+ if (newvar) {
+ var hidden = document.createElement('input');
+ hidden.type = 'hidden';
+ hidden.name = newvar;
+ hidden.value = val != null ? val : 1;
+ form.appendChild(hidden);
+ }
+ // Submit
+ form.submit();
+ }
+
+// Check/uncheck a checkbox
+ function toggle_checkbox(id, check) {
+ var e = $(id);
+ if (check)
+ e.checked = true;
+ else if (check != null)
+ e.checked = false;
+ else
+ e.checked = e.checked ? false : true;
+ }
+
+// Change the help text
+ function help_text(text) {
+ // Set the text
+ $('help_text').innerHTML = text;
+ // Toggle the regions
+ $('help_text_default').toggle();
+ $('help_text').toggle();
+ }
+
+
+// Return a time in hours and minutes
+ function nice_length(mylength, rx_hr, rx_hrs, rx_min, rx_mins) {
+ var mins = Math.round((mylength % 3600) / 60);
+ var hours = Math.round(mylength / 3600);
+ var ret;
+ if (hours) {
+ if (hours > 1)
+ ret = rx_hrs.replace(/\$1/, hours);
+ else
+ ret = rx_hr.replace(/\$1/, hours);
+ }
+ else
+ ret = '';
+ if (mins > 0) {
+ if (ret.length)
+ ret = ret + ' ';
+ if (mins > 1)
+ ret = ret + rx_mins.replace(/\$1/, mins);
+ else
+ ret = ret + rx_min.replace(/\$1/, mins);
+ }
+ return ret;
+ }
+
+// Return a human-readable filesize
+ function nice_filesize(size) {
+ var kb = 1024; // Kilobyte
+ var mb = 1024 * kb; // Megabyte
+ var gb = 1024 * mb; // Gigabyte
+ var tb = 1024 * gb; // Terabyte
+ // If it's less than a kb we just return the size
+ if (size < kb)
+ return size + ' B';
+ // Otherwise we keep going until the size is in the appropriate measurement range.
+ else if (size < mb)
+ return Math.round(size/kb) + ' KB';
+ else if (size < gb)
+ return Math.round(size/mb) + ' MB';
+ else if (size < tb)
+ return Math.round(size/gb) + ' GB';
+ else
+ return Math.round(size/tb) + ' TB';
+ }
+
+// The routines to allow a small ajax request counter...
+ var pending_ajax_requests = 0;
+
+ function ajax_add_request() {
+ pending_ajax_requests += 1;
+ $('ajax_num_requests').innerHTML = pending_ajax_requests;
+ $('ajax_working').removeClassName('hidden');
+ }
+
+ function ajax_remove_request() {
+ pending_ajax_requests -= 1;
+ $('ajax_num_requests').innerHTML = pending_ajax_requests;
+ if (pending_ajax_requests == 0)
+ $('ajax_working').addClassName('hidden');
+ }
diff --git a/abs/core-testing/local-website/htdocs/rrd/index.html b/abs/core-testing/local-website/htdocs/rrd/index.html
index c60692f..f6a7135 100644
--- a/abs/core-testing/local-website/htdocs/rrd/index.html
+++ b/abs/core-testing/local-website/htdocs/rrd/index.html
@@ -3,7 +3,7 @@
<head>
<meta content="text/html; charset=ISO-8859-1" http-equiv="content-type">
<meta content="Cecil Watson" name="author">
- <title>KnoppMyth R5.5</title>
+ <title>LinHES</title>
<!-- Generated by: /usr/local/bin/rrd_Configure.sh -->
<link href="/KnoppMyth.css" rel="stylesheet" type="text/css" />
<p align="center"><a href="http://www.mysettopbox.tv">
diff --git a/abs/core-testing/local-website/htdocs/wap.html b/abs/core-testing/local-website/htdocs/wap.html
new file mode 100755
index 0000000..72e6264
--- /dev/null
+++ b/abs/core-testing/local-website/htdocs/wap.html
@@ -0,0 +1,118 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
+<html>
+<head>
+ <base href="/linhes/">
+ <title>Welcome to LinHES R6!</title>
+
+ <meta http-equiv="content-type" content="text/html; charset=utf-8">
+ <meta name="robots" content="noindex, nofollow">
+
+ <script type="text/javascript" src="js/prototype.js"></script>
+ <script type="text/javascript" src="js/prototip/prototip.js"></script>
+ <link rel="stylesheet" type="text/css" href="js/prototip/prototip.css">
+
+ <script type="text/javascript" src="js/utils.js"></script>
+ <script type="text/javascript" src="js/AC_OETags.js"></script>
+ <script type="text/javascript" src="js/table_sort.js"></script>
+
+ <link rel="stylesheet" type="text/css" href="/linhes/wap/style.css">
+ <link rel="stylesheet" type="text/css" href="/linhes/wap/header.css">
+ <link rel="stylesheet" type="text/css" href="/linhes/wap/menus.css">
+ <link rel="stylesheet" type="text/css" href="/linhes/wap/programming.css">
+
+ <link rel="stylesheet" type="text/css" href="/linhes/wap/welcome.css">
+</head>
+
+<body>
+<div id="page_header" style="position:relative; text-align:center;">
+ <div id="logo_box">
+ <a id="LinHES_logo" href="http://linhes.org/">
+ <img src="/header.png" alt="Tux with a Remote" class="body">
+ </a>
+ </div>
+</div>
+
+<table width="100%" border="0" cellspacing="2" cellpadding="0">
+<tr>
+ <td colspan="2" class="menu menu_border_t menu_border_b">
+ <table class="body" width="100%" border="0" cellspacing="2" cellpadding="2">
+ <td align="center">
+ <a href="http://linhes.org" <b>The Linux Home Entertainment System Release 6</b></a>
+ </td>
+ </table>
+ </td>
+</tr>
+</table>
+
+
+<script type="text/javascript">
+<!--
+
+ var visible_module = 'media';
+ function show_module_info(module) {
+ if (visible_module == module)
+ return;
+ // Change the outline on the list item
+ $('module_'+ visible_module).removeClassName('selected');
+ $('module_'+ module).addClassName('selected');
+ // Show and hide the appropriate info boxes
+ $('info_' + visible_module).hide();
+ $('info_' + visible_module).addClassName('hidden');
+ $('info_' + module).show();
+ $('info_' + module).removeClassName('hidden');
+ // Keep track of what's visible now
+ visible_module = module;
+ }
+
+// -->
+</script>
+
+<div id="modules" class="clearfix">
+
+ <div id="module_names">
+ <ul>
+ <li id="module_media" class="selected" onmouseover="show_module_info('media')">Media</li>
+ <li id="module_status" onmouseover="show_module_info('status')">Status</li>
+ <li id="module_help" onmouseover="show_module_info('help')">Help</li>
+ </ul>
+ </div>
+
+ <div id="module_info">
+ <div id="info_media">
+ <ul>
+ <li><a href="/mythweb/">MythWeb</a> - MythWeb provides a frontend for scheduling and managing recordings on your MythBox from a web browser.<br></li>
+ <li><a href="/remote/index.html">MythTV Web Virtual Remote</a> - A web based virtual remote control for MythTV. For this to work, you must enable "Network Remote Control interface" in Service Menu -> MythTV Configuration -> Setup -> General -> Remote Control.<br></li>
+ <li><a href="/ipodfeed/feed.php">iPod Feeds</a> - Transcodes ready for the iPod. If you have no recordings, you will see a warning issued from PHP.<br></li>
+ <li><a href="/ipodfeed/m2iweb.php">Delete iPod Transcodes</a><br></li>
+ <li><a href="/archive/feed.php">XviD Feeds</a> - Programs you have transcoded to XviD. If you have no recordings, you will see a warning issued from PHP.<br></li>
+ <li><a href="/archive/archive.php">Delete XviD Transcodes</a><br></li>
+ <li><a href="/fuppes.php">FUPPES</a> - Free UPnP Entertainment Service. A UPnP to be used inplace of the UPnP server that comes with MythTV. Install via the Service Menu.<br></li>
+ <li><a href="/mediaserv.php">Mediaserv</a> - A on-demand transcoding server for videos. Mediaserv is designed to transcode video in a format playable on the Nokia Internet Tablets. However it works well at transcoding and streaming to any device that will playback AVIs (think streaming to any browser!). By wap, we have it set to link to TV recordings (pretty) and your video directory. Additionally if you want it to stream contents from a network share, it will! ln -s /path/to/share /myth/mediaserv/media/<br></li>
+ <li><a href="/mythweb/data/mp3player.html">Radio</a> - Music in MythMusic must be encoded as MP3s.<br></li>
+ </ul>
+ </div>
+ <div id="info_status" class="hidden">
+ <ul>
+ <li><a href="/rrd/index.html">RRDTool</a> - Hardware status graphs.</li>
+ <li><a href="/monitorix/">Monitorix</a> - A system monitoring perl script that uses rrd databases to log system data.<br></li>
+ <li><a href="http://fah-web.stanford.edu/cgi-bin/main.py?qtype=teampage&amp;teamnum=50975">KnoppMyth Folding@home Team Status</a></li>
+ <li><a href="/foldingathome/">My Folding@home Status</a></li>
+ </ul>
+ </div>
+ <div id="info_help" class="hidden">
+ <ul>
+ <li><a href="http://www.mythtv.org/docs/">MythTV Documentation</a></li>
+ <li><a href="/mythtv-doc/keys.txt">MythTV Default Keybindings</a></li>
+ <li><a href="http://www.mythtv.org/support">MythTV Support</a></li>
+ <li><a href="http://www.schedulesdirect.org/">Schedules Direct</a> - Provides U.S./Canadian TV listing data.<br></li>
+ <li><a href="/linhes.html">LinHES</a> - Describes how "The Project Leader" setup multiple systems to form a <b>Lin</b>ux <b>H</b>ome <b>E</b>ntertainment <b>S</b>ystem.<br></li>
+ <li><a href="http://linhes.org/phpBB2/">LinHES Forum</a></li>
+ <li><a href="http://www.google.com/advanced_search?q=+site:mysettopbox.tv/phpBB2&hl=en&lr=&as_qdr=all">Search LinHES Forum</a></li>
+ <li><a href="http://www.knoppmythwiki.org/">KnoppMyth Wiki</a></li>
+ <li><a href="http://linhes.org/bugs/projects/linhes/wiki">LinHES R6 Hints & Tips</a></li>
+ <li><a href="http://linhes.org/bugs">LinHES Bug Tracker</a></li>
+ </ul>
+ </div>
+
+</body>
+</html>
diff --git a/abs/core-testing/mplayer-wrapper/PKGBUILD b/abs/core-testing/mplayer-wrapper/PKGBUILD
index c64875d..2dbf67d 100644
--- a/abs/core-testing/mplayer-wrapper/PKGBUILD
+++ b/abs/core-testing/mplayer-wrapper/PKGBUILD
@@ -1,16 +1,15 @@
pkgname=mplayer-wrapper
pkgver=1
-pkgrel=9
+pkgrel=10
pkgdesc="wrapper for mplayer and mplayer derivatives"
arch=('i686' 'x86_64')
-depends=('perl')
+depends=('perl' 'vdpauinfo')
source=(mplayer-wrapper.pl)
license=('GPL2')
-install=mplayer-wrapper.install
build() {
LH_ROOT=/usr/LH
mkdir -p $startdir/pkg/$LH_ROOT/bin/
@@ -19,3 +18,4 @@ build() {
# executables
install -m0755 -D *.pl $startdir/pkg/$LH_ROOT/bin/
}
+md5sums=('c21a8b05d2134262c876396bde9da0a2')
diff --git a/abs/core-testing/mplayer-wrapper/mplayer-wrapper.pl b/abs/core-testing/mplayer-wrapper/mplayer-wrapper.pl
index da0e838..18f3caf 100755..100644
--- a/abs/core-testing/mplayer-wrapper/mplayer-wrapper.pl
+++ b/abs/core-testing/mplayer-wrapper/mplayer-wrapper.pl
@@ -97,10 +97,13 @@ sub dynamic_parameters () {
my($mediafile)=@_;
my @parameters = ();
my $codec="";
+ my $xresolution=0;
+ my $yresolution=0;
my %vdpau_supported_modes=();
+ my $vf_parameters="";
# See if the GPU and driver support vdpau for GPU-based accelerated decoding
- my $command="vdpinfo |";
+ my $command="vdpauinfo |";
# On supported hardware, vdpinfo produces relevant results that look something like this (see
# http://www.phoronix.com/forums/showthread.php?t=14493 for additional details, or run
# vdpinfo on vdpau-capable hardware yourself):
@@ -130,49 +133,95 @@ sub dynamic_parameters () {
}
close(SHELL);
- # figure out what codec the video uses
- my $command="mplayer -identify -frames 0 \"$mediafile\" | grep ID_VIDEO_CODEC | cut -c 16- |";
+ # Learn some things about the video: codec and resolution
+ my $command="mplayer -identify -frames 0 \"$mediafile\" |";
open(SHELL, $command);
while (<SHELL>) {
chop;
- $codec = $_;
- #print "DEBUG: codec is $codec\n";
+ if (m/ID_VIDEO_CODEC=(.*)/g) {
+ $codec = $1;
+ #print "DEBUG: codec is $codec\n";
+ } elsif (m/ID_VIDEO_WIDTH=(.*)/g) {
+ $xresolution = $1;
+ #print "DEBUG: x resolution is $xresolution\n";
+ } elsif (m/ID_VIDEO_HEIGHT=(.*)/g) {
+ $yresolution = $1;
+ #print "DEBUG: y resolution is $yresolution\n";
+ }
}
close(SHELL);
- # We should use vdpau if it's available and helps with the codec we need to decode.
- if ($codec eq "ffh264") { # h.264
- if ($vdpau_supported_modes{"H264"}) {
- push(@parameters, "-vo vdpau");
- push(@parameters, "-vc ffh264vdpau");
+ # see if it's a malformed 4:3 video with top and side bars, in need of cropping
+ my $crop_candidate="";
+ my $biggestX=0;
+ my $biggestY=0;
+ # The algorithm here is trial and error. Skip 6 minutes into a video, and look at 40 frames of
+ # video. Videos shorter than 6 minutes will not end up being examined for letterboxing badness.
+ # In a longer video, use the least-recommended pruning that mplayer suggests, among the frames polled.
+ my $command="mplayer -ss 360 -ao null -vo null -vf cropdetect -frames 40 \"$mediafile\" | grep CROP | tail -1 |";
+ open(SHELL, $command);
+ while (<SHELL>) {
+ if (m/-vf (crop=.*)\)/g) {
+ $crop_candidate = $1;
+ print "DEBUG: $crop_candidate\n";
+ if ($crop_candidate =~ m/(\d+):(\d+)/) {
+ if (($1 > $biggestX) && ($2 > $biggestY)) {
+ $biggestX = $1;
+ $biggestY = $2;
+ print "newX: $biggestX\n";
+ print "newY: $biggestY\n";
+ }
+ }
}
- } elsif ($codec eq "ffmpeg2") { # MPEG2
- if ($vdpau_supported_modes{"MPEG2"}) {
- push(@parameters, "-vo vdpau");
- push(@parameters, "-vc ffmpeg12vdpau");
+ if (($biggestX != $xresolution) || ($biggestY != $yresolution)) {
+ $vf_parameters = $crop_candidate;
}
+ print "DEBUG: crop parameter is $vf_parameters\n";
+ }
+ close(SHELL);
- # ??? although MPEG1 is rare, it seems as if it should work with -vc ffmpeg12vdpau as well
-
- # problems have been reported with WMV3 support
-
+ # If there are no crop parameters, use vdpau if it's supported. Don't use vdpau if there's cropping
+ # because vdpau doesn't work with mplayer's cropping video filter.
+
+ # We should use vdpau if it's available and helps with the codec we need to decode.
+ if ($vf_parameters eq "") {
+ if ($codec eq "ffh264") { # h.264
+ if ($vdpau_supported_modes{"H264"}) {
+ push(@parameters, "-vo vdpau");
+ push(@parameters, "-vc ffh264vdpau");
+ }
+ } elsif ($codec eq "ffmpeg2") { # MPEG2
+ if ($vdpau_supported_modes{"MPEG2"}) {
+ push(@parameters, "-vo vdpau");
+ push(@parameters, "-vc ffmpeg12vdpau");
+ }
+
+ # ??? although MPEG1 is rare, it seems as if it should work with -vc ffmpeg12vdpau as well
+
+ # problems have been reported with WMV3 support
+
# } elsif ($codec eq "ffwmv3") { # WMV3
# if ($vdpau_supported) {
# push(@parameters, "-vo vdpau");
# push(@parameters, "-vc ffwmv3vdpau");
# }
- # problems have been reported with WVC1 support
-
+ # problems have been reported with WVC1 support
+
# } elsif ($codec eq "ffvc1") { # WVC1
# if ($vdpau_supported) {
# push(@parameters, "-vo vdpau");
# push(@parameters, "-vc ffvc1vdpau");
# }
-
- } else {
+
+ } else { # any codec that doesn't work with vdpau
+ push(@parameters, "-vo xv,x11,");
+ push(@parameters, "-vc ,");
+ push(@parameters, "-vf pp=lb,$vf_parameters");
+ }
+ } else { # there is a crop parameter
push(@parameters, "-vo xv,x11,");
push(@parameters, "-vc ,");
- push(@parameters, "-vf pp=lb,"); # doesn't actually work with vdpau, but doesn't break anything
+ push(@parameters, "-vf pp=lb,$vf_parameters");
}
return(@parameters);
}
diff --git a/abs/core-testing/mythinstall/PKGBUILD b/abs/core-testing/mythinstall/PKGBUILD
index 6cc39a9..7a8cccd 100644
--- a/abs/core-testing/mythinstall/PKGBUILD
+++ b/abs/core-testing/mythinstall/PKGBUILD
@@ -1,11 +1,11 @@
# Maintainer: Jams
pkgname=mythinstall
pkgver=2
-pkgrel=33
+pkgrel=42
pkgdesc="LinHES installer/systemconfig GUI."
arch=i686
depends=()
-makedepends=('mythtv>=0.22')
+makedepends=('mythtv>=0.23')
source=('install-ui.xml')
build() {
diff --git a/abs/core-testing/mythinstall/checkout_MythVantage.sh b/abs/core-testing/mythinstall/checkout_MythVantage.sh
index 58849bf..eea6727 100755
--- a/abs/core-testing/mythinstall/checkout_MythVantage.sh
+++ b/abs/core-testing/mythinstall/checkout_MythVantage.sh
@@ -1,6 +1,6 @@
#!/bin/bash
MYDIR=`pwd`
-MYTHPATH="\/data\/LinHES-PKGBUILD\/abs\/core-testing\/mythtv\/stable-0.22\/mythtv\/src\/mythtv"
+MYTHPATH="\/data\/LinHES-PKGBUILD\/abs\/core-testing\/mythtv\/stable-0.23\/mythtv\/src\/mythtv"
function setup_links {
rm mythinstall.bin
diff --git a/abs/core-testing/mythstream/PKGBUILD b/abs/core-testing/mythstream/PKGBUILD
index d23da84..2ff82ee 100644
--- a/abs/core-testing/mythstream/PKGBUILD
+++ b/abs/core-testing/mythstream/PKGBUILD
@@ -4,7 +4,7 @@
pkgname=mythstream
pkgver=0.18_3
-pkgrel=4
+pkgrel=5
pkgdesc="Unofficial MythTV plugin for Internet audio and video streams."
arch=('i686' 'x86_64')
url="http://home.kabelfoon.nl/~moongies/streamtuned.html"
@@ -18,7 +18,7 @@ install=mythstream.install
build() {
cd $startdir/src/mythstream_mythtv-r21640
- ln -s ../../../mythtv/stable-0.22/mythtv/src/mythtv/libs/lib* .
+ ln -s ../../../mythtv/stable-0.23/mythtv/src/mythtv/libs/lib* .
patch -p1 < ../mythstream.patch || return 1
diff --git a/abs/core-testing/mythtv/stable-0.22/clean_all.sh b/abs/core-testing/mythtv/old/stable-0.22/clean_all.sh
index 1ebdc43..1ebdc43 100755
--- a/abs/core-testing/mythtv/stable-0.22/clean_all.sh
+++ b/abs/core-testing/mythtv/old/stable-0.22/clean_all.sh
diff --git a/abs/core-testing/mythtv/stable-0.22/morethemes/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/morethemes/PKGBUILD
index 479f886..479f886 100644
--- a/abs/core-testing/mythtv/stable-0.22/morethemes/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/morethemes/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mp_all.sh b/abs/core-testing/mythtv/old/stable-0.22/mp_all.sh
index 96d5dde..96d5dde 100755
--- a/abs/core-testing/mythtv/stable-0.22/mp_all.sh
+++ b/abs/core-testing/mythtv/old/stable-0.22/mp_all.sh
diff --git a/abs/core-testing/mythtv/stable-0.22/mytharchive/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mytharchive/PKGBUILD
index cc49523..cc49523 100644
--- a/abs/core-testing/mythtv/stable-0.22/mytharchive/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mytharchive/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythbrowser/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythbrowser/PKGBUILD
index 3508b9f..3508b9f 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythbrowser/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythbrowser/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythflix/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythflix/PKGBUILD
index 8d5da1e..8d5da1e 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythflix/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythflix/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythgallery/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythgallery/PKGBUILD
index d31d645..d31d645 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythgallery/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythgallery/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythgame/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythgame/PKGBUILD
index 7441a12..7441a12 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythgame/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythgame/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythmovies/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythmovies/PKGBUILD
index 8685a87..8685a87 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythmovies/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythmovies/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythmusic/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythmusic/PKGBUILD
index 4722701..4722701 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythmusic/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythmusic/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythnews/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythnews/PKGBUILD
index 7450c9d..7450c9d 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythnews/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythnews/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythsmolt/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythsmolt/PKGBUILD
index e609048..52549d4 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythsmolt/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythsmolt/PKGBUILD
@@ -1,12 +1,12 @@
pkgname=mythsmolt
pkgver=0.22
-pkgrel=16
+pkgrel=28
pkgdesc="mythsmolt, a hardware profileing tool"
arch=('i686' 'x86_64')
url="http://www.mythvantage.com"
license=('GPL')
depends=("mythtv>=${pkgver}" urlgrabber python-simplejson)
-source=("http://www.mythvantage.com/request.php?4")
+source=("http://www.mythvantage.com/request.php?4" 'smolt_init_login.sh' )
groups=('mythtv-extras')
@@ -15,6 +15,7 @@ build() {
./configure.sh
make || return 1
make INSTALL_ROOT=$startdir/pkg install
+ install -D -m 755 $srcdir/smolt_init_login.sh $pkgdir/etc/profile.d/smolt_init_login.sh
}
-md5sums=('b8e9b79db0d8f428ba127c6e42577761')
-md5sums=('fdf68ec5c78827aefca6f09ad82296a4')
+md5sums=('4641b425d1aa910d82972ebb3a8d4998'
+ '57a3416d90e59abbd5062436583c17e1')
diff --git a/abs/core-testing/mythtv/old/stable-0.22/mythsmolt/smolt_init_login.sh b/abs/core-testing/mythtv/old/stable-0.22/mythsmolt/smolt_init_login.sh
new file mode 100644
index 0000000..0b76305
--- /dev/null
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythsmolt/smolt_init_login.sh
@@ -0,0 +1,39 @@
+if [ $UID = 0 -o $UID = 1000 ]
+then
+ INIT=`ps -p 1 -o comm=`
+ if [ x$INIT = xrunit ]
+ then
+ if [[ -f /home/mythtv/.configure && $- = *i* ]]
+ then
+ if [ ! -z "$PS1" ]
+ then
+ if [ $0 = "-bash" ]
+ then
+ if [ ! -e /home/mythtv/.mythtv/MythSmolt/hw-uuid ]
+ then
+ echo ""
+ echo "####################################################"
+ echo "It appears you have not yet run smolt"
+ echo "Please take the time to submit your hardware profile"
+ echo ""
+ echo "press any key to continue:"
+ echo "####################################################"
+ read a
+ mkdir -p /home/mythtv/.mythtv/MythSmolt
+ chown -R mythtv:users /home/mythtv/.mythtv/MythSmolt
+
+ if [ $UID = 0 ]
+ then
+ su mythtv -c "/usr/share/mythtv/mythsmolt/scripts/sendProfile.py" && su mythtv -c "touch /home/mythtv/.mythtv/MythSmolt/hw-uuid"
+ else
+ /usr/share/mythtv/mythsmolt/scripts/sendProfile.py && touch /home/mythtv/.mythtv/MythSmolt/hw-uuid
+ fi
+ fi
+ fi
+ fi
+ fi
+ fi
+fi
+
+
+
diff --git a/abs/core-testing/mythtv/stable-0.22/myththemes/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/myththemes/PKGBUILD
index 72b913a..72b913a 100755
--- a/abs/core-testing/mythtv/stable-0.22/myththemes/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/myththemes/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythtv/PKGBUILD
index 82a9b7c..82a9b7c 100755
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/changeset_r23616.patch b/abs/core-testing/mythtv/old/stable-0.22/mythtv/changeset_r23616.patch
index 2af779a..2af779a 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/changeset_r23616.patch
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/changeset_r23616.patch
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/HOST_SETTINGS.xml b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/HOST_SETTINGS.xml
index 1c6bb06..1c6bb06 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/HOST_SETTINGS.xml
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/HOST_SETTINGS.xml
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/is.xml b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/is.xml
index 88b7e6b..88b7e6b 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/is.xml
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/is.xml
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/library.xml.patch b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/library.xml.patch
index 81ea604..81ea604 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/library.xml.patch
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/library.xml.patch
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/linhes.xml b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/linhes.xml
index ebc848b..ebc848b 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/linhes.xml
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/linhes.xml
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mainmenu.tv.patch b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mainmenu.tv.patch
index 930fc5b..930fc5b 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mainmenu.tv.patch
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mainmenu.tv.patch
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mainmenu.xml.patch b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mainmenu.xml.patch
index ed5dc72..ed5dc72 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mainmenu.xml.patch
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mainmenu.xml.patch
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mythbackup.xml b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mythbackup.xml
index 5914b33..5914b33 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mythbackup.xml
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mythbackup.xml
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mythrestore.xml b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mythrestore.xml
index 8f5c285..8f5c285 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/mythrestore.xml
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/mythrestore.xml
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/optical_menu.xml.patch b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/optical_menu.xml.patch
index b4b1411..b4b1411 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/optical_menu.xml.patch
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/optical_menu.xml.patch
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/original/create_patch.sh b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/original/create_patch.sh
index 34d8b8c..34d8b8c 100755
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/original/create_patch.sh
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/original/create_patch.sh
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/setup.xml b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/setup.xml
index f56bb6f..f56bb6f 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/setup.xml
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/setup.xml
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/siriusmenu.xml b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/siriusmenu.xml
index e317b36..e317b36 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/siriusmenu.xml
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/siriusmenu.xml
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/themeinfo.xml-tv b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/themeinfo.xml-tv
index 64a3207..64a3207 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/themeinfo.xml-tv
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/themeinfo.xml-tv
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/update.xml b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/update.xml
index 5b28833..5b28833 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/update.xml
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/update.xml
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/update2.xml b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/update2.xml
index 2ab82ea..2ab82ea 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/update2.xml
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/update2.xml
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/util_menu.xml.patch b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/util_menu.xml.patch
index 3a1072a..3a1072a 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/util_menu.xml.patch
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/util_menu.xml.patch
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/xmmenu.xml b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/xmmenu.xml
index 6b26d11..6b26d11 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menu-xml/xmmenu.xml
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menu-xml/xmmenu.xml
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/menutheme_fallback.patch b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menutheme_fallback.patch
index aa633ff..aa633ff 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/menutheme_fallback.patch
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/menutheme_fallback.patch
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/myth.sh b/abs/core-testing/mythtv/old/stable-0.22/mythtv/myth.sh
index fb7122c..fb7122c 100755
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/myth.sh
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/myth.sh
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/mythbackend b/abs/core-testing/mythtv/old/stable-0.22/mythtv/mythbackend
index 93773a2..93773a2 100755
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/mythbackend
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/mythbackend
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/mythbackend.lr b/abs/core-testing/mythtv/old/stable-0.22/mythtv/mythbackend.lr
index 4f218bc..4f218bc 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/mythbackend.lr
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/mythbackend.lr
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/mythbackend.sh b/abs/core-testing/mythtv/old/stable-0.22/mythtv/mythbackend.sh
index e7a7b70..e7a7b70 100755
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/mythbackend.sh
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/mythbackend.sh
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/mythfrontend.lr b/abs/core-testing/mythtv/old/stable-0.22/mythtv/mythfrontend.lr
index 1580533..1580533 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/mythfrontend.lr
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/mythfrontend.lr
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/mythtv.install b/abs/core-testing/mythtv/old/stable-0.22/mythtv/mythtv.install
index 6b35d5b..6b35d5b 100755
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/mythtv.install
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/mythtv.install
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/pretty b/abs/core-testing/mythtv/old/stable-0.22/mythtv/pretty
index 8b0e051..795ad4c 100755
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/pretty
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/pretty
@@ -1,11 +1,10 @@
#!/bin/bash
-#!/bin/bash
if [ -f /usr/share/mythtv/contrib/user_jobs/mythlink.pl ]
then
su - mythtv -c "perl /usr/share/mythtv/contrib/user_jobs/mythlink.pl --link /myth/pretty"
elif [ -f /usr/share/mythtv/contrib/user_jobs/mythrename.pl ]
then
- su - mythtv -c "perl /usr/share/mythtv/contrib/user_jobs/mythrename.pl --link /myth/pretty"a
+ su - mythtv -c "perl /usr/share/mythtv/contrib/user_jobs/mythrename.pl --link /myth/pretty"
fi
diff --git a/abs/core-testing/mythtv/stable-0.22/mythtv/smolt_jump.patch b/abs/core-testing/mythtv/old/stable-0.22/mythtv/smolt_jump.patch
index 0fc452a..0fc452a 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythtv/smolt_jump.patch
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythtv/smolt_jump.patch
diff --git a/abs/core-testing/mythtv/stable-0.22/mythvideo/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythvideo/PKGBUILD
index 1affe22..1affe22 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythvideo/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythvideo/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythweather/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythweather/PKGBUILD
index 96c3457..96c3457 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythweather/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythweather/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythweb/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythweb/PKGBUILD
index 060a229..060a229 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythweb/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythweb/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.22/mythweb/mythweb.install b/abs/core-testing/mythtv/old/stable-0.22/mythweb/mythweb.install
index 470cbd1..470cbd1 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythweb/mythweb.install
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythweb/mythweb.install
diff --git a/abs/core-testing/mythtv/stable-0.22/mythzoneminder/PKGBUILD b/abs/core-testing/mythtv/old/stable-0.22/mythzoneminder/PKGBUILD
index 228626f..228626f 100644
--- a/abs/core-testing/mythtv/stable-0.22/mythzoneminder/PKGBUILD
+++ b/abs/core-testing/mythtv/old/stable-0.22/mythzoneminder/PKGBUILD
diff --git a/abs/core-testing/mythtv/stable-0.23/clean_all.sh b/abs/core-testing/mythtv/stable-0.23/clean_all.sh
new file mode 100755
index 0000000..b56450e
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/clean_all.sh
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+buildlist=('mythtv' 'mytharchive' 'mythbrowser' 'mythgallery' 'mythgame' 'mythmovies' 'mythmusic' 'mythnetvision' 'mythnews' 'mythvideo' 'mythweather' 'mythzoneminder' 'mythweb' 'myththemes' 'morethemes')
+
+# clean up current directory
+rm -f *~
+
+# clean up mythtv directories
+for i in `echo ${buildlist[@]:0}`
+do
+ echo "-- cleaning $i"
+ cd ./$i
+
+ # clean up everything
+ rm -rf pkg src
+ rm -f *~
+
+ cd ..
+done
+
+echo "DONE!"
+
diff --git a/abs/core-testing/mythtv/stable-0.23/morethemes/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/morethemes/PKGBUILD
new file mode 100644
index 0000000..c8f892e
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/morethemes/PKGBUILD
@@ -0,0 +1,54 @@
+pkgname=morethemes-svn
+pkgver=23790
+pkgrel=1
+pkgdesc="Additional themes for MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv-svn')
+conflicts=('morethemes')
+groups=('mythtv-extras-svn')
+
+patches=()
+source=(`echo ${patches[@]:0}`)
+
+_svntrunk=http://cvs.mythtv.org/svn/trunk/themes
+_svnmod=themes
+
+
+build() {
+
+ svn co $_svntrunk --config-dir ./ -r $pkgver $_svnmod
+ svn revert -R $_svnmod
+
+ cd $startdir/src/$_svnmod
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+# ./configure --prefix=/usr || return 1
+ ./configure --prefix=/usr
+
+ # build and install
+ . /etc/profile
+# make || return 1
+# make INSTALL_ROOT=$startdir/pkg install || return 1
+ make
+ make INSTALL_ROOT=$startdir/pkg install
+ return 0
+#### THIS PKGBUILD IS HACKED TO BUILD WITH ZERO CONTENT RIGHT NOW ####
+}
diff --git a/abs/core-testing/mythtv/stable-0.23/mp_all.sh b/abs/core-testing/mythtv/stable-0.23/mp_all.sh
new file mode 100755
index 0000000..4aefd89
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mp_all.sh
@@ -0,0 +1,30 @@
+#!/bin/sh
+pkgver=23790
+pkgrel=1
+
+# NOTE: Make sure to build and install mythtv first BEFORE building anything else
+buildlist=('mythtv' 'mytharchive' 'mythbrowser' 'mythgallery' 'mythgame' 'mythmovies' 'mythmusic' 'mythnetvision' 'mythnews' 'mythvideo' 'mythweather' 'mythzoneminder' 'mythweb' 'myththemes' 'morethemes')
+
+# build and install
+for i in `echo ${buildlist[@]:0}`
+do
+ echo "---------- building $i ----------"
+ cd ./$i
+
+ # set svn version in the PKGBUILD
+ sed -i s/^pkgver=.*/pkgver=$pkgver/ PKGBUILD
+ sed -i s/^pkgrel=.*/pkgrel=$pkgrel/ PKGBUILD
+
+ # make the package
+ mp -f -i --holdver --skipinteg || exit 1
+
+ # clean up afterwards
+ rm -rf pkg
+ rm -f *~
+
+ cd ..
+done
+
+echo ""
+echo "DONE!"
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mytharchive/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mytharchive/PKGBUILD
new file mode 100644
index 0000000..7c5b99e
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mytharchive/PKGBUILD
@@ -0,0 +1,47 @@
+pkgname=mytharchive
+pkgver=0.23
+pkgrel=1
+pkgdesc="MythTV plugin that lets you create DVDs from or archive your recorded shows."
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23' 'libxmu' 'mysql-python' 'pil' 'dvdauthor' 'mjpegtools' 'transcode')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo ${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mytharchive || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythbrowser/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythbrowser/PKGBUILD
new file mode 100644
index 0000000..c5ae2bb
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythbrowser/PKGBUILD
@@ -0,0 +1,47 @@
+pkgname=mythbrowser
+pkgver=0.23
+pkgrel=1
+pkgdesc="Mini web browser for MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23' 'wget')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo ${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mythbrowser || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythgallery/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythgallery/PKGBUILD
new file mode 100644
index 0000000..ecd6676
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythgallery/PKGBUILD
@@ -0,0 +1,45 @@
+pkgname=mythgallery
+pkgver=0.23
+pkgrel=1
+pkgdesc="Image gallery plugin for MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23' 'libexif' 'libtiff')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo ${patches[@]:0}`)
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mythgallery || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
diff --git a/abs/core-testing/mythtv/stable-0.23/mythgame/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythgame/PKGBUILD
new file mode 100644
index 0000000..04f7c8e
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythgame/PKGBUILD
@@ -0,0 +1,47 @@
+pkgname=mythgame
+pkgver=0.23
+pkgrel=1
+pkgdesc="Emulation plugin for MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23' 'zlib')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo ${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mythgame || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythmovies/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythmovies/PKGBUILD
new file mode 100644
index 0000000..dd8cc34
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythmovies/PKGBUILD
@@ -0,0 +1,48 @@
+pkgname=mythmovies
+pkgver=0.23
+pkgrel=1
+pkgdesc="Displays information about movies playing in the area."
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23')
+conflicts=('mythmovies')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo ${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mythmovies || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythmusic/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythmusic/PKGBUILD
new file mode 100644
index 0000000..d1df770
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythmusic/PKGBUILD
@@ -0,0 +1,51 @@
+pkgname=mythmusic
+pkgver=0.23
+pkgrel=2
+pkgdesc="Music playing plugin for MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23' 'libid3tag' 'libmad' 'libvorbis' 'flac>=1.1.4' 'libcdaudio' \
+ 'cdparanoia' 'fftw2' 'sdl' 'faad2>=2.6.1' 'lame' 'taglib' \
+ 'libvisual-plugins' 'libvisual-projectm')
+conflicts=('mythmusic')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo ${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mythmusic --enable-libvisual --enable-fftw --enable-sdl \
+ --enable-aac || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythnetvision/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythnetvision/PKGBUILD
new file mode 100644
index 0000000..99674d5
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythnetvision/PKGBUILD
@@ -0,0 +1,47 @@
+pkgname=mythnetvision
+pkgver=0.23
+pkgrel=1
+pkgdesc="Internet video plugin for MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv' 'python-pycurl' 'flashplugin')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo ${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mythnetvision || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythnews/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythnews/PKGBUILD
new file mode 100644
index 0000000..f618940
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythnews/PKGBUILD
@@ -0,0 +1,47 @@
+pkgname=mythnews
+pkgver=0.23
+pkgrel=2
+pkgdesc="News checking plugin for MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo ${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mythnews || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/stable-0.23/myththemes/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/myththemes/PKGBUILD
new file mode 100755
index 0000000..da4c6e8
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/myththemes/PKGBUILD
@@ -0,0 +1,47 @@
+pkgname=myththemes
+pkgver=0.23
+pkgrel=3
+pkgdesc="Themes for MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/myththemes-0.23-fixes.tar.bz2' `echo ${patches[@]:0}`)
+
+md5sums=('5e5cafe0dd3fadadbc37d29708e3ec74')
+
+build() {
+
+ cd $startdir/src/myththemes
+ svn update
+ rm -fr Mythbuntu
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythtv/PKGBUILD
new file mode 100755
index 0000000..a62fd65
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/PKGBUILD
@@ -0,0 +1,93 @@
+pkgname=mythtv
+pkgver=0.23
+pkgrel=13
+pkgdesc="A personal video recorder for Linux"
+url="http://www.mythtv.org"
+license="GPL"
+depends=('bash' 'mysql-clients>=5.0' 'qt' 'lame' 'lirc-utils' 'ffmpeg' \
+ 'faad2' 'libxv' 'libxvmc' 'libavc1394' 'libdc1394' 'libiec61883' \
+ 'perl-net-upnp' 'libvdpau')
+makedepends=('libgl' 'subversion')
+replaces=()
+groups=('pvr')
+#backup=(/usr/share/mythtv/is.xml)
+#options=(!strip)
+#MAKEFLAGS="-j6"
+install='mythtv.install'
+
+patchs=()
+#patchs=('smolt_jump.patch')
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythtv-0.23-fixes.tar.bz2'
+ 'mythbackend' 'myth.sh' `echo ${patchs[@]:0}` 'mythbackend.lr' 'mythfrontend.lr' 'pretty')
+arch=('i686' 'x86_64')
+
+build() {
+
+ # get clean copy from SVN repo
+ cd $startdir/src/mythtv
+ svn update
+
+ # apply patches
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patchs[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ sed -i -e "s/\`(svnversion \$\${SVNTREEDIR} 2>\/dev\/null) || echo Unknown\`/$pkgver/" version.pro
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up from last build
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --arch=${ARCH} \
+ --enable-vdpau --enable-xvmc --enable-xvmc-pro \
+ --enable-opengl-vsync --enable-libfaad --enable-dvb --enable-firewire \
+ --compile-type=release --with-bindings=perl,python \
+ --enable-audio-alsa --disable-audio-jack --disable-audio-pulseoutput || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+ # install db schema, scripts and docs
+ install -m0644 database/mc.sql $startdir/pkg/usr/share/mythtv/ || return 1
+ install -D -m0755 ../mythbackend $startdir/pkg/etc/rc.d/mythbackend || return 1
+# cp -r docs $startdir/pkg/usr/share/mythtv/ || return 1
+ rsync -arp --exclude .svn --delete-excluded docs $startdir/pkg/usr/share/mythtv/ || return 1
+
+ # install contrib
+ rsync -arp --exclude .svn --delete-excluded contrib $startdir/pkg/usr/share/mythtv/ || return 1
+ #cp -r contrib $startdir/pkg/usr/share/mythtv/ || return 1
+
+ # patch the xml LinHES style
+ cp -r $startdir/menu-xml/*.xml $startdir/pkg/usr/share/mythtv/themes/defaultmenu/
+# mv $startdir/pkg/usr/share/mythtv/themes/defaultmenu/is.xml $startdir/pkg/usr/share/mythtv/
+ cd $startdir/pkg/usr/share/mythtv/themes/defaultmenu
+ patch -p0 < $startdir/menu-xml/mainmenu.xml.patch || return 1
+ patch -p0 < $startdir/menu-xml/optical_menu.xml.patch || return 1
+ patch -p0 < $startdir/menu-xml/library.xml.patch || return 1
+ patch -p0 < $startdir/menu-xml/util_menu.xml.patch || return 1
+
+ # make log dir
+ mkdir -p $startdir/pkg/var/log/mythtv
+ chown 1000.1000 $startdir/pkg/var/log/mythtv
+ mkdir -p $startdir/pkg/etc/logrotate.d
+ cp $startdir/src/*.lr $startdir/pkg/etc/logrotate.d
+ mkdir -p $startdir/pkg/etc/cron.hourly/
+ install -m0755 $startdir/src/pretty $startdir/pkg/etc/cron.hourly/
+}
+
+md5sums=('f75a4f1be66c2803df54466d4c30361a'
+ '7ef6de58240e7aad389a0b13d91b1cf6'
+ '2babd4b8e146a7538d18dcd55695b0be'
+ 'f735805a80b0d1180dee01f9df1b7004'
+ 'f407d6af23e74a49540755420f84fa58'
+ '5469d9921b726db750b991c87d226158')
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/HOST_SETTINGS.xml b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/HOST_SETTINGS.xml
new file mode 100644
index 0000000..ac52497
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/HOST_SETTINGS.xml
@@ -0,0 +1,94 @@
+<mythmenu name="HOST_SETTINGS">
+
+ <button>
+ <type>MV_NETWORK_SETUP_MENU</type>
+ <text>Network Settings</text>
+ <action>EXEC mythinstall -s network </action>
+ </button>
+
+ <button>
+ <type>MV_NETWORK_SETUP_MENU</type>
+ <text>DDNS Settings</text>
+ <action>EXEC mythinstall -s ddns </action>
+ </button>
+ <button>
+ <type>MV_SYSTEM_SETUP_MENU</type>
+ <text>System Type</text>
+ <action>EXEC mythinstall -s hostype </action>
+ </button>
+
+ <button>
+ <type>MV_SCREENSAVER_SETUP_MENU</type>
+ <text>Screensaver Settings</text>
+ <action>EXEC mythinstall -s screensaver </action>
+ </button>
+
+ <button>
+ <type>MV_IR_SETUP_MENU</type>
+ <text>Remotes</text>
+ <action>EXEC mythinstall -s ir </action>
+ </button>
+
+ <button>
+ <type>MV_MISC_SETUP_MENU</type>
+ <text>Miscellanous Settings</text>
+ <action>EXEC mythinstall -s misc </action>
+ </button>
+
+ <button>
+ <type>MV_SOFTWARE_MENU</type>
+ <text>Software</text>
+ <action>EXEC mythinstall -s plugins </action>
+ </button>
+
+ <button>
+ <type>MV_SHUTDOWN_SETUP_MENU</type>
+ <text>Shutdown Settings</text>
+ <action>EXEC mythinstall -s sleep </action>
+ </button>
+
+ <button>
+ <type>MV_ADVANCED_X_SETUP_MENU</type>
+ <text>Display Settings</text>
+ <action>EXEC mythinstall -s advancedX</action>
+ </button>
+
+ <button>
+ <type>MV_ADVANCED_SETUP_MENU</type>
+ <text>Advanced Settings</text>
+ <action>EXEC mythinstall -s advanced</action>
+ </button>
+
+ <button>
+ <type>MV_AUDIO_SETUP_MENU</type>
+ <text>Audio Settings</text>
+ <action>EXEC mythinstall -s sound </action>
+ </button>
+
+ <button>
+ <type>MV_ACCESS_SETUP_MENU</type>
+ <text>Access Control</text>
+ <action>EXEC mythinstall -s accesscontrol </action>
+ </button>
+
+ <button>
+ <type>MV_USER_SETUP_MENU</type>
+ <text>User Accounts</text>
+ <action>EXEC mythinstall -s user </action>
+ </button>
+
+ <button>
+ <type>MV_WEBACCESS_SETUP_MENU</type>
+ <text>Web Security</text>
+ <action>EXEC mythinstall -s webuser </action>
+ </button>
+
+ <!--
+ <button>
+ <type>SETUP_MENU</type>
+ <text>Settings Profile Manager</text>
+ <action>EXEC mythinstall -t </action>
+ </button>
+ -->
+
+</mythmenu>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/is.xml b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/is.xml
new file mode 100644
index 0000000..88b7e6b
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/is.xml
@@ -0,0 +1,3 @@
+<mythmenu name="Internet Steams">
+
+</mythmenu>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/library.xml.patch b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/library.xml.patch
new file mode 100644
index 0000000..81ea604
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/library.xml.patch
@@ -0,0 +1,12 @@
+--- library.xml.orig 2009-10-16 12:45:44.000000000 +0000
++++ library.xml 2009-10-16 17:21:44.000000000 +0000
+@@ -123,8 +123,7 @@
+ <text lang="HU">Online folyam lejátszása</text>
+ <description></description>
+ <description lang="DE"></description>
+- <action>PLUGIN mythstream</action>
+- <depends>mythstream</depends>
++ <action>MENU is.xml</action>
+ </button>
+
+ <button>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/linhes.xml b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/linhes.xml
new file mode 100644
index 0000000..ebc848b
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/linhes.xml
@@ -0,0 +1,59 @@
+<mythmenu name="LinHES">
+
+ <button>
+ <type>SETUP_GENERAL</type>
+ <text>MythTV Configuration</text>
+ <text lang="IT">Impostazioni</text>
+ <text lang="ES">Configuración</text>
+ <text lang="DE">Zubehör / Konfiguration</text>
+ <text lang="DA">Tilbehør/Indstillinger</text>
+ <text lang="IS">Uppsetning</text>
+ <text lang="NL">Configuratie</text>
+ <text lang="PT">Utensílios</text>
+ <text lang="SV">Verktyg / Inställningar</text>
+ <text lang="JA">設å®~Z</text>
+ <text lang="FI">Oheis/Asetukset</text>
+ <text lang="ZH_TW">å·¥å~E·/設å®~Z</text>
+ <text lang="SL">Nastavitve</text>
+ <text lang="ET">Utiliidid / sätted</text>
+ <text lang="RU">УÑ~BилиÑ~BÑ~K / Ð~]аÑ~AÑ~BÑ~@ойки</text>
+ <text lang="AR">تضبÙ~Jطات</text>
+ <text lang="PL">NarzÄ~Ydzia / ustawienia</text>
+ <text lang="HE">×¢×~Vר×~Y×~] / ×~T×~R×~Sר×~Uת</text>
+ <text lang="HU">Eszközök / Beállítások</text>
+ <alttext lang="DE">Verschiedenes</alttext>
+ <alttext lang="SV">Inställningar</alttext>
+ <alttext lang="ET">Sätted</alttext>
+ <alttext lang="RU">Ð~]аÑ~AÑ~BÑ~@ойки</alttext>
+ <alttext lang="AR">تضبÙ~Jطات</alttext>
+ <description>Configure MythTV and plugins</description>
+ <description lang="DE">MythTV und Plugins konfigurieren</description>
+ <action>MENU util_menu.xml</action>
+ </button>
+
+ <button>
+ <type>LINHES_SETUP</type>
+ <text>LinHES Configuration</text>
+ <action>MENU HOST_SETTINGS.xml</action>
+ </button>
+
+ <button>
+ <type>BACKUP</type>
+ <text>Backup LinHES</text>
+ <action>MENU mythbackup.xml</action>
+ </button>
+
+ <button>
+ <type>RESTORE</type>
+ <text>Restore LinHES</text>
+ <action>MENU mythrestore.xml</action>
+ </button>
+
+<!--#Check for updates-->
+ <button>
+ <type>UPGRADE</type>
+ <text>Upgrade LinHES</text>
+ <action>MENU update.xml</action>
+ </button>
+<!--#Check for updates-->
+</mythmenu>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mainmenu.xml.patch b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mainmenu.xml.patch
new file mode 100644
index 0000000..0ec7b5b
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mainmenu.xml.patch
@@ -0,0 +1,95 @@
+--- mainmenu.xml.orig 2010-04-18 01:29:44.000000000 +0000
++++ mainmenu.xml 2010-04-18 01:32:38.000000000 +0000
+@@ -2,6 +2,31 @@
+ <mythmenu name="MAIN">
+
+ <button>
++ <type>TV_WATCH_TV</type>
++ <text>Watch TV</text>
++ <text lang="IT">Guarda la TV</text>
++ <text lang="ES">Ver la TV</text>
++ <text lang="NL">TV Kijken</text>
++ <text lang="DE">Fernsehen</text>
++ <text lang="IS">Horfa á sjónvarp</text>
++ <text lang="PT">Ver Televisão</text>
++ <text lang="SV">Se på TV</text>
++ <text lang="JA">TV放é€</text>
++ <text lang="FI">Katso Televisiota</text>
++ <text lang="ZH_TW">觀看電視</text>
++ <text lang="SL">Glej TV</text>
++ <text lang="ET">Vaata telerit</text>
++ <text lang="RU">Смотреть ТВ</text>
++ <text lang="AR">شاهد التلÙاز</text>
++ <text lang="PL">OglÄ…danie TV</text>
++ <text lang="HE">צפיה בטלויזיה</text>
++ <text lang="HU">TV nézés</text>
++ <description>Watch live television</description>
++ <description lang="DE">Jetzt Fernsehen schauen</description>
++ <action>TV_WATCH_LIVE</action>
++ </button>
++
++ <button>
+ <type>MENU_MEDIA_LIBRARY</type>
+ <text>Media Library</text>
+ <text lang="IT">Multimedia</text>
+@@ -125,58 +150,9 @@
+ </button>
+
+ <button>
+- <type>TV_WATCH_TV</type>
+- <text>Watch TV</text>
+- <text lang="IT">Guarda la TV</text>
+- <text lang="ES">Ver la TV</text>
+- <text lang="NL">TV Kijken</text>
+- <text lang="DE">Fernsehen</text>
+- <text lang="IS">Horfa á sjónvarp</text>
+- <text lang="PT">Ver Televisão</text>
+- <text lang="SV">Se på TV</text>
+- <text lang="JA">TV放é€</text>
+- <text lang="FI">Katso Televisiota</text>
+- <text lang="ZH_TW">觀看電視</text>
+- <text lang="SL">Glej TV</text>
+- <text lang="ET">Vaata telerit</text>
+- <text lang="RU">Смотреть ТВ</text>
+- <text lang="AR">شاهد التلÙاز</text>
+- <text lang="PL">OglÄ…danie TV</text>
+- <text lang="HE">צפיה בטלויזיה</text>
+- <text lang="HU">TV nézés</text>
+- <description>Watch live television</description>
+- <description lang="DE">Jetzt Fernsehen schauen</description>
+- <action>TV_WATCH_LIVE</action>
+- </button>
+-
+- <button>
+ <type>MENU_UTILITIES_SETUP</type>
+- <text>Utilities / Setup</text>
+- <text lang="IT">Impostazioni</text>
+- <text lang="ES">Configuración</text>
+- <text lang="DE">Zubehör / Konfiguration</text>
+- <text lang="IS">Uppsetning</text>
+- <text lang="NL">Configuratie</text>
+- <text lang="PT">Utensílios</text>
+- <text lang="SV">Verktyg / Inställningar</text>
+- <text lang="JA">設定</text>
+- <text lang="FI">Oheis/Asetukset</text>
+- <text lang="ZH_TW">工具/設定</text>
+- <text lang="SL">Nastavitve</text>
+- <text lang="ET">Utiliidid / sätted</text>
+- <text lang="RU">Утилиты / ÐаÑтройки</text>
+- <text lang="AR">تضبيطات</text>
+- <text lang="PL">Narzędzia / ustawienia</text>
+- <text lang="HE">×¢×–×¨×™× / הגדרות</text>
+- <text lang="HU">Eszközök / Beállítások</text>
+- <alttext lang="DE">Verschiedenes</alttext>
+- <alttext lang="SV">Inställningar</alttext>
+- <alttext lang="ET">Sätted</alttext>
+- <alttext lang="RU">ÐаÑтройки</alttext>
+- <alttext lang="AR">تضبيطات</alttext>
+- <description>Configure MythTV and plugins</description>
+- <description lang="DE">MythTV und Plugins konfigurieren</description>
+- <action>MENU util_menu.xml</action>
++ <text>Service Menu</text>
++ <action>MENU linhes.xml</action>
+ </button>
+
+ <!-- <button>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mythbackup.xml b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mythbackup.xml
new file mode 100644
index 0000000..5914b33
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mythbackup.xml
@@ -0,0 +1,20 @@
+<mythmenu name="LinHES">
+
+ <button>
+ <type>BACKUP</type>
+ <text>Do you wish to backup?</text>
+ <action>NONE</action>
+ </button>
+
+ <button>
+ <type>BACKUP</type>
+ <text>Yes</text>
+ <action>EXEC sudo /usr/LH/bin/mythbackup</action>
+ </button>
+
+ <button>
+ <type>BACKUP</type>
+ <text>No</text>
+ <action>UPMENU</action>
+ </button>
+</mythmenu>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mythrestore.xml b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mythrestore.xml
new file mode 100644
index 0000000..8f5c285
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/mythrestore.xml
@@ -0,0 +1,20 @@
+<mythmenu name="LinHES">
+
+ <button>
+ <type>RESTORE</type>
+ <text>Do you wish to restore?</text>
+ <action>NONE</action>
+ </button>
+
+ <button>
+ <type>RESTORE</type>
+ <text>Yes</text>
+ <action>EXEC sudo /usr/LH/bin/mythrestore</action>
+ </button>
+
+ <button>
+ <type>BACKUP</type>
+ <text>No</text>
+ <action>UPMENU</action>
+ </button>
+</mythmenu>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/optical_menu.xml.patch b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/optical_menu.xml.patch
new file mode 100644
index 0000000..b4b1411
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/optical_menu.xml.patch
@@ -0,0 +1,16 @@
+--- optical_menu.xml.orig 2009-03-23 20:05:43.000000000 +0000
++++ optical_menu.xml 2009-03-23 20:10:02.000000000 +0000
+@@ -134,6 +134,13 @@
+ </button>
+
+ <button>
++ <type>DVD_RIP</type>
++ <text>Import video files from DVD</text>
++ <description>Import video files from a data DVD</description>
++ <action>EXEC /usr/LH/bin/importfiles.sh</action>
++ </button>
++
++ <button>
+ <type>EJECT</type>
+ <text>Eject media</text>
+ <text lang="IT">Espelli Media</text>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/original/create_patch.sh b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/original/create_patch.sh
new file mode 100755
index 0000000..34d8b8c
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/original/create_patch.sh
@@ -0,0 +1,5 @@
+#!/bin/bash
+for i in *.xml
+do
+ diff -u $i.orig $i > ../$i.patch
+done
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/setup.xml b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/setup.xml
new file mode 100644
index 0000000..f56bb6f
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/setup.xml
@@ -0,0 +1,111 @@
+<mythmenu name="MAIN">
+
+ <button>
+ <type>SETUP_GENERAL</type>
+ <text>1. General</text>
+ <text lang="IT">1. Generale</text>
+ <text lang="PT">1. Geral</text>
+ <text lang="SV">1. Generellt</text>
+ <text lang="JA">1. 一般</text>
+ <text lang="DE">1. Allgemeines</text>
+ <text lang="FI">1. Yleiset</text>
+ <text lang="FR">1. Général</text>
+ <text lang="SI">1. Splošno</text>
+ <text lang="ET">1. Ãœldine</text>
+ <text lang="NB">1 Generelt</text>
+ <text lang="DK">1. Generelt</text>
+ <text lang="ES">1. General</text>
+ <text lang="CZ">1. Obecný</text>
+ <text lang="RU">1. Общие</text>
+ <action>GENERAL</action>
+ </button>
+
+ <button>
+ <type>SETUP_CAPTURE_CARDS</type>
+ <text>2. Capture cards</text>
+ <text lang="IT">2. Schede di Acquisizione</text>
+ <text lang="PT">2. Placas de Captura</text>
+ <text lang="SV">2. TV-kort</text>
+ <text lang="JA">2. キャプãƒãƒ£ã‚«ãƒ¼ãƒ‰</text>
+ <text lang="DE">2. TV-Karten</text>
+ <text lang="FI">2. TV-kortit</text>
+ <text lang="FR">2. Cartes d'acquisition</text>
+ <text lang="SI">2. Kartice za zajem</text>
+ <text lang="ET">2. TV-kaardid</text>
+ <text lang="NB">2 TV-kort</text>
+ <text lang="DK">2. TV-kort</text>
+ <text lang="ES">2. Capturadoras</text>
+ <text lang="CZ">2. Zachytávací karty</text>
+ <text lang="RU">2. Карты захвата</text>
+ <action>CAPTURE CARDS</action>
+ </button>
+
+ <button>
+ <type>SETUP_VIDEO_SOURCES</type>
+ <text>3. Video sources</text>
+ <text lang="IT">3. Fonte Video</text>
+ <text lang="PT">3. Fontes de Vídeo</text>
+ <text lang="SV">3. Videokällor</text>
+ <text lang="JA">3. ビデオソース</text>
+ <text lang="DE">3. Videoquellen</text>
+ <text lang="FI">3. Kuvanlähteet</text>
+ <text lang="FR">3. Sources vidéo</text>
+ <text lang="SI">3. Video viri</text>
+ <text lang="ET">3. Videosisendid</text>
+ <text lang="NB">3 Videokilder</text>
+ <text lang="DK">3. Videokilder</text>
+ <text lang="ES">3. Fuentes de Vídeo</text>
+ <text lang="CZ">3. Zdroje obrazu</text>
+ <text lang="RU">3. Видео иÑточники</text>
+ <action>VIDEO SOURCES</action>
+ </button>
+
+ <button>
+ <type>SETUP_INPUT_CONNECTIONS</type>
+ <text>4. Input connections</text>
+ <text lang="IT">4. Connessioni di Ingresso</text>
+ <text lang="PT">4. Ligações de Entrada</text>
+ <text lang="SV">4. Anslutningar</text>
+ <text lang="JA">4. 入力ã¨ã‚½ãƒ¼ã‚¹ã®æŽ¥ç¶š</text>
+ <text lang="DE">4. Verknüpfungen</text>
+ <text lang="FI">4. Sisääntuloasetukset</text>
+ <text lang="FR">4. Entrées Vidéos</text>
+ <text lang="SI">4. Vhodne povezave</text>
+ <text lang="ET">4. Sisendite ühendused</text>
+ <text lang="NB">4 Inndata</text>
+ <text lang="DK">4. Indgange</text>
+ <text lang="ES">4. Conexiones</text>
+ <text lang="CZ">4. Připojení vstupů</text>
+ <text lang="RU">4. Соединение входов</text>
+ <action>CARD INPUTS</action>
+ </button>
+
+ <button>
+ <type>SETUP_CHANNEL_EDITOR</type>
+ <text>5. Channel Editor</text>
+ <text lang="IT">5. Modifica Canali</text>
+ <text lang="SV">5. Kanaleditor</text>
+ <text lang="JA">5. ãƒãƒ£ãƒ³ãƒãƒ«è¨­å®š</text>
+ <text lang="DE">5. Sender bearbeiten</text>
+ <text lang="FI">5. Kanavanviritys</text>
+ <text lang="FR">5. Editeur de chaînes</text>
+ <text lang="SI">5. Urejanje kanalov</text>
+ <text lang="ET">5. Kanaliredaktor</text>
+ <text lang="NB">5 Kanalredigerer</text>
+ <text lang="DK">5. Kanal opsætning</text>
+ <text lang="ES">5. Editor Canales</text>
+ <text lang="CZ">5. Editor kanálů</text>
+ <text lang="RU">5. Редактор каналов</text>
+ <action>CHANNEL EDITOR</action>
+ </button>
+
+ <button>
+ <type>SETUP_STORAGE_GROUPS</type>
+ <text>6. Storage Directories</text>
+ <text lang="IT">6. Cartelle</text>
+ <text lang="FI">Tallennusryhmät</text>
+ <text lang="SV">Lagringsgrupper</text>
+ <action>STORAGE GROUPS</action>
+ </button>
+
+</mythmenu>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/siriusmenu.xml b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/siriusmenu.xml
new file mode 100644
index 0000000..e317b36
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/siriusmenu.xml
@@ -0,0 +1,419 @@
+<mythmenu name="SIRIUS">
+ <button>
+ <type>MUSIC</type>
+ <text>Sirius Hits 1</text>
+ <action>EXEC /usr/bin/cliSipie siriushits1</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>StarLite</text>
+ <action>EXEC /usr/bin/cliSipie starlite</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Sirius Love</text>
+ <action>EXEC /usr/bin/cliSipie siriuslove</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Movin EZ</text>
+ <action>EXEC /usr/bin/cliSipie movineasy</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Sirius Gold</text>
+ <action>EXEC /usr/bin/cliSipie siriusgold</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>'60s Vibrations</text>
+ <action>EXEC /usr/bin/cliSipie 60svibrations</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Totally '70s</text>
+ <action>EXEC /usr/bin/cliSipie totally70s</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Big '80s</text>
+ <action>EXEC /usr/bin/cliSipie big80s</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>ThePulse</text>
+ <action>EXEC /usr/bin/cliSipie thepulse</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Bridge</text>
+ <action>EXEC /usr/bin/cliSipie thebridge</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>BBC Radio 1</text>
+ <action>EXEC /usr/bin/cliSipie bbcradio1</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Super Shuffle</text>
+ <action>EXEC /usr/bin/cliSipie supershuffle</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Elvis Radio</text>
+ <action>EXEC /usr/bin/cliSipie elvisradio</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Classic Vinyl</text>
+ <action>EXEC /usr/bin/cliSipie classicvinyl</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Classic Rewind</text>
+ <action>EXEC /usr/bin/cliSipie classicrewind</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>TheVault</text>
+ <action>EXEC /usr/bin/cliSipie thevault</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Jam_ON</text>
+ <action>EXEC /usr/bin/cliSipie jamon</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Spectrum</text>
+ <action>EXEC /usr/bin/cliSipie thespectrum</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>BuzzSaw</text>
+ <action>EXEC /usr/bin/cliSipie buzzsaw</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Octane</text>
+ <action>EXEC /usr/bin/cliSipie octane</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Alt Nation</text>
+ <action>EXEC /usr/bin/cliSipie altnation</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>1st Wave</text>
+ <action>EXEC /usr/bin/cliSipie firstwave</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Hair Nation</text>
+ <action>EXEC /usr/bin/cliSipie hairnation</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>'90s Alternative</text>
+ <action>EXEC /usr/bin/cliSipie 90salternative</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Garage</text>
+ <action>EXEC /usr/bin/cliSipie undergroundgarage</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Left of Center</text>
+ <action>EXEC /usr/bin/cliSipie leftofcenter</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Hard Attack</text>
+ <action>EXEC /usr/bin/cliSipie hardattack</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Faction</text>
+ <action>EXEC /usr/bin/cliSipie faction</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Punk</text>
+ <action>EXEC /usr/bin/cliSipie punk</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>The Coffee House</text>
+ <action>EXEC /usr/bin/cliSipie coffeehouse</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Margaritaville</text>
+ <action>EXEC /usr/bin/cliSipie radiomargaritaville</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Sirius Disorder</text>
+ <action>EXEC /usr/bin/cliSipie siriusdisorder</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Reggae</text>
+ <action>EXEC /usr/bin/cliSipie reggaerhythms</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Area 33</text>
+ <action>EXEC /usr/bin/cliSipie area33</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Boombox</text>
+ <action>EXEC /usr/bin/cliSipie boombox</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Chill</text>
+ <action>EXEC /usr/bin/cliSipie chill</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>The Beat</text>
+ <action>EXEC /usr/bin/cliSipie thebeat</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Strobe</text>
+ <action>EXEC /usr/bin/cliSipie thestrobe</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Hip-Hop Nation</text>
+ <action>EXEC /usr/bin/cliSipie hiphopnation</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>BackSpin</text>
+ <action>EXEC /usr/bin/cliSipie backspin</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Shade 45</text>
+ <action>EXEC /usr/bin/cliSipie shade45</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Hot Jamz</text>
+ <action>EXEC /usr/bin/cliSipie hotjamz</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Heart &amp; Soul</text>
+ <action>EXEC /usr/bin/cliSipie heartandsoul</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>SoulTown</text>
+ <action>EXEC /usr/bin/cliSipie soultown</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>New Country</text>
+ <action>EXEC /usr/bin/cliSipie newcountry</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Prime Country</text>
+ <action>EXEC /usr/bin/cliSipie primecountry</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Roadhouse</text>
+ <action>EXEC /usr/bin/cliSipie theroadhouse</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Outlaw Country</text>
+ <action>EXEC /usr/bin/cliSipie outlawcountry</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Bluegrass</text>
+ <action>EXEC /usr/bin/cliSipie bluegrass</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Spirit</text>
+ <action>EXEC /usr/bin/cliSipie spirit</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Praise</text>
+ <action>EXEC /usr/bin/cliSipie praise</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Planet Jazz</text>
+ <action>EXEC /usr/bin/cliSipie planetjazz</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>JazzCafe</text>
+ <action>EXEC /usr/bin/cliSipie jazzcafe</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>PureJazz</text>
+ <action>EXEC /usr/bin/cliSipie purejazz</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Spa 73</text>
+ <action>EXEC /usr/bin/cliSipie spa73</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Blues</text>
+ <action>EXEC /usr/bin/cliSipie siriusblues</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Siriusly Sinatra</text>
+ <action>EXEC /usr/bin/cliSipie siriuslysinatra</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Broadway's Best</text>
+ <action>EXEC /usr/bin/cliSipie broadwaysbest</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Symphony Hall</text>
+ <action>EXEC /usr/bin/cliSipie symphonyhall</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Met Opera Radio</text>
+ <action>EXEC /usr/bin/cliSipie metropolitanopera</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Sirius Pops</text>
+ <action>EXEC /usr/bin/cliSipie siriuspops</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Universo Latino</text>
+ <action>EXEC /usr/bin/cliSipie universolatino</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Rumbon</text>
+ <action>EXEC /usr/bin/cliSipie rumbon</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Martha Stewart</text>
+ <action>EXEC /usr/bin/cliSipie marthastewartlivingradio</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Sirius Stars</text>
+ <action>EXEC /usr/bin/cliSipie siriusstars</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>OutQ Gay Radio</text>
+ <action>EXEC /usr/bin/cliSipie siriusoutq</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Patriot</text>
+ <action>EXEC /usr/bin/cliSipie siriuspatriot</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Left</text>
+ <action>EXEC /usr/bin/cliSipie siriusleft</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>CNN</text>
+ <action>EXEC /usr/bin/cliSipie cnn</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>wrn</text>
+ <action>EXEC /usr/bin/cliSipie wrn</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Blue Collar Comedy</text>
+ <action>EXEC /usr/bin/cliSipie bluecollarcomedy</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Raw Dog Comedy</text>
+ <action>EXEC /usr/bin/cliSipie rawdog</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Laugh Break Comedy</text>
+ <action>EXEC /usr/bin/cliSipie laughbreak</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>thefoxxhole</text>
+ <action>EXEC /usr/bin/cliSipie thefoxxhole</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>lime</text>
+ <action>EXEC /usr/bin/cliSipie lime</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Kids Stuff</text>
+ <action>EXEC /usr/bin/cliSipie kidsstuff</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Catholic Channel</text>
+ <action>EXEC /usr/bin/cliSipie thecatholicchannel</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>EWTN</text>
+ <action>EXEC /usr/bin/cliSipie ewtnglobal</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>christiantalk</text>
+ <action>EXEC /usr/bin/cliSipie christiantalk</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Sirius NFL Radio</text>
+ <action>EXEC /usr/bin/cliSipie siriusnflradio</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Maxim Radio</text>
+ <action>EXEC /usr/bin/cliSipie maximradio</action>
+ </button>
+ <button>
+ <type>MUSIC</type>
+ <text>Cosmo Radio</text>
+ <action>EXEC /usr/bin/cliSipie cosmopolitanradio</action>
+ </button>
+ <button>
+ <type>TV_DELETE</type>
+ <text>Stop Listening</text>
+ <action>EXEC /usr/bin/sipie_kill</action>
+ </button>
+
+</mythmenu>
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/update.xml b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/update.xml
new file mode 100644
index 0000000..5b28833
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/update.xml
@@ -0,0 +1,20 @@
+<mythmenu name="LinHES">
+
+ <button>
+ <type>UPGRADE</type>
+ <text>Check for updates?</text>
+ <action>NONE</action>
+ </button>
+
+ <button>
+ <type>UPGRADE</type>
+ <text>Yes</text>
+ <action>EXEC sudo /usr/LH/bin/linhes_update.sh</action>
+ </button>
+
+ <button>
+ <type>UPGRADE</type>
+ <text>No</text>
+ <action>UPMENU</action>
+ </button>
+</mythmenu>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/update2.xml b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/update2.xml
new file mode 100644
index 0000000..2ab82ea
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/update2.xml
@@ -0,0 +1,26 @@
+<mythmenu name="LinHES">
+
+ <button>
+ <type>UPGRADE</type>
+ <text>Perform updates?</text>
+ <action>NONE</action>
+ </button>
+
+ <button>
+ <type>UPGRADE</type>
+ <text>Yes</text>
+ <action>EXEC sudo /usr/LH/bin/linhes_update2.sh</action>
+ </button>
+
+ <button>
+ <type>UPGRADE</type>
+ <text>No</text>
+ <action>UPMENU</action>
+ </button>
+
+ <button>
+ <type>UPGRADE</type>
+ <text>View files to be upgraded.</text>
+ <action>EXEC sudo /usr/LH/bin/linhes_update3.sh</action>
+ </button>
+</mythmenu>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/util_menu.xml.patch b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/util_menu.xml.patch
new file mode 100644
index 0000000..3a1072a
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/util_menu.xml.patch
@@ -0,0 +1,16 @@
+--- util_menu.xml.orig 2009-03-23 18:43:18.000000000 +0000
++++ util_menu.xml 2009-03-23 20:16:56.000000000 +0000
+@@ -56,6 +56,13 @@
+ </button>
+
+ <button>
++ <type>VIDEO_SCREENSHOOTER</type>
++ <text>Thumbnail Generator</text>
++ <description>Generate thumbnail images for videos</description>
++ <action>EXEC /usr/LH/bin/shootscreens-mythtv.sh</action>
++ </button>
++
++ <button>
+ <type>SETUP_KEYS</type>
+ <text>Edit Keys</text>
+ <text lang="IT">Modifica Tasti</text>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/xmmenu.xml b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/xmmenu.xml
new file mode 100644
index 0000000..6b26d11
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/menu-xml/xmmenu.xml
@@ -0,0 +1,574 @@
+<!-- Current as of April 25, 2007 -->
+<mythmenu name="XM">
+
+ <button>
+ <type>MUSIC</type>
+ <text>The '40s</text>
+ <action>EXEC /usr/bin/xamp kill 4</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The '50s</text>
+ <action>EXEC /usr/bin/xamp kill 5</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The '60s</text>
+ <action>EXEC /usr/bin/xamp kill 6</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The '70s</text>
+ <action>EXEC /usr/bin/xamp kill 7</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The '80s</text>
+ <action>EXEC /usr/bin/xamp kill 8</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The '90s</text>
+ <action>EXEC /usr/bin/xamp kill 9</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>America</text>
+ <action>EXEC /usr/bin/xamp kill 10</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>X Country</text>
+ <action>EXEC /usr/bin/xamp kill 12</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Willie's Place</text>
+ <action>EXEC /usr/bin/xamp kill 13</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Bluegrass Junction</text>
+ <action>EXEC /usr/bin/xamp kill 14</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Village</text>
+ <action>EXEC /usr/bin/xamp kill 15</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Highway 16</text>
+ <action>EXEC /usr/bin/xamp kill 16</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>US Country</text>
+ <action>EXEC /usr/bin/xamp kill 17</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>20 on 20</text>
+ <action>EXEC /usr/bin/xamp kill 20</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Heart</text>
+ <action>EXEC /usr/bin/xamp kill 23</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Blend</text>
+ <action>EXEC /usr/bin/xamp kill 25</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Flight 26</text>
+ <action>EXEC /usr/bin/xamp kill 26</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Cinemagic</text>
+ <action>EXEC /usr/bin/xamp kill 27</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>On Broadway</text>
+ <action>EXEC /usr/bin/xamp kill 28</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>U-Pop</text>
+ <action>EXEC /usr/bin/xamp kill 29</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>XM Hitlist</text>
+ <action>EXEC /usr/bin/xamp kill 30</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Torch</text>
+ <action>EXEC /usr/bin/xamp kill 31</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Message</text>
+ <action>EXEC /usr/bin/xamp kill 32</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Spirit</text>
+ <action>EXEC /usr/bin/xamp kill 33</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>enLighten</text>
+ <action>EXEC /usr/bin/xamp kill 34</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Deep Tracks</text>
+ <action>EXEC /usr/bin/xamp kill 40</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Boneyard</text>
+ <action>EXEC /usr/bin/xamp kill 41</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>XM Liquid Metal</text>
+ <action>EXEC /usr/bin/xamp kill 42</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>XMU</text>
+ <action>EXEC /usr/bin/xamp kill 43</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Fred</text>
+ <action>EXEC /usr/bin/xamp kill 44</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>XM Cafe</text>
+ <action>EXEC /usr/bin/xamp kill 45</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Top Tracks</text>
+ <action>EXEC /usr/bin/xamp kill 46</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Ethel</text>
+ <action>EXEC /usr/bin/xamp kill 47</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Squizz</text>
+ <action>EXEC /usr/bin/xamp kill 48</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Big Tracks</text>
+ <action>EXEC /usr/bin/xamp kill 49</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Loft</text>
+ <action>EXEC /usr/bin/xamp kill 50</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>XM Music Lab</text>
+ <action>EXEC /usr/bin/xamp kill 51</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Verge</text>
+ <action>EXEC /usr/bin/xamp kill 52</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Fungus</text>
+ <action>EXEC /usr/bin/xamp kill 53</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Lucy</text>
+ <action>EXEC /usr/bin/xamp kill 54</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Soul Street</text>
+ <action>EXEC /usr/bin/xamp kill 60</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Flow</text>
+ <action>EXEC /usr/bin/xamp kill 61</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Suite 62</text>
+ <action>EXEC /usr/bin/xamp kill 62</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Groove</text>
+ <action>EXEC /usr/bin/xamp kill 64</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Rhyme</text>
+ <action>EXEC /usr/bin/xamp kill 65</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>RAW</text>
+ <action>EXEC /usr/bin/xamp kill 66</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The City</text>
+ <action>EXEC /usr/bin/xamp kill 67</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Heat</text>
+ <action>EXEC /usr/bin/xamp kill 68</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Real Jazz</text>
+ <action>EXEC /usr/bin/xamp kill 70</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Watercolors</text>
+ <action>EXEC /usr/bin/xamp kill 71</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Beyond Jazz</text>
+ <action>EXEC /usr/bin/xamp kill 72</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>High Standards</text>
+ <action>EXEC /usr/bin/xamp kill 73</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Bluesville</text>
+ <action>EXEC /usr/bin/xamp kill 74</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Hear Music</text>
+ <action>EXEC /usr/bin/xamp kill 75</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Fine Tuning</text>
+ <action>EXEC /usr/bin/xamp kill 76</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Audio Visions</text>
+ <action>EXEC /usr/bin/xamp kill 77</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Escape</text>
+ <action>EXEC /usr/bin/xamp kill 78</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>On The Rocks</text>
+ <action>EXEC /usr/bin/xamp kill 79</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Move</text>
+ <action>EXEC /usr/bin/xamp kill 80</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>BPM</text>
+ <action>EXEC /usr/bin/xamp kill 81</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The System</text>
+ <action>EXEC /usr/bin/xamp kill 82</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Chrome</text>
+ <action>EXEC /usr/bin/xamp kill 83</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>XM-Chill</text>
+ <action>EXEC /usr/bin/xamp kill 84</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Fuego</text>
+ <action>EXEC /usr/bin/xamp kill 90</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Viva</text>
+ <action>EXEC /usr/bin/xamp kill 91</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Aguila</text>
+ <action>EXEC /usr/bin/xamp kill 92</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Caliente</text>
+ <action>EXEC /usr/bin/xamp kill 94</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Luna</text>
+ <action>EXEC /usr/bin/xamp kill 95</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Air Musique</text>
+ <action>EXEC /usr/bin/xamp kill 100</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Joint</text>
+ <action>EXEC /usr/bin/xamp kill 101</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Sur La Route</text>
+ <action>EXEC /usr/bin/xamp kill 102</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>World Zone</text>
+ <action>EXEC /usr/bin/xamp kill 103</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Ngoma</text>
+ <action>EXEC /usr/bin/xamp kill 104</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>XM Classics</text>
+ <action>EXEC /usr/bin/xamp kill 110</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Vox</text>
+ <action>EXEC /usr/bin/xamp kill 112</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>XM Pops</text>
+ <action>EXEC /usr/bin/xamp kill 113</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>XM Kids</text>
+ <action>EXEC /usr/bin/xamp kill 116</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Bob Edwards Show</text>
+ <action>EXEC /usr/bin/xamp kill 133</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>XM Comedy</text>
+ <action>EXEC /usr/bin/xamp kill 150</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Laugh USA</text>
+ <action>EXEC /usr/bin/xamp kill 151</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Special X</text>
+ <action>EXEC /usr/bin/xamp kill 154</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Agenda</text>
+ <action>EXEC /usr/bin/xamp kill 134</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Oprah and Friends</text>
+ <action>EXEC /usr/bin/xamp kill 156</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>The Virus</text>
+ <action>EXEC /usr/bin/xamp kill 202</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>1 Hit Wonders</text>
+ <action>EXEC /usr/bin/xamp kill 300</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Metalcore</text>
+ <action>EXEC /usr/bin/xamp kill 301</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>New Indie First</text>
+ <action>EXEC /usr/bin/xamp kill 302</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Late Night Mix</text>
+ <action>EXEC /usr/bin/xamp kill 303</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Sessions@AOL</text>
+ <action>EXEC /usr/bin/xamp kill 304</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>Shuffle</text>
+ <action>EXEC /usr/bin/xamp kill 305</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>New Rock First</text>
+ <action>EXEC /usr/bin/xamp kill 306</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>New Country First</text>
+ <action>EXEC /usr/bin/xamp kill 307</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>New Hip Hop First</text>
+ <action>EXEC /usr/bin/xamp kill 308</action>
+ </button>
+
+ <button>
+ <type>MUSIC</type>
+ <text>New Pop First</text>
+ <action>EXEC /usr/bin/xamp kill 309</action>
+ </button>
+
+ <button>
+ <type>TV_DELETE</type>
+ <text>Stop Listening</text>
+ <action>EXEC /usr/bin/xamp kill</action>
+ </button>
+
+</mythmenu>
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/myth.sh b/abs/core-testing/mythtv/stable-0.23/mythtv/myth.sh
new file mode 100755
index 0000000..fb7122c
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/myth.sh
@@ -0,0 +1,4 @@
+export PATH=$PATH:/usr/local/bin
+# set core file size to 0
+ulimit -c 0
+export MALLOC_CHECK_=0 \ No newline at end of file
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/mythbackend b/abs/core-testing/mythtv/stable-0.23/mythtv/mythbackend
new file mode 100755
index 0000000..93773a2
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/mythbackend
@@ -0,0 +1,38 @@
+#!/bin/bash
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+PID=`pidof -o %PPID /usr/bin/mythbackend`
+case "$1" in
+ start)
+ stat_busy "Starting MythTV Backend"
+ [ ! -e /var/run/mysqld.pid ] && echo -n "mysqld not started" && stat_fail && exit
+ [ -z "$PID" ] && /usr/bin/mythbackend -d -l /var/log/mythbackend.log -v important
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ echo $PID > /var/run/mythbackend.pid
+ add_daemon mythbackend
+ stat_done
+ fi
+ ;;
+ stop)
+ stat_busy "Stopping MythTV Backend"
+ [ ! -z "$PID" ] && kill $PID &>/dev/null
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ rm_daemon mythbackend
+ stat_done
+ fi
+ ;;
+ restart)
+ $0 stop
+ sleep 1s
+ $0 start
+ ;;
+ *)
+ echo "usage: $0 {start|stop|restart}"
+esac
+exit 0
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/mythbackend.lr b/abs/core-testing/mythtv/stable-0.23/mythtv/mythbackend.lr
new file mode 100644
index 0000000..4f218bc
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/mythbackend.lr
@@ -0,0 +1,9 @@
+/var/log/mythtv/mythbackend.log {
+ copytruncate
+ daily
+ size 10M
+ missingok
+ rotate 7
+ compress
+ notifempty
+}
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/mythbackend.sh b/abs/core-testing/mythtv/stable-0.23/mythtv/mythbackend.sh
new file mode 100755
index 0000000..e7a7b70
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/mythbackend.sh
@@ -0,0 +1,117 @@
+#!/bin/bash
+#
+# /etc/rc.d/init.d/mythbackend
+#
+# Starts the mythbackend as a daemon
+#
+# chkconfig: 345 90 10
+# description: Starts the mythbackend process as a daemon after the XWindows \
+# system is started, in runlevel 5. This allows scheduled \
+# recordings to occur without manual intervention.
+# processname: mythbackend
+
+# Copyright (c) by Michael Thomson <linux at m-thomson dot net>
+# With thanks to Stu Tomlinson <stu at nosnilmot dot com>
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 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, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+# Default values to use if none are supplied in the config file.
+# User who should start the mythbackend processes
+MBE_USER="root"
+# Directory holding the mythbackend binary
+MBE_LOCATION="/usr/local/bin/"
+# Name of mythbackend binary
+MBE_PROG="mythbackend"
+# Full path to mythbackend log file
+MBE_LOGFILE="/var/log/mythtv/mythbackend.log"
+
+# Source function library.
+. /etc/init.d/functions
+
+# Source config file if available
+if [ -f "/etc/sysconfig/mythbackend" ]; then
+ . /etc/sysconfig/mythbackend
+fi
+
+test -x ${MBE_LOCATION}${MBE_PROG} || exit 0
+
+RETVAL=0
+
+#
+# See how we were called.
+#
+
+start() {
+ # Check if mythbackend is already running
+ if [ ! -f /var/lock/subsys/${MBE_PROG} ]; then
+ echo -n "Starting ${MBE_PROG}: "
+ # /usr/local/bin/mythbackend -d -l /some/log/file
+ #daemon --user ${MBE_USER} ${MBE_LOCATION}${MBE_PROG} -d -l ${MBE_LOGFILE}
+ ${MBE_LOCATION}${MBE_PROG} -d -l ${MBE_LOGFILE}
+ RETVAL=$?
+ [ $RETVAL -eq 0 ] && touch /var/lock/subsys/${MBE_PROG}
+ echo
+ fi
+ return $RETVAL
+}
+
+stop() {
+ echo -n "Stopping ${MBE_PROG}: "
+ killproc ${MBE_LOCATION}${MBE_PROG}
+ RETVAL=$?
+ [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/${MBE_PROG}
+ echo
+ return $RETVAL
+}
+
+
+restart() {
+ stop
+ start
+}
+
+reload() {
+ restart
+}
+
+status_at() {
+ status ${MBE_LOCATION}${MBE_PROG}
+}
+
+case "$1" in
+start)
+ start
+ ;;
+stop)
+ stop
+ ;;
+reload|restart)
+ restart
+ ;;
+condrestart)
+ if [ -f /var/lock/subsys/${MBE_PROG} ]; then
+ restart
+ fi
+ ;;
+status)
+ status_at
+ ;;
+*)
+ echo "Usage: $0 {start|stop|restart|condrestart|status}"
+ exit 1
+esac
+
+exit $?
+exit $RETVAL
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/mythfrontend.lr b/abs/core-testing/mythtv/stable-0.23/mythtv/mythfrontend.lr
new file mode 100644
index 0000000..1580533
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/mythfrontend.lr
@@ -0,0 +1,9 @@
+/var/log/mythtv/mythfrontend.log {
+ copytruncate
+ daily
+ size 10M
+ missingok
+ rotate 7
+ compress
+ notifempty
+}
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/mythtv.install b/abs/core-testing/mythtv/stable-0.23/mythtv/mythtv.install
new file mode 100755
index 0000000..0524f86
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/mythtv.install
@@ -0,0 +1,47 @@
+# arg 1: the new package version
+post_install() {
+ if [ ! -d /var/log/mythtv ]
+ then
+ mkdir -p /var/log/mythv
+ chown -R mythtv /var/log/mythtv
+ echo "---" > /var/log/mythtv/mythbackend.log
+ chown mythtv /var/log/mythtv/mythbackend.log
+ fi
+ ln -s /usr/share/mythtv/themes/defaultmenu/is.xml /usr/share/mythtv/is.xml
+}
+
+pre_upgrade() {
+ if [ ! -L /usr/share/mythtv/is.xml ]
+ then
+ mv /usr/share/mythtv/is.xml /usr/share/mythtv/is.xml.pre
+ else
+ mv /usr/share/mythtv/themes/defaultmenu/is.xml /usr/share/mythtv/themes/defaultmenu/is.xml.pre
+ fi
+}
+
+post_upgrade() {
+ if [ ! -d /var/log/mythtv ]
+ then
+ mkdir -p /var/log/mythv
+ chown -R mythtv /var/log/mythtv
+ fi
+ if [ -e /usr/share/mythtv/is.xml.pre ]
+ then
+ rm -fr /usr/share/mythtv/themes/defaultmenu/is.xml
+ mv /usr/share/mythtv/is.xml.pre /usr/share/mythtv/themes/defaultmenu/is.xml
+ ln -s /usr/share/mythtv/themes/defaultmenu/is.xml /usr/share/mythtv/is.xml
+ else
+ mv /usr/share/mythtv/themes/defaultmenu/is.xml.pre /usr/share/mythtv/themes/defaultmenu/is.xml
+ fi
+}
+
+
+# arg 1: the old package version
+post_remove() {
+ /bin/true
+
+}
+
+op=$1
+shift
+$op $*
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/pretty b/abs/core-testing/mythtv/stable-0.23/mythtv/pretty
new file mode 100755
index 0000000..7e0ab21
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/pretty
@@ -0,0 +1,9 @@
+#!/bin/bash
+if [ -f /usr/share/mythtv/contrib/user_jobs/mythlink.pl ]
+then
+ su - mythtv -c "perl /usr/share/mythtv/contrib/user_jobs/mythlink.pl --link /myth/pretty"
+elif [ -f /usr/share/mythtv/contrib/user_jobs/mythrename.pl ]
+then
+ su - mythtv -c "perl /usr/share/mythtv/contrib/user_jobs/mythrename.pl --link /myth/pretty"
+fi
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythtv/smolt_jump.patch b/abs/core-testing/mythtv/stable-0.23/mythtv/smolt_jump.patch
new file mode 100644
index 0000000..0fc452a
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythtv/smolt_jump.patch
@@ -0,0 +1,30 @@
+Index: programs/mythfrontend/networkcontrol.cpp
+===================================================================
+--- programs/mythfrontend/networkcontrol.cpp (revision 19291)
++++ programs/mythfrontend/networkcontrol.cpp (working copy)
+@@ -83,6 +83,7 @@
+ jumpMap["zoneminderliveview"] = "ZoneMinder Live View";
+ jumpMap["zoneminderevents"] = "ZoneMinder Events";
+ jumpMap["snapshot"] = "ScreenShot";
++ jumpMap["mythsmolt"] = "MythSmolt";
+
+ // These jump point names match the (lowercased) locations from gContext
+ jumpMap["channelrecpriority"] = "Channel Recording Priorities";
+@@ -191,7 +192,7 @@
+ pthread_create(&command_thread, NULL, CommandThread, this);
+
+ gContext->addListener(this);
+-
++
+ connect(this, SIGNAL(newConnection()), this, SLOT(newConnection()));
+ }
+
+@@ -307,7 +308,7 @@
+ cs = new QTextStream(s);
+ cs->setCodec("UTF-8");
+ }
+-
++
+ if (client)
+ {
+ closedOldConn = true;
diff --git a/abs/core-testing/mythtv/stable-0.23/mythvideo/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythvideo/PKGBUILD
new file mode 100644
index 0000000..b4a6fe1
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythvideo/PKGBUILD
@@ -0,0 +1,47 @@
+pkgname=mythvideo
+pkgver=0.23
+pkgrel=2
+pkgdesc="Video playback and browsing plugin for MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23' 'mplayer' 'perlxml' 'perl-libwww' 'perl-uri' 'perl-xml-simple' 'ffmpeg')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mythvideo || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythweather/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythweather/PKGBUILD
new file mode 100644
index 0000000..cae0c67
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythweather/PKGBUILD
@@ -0,0 +1,47 @@
+pkgname=mythweather
+pkgver=0.23
+pkgrel=2
+pkgdesc="Weather checking plugin for MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23' 'wget')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mythweather || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/stable-0.23/mythweb/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythweb/PKGBUILD
new file mode 100644
index 0000000..cccdd1e
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythweb/PKGBUILD
@@ -0,0 +1,46 @@
+pkgname=mythweb
+pkgver=0.23
+pkgrel=1
+pkgdesc="Web interface for MythTV's backend"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23' 'lighttpd' 'php' 'local-website')
+groups=('mythtv-extras')
+install=mythweb.install
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+DOCROOT=/data/srv/httpd/htdocs/mythweb
+
+build() {
+
+ cd $startdir/src/$_svnmod
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ mkdir -p $startdir/pkg/$DOCROOT/{image_cache,php_sessions}
+
+# cp -r $startdir/src/mythplugins/mythweb/* $startdir/pkg/$DOCROOT
+# cp $startdir/src/mythplugins-$pkgver/mythweb/data/.htaccess $startdir/pkg/$DOCROOT
+ rsync -arp --exclude .svn --delete-excluded $startdir/src/mythplugins/mythweb/* $startdir/pkg/$DOCROOT
+ rm $startdir/pkg/$DOCROOT/README
+ chown -R http:users $startdir/pkg/$DOCROOT
+ chmod g+rw $startdir/pkg/$DOCROOT/{image_cache,php_sessions,data}
+
+}
diff --git a/abs/core-testing/mythtv/stable-0.23/mythweb/mythweb.install b/abs/core-testing/mythtv/stable-0.23/mythweb/mythweb.install
new file mode 100644
index 0000000..470cbd1
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythweb/mythweb.install
@@ -0,0 +1,10 @@
+post_install() {
+ echo "You must create a symlink from /home/httpd/html/mythweb/video_dir"
+ echo "to your MythTV recordings directory. Don't forget to change the"
+ echo "permissions so that the webserver can read those files and create"
+ echo "thumbnails."
+}
+
+op=$1
+shift
+$op $*
diff --git a/abs/core-testing/mythtv/stable-0.23/mythzoneminder/PKGBUILD b/abs/core-testing/mythtv/stable-0.23/mythzoneminder/PKGBUILD
new file mode 100644
index 0000000..7512e01
--- /dev/null
+++ b/abs/core-testing/mythtv/stable-0.23/mythzoneminder/PKGBUILD
@@ -0,0 +1,47 @@
+pkgname=mythzoneminder
+pkgver=0.23
+pkgrel=1
+pkgdesc="Integrates ZoneMinder into MythTV"
+url="http://www.mythtv.org"
+license="GPL"
+arch=('i686' 'x86_64')
+
+depends=('mythtv>=0.23' 'zoneminder=1.23.3')
+groups=('mythtv-extras')
+
+patches=()
+source=('ftp://ftp.knoppmyth.net/R6/sources/mythplugins-0.23-fixes.tar.bz2' `echo${patches[@]:0}`)
+
+md5sums=('590c6e72c72e10d4c7edf72d7fb6b940')
+
+build() {
+
+ cd $startdir/src/mythplugins
+ svn update
+
+ echo "--------------------------applying patches----------------------------------------------------"
+ for i in `echo ${patches[@]:0} `
+ do
+ echo applying $i
+ echo "-----------------------------"
+ patch -Np0 -i ${startdir}/src/$i || return 1
+ done
+ echo "--------------------------done applying patches-----------------------------------------------"
+
+ [ "$CARCH" = "i686" ] && ARCH="i686"
+ [ "$CARCH" = "x86_64" ] && ARCH="x86-64"
+
+ # clean up
+ make distclean
+
+ # configure
+ ./configure --prefix=/usr --cpu=${ARCH} --disable-all --enable-opengl \
+ --enable-mythzoneminder || return 1
+
+ # build and install
+ . /etc/profile
+ make || return 1
+ make INSTALL_ROOT=$startdir/pkg install || return 1
+
+}
+
diff --git a/abs/core-testing/mythtv/trunk/mythtv/pretty b/abs/core-testing/mythtv/trunk/mythtv/pretty
index 7e1dcac..7e0ab21 100755
--- a/abs/core-testing/mythtv/trunk/mythtv/pretty
+++ b/abs/core-testing/mythtv/trunk/mythtv/pretty
@@ -1,5 +1,4 @@
#!/bin/bash
-#!/bin/bash
if [ -f /usr/share/mythtv/contrib/user_jobs/mythlink.pl ]
then
su - mythtv -c "perl /usr/share/mythtv/contrib/user_jobs/mythlink.pl --link /myth/pretty"
diff --git a/abs/core-testing/nvidia-96xx-utils/PKGBUILD b/abs/core-testing/nvidia-96xx-utils/PKGBUILD
index 749dc08..7442a21 100644
--- a/abs/core-testing/nvidia-96xx-utils/PKGBUILD
+++ b/abs/core-testing/nvidia-96xx-utils/PKGBUILD
@@ -1,65 +1,63 @@
-# $Id: PKGBUILD 18827 2008-11-09 14:01:28Z jgc $
-# Maintainer: Tobias Powalowski <tpowa@archlinux.org>
-# Contributor: James Rayner <iphitus@gmail.com>
+# $Id: PKGBUILD 69361 2010-02-20 11:24:49Z tpowa $
+# Maintainer: Thomas Baechler <thomas@archlinux.org>
pkgname=nvidia-96xx-utils
-pkgver=96.43.09
+pkgver=96.43.16
pkgrel=1
-pkgdesc="NVIDIA legacy drivers utilities and libraries, 96xx branch."
-arch=(i686 x86_64)
-license=('custom')
+pkgdesc="NVIDIA drivers utilities and libraries, 96xx branch."
+arch=('i686' 'x86_64')
[ "$CARCH" = "i686" ] && ARCH=x86
[ "$CARCH" = "x86_64" ] && ARCH=x86_64
url="http://www.nvidia.com/"
depends=('xorg-server')
-conflicts=('libgl' 'libgl-dri' 'ati-fglrx-utils' 'nvidia-utils' \
- 'nvidia-71xx-utils' 'nvidia-legacy-utils')
+optdepends=('gtk2: nvidia-settings' 'pkgconfig: nvidia-xconfig')
+conflicts=('libgl')
provides=('libgl')
-install=nvidia-96xx.install
-source=(http://download.nvidia.com/XFree86/Linux-${ARCH}/${pkgver}/NVIDIA-Linux-${ARCH}-${pkgver}-pkg0.run \
- supported-cards.txt)
-md5sums=('758c739114b81ea2cb7da7c22ab80a7e'
- '6363d7e494d33729609540088e33e73f')
-[ "$CARCH" = "x86_64" ] && md5sums=('c03bd2469292d91dde8767af1418c4e1'
- '6363d7e494d33729609540088e33e73f')
-options=(docs !strip)
+license=('custom')
+install=nvidia.install
+options=(!strip)
+source=("http://download.nvidia.com/XFree86/Linux-${ARCH}/${pkgver}/NVIDIA-Linux-${ARCH}-${pkgver}-pkg0.run")
+md5sums=('7479b25c747e29af95b9ccf06f43fbf9')
+[ "$CARCH" = "x86_64" ] && md5sums=('73e226d4ee0996b6df4bdf44cc1fc6f5')
+
+build() {
+ cd $srcdir
+ sh NVIDIA-Linux-${ARCH}-${pkgver}-pkg0.run --extract-only
+ cd NVIDIA-Linux-${ARCH}-${pkgver}-pkg0/usr/
+
+ mkdir -p $pkgdir/usr/{lib,bin,share/applications,share/pixmaps,share/man/man1}
+ mkdir -p $pkgdir/usr/lib/xorg/modules/{extensions,drivers}
+ mkdir -p $pkgdir/usr/share/licenses/nvidia-96xx/
-build()
-{
- # override nvida install routine and do it the long way.
- cd $startdir/src/
- sh NVIDIA-Linux-${ARCH}-${pkgver}-pkg0.run --extract-only
- cd NVIDIA-Linux-${ARCH}-${pkgver}-pkg0/usr/
+ install lib/{libGLcore,libGL,libnvidia-cfg,tls/libnvidia-tls}.so.${pkgver} \
+ $pkgdir/usr/lib/ || return 1
+ install -m644 share/man/man1/* $pkgdir/usr/share/man/man1/ || return 1
+ rm $pkgdir/usr/share/man/man1/nvidia-installer.1.gz || return 1
+ install X11R6/lib/libXv* $pkgdir/usr/lib/ || return 1
+ install -m644 share/applications/nvidia-settings.desktop $pkgdir/usr/share/applications/ || return 1
+ # fix nvidia .desktop file
+ sed -e 's:__UTILS_PATH__:/usr/bin:' -e 's:__PIXMAP_PATH__:/usr/share/pixmaps:' -i $pkgdir/usr/share/applications/nvidia-settings.desktop
+ install -m644 share/pixmaps/nvidia-settings.png $pkgdir/usr/share/pixmaps/ || return 1
+ install X11R6/lib/modules/drivers/nvidia_drv.so $pkgdir/usr/lib/xorg/modules/drivers || return 1
+ install X11R6/lib/modules/extensions/libglx.so.$pkgver $pkgdir/usr/lib/xorg/modules/extensions || return 1
+ install -m755 bin/nvidia-{settings,xconfig,bug-report.sh} $pkgdir/usr/bin/ || return 1
+ cd $pkgdir/usr/lib/
+ ln -s libGL.so.$pkgver libGL.so || return 1
+ ln -s libGL.so.$pkgver libGL.so.1 || return 1
+ ln -s libGLcore.so.$pkgver libGLcore.so.1 || return 1
+ ln -s libnvidia-cfg.so.$pkgver libnvidia-cfg.so.1 || return 1
+ ln -s libnvidia-tls.so.$pkgver libnvidia-tls.so.1 || return 1
+ ln -s libXvMCNVIDIA.so.$pkgver libXvMCNVIDIA_dynamic.so.1 || return 1
- mkdir -p $startdir/pkg/usr/{lib,bin,share/applications,share/pixmaps,share/man/man1}
- mkdir -p $startdir/pkg/usr/lib/xorg/modules/{extensions,drivers}
- mkdir -p $startdir/pkg/usr/share/licenses/nvidia-96xx/
-
- install lib/{libGLcore.so.${pkgver},libGL.so.${pkgver},libnvidia-cfg.so.${pkgver},tls/libnvidia-tls.so.${pkgver}} \
- $startdir/pkg/usr/lib/ || return 1
- install -m644 share/man/man1/* $startdir/pkg/usr/share/man/man1/ || return 1
- rm $startdir/pkg/usr/share/man/man1/nvidia-installer.1.gz || return 1
- install X11R6/lib/libXv* $startdir/pkg/usr/lib/ || return 1
- install -m644 share/applications/nvidia-settings.desktop $startdir/pkg/usr/share/applications/ || return 1
- # fix nvidia .desktop file
- sed -e 's:__UTILS_PATH__:/usr/bin:' -e 's:__PIXMAP_PATH__:/usr/share/pixmaps:' -i $startdir/pkg/usr/share/applications/nvidia-settings.desktop
- install -m644 share/pixmaps/nvidia-settings.png $startdir/pkg/usr/share/pixmaps/ || return 1
- install X11R6/lib/modules/drivers/nvidia_drv.so $startdir/pkg/usr/lib/xorg/modules/drivers || return 1
- install X11R6/lib/modules/extensions/libglx.so.$pkgver $startdir/pkg/usr/lib/xorg/modules/extensions || return 1
- install -m755 bin/nvidia-{settings,xconfig,bug-report.sh} $startdir/pkg/usr/bin/ || return 1
- cd $startdir/pkg/usr/lib/
- ln -s /usr/lib/libGL.so.$pkgver libGL.so || return 1
- ln -s /usr/lib/libGL.so.$pkgver libGL.so.1 || return 1
- ln -s /usr/lib/libGLcore.so.$pkgver libGLcore.so.1 || return 1
- ln -s /usr/lib/libnvidia-cfg.so.$pkgver libnvidia-cfg.so.1 || return 1
- ln -s /usr/lib/libnvidia-tls.so.$pkgver libnvidia-tls.so.1 || return 1
- cd $startdir/pkg/usr/lib/xorg/modules/extensions
- ln -s /usr/lib/xorg/modules/extensions/libglx.so.$pkgver libglx.so || return 1
+ cd $pkgdir/usr/lib/xorg/modules/extensions
+ ln -s libglx.so.$pkgver libglx.so || return 1
- install -m644 $startdir/src/NVIDIA-Linux-${ARCH}-${pkgver}-pkg0/LICENSE $startdir/pkg/usr/share/licenses/nvidia-96xx/ || return 1
- install -D -m644 $startdir/src/NVIDIA-Linux-${ARCH}-${pkgver}-pkg0/usr/share/doc/README.txt $startdir/pkg/usr/share/doc/nvidia/README || return 1
- install -D -m644 $startdir/src/supported-cards.txt $startdir/pkg/usr/share/doc/nvidia/supported-cards.txt || return 1
-
- find $startdir/pkg/usr -type d -exec chmod 755 {} \;
- # phew :)
+ install -m644 $srcdir/NVIDIA-Linux-${ARCH}-${pkgver}-pkg0/LICENSE $pkgdir/usr/share/licenses/nvidia-96xx/ || return 1
+ ln -s nvidia-96xx $startdir/pkg/usr/share/licenses/nvidia-96xx-utils || return 1
+
+ install -D -m644 $srcdir/NVIDIA-Linux-${ARCH}-${pkgver}-pkg0/usr/share/doc/README.txt $pkgdir/usr/share/doc/nvidia-96xx/README || return 1
+
+ find $pkgdir/usr -type d -exec chmod 755 {} \;
}
+
+
diff --git a/abs/core-testing/nvidia-96xx-utils/nvidia-96xx.install b/abs/core-testing/nvidia-96xx-utils/nvidia-96xx.install
deleted file mode 100644
index bb1fff2..0000000
--- a/abs/core-testing/nvidia-96xx-utils/nvidia-96xx.install
+++ /dev/null
@@ -1,22 +0,0 @@
-# arg 1: the new package version
-post_install() {
-
- echo -------------------------------
- echo By using this package you accept the NVIDIA license,
- echo which has been installed in /usr/share/licenses/nvidia/LICENSE
- echo If you do not accept this license, you must remove the package immediately.
- echo Dont forget to update your /etc/X11/xorg.conf
- echo In order to use nvidia-settings, you need to install 'gtk2' package.
- echo -------------------------------
-
-}
-
-# arg 1: the new package version
-# arg 2: the old package version
-post_upgrade() {
- post_install $1
-}
-
-op=$1
-shift
-$op $*
diff --git a/abs/core-testing/nvidia-96xx-utils/nvidia.install b/abs/core-testing/nvidia-96xx-utils/nvidia.install
new file mode 100644
index 0000000..0a878a7
--- /dev/null
+++ b/abs/core-testing/nvidia-96xx-utils/nvidia.install
@@ -0,0 +1,6 @@
+post_install() {
+ echo By using this package you accept the NVIDIA license,
+ echo which has been installed in /usr/share/licenses/nvidia/LICENSE
+ echo If you do not accept this license, you must remove the package immediately.
+ echo Dont forget to update your /etc/X11/xorg.conf
+}
diff --git a/abs/core-testing/nvidia-96xx/NVIDIA_173.14.12_2.6.27.patch b/abs/core-testing/nvidia-96xx/NVIDIA_173.14.12_2.6.27.patch
deleted file mode 100644
index 1ba936b..0000000
--- a/abs/core-testing/nvidia-96xx/NVIDIA_173.14.12_2.6.27.patch
+++ /dev/null
@@ -1,87 +0,0 @@
-diff -Nru NVIDIA-Linux-x86-173.14.12-pkg0.orig/usr/src/nv/nv.c NVIDIA-Linux-x86-173.14.12-pkg0/usr/src/nv/nv.c
---- usr/src/nv/nv.c 2008-07-18 03:42:50.000000000 +0200
-+++ NVIDIA-Linux-x86-173.14.12-pkg0/usr/src/nv/nv.c 2008-08-12 00:35:45.000000000 +0200
-@@ -1296,14 +1296,22 @@
- if (get_cpu() == cpu)
- __nv_setup_pat_entries(NULL);
- else
-+ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27)
-+ smp_call_function(__nv_setup_pat_entries, hcpu, 1);
-+ #else
- smp_call_function(__nv_setup_pat_entries, hcpu, 1, 1);
-+ #endif
- put_cpu();
- break;
- case CPU_DOWN_PREPARE:
- if (get_cpu() == cpu)
- __nv_restore_pat_entries(NULL);
- else
-+ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27)
-+ smp_call_function(__nv_restore_pat_entries, hcpu, 1);
-+ #else
- smp_call_function(__nv_restore_pat_entries, hcpu, 1, 1);
-+ #endif
- put_cpu();
- break;
- }
-diff -Nru NVIDIA-Linux-x86-173.14.12-pkg0.orig/usr/src/nv/nv-linux.h NVIDIA-Linux-x86-173.14.12-pkg0/usr/src/nv/nv-linux.h
---- usr/src/nv/nv-linux.h 2008-07-18 03:42:51.000000000 +0200
-+++ NVIDIA-Linux-x86-173.14.12-pkg0/usr/src/nv/nv-linux.h 2008-08-12 00:44:27.000000000 +0200
-@@ -104,7 +104,10 @@
- #endif
-
- #include <linux/spinlock.h>
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27)
-+#else
- #include <asm/semaphore.h>
-+#endif
- #include <linux/completion.h>
- #include <linux/highmem.h>
-
-@@ -665,13 +668,21 @@
- #if defined(preempt_disable)
- preempt_disable();
- #endif
-+ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27)
-+ ret = smp_call_function(func, info, 1);
-+ #else
- ret = smp_call_function(func, info, 1, 1);
-+ #endif
- func(info);
- #if defined(preempt_enable)
- preempt_enable();
- #endif
- #else
-+ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27)
-+ ret = on_each_cpu(func, info, 1);
-+ #else
- ret = on_each_cpu(func, info, 1, 1);
-+ #endif
- #endif
- return ret;
- }
-diff -Nru NVIDIA-Linux-x86-173.14.12-pkg0.orig/usr/src/nv/os-interface.c NVIDIA-Linux-x86-173.14.12-pkg0/usr/src/nv/os-interface.c
---- usr/src/nv/os-interface.c 2008-07-18 03:42:50.000000000 +0200
-+++ NVIDIA-Linux-x86-173.14.12-pkg0/usr/src/nv/os-interface.c 2008-08-12 00:48:07.000000000 +0200
-@@ -48,7 +48,11 @@
- #endif
- local_bh_disable();
- atomic_set(&os_smp_barrier, 1);
-+ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27)
-+ ret = smp_call_function(ipi_handler, NULL, 0);
-+ #else
- ret = smp_call_function(ipi_handler, NULL, 1, 0);
-+ #endif
- #endif
- return (ret == 0) ? RM_OK : RM_ERROR;
- }
-@@ -704,7 +708,9 @@
- U032 sig
- )
- {
-+ #if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 26)
- return kill_proc(pid, sig, 1) ? RM_ERR_OPERATING_SYSTEM : RM_OK;
-+ #endif
- }
-
- /*******************************************************************************/
diff --git a/abs/core-testing/nvidia-96xx/PKGBUILD b/abs/core-testing/nvidia-96xx/PKGBUILD
index ee165d2..df89e5f 100644
--- a/abs/core-testing/nvidia-96xx/PKGBUILD
+++ b/abs/core-testing/nvidia-96xx/PKGBUILD
@@ -1,38 +1,35 @@
-# $Id: PKGBUILD 22496 2008-12-26 22:51:15Z tpowa $
-# Maintainer : Tobias Powalowski <tpowa@archlinux.org>
+# $Id: PKGBUILD 69360 2010-02-20 11:24:15Z tpowa $
+# Maintainer : Thomas Baechler <thomas@archlinux.org>
pkgname=nvidia-96xx
-pkgver=96.43.09
+pkgver=96.43.16
_kernver='2.6.28-LinHES'
-pkgrel=5
-pkgdesc="NVIDIA legacy drivers for kernel26, 96xx branch"
-arch=(i686 x86_64)
-license=('custom:NVIDIA')
+
+pkgrel=1
+pkgdesc="NVIDIA drivers for kernel26, 96xx branch."
+arch=('i686' 'x86_64')
[ "$CARCH" = "i686" ] && ARCH=x86
[ "$CARCH" = "x86_64" ] && ARCH=x86_64
url="http://www.nvidia.com/"
-depends=('kernel26>=2.6.28' 'kernel26<2.6.29' 'nvidia-96xx-utils' 'vdpinfo-96xx')
-conflicts=('nvidia' 'nvidia-71xx' 'nvidia-legacy')
-install=nvidia-96xx.install
+depends=('kernel26>=2.6.28' 'kernel26<2.6.29' 'nvidia-96xx-utils')
+makedepends=('kernel-headers>=2.6.28' 'kernel-headers<2.6.29')
+conflicts=('nvidia' 'nvidia-173xx')
license=('custom')
-source=(http://download.nvidia.com/XFree86/Linux-$ARCH/${pkgver}/NVIDIA-Linux-$ARCH-${pkgver}-pkg0.run)
-md5sums=('758c739114b81ea2cb7da7c22ab80a7e')
-[ "$CARCH" = "x86_64" ] && md5sums=('00a4cd93adc956f8cf173ab1036a5bf7')
+install=nvidia.install
+source=("http://download.nvidia.com/XFree86/Linux-$ARCH/${pkgver}/NVIDIA-Linux-$ARCH-${pkgver}-pkg0.run")
+md5sums=('7479b25c747e29af95b9ccf06f43fbf9')
+[ "$CARCH" = "x86_64" ] && md5sums=('73e226d4ee0996b6df4bdf44cc1fc6f5')
+
+build() {
+ cd $srcdir
+ sh NVIDIA-Linux-$ARCH-${pkgver}-pkg0.run --extract-only
+ cd NVIDIA-Linux-$ARCH-${pkgver}-pkg0
+ cd usr/src/nv/
+ ln -s Makefile.kbuild Makefile
+ make SYSSRC=/lib/modules/${_kernver}/build module || return 1
-build()
-{
- # Extract
- cd $startdir/src/
- sh NVIDIA-Linux-$ARCH-${pkgver}-pkg0.run --extract-only
- cd NVIDIA-Linux-$ARCH-${pkgver}-pkg0
-
- cd usr/src/nv/
- ln -s Makefile.kbuild Makefile
- make SYSSRC=/lib/modules/$_kernver/build module || return 1
-
- # install kernel module
- mkdir -p $startdir/pkg/lib/modules/${_kernver}/kernel/drivers/video/
- install -m644 nvidia.ko $startdir/pkg/lib/modules/${_kernver}/kernel/drivers/video/ || return 1
+ mkdir -p $pkgdir/lib/modules/${_kernver}/kernel/drivers/video/
+ install -m644 nvidia.ko $pkgdir/lib/modules/${_kernver}/kernel/drivers/video/
- sed -i -e "s/KERNEL_VERSION='.*'/KERNEL_VERSION='${_kernver}'/" $startdir/*.install
+ sed -i -e "s/KERNEL_VERSION='.*'/KERNEL_VERSION='${_kernver}'/" $startdir/nvidia.install
}
diff --git a/abs/core-testing/nvidia-96xx/nvidia-96.43.11-2.6.30.patch b/abs/core-testing/nvidia-96xx/nvidia-96.43.11-2.6.30.patch
new file mode 100644
index 0000000..44d44fd
--- /dev/null
+++ b/abs/core-testing/nvidia-96xx/nvidia-96.43.11-2.6.30.patch
@@ -0,0 +1,103 @@
+--- usr/src/nv/nv.c.orig
++++ usr/src/nv/nv.c
+@@ -15,6 +15,7 @@
+ #include "nv_compiler.h"
+ #include "os-agp.h"
+ #include "nv-vm.h"
++#include <linux/version.h>
+
+ #ifdef MODULE_ALIAS_CHARDEV_MAJOR
+ MODULE_ALIAS_CHARDEV_MAJOR(NV_MAJOR_DEVICE_NUMBER);
+@@ -499,10 +500,12 @@
+ * Set the module owner to ensure that the reference
+ * count reflects accesses to the proc files.
+ */
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30)
+ proc_nvidia->owner = THIS_MODULE;
+ proc_nvidia_cards->owner = THIS_MODULE;
+ proc_nvidia_warnings->owner = THIS_MODULE;
+
++#endif
+ for (j = 0; j < num_nv_devices; j++)
+ {
+ nvl = &nv_linux_devices[j];
+@@ -521,7 +524,9 @@
+
+ entry->data = nv;
+ entry->read_proc = nv_kern_read_cardinfo;
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30)
+ entry->owner = THIS_MODULE;
++#endif
+
+ if (nvos_find_agp_capability(dev)) {
+ /*
+@@ -534,7 +539,9 @@
+ goto failed;
+ }
+
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30)
+ entry->owner = THIS_MODULE;
++#endif
+ proc_nvidia_agp = entry;
+
+ entry = create_proc_entry("status", flags, proc_nvidia_agp);
+@@ -545,7 +552,9 @@
+
+ entry->data = nv;
+ entry->read_proc = nv_kern_read_status;
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30)
+ entry->owner = THIS_MODULE;
++#endif
+
+ entry = create_proc_entry("host-bridge", flags, proc_nvidia_agp);
+ if (!entry) {
+@@ -555,8 +564,9 @@
+
+ entry->data = NULL;
+ entry->read_proc = nv_kern_read_agpinfo;
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30)
+ entry->owner = THIS_MODULE;
+-
++#endif
+ entry = create_proc_entry("card", flags, proc_nvidia_agp);
+ if (!entry) {
+ NV_PCI_DEV_PUT(dev);
+@@ -565,7 +575,9 @@
+
+ entry->data = nv;
+ entry->read_proc = nv_kern_read_agpinfo;
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30)
+ entry->owner = THIS_MODULE;
++#endif
+ }
+
+ NV_PCI_DEV_PUT(dev);
+@@ -576,14 +588,18 @@
+ goto failed;
+
+ entry->read_proc = nv_kern_read_version;
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30)
+ entry->owner = THIS_MODULE;
++#endif
+
+ entry = create_proc_entry("registry", flags, proc_nvidia);
+ if (!entry)
+ goto failed;
+
+ entry->read_proc = nv_kern_read_registry;
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30)
+ entry->owner = THIS_MODULE;
++#endif
+
+ return;
+
+@@ -610,7 +626,9 @@
+
+ entry->data = (void *)message;
+ entry->read_proc = nv_kern_read_warning;
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30)
+ entry->owner = THIS_MODULE;
++#endif
+ #endif
+ }
+
diff --git a/abs/core-testing/nvidia-96xx/nvidia-96xx.install b/abs/core-testing/nvidia-96xx/nvidia-96xx.install
deleted file mode 100644
index 23e04af..0000000
--- a/abs/core-testing/nvidia-96xx/nvidia-96xx.install
+++ /dev/null
@@ -1,22 +0,0 @@
-# arg 1: the new package version
-post_install() {
- KERNEL_VERSION='2.6.28-LinHES'
- depmod -v $KERNEL_VERSION > /dev/null 2>&1
-}
-
-# arg 1: the new package version
-# arg 2: the old package version
-post_upgrade() {
- post_install $1
- rmmod nvidia || echo 'In order to use the new nvidia module, exit Xserver and unload it manually.'
-}
-
-# arg 1: the old package version
-post_remove() {
- KERNEL_VERSION='2.6.28-LinHES'
- depmod -v $KERNEL_VERSION > /dev/null 2>&1
-}
-
-op=$1
-shift
-$op $*
diff --git a/abs/core-testing/nvidia-96xx/nvidia.install b/abs/core-testing/nvidia-96xx/nvidia.install
new file mode 100644
index 0000000..ab86ea2
--- /dev/null
+++ b/abs/core-testing/nvidia-96xx/nvidia.install
@@ -0,0 +1,14 @@
+post_install() {
+ KERNEL_VERSION='2.6.28-LinHES'
+ depmod $KERNEL_VERSION
+}
+
+post_upgrade() {
+ post_install
+ rmmod nvidia || echo 'In order to use the new nvidia module, exit Xserver and unload it manually.'
+}
+
+post_remove() {
+ KERNEL_VERSION='2.6.28-LinHES'
+ depmod $KERNEL_VERSION
+}
diff --git a/abs/core-testing/libxml-perl/PKGBUILD b/abs/core-testing/perl_modules/libxml-perl/PKGBUILD
index 5867a11..5867a11 100644
--- a/abs/core-testing/libxml-perl/PKGBUILD
+++ b/abs/core-testing/perl_modules/libxml-perl/PKGBUILD
diff --git a/abs/core-testing/perl-xml-dom/PKGBUILD b/abs/core-testing/perl_modules/perl-xml-dom/PKGBUILD
index ab6e8a5..ab6e8a5 100644
--- a/abs/core-testing/perl-xml-dom/PKGBUILD
+++ b/abs/core-testing/perl_modules/perl-xml-dom/PKGBUILD
diff --git a/abs/core-testing/perlxml/PKGBUILD b/abs/core-testing/perl_modules/perlxml/PKGBUILD
index c9b2f30..c9b2f30 100644
--- a/abs/core-testing/perlxml/PKGBUILD
+++ b/abs/core-testing/perl_modules/perlxml/PKGBUILD
diff --git a/abs/core-testing/runit-scripts/PKGBUILD b/abs/core-testing/runit-scripts/PKGBUILD
index 2c1300d..a8087bd 100755
--- a/abs/core-testing/runit-scripts/PKGBUILD
+++ b/abs/core-testing/runit-scripts/PKGBUILD
@@ -1,6 +1,6 @@
pkgname=runit-scripts
pkgver=1.8.0
-pkgrel=109
+pkgrel=117
pkgdesc="collection of startup scripts for runit"
url="http://smarden.org/runit/"
license="BSD"
diff --git a/abs/core-testing/runit-scripts/runitscripts/services/lircd/run b/abs/core-testing/runit-scripts/runitscripts/services/lircd/run
index 07ec214..3ff8af3 100755
--- a/abs/core-testing/runit-scripts/runitscripts/services/lircd/run
+++ b/abs/core-testing/runit-scripts/runitscripts/services/lircd/run
@@ -6,8 +6,6 @@ export TERM=linux
. /etc/rc.conf
. /etc/rc.d/functions
-#since what we do may not be enough
-#if your one of those people, this is where you place your stuff
LOG=/tmp/lirc.log
@@ -16,12 +14,17 @@ then
rm -f $LOG
fi
+#since what we do may not be enough
+#if your one of those people, this is where you place your stuff
+#This means place your lirc stuff in /etc/runit/lirc.sh.
+#Anything in that file will be used and the rest of this file is ignored
+
if [ -f /etc/runit/lirc.sh ]
then
#program must not terminate.
stat_runit "Starting lirc"
-
+
/etc/runit/lirc.sh
else
. /etc/systemconfig
@@ -55,8 +58,8 @@ else
then
#/dev/ttyS0 (COM1), port 0x3f8, irq 4
#/dev/ttyS1 (COM2), port 0x2f8, irq 3
- #/dev/ttyS2 (COM3), port 0x3e8, irq 4
- #/dev/ttyS3 (COM4), port 0x2e8, irq 3
+ #/dev/ttyS2 (COM3), port 0x3e8, irq 4
+ #/dev/ttyS3 (COM4), port 0x2e8, irq 3
case $serial_port in
ttyS0)
@@ -73,9 +76,9 @@ else
;;
esac
/usr/bin/setserial /dev/$serial_port uart none
- sleep 0.5
+ sleep 0.5
/sbin/modprobe lirc_serial $FLAGS
- sleep 0.5
+ sleep 0.5
fi
dvico_detect
@@ -83,56 +86,63 @@ else
if [ x$HostBlasterType = xCommandIR -o x$ReceiverType = xCommandIR ]
then
CMD="/usr/sbin/lircd -r -n --driver=commandir"
- printhl " Using commandir"
+ printhl " Using commandir"
$CMD >>$LOG 2>>$LOG
-#echo $CMD
+ #echo $CMD
elif [ x$HostBlasterType = xiguanaIR-usb -o x$ReceiverType = xiguanaIR-usb ]
then
- sv start igdaemon
+ sv start igdaemon
CMD="/usr/sbin/lircd -r -n --driver=iguanaIR"
- printhl " Using iguanaIR usb"
-#echo $CMD
+ printhl " Using iguanaIR usb"
+ #echo $CMD
$CMD >>$LOG 2>>$LOG
+
+ elif [ x$ReceiverType = "xSiliconDust_HDHR" ]
+ then
+ # if using the SiliconDust_HDHR as an I/R Receiver
+ printhl " Using SiliconDust on port 5000"
+ CMD="/usr/sbin/lircd -H udp -d 5000 -n"
+ exec $CMD >>$LOG 2>>$LOG
else
LASTCMD=""
for i in `seq 1 $num_lirc`
do
CMD="/usr/sbin/lircd -r -d /dev/lirc$i --output=/dev/lircd$i --pidfile=/var/run/lircd$i.pid --listen=876$i"
- printhl " Device $i"
-#echo $CMD
+ printhl " Device $i"
+ #echo $CMD
$CMD >>$LOG 2>>$LOG
LASTCMD="--connect=localhost:876$i $LASTCMD "
done
- if [ $RunDvico = "true" ]
- then
- if [ x$Remotetype = "xdvico" ]
+ if [ $RunDvico = "true" ]
+ then
+ if [ x$Remotetype = "xdvico" ]
then
LCMD="/usr/sbin/lircd -r -n -d /dev/usb/dvicoIR --driver=dvico --output /dev/lircd"
else
LCMD="/usr/sbin/lircd -r -n -d /dev/input/irremote --driver=devinput --output /dev/lircd"
fi
- if [ $num_lirc -lt 0 ]
- then
- # Only run Dvico
- printhl " Device $Remotetype"
-#echo $LCMD
- exec $LCMD >>$LOG 2>>$LOG
- elif [ $num_lirc -gt -1 ]
- then
+ if [ $num_lirc -lt 0 ]
+ then
+ # Only run Dvico
+ printhl " Device $Remotetype"
+ #echo $LCMD
+ exec $LCMD >>$LOG 2>>$LOG
+ elif [ $num_lirc -gt -1 ]
+ then
i=$((i+1))
CMD="$LCMD --output=/dev/lircd$i --pidfile=/var/run/lircd$i.pid --listen=876$i"
$CMD >> $LOG
LASTCMD="--connect=localhost:876$i $LASTCMD "
- printhl " Device Dvico"
- /usr/sbin/lircd -r -n -d /dev/lirc0 --output /dev/lircd $LASTCMD >>$LOG 2>>$LOG
- fi
- else
- LCMD="/usr/sbin/lircd -r -n -d /dev/lirc0 --output /dev/lircd $LASTCMD"
-#echo $LCMD
- exec $LCMD >>$LOG 2>>$LOG
- fi
+ printhl " Device Dvico"
+ /usr/sbin/lircd -r -n -d /dev/lirc0 --output /dev/lircd $LASTCMD >>$LOG 2>>$LOG
+ fi
+ else
+ LCMD="/usr/sbin/lircd -r -n -d /dev/lirc0 --output /dev/lircd $LASTCMD"
+ #echo $LCMD
+ exec $LCMD >>$LOG 2>>$LOG
+ fi
fi
fi
diff --git a/abs/core-testing/runit-scripts/runitscripts/services/postfix/run b/abs/core-testing/runit-scripts/runitscripts/services/postfix/run
new file mode 100755
index 0000000..1fa526e
--- /dev/null
+++ b/abs/core-testing/runit-scripts/runitscripts/services/postfix/run
@@ -0,0 +1,8 @@
+#!/bin/bash
+exec 1>&2
+export TERM=linux
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+stat_runit "Starting postfix"
+exec /usr/lib/postfix/master -D
diff --git a/abs/core-testing/system-templates/PKGBUILD b/abs/core-testing/system-templates/PKGBUILD
index 25d70c9..6e88b13 100755
--- a/abs/core-testing/system-templates/PKGBUILD
+++ b/abs/core-testing/system-templates/PKGBUILD
@@ -1,6 +1,6 @@
pkgname=system-templates
pkgver=1.0
-pkgrel=39
+pkgrel=44
conflicts=( )
pkgdesc="Templates used for system configuration"
depends=()
diff --git a/abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/lircd-haupgrey-alt.conf b/abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/lircd-haupgrey-alt.conf
new file mode 100644
index 0000000..c0849ef
--- /dev/null
+++ b/abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/lircd-haupgrey-alt.conf
@@ -0,0 +1,199 @@
+#
+# this config file was automatically generated
+# using lirc-0.5.5pre8 on Sun Apr 18 11:43:45 1999
+#
+# contributed by Jens Leuschner <leuschner@gmx.net>
+#
+# brand: Hauppauge
+# model:
+# supported devices: WinTV primo; WinTV pci; WinTV radio
+#
+# This config file will work with both homebrew receivers and
+# original Hauppauge TV cards !!!
+#
+
+begin remote
+
+ name Hauppauge
+ bits 13
+ flags SHIFT_ENC
+ eps 30
+ aeps 100
+
+ one 950 830
+ zero 950 830
+ plead 960
+ gap 89584
+ repeat_bit 2
+
+ begin codes
+ TV 0x000000000000100F
+ RADIO 0x000000000000100C
+ FULL_SCREEN 0x000000000000102E
+ CH+ 0x0000000000001020
+ CH- 0x0000000000001021
+ VOL- 0x0000000000001011
+ VOL+ 0x0000000000001010
+ MUTE 0x000000000000100D
+ SOURCE 0x0000000000001022
+ 1 0x0000000000001001
+ 2 0x0000000000001002
+ 3 0x0000000000001003
+ 4 0x0000000000001004
+ 5 0x0000000000001005
+ 6 0x0000000000001006
+ 7 0x0000000000001007
+ 8 0x0000000000001008
+ 9 0x0000000000001009
+ 0 0x0000000000001000
+ RESERVED 0x000000000000101E
+ MINIMIZE 0x0000000000001026
+ end codes
+
+end remote
+
+
+#
+# this config file was automatically generated
+# using lirc-0.6.6(animax) on Tue Apr 15 19:50:27 2003
+#
+# contributed by
+#
+# brand: Hauppauge
+# model no. of remote control:
+# devices being controlled by this remote: PVR 2/350
+#
+
+begin remote
+
+ name hauppauge_pvr
+ bits 13
+ flags RC5|CONST_LENGTH
+ eps 30
+ aeps 100
+
+ one 969 811
+ zero 969 811
+ plead 1097
+ gap 114605
+ toggle_bit 2
+
+
+ begin codes
+ Power 0x00000000000017FD
+ Go 0x00000000000017FB
+ 1 0x00000000000017C1
+ 2 0x00000000000017C2
+ 3 0x00000000000017C3
+ 4 0x00000000000017C4
+ 5 0x00000000000017C5
+ 6 0x00000000000017C6
+ 7 0x00000000000017C7
+ 8 0x00000000000017C8
+ 9 0x00000000000017C9
+ Back/Exit 0x00000000000017DF
+ 0 0x00000000000017C0
+ Menu 0x00000000000017CD
+ Red 0x00000000000017CB
+ Green 0x00000000000017EE
+ Yellow 0x00000000000017F8
+ Blue 0x00000000000017E9
+ Ch+ 0x00000000000017E0
+ Ch- 0x00000000000017E1
+ Vol- 0x00000000000017D1
+ Vol+ 0x00000000000017D0
+ Ok 0x00000000000017E5
+ Mute 0x00000000000017CF
+ Blank 0x00000000000017CC
+ Full 0x00000000000017FC
+ Rewind 0x00000000000017F2
+ Play 0x00000000000017F5
+ Forward 0x00000000000017F4
+ Record 0x00000000000017F7
+ Stop 0x00000000000017F6
+ Pause 0x00000000000017F0
+ Replay 0x00000000000017E4
+ Skip 0x00000000000017DE
+ end codes
+
+end remote
+
+
+#
+# this config file was automatically generated
+# using lirc-0.7.0(any) on Sun Nov 28 20:25:09 2004
+#
+# contributed by
+#
+# brand: Hauppauge 350
+# Created: G.J. Werler (The Netherlands)
+# Project: Mythtv Fedora Pundit-R www.mythtvportal.com
+# Date: 2004/11/28
+# model no. of remote control: Hauppauge A415-HPG
+# devices being controlled by this remote: PVR-350
+#
+
+begin remote
+
+ name Hauppauge_350
+ bits 13
+ flags RC5|CONST_LENGTH
+ eps 30
+ aeps 100
+
+ one 969 811
+ zero 969 811
+ plead 1097
+ gap 114605
+ toggle_bit 2
+
+
+ begin codes
+ Go 0x00000000000017BB
+ Power 0x00000000000017BD
+ TV 0x000000000000179C
+ Videos 0x0000000000001798
+ Music 0x0000000000001799
+ Pictures 0x000000000000179A
+ Guide 0x000000000000179B
+ Radio 0x000000000000178C
+ Up 0x0000000000001794
+ Left 0x0000000000001796
+ Right 0x0000000000001797
+ Down 0x0000000000001795
+ OK 0x00000000000017A5
+ Back/Exit 0x000000000000179F
+ Menu/i 0x000000000000178D
+ Vol+ 0x0000000000001790
+ Vol- 0x0000000000001791
+ Prev.Ch 0x0000000000001792
+ Mute 0x000000000000178F
+ Ch+ 0x00000000000017A0
+ Ch- 0x00000000000017A1
+ Record 0x00000000000017B7
+ Stop 0x00000000000017B6
+ Rewind 0x00000000000017B2
+ Play 0x00000000000017B5
+ Forward 0x00000000000017B4
+ Replay/SkipBackward 0x00000000000017A4
+ Pause 0x00000000000017B0
+ SkipForward 0x000000000000179E
+ 1 0x0000000000001781
+ 2 0x0000000000001782
+ 3 0x0000000000001783
+ 4 0x0000000000001784
+ 5 0x0000000000001785
+ 6 0x0000000000001786
+ 7 0x0000000000001787
+ 8 0x0000000000001788
+ 9 0x0000000000001789
+ Asterix 0x000000000000178A
+ 0 0x0000000000001780
+ # 0x000000000000178E
+ Red 0x000000000000178B
+ Green 0x00000000000017AE
+ Yellow 0x00000000000017B8
+ Blue 0x00000000000017A9
+ end codes
+
+end remote
diff --git a/abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/lircrc-haupgrey-alt b/abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/lircrc-haupgrey-alt
new file mode 100644
index 0000000..f86246a
--- /dev/null
+++ b/abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/lircrc-haupgrey-alt
@@ -0,0 +1,533 @@
+# put this in /usr/MythVantage/templates/remotes/hauppauge-grey/
+# then change /etc/lircrc to include it
+#
+# lircrc.example.HauppaugeGrey-nativelirc
+# 2003-09-17, Robert Kulagowski
+# mailto:rkulagow@rocketmail.com
+# Save this file in ~/.mythtv/lircrc
+
+begin
+ prog = mythtv
+ button = Power
+ config = Esc
+end
+
+begin
+ prog = mythtv
+ button = Go
+# Swap the PiP windows
+ config = N
+end
+
+begin
+ prog = mythtv
+ button = 1
+ config = 1
+end
+
+begin
+ prog = mythtv
+ button = 2
+ config = 2
+end
+
+begin
+ prog = mythtv
+ button = 3
+ config = 3
+end
+
+begin
+ prog = mythtv
+ button = 4
+ config = 4
+end
+
+begin
+ prog = mythtv
+ button = 5
+ config = 5
+end
+
+begin
+ prog = mythtv
+ button = 6
+ config = 6
+end
+
+begin
+ prog = mythtv
+ button = 7
+ config = 7
+end
+
+begin
+ prog = mythtv
+ button = 8
+ config = 8
+end
+
+begin
+ prog = mythtv
+ button = 9
+ config = 9
+end
+
+begin
+ prog = mythtv
+ button = Back/Exit
+ config = Esc
+end
+
+begin
+ prog = mythtv
+ button = 0
+ config = 0
+end
+
+begin
+ prog = mythtv
+ button = Menu
+ config = M
+end
+
+# Below are keys used with the Hauppauge Grey remote
+
+begin
+ prog = mythtv
+# This is the Red key
+# We'll use it for "Delete"
+ button = Red
+ config = Space
+end
+
+begin
+ prog = mythtv
+# This is the Green key
+# We'll use it for "Information"
+ button = Green
+ config = I
+end
+
+# Note the "repeat = " strings in the volume and channel.
+# This means that if you hold down the key, every nth instance will be
+# passed. This depends on your system, so you may want to increase or
+# decrease this and see what happens. repeat = 1 is probably too
+# fast.
+
+begin
+ prog = mythtv
+# This is the Yellow key
+# Use it as a volume key
+ button = Yellow
+ repeat = 3
+ config = F10
+end
+
+begin
+ prog = mythtv
+# This is the Blue key
+# Use it as a volume key
+ button = Blue
+ repeat = 3
+ config = F11
+end
+
+begin
+ prog = mythtv
+ button = Ch+
+# This is the "up" on the central diamond
+ repeat = 3
+ config = Up
+end
+
+begin
+ prog = mythtv
+ button = Ch-
+# This is the "down" on the central diamond
+ repeat = 3
+ config = Down
+end
+
+begin
+ prog = mythtv
+ button = Vol-
+# This is the "left" on the central diamond
+ repeat = 3
+ config = Left
+end
+
+begin
+ prog = mythtv
+ button = Vol+
+# This is the "right" on the central diamond
+ repeat = 3
+ config = Right
+end
+
+begin
+ prog = mythtv
+# Middle button on the diamond
+ button = Ok
+ config = Return
+end
+
+begin
+ prog = mythtv
+ button = Mute
+ config = F9
+end
+
+begin
+ prog = mythtv
+# Change focus for PiP (to change channel in the other window)
+ button = Blank
+ config = B
+end
+
+begin
+ prog = mythtv
+# Toggle PiP on/off
+ button = Full
+ config = V
+end
+
+begin
+ prog = mythtv
+ button = Rewind
+ config = Left
+end
+
+begin
+ prog = mythtv
+ button = Play
+ config = P
+end
+
+begin
+ prog = mythtv
+ button = Forward
+ config = Right
+end
+
+begin
+ prog = mythtv
+ button = Record
+ config = R
+end
+
+begin
+ prog = mythtv
+# Teletext
+ button = Stop
+ config = T
+end
+
+begin
+ prog = mythtv
+ button = Pause
+ config = P
+end
+
+begin
+ prog = mythtv
+ button = Replay
+# Use for backwards commercial skip
+ config = Q
+end
+
+begin
+ prog = mythtv
+ button = Skip
+# Use for forward commercial skip
+ config = Z
+end
+
+#MPlayer
+begin
+ prog = mplayer
+ button = Power
+ config = quit
+end
+
+begin
+ prog = mplayer
+ button = Menu
+ config = osd
+end
+
+begin
+ prog = mplayer
+ button = Rewind
+ config = seek -10
+ repeat = 1
+end
+
+begin
+ prog = mplayer
+ button = Forward
+ config = seek +10
+ repeat = 1
+end
+
+begin
+ prog = mplayer
+ button = Vol-
+ config = seek -15
+ repeat = 1
+end
+
+begin
+ prog = mplayer
+ button = Vol+
+ config = seek +15
+ repeat = 1
+end
+
+begin
+ prog = mplayer
+ button = Replay
+ config = seek -60
+ repeat = 1
+end
+
+begin
+ prog = mplayer
+ button = Skip
+ config = seek +60
+ repeat = 1
+end
+
+begin
+ prog = mplayer
+ button = Pause
+ config = pause
+end
+
+begin
+ prog = mplayer
+ button = OK
+ config = pause
+end
+
+begin
+ prog = mplayer
+ button = Play
+ config = pause
+end
+
+begin
+ prog = mplayer
+ button = Back/Exit
+ config = quit
+end
+
+begin
+ prog = mplayer
+ button = Play
+ config = pause
+end
+
+begin
+ prog = mplayer
+ button = Ch+
+ config = volume +1
+ repeat = 1
+end
+
+begin
+ prog = mplayer
+ button = Ch-
+ config = volume -1
+ repeat = 1
+end
+
+begin
+ prog = mplayer
+ button = Mute
+ config = mute
+end
+##XINE
+
+ begin
+ prog = xine
+ button = Play
+ repeat = 3
+ config = Play
+ end
+
+ begin
+ prog = xine
+ button = Stop
+ repeat = 3
+ config = Stop
+ end
+
+ begin
+ prog = xine
+ button = Back/Exit
+ config = Quit
+ end
+
+ begin
+ prog = xine
+ button = Pause
+ repeat = 3
+ config = Pause
+ end
+
+ begin
+ prog = xine
+ button = Ch+
+ repeat = 4
+ config = EventUp
+ end
+
+ begin
+ prog = xine
+ button = Ch-
+ repeat = 4
+ config = EventDown
+ end
+
+ begin
+ prog = xine
+ button = Vol-
+ repeat = 4
+ config = EventLeft
+ end
+
+ begin
+ prog = xine
+ button = Vol+
+ repeat = 4
+ config = EventRight
+ end
+
+ begin
+ prog = xine
+ button = Ok
+ repeat = 0
+ config = EventSelect
+ end
+
+ begin
+ prog = xine
+ button = Menu
+ repeat = 0
+ config = Menu
+ end
+
+ #vol down
+ begin
+ prog = xine
+ button = Yellow
+ repeat = 1
+ config = Volume-
+ end
+
+ #vol up
+ begin
+ prog = xine
+ button = Red
+ repeat = 1
+ config = Volume+
+ end
+
+ begin
+ prog = xine
+ button = Forward
+ repeat = 2
+ config = SeekRelative+30
+ end
+
+ begin
+ prog = xine
+ button = Rewind
+ repeat = 2
+ config = SeekRelative-30
+ end
+
+ #ch up
+ begin
+ prog = xine
+ button = Green
+ repeat = 1
+ config = SeekRelative+60
+ end
+
+ #ch down
+ begin
+ prog = xine
+ button = Blue
+ repeat = 1
+ config = SeekRelative-60
+ end
+
+ #sleep
+ begin
+ prog = xine
+ button = Go
+ repeat = 1
+ config = ZoomIn
+ end
+
+ #display
+ begin
+ prog = xine
+ button = Skip
+ repeat = 1
+ config = ZoomOut
+ end
+
+ #skip chapter forward
+ begin
+ prog = xine
+ button = Skip
+ repeat = 1
+ config = EventNext
+ end
+
+ #skip chapter backward
+ begin
+ prog = xine
+ button = Replay
+ repeat = 1
+ config = EventPrior
+ end
+
+ begin
+ prog = lircnav
+ button = Vol-
+ config = page_down
+ end
+
+ begin
+ prog = lircnav
+ button = Vol+
+ config = page_up
+ end
+
+ begin
+ prog = lircnav
+ button = Ch+
+ config = up
+ end
+
+ begin
+ prog = lircnav
+ button = Ch-
+ config = down
+ end
+
+ begin
+ prog = lircnav
+ button = Ok
+ config = select
+ end
+
+ begin
+ prog = lircnav
+ button = Power
+ config = quit
+ end
diff --git a/abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/preview.jpg b/abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/preview.jpg
new file mode 100644
index 0000000..19acba3
--- /dev/null
+++ b/abs/core-testing/system-templates/templates/remotes/hauppauge-grey-alt/preview.jpg
Binary files differ
diff --git a/abs/core-testing/system-templates/templates/remotes/imon/lircrc b/abs/core-testing/system-templates/templates/remotes/imon/lircrc
new file mode 100644
index 0000000..3ad34d8
--- /dev/null
+++ b/abs/core-testing/system-templates/templates/remotes/imon/lircrc
@@ -0,0 +1,240 @@
+###################################
+# lircrc config as used by Stev391 June 2007
+# Not all of the buttons are configured yet, only the commonly used buttons
+###################################
+
+# Escape
+begin
+ prog = mythtv
+ button = AppExit
+ config = Esc
+ repeat = 3
+end
+
+# Escape Key 2
+begin
+ prog = mythtv
+ button = Esc
+ config = Esc
+end
+
+# Channel Up
+begin
+ prog = mythtv
+ button = Ch+
+ config = Up
+ repeat = 3
+end
+
+# Channel Down
+begin
+ prog = mythtv
+ button = Ch-
+ config = Down
+ repeat = 3
+end
+
+# Volume Up
+begin
+ prog = mythtv
+ button = Vol+
+ repeat = 3
+ config = Right
+end
+
+# Volume Down
+begin
+ prog = mythtv
+ button = Vol-
+ repeat = 3
+ config = Left
+end
+
+# Enter/Return
+begin
+ prog = mythtv
+ button = Enter
+ config = Return
+end
+
+# Menu Button
+begin
+ prog = mythtv
+ button = Menu
+ config = M
+end
+
+# Mute
+begin
+ prog = mythtv
+ button = Mute
+ config = F9
+end
+
+# Rewind
+begin
+ prog = mythtv
+ button = Rewind
+ config = PgUp
+end
+
+# Fast Forward
+begin
+ prog = mythtv
+ button = FastForward
+ config = PgDown
+end
+
+# Play
+begin
+ prog = mythtv
+ button = Play
+ config = P
+end
+
+# Pause
+begin
+ prog = mythtv
+ button = Pause
+ config = P
+end
+
+# Record
+begin
+ prog = mythtv
+ button = Record
+ config = R
+end
+
+# Stop
+begin
+ prog = mythtv
+ button = Stop
+ config = O
+end
+
+# Previous Track/Chapter
+begin
+ prog = mythtv
+ button = PrevChapter
+ config = Home
+end
+
+# Next Track/Chapter
+begin
+ prog = mythtv
+ button = NextChapter
+ config = End
+end
+
+# Jump Point to MythVideo
+begin
+ prog = mythtv
+ button = MyMovie
+ config = F12
+end
+
+# Jump Point to MythMusic
+begin
+ prog = mythtv
+ button = MyMusic
+ config = F11
+end
+
+# Jump Point to LiveTV
+begin
+ prog = mythtv
+ button = MyTV
+ config = F10
+end
+
+# Jump Point to Main Menu
+begin
+ prog = mythtv
+ button = Multimon
+ config = F2
+end
+
+# Jump Point to Myth Gallery
+begin
+ prog = mythtv
+ button = MyPhoto
+ config = F3
+end
+
+# Jump Point to Play DVD
+begin
+ prog = mythtv
+ button = MyDVD
+ config = F4
+end
+
+# Display Information
+begin
+ prog = mythtv
+ button = Caption
+ config = I
+end
+
+##############################
+# Numbers
+##############################
+begin
+ prog = mythtv
+ button = 0
+ config = 0
+end
+
+begin
+ prog = mythtv
+ button = 1
+ config = 1
+end
+
+begin
+ prog = mythtv
+ button = 2
+ config = 2
+end
+
+begin
+ prog = mythtv
+ button = 3
+ config = 3
+end
+
+begin
+ prog = mythtv
+ button = 4
+ config = 4
+end
+
+begin
+ prog = mythtv
+ button = 5
+ config = 5
+end
+
+begin
+ prog = mythtv
+ button = 6
+ config = 6
+end
+
+begin
+ prog = mythtv
+ button = 7
+ config = 7
+end
+
+begin
+ prog = mythtv
+ button = 8
+ config = 8
+end
+
+begin
+ prog = mythtv
+ button = 9
+ config = 9
+end
diff --git a/abs/core-testing/system-templates/templates/settings/default_1/jumppoints.txt b/abs/core-testing/system-templates/templates/settings/default_1/jumppoints.txt
new file mode 100644
index 0000000..1cbf116
--- /dev/null
+++ b/abs/core-testing/system-templates/templates/settings/default_1/jumppoints.txt
@@ -0,0 +1,44 @@
+destination description keylist hostname
+Reload Theme REPLACEME
+Main Menu REPLACEME
+Program Guide REPLACEME
+Program Finder REPLACEME
+Manage Recordings / Fix Conflicts REPLACEME
+Program Recording Priorities REPLACEME
+Manage Recording Rules REPLACEME
+Channel Recording Priorities REPLACEME
+TV Recording Playback REPLACEME
+TV Recording Deletion REPLACEME
+Live TV REPLACEME
+Live TV In Guide REPLACEME
+Status Screen REPLACEME
+Previously Recorded REPLACEME
+ScreenShot REPLACEME
+Create DVD REPLACEME
+Create Archive REPLACEME
+Import Archive REPLACEME
+View Archive Log REPLACEME
+Play Created DVD REPLACEME
+Burn DVD REPLACEME
+Netflix Browser Browse Netflix titles REPLACEME
+Netflix Queue Administer Netflix Queue REPLACEME
+Netflix History View Netflix History REPLACEME
+MythGallery Image viewer / slideshow REPLACEME
+MythGame Game frontend REPLACEME
+Play music REPLACEME
+Select music playlists REPLACEME
+Rip CD REPLACEME
+Scan music REPLACEME
+Show Music Miniplayer REPLACEME
+MythNews RSS News feed reader REPLACEME
+MythSmolt Sample plugin Ctrl+Alt+P REPLACEME
+MythStream AV stream plugin REPLACEME
+MythVideo The MythVideo default view REPLACEME
+Video Manager The MythVideo video manager REPLACEME
+Video Browser The MythVideo video browser REPLACEME
+Video Listings The MythVideo video listings REPLACEME
+Video Gallery The MythVideo video gallery REPLACEME
+Play DVD Play a DVD REPLACEME
+Play VCD Play a VCD REPLACEME
+Rip DVD Import a DVD into your MythVideo database REPLACEME
+MythWeather Weather forecasts REPLACEME
diff --git a/abs/core-testing/system-templates/templates/settings/default_2/jumppoints.txt b/abs/core-testing/system-templates/templates/settings/default_2/jumppoints.txt
new file mode 100644
index 0000000..1cbf116
--- /dev/null
+++ b/abs/core-testing/system-templates/templates/settings/default_2/jumppoints.txt
@@ -0,0 +1,44 @@
+destination description keylist hostname
+Reload Theme REPLACEME
+Main Menu REPLACEME
+Program Guide REPLACEME
+Program Finder REPLACEME
+Manage Recordings / Fix Conflicts REPLACEME
+Program Recording Priorities REPLACEME
+Manage Recording Rules REPLACEME
+Channel Recording Priorities REPLACEME
+TV Recording Playback REPLACEME
+TV Recording Deletion REPLACEME
+Live TV REPLACEME
+Live TV In Guide REPLACEME
+Status Screen REPLACEME
+Previously Recorded REPLACEME
+ScreenShot REPLACEME
+Create DVD REPLACEME
+Create Archive REPLACEME
+Import Archive REPLACEME
+View Archive Log REPLACEME
+Play Created DVD REPLACEME
+Burn DVD REPLACEME
+Netflix Browser Browse Netflix titles REPLACEME
+Netflix Queue Administer Netflix Queue REPLACEME
+Netflix History View Netflix History REPLACEME
+MythGallery Image viewer / slideshow REPLACEME
+MythGame Game frontend REPLACEME
+Play music REPLACEME
+Select music playlists REPLACEME
+Rip CD REPLACEME
+Scan music REPLACEME
+Show Music Miniplayer REPLACEME
+MythNews RSS News feed reader REPLACEME
+MythSmolt Sample plugin Ctrl+Alt+P REPLACEME
+MythStream AV stream plugin REPLACEME
+MythVideo The MythVideo default view REPLACEME
+Video Manager The MythVideo video manager REPLACEME
+Video Browser The MythVideo video browser REPLACEME
+Video Listings The MythVideo video listings REPLACEME
+Video Gallery The MythVideo video gallery REPLACEME
+Play DVD Play a DVD REPLACEME
+Play VCD Play a VCD REPLACEME
+Rip DVD Import a DVD into your MythVideo database REPLACEME
+MythWeather Weather forecasts REPLACEME
diff --git a/abs/core-testing/system-templates/templates/settings/default_2/settings.txt b/abs/core-testing/system-templates/templates/settings/default_2/settings.txt
index 106be04..8c3a391 100644
--- a/abs/core-testing/system-templates/templates/settings/default_2/settings.txt
+++ b/abs/core-testing/system-templates/templates/settings/default_2/settings.txt
@@ -74,7 +74,6 @@ GuiOffsetY 0 REPLACEME
GuiSizeForTV 0 REPLACEME
GuiVidModeResolution 640x480 REPLACEME
GuiWidth 0 REPLACEME
-HaltCommand halt REPLACEME
HideMouseCursor 1 REPLACEME
HorizScanPercentage 0 REPLACEME
Ignore_ID3 0 REPLACEME
@@ -126,7 +125,7 @@ LogPrintLevel 8 REPLACEME
LogPrintLevel 8 REPLACEME
LongChannelFormat <num> <name> REPLACEME
MasterMixerVolume 70 REPLACEME
-MenuTheme STB-menu REPLACEME
+MenuTheme MythVantage-menu REPLACEME
MixerControl PCM REPLACEME
MixerDevice /dev/mixer REPLACEME
MonitorDrives 0 REPLACEME
@@ -248,7 +247,7 @@ SlideshowTransition none REPLACEME
SmartChannelChange 0 REPLACEME
SmartForward 0 REPLACEME
StickyKeys 1 REPLACEME
-Style REPLACEME
+Style Windows REPLACEME
SubTitleCommand -sid %s REPLACEME
TagSeparator - REPLACEME
Theme basic-blue REPLACEME
@@ -276,7 +275,6 @@ UnknownCategory Unknown REPLACEME
UnknownTitle Unknown REPLACEME
upnp:UDN:urn:schemas-upnp-org:device:MediaServer:1 dee5b0fe-7087-4960-8794-428d3e01a61f REPLACEME
UseArrowAccels 1 REPLACEME
-UseDHCP 1 REPLACEME
UseOutputPictureControls 1 REPLACEME
UseVideoModes 0 REPLACEME
UseVideoTimebase 0 REPLACEME
@@ -293,9 +291,9 @@ VideoGalleryColsPerPage 4 REPLACEME
VideoGalleryNoDB 0 REPLACEME
VideoGalleryRowsPerPage 3 REPLACEME
VideoGallerySubtitle 1 REPLACEME
-VideoDefaultPlayer /usr/bin/playmedia.sh VIDEO %s REPLACEME
VideoListUnknownFiletypes 1 REPLACEME
VideoNewBrowsable 1 REPLACEME
+VideoDefaultPlayer Internal REPLACEME
VideoStartupDir /data/media/video/movies REPLACEME
VideoTreeLoadMetaData 1 REPLACEME
VideoTreeNoDB 0 REPLACEME
@@ -318,3 +316,5 @@ WebBrowserScrollSpeed 4 REPLACEME
WebBrowserZoomLevel 20 REPLACEME
XScanDisplacement 0 REPLACEME
YScanDisplacement 0 REPLACEME
+HaltCommand sudo /sbin/poweroff REPLACEME
+RebootCommand sudo /sbin/reboot REPLACEME
diff --git a/abs/core-testing/system-templates/templates/transmit/motorola_dct700/lircd.conf b/abs/core-testing/system-templates/templates/transmit/motorola_dct700/lircd.conf
index 31df8aa..93a2183 100755..100644
--- a/abs/core-testing/system-templates/templates/transmit/motorola_dct700/lircd.conf
+++ b/abs/core-testing/system-templates/templates/transmit/motorola_dct700/lircd.conf
@@ -1,83 +1,359 @@
+#########
#
-# this config file was originally generated
-# using lirc-0.6.6(serial) on Fri Mar 28 22:46:44 2003
-# modified by hand on Sunday Jul 17 00:12:00 2005
+# Modified DCT2000 entry for DCT700 (sends zeros)
+# For use with the USB MCE ir receiver
#
-# contributed by rob scullion
-# based on the DCT2000 file contrib'd by shane bradley
-#
-# brand: Motorola
-# model no. of remote control: ? - Comcast badged
-# devices being controlled by this remote: DCT2524/1612
-#
-# Note: The "ON DEMAND" button on the Comcast
-# badged remote just sends a "1" followed by
-# an "ok/select" and is thus not included in
-# this config file.
-
+
begin remote
- name DCT2524
- bits 16
- flags SPACE_ENC|CONST_LENGTH
- eps 30
- aeps 100
-
- header 9036 4424
- one 556 2185
- zero 556 4424
- ptrail 556
- gap 100025
- toggle_bit 0
-
-
- begin codes
- power 0x000000000000AFF9
- rew 0x00000000000087F7
- play 0x00000000000027FD
- ffwd 0x00000000000047FB
- stop 0x000000000000C7F3
- pause 0x00000000000007FF
- rec 0x00000000000073FC
- skipback 0x000000000000C3F7
- mydvr 0x00000000000043FF
- live 0x00000000000083F0
- pageup 0x000000000000A3F3
- pagedown 0x00000000000023FB
- a_lock 0x00000000000097F6
- b_day- 0x00000000000063FD
- c_day+ 0x000000000000E3F5
- up 0x000000000000D3F6
- down 0x00000000000053FE
- left 0x00000000000093F1
- right 0x00000000000013F9
- ok/select 0x00000000000077F8
- guide 0x000000000000F3F4
- info 0x00000000000033FA
- menu 0x00000000000067F9
- exit 0x000000000000B7F4
- help 0x000000000000B3F2
- last 0x00000000000037FC
- vol+ 0x0000000000004FF3
- vol- 0x0000000000008FFB
- mute 0x0000000000000FF7
- fav 0x00000000000057FA
- ch+ 0x0000000000002FF5
- ch- 0x000000000000CFFD
- 1 0x0000000000007FF0
- 2 0x000000000000BFF8
- 3 0x0000000000003FF4
- 4 0x000000000000DFFC
- 5 0x0000000000005FF2
- 6 0x0000000000009FFA
- 7 0x0000000000001FF6
- 8 0x000000000000EFFE
- 9 0x0000000000006FF1
- 0 0x000000000000FFFF
- tv/vcr_input 0x000000000000D7F2
- hdzoom_enter 0x000000000000FDFC
- pnp-swap 0x0000000000003BF2
- end codes
-
-end remote
+ name DCT700
+ flags RAW_CODES
+ eps 30
+ aeps 100
+
+ ptrail 520
+ repeat 0 0
+ gap 100000
+
+ begin raw_codes
+
+ name bypass
+ 9000 4400 550 2200 550 2150
+ 550 4450 550 2150 550 4450
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 4450 550 4400
+ 550 2200 550 4400 550
+
+ name power
+ 9050 4400 550 2200 550 4400
+ 550 2200 550 4400 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 4400
+ 550 4450 550 2150 550
+
+ name help
+ 9000 4400 600 2150 550 4450
+ 550 2150 550 2200 550 4400
+ 550 4450 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 4400 550 4450
+ 500 2200 550 4450 550
+
+ name day-
+ 9000 4400 550 4400 550 2200
+ 550 2200 550 4400 550 4400
+ 600 4400 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 500 2200
+ 550 4450 550 2150 550
+
+ name day+
+ 9000 4400 550 2200 550 2200
+ 550 2150 550 4450 550 4400
+ 550 4400 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 4450 550 2150
+ 550 4450 550 2200 500
+
+ name rec
+ 9050 4400 550 4400 550 2200
+ 550 2200 550 2150 550 4450
+ 550 4400 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 4450 550 4400 550
+
+ name stop
+ 9000 4400 550 4400 550 2200
+ 550 2200 550 4400 550 4400
+ 550 4450 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 4450 500 2200 550
+
+ name pause
+ 9000 4400 550 4400 550 4450
+ 550 4400 550 4450 550 4400
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550
+
+ name rew
+ 9000 4400 550 2200 550 4400
+ 550 4450 550 4400 550 4450
+ 550 2150 550 2200 550 2200
+ 500 2200 550 2200 550 2200
+ 500 2200 550 4450 550 2150
+ 550 2200 550 2200 500
+
+ name ffwd
+ 9050 4400 550 4400 550 2200
+ 550 4400 550 4450 550 4400
+ 550 2200 550 2150 600 2150
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 4450
+ 550 2200 500 2200 550
+
+ name play
+ 9050 4400 550 2150 550 2200
+ 550 2200 550 4400 550 4400
+ 550 4450 550 2200 550 2150
+ 550 2200 550 2200 500 2200
+ 550 2200 550 4400 550 2200
+ 550 4400 550 2200 550
+
+ name pageup
+ 9000 4400 550 2200 550 4400
+ 550 2200 550 4400 550 4450
+ 550 4400 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 4400 550 4450
+ 550 2150 550 2200 550
+
+ name pagedown
+ 9000 4400 550 4450 550 4400
+ 550 2200 550 4400 550 4450
+ 550 4400 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 550 4400
+ 550 2200 550 2150 550
+
+ name info
+ 9050 4400 550 4400 550 4400
+ 600 2150 550 2200 550 4400
+ 550 4450 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 4450
+ 550 2150 550 4450 550
+
+ name menu
+ 9050 4400 550 4400 550 2200
+ 550 2200 550 4400 550 4400
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 550 4400
+ 550 4400 550 2200 550
+
+ name guide
+ 9050 4400 550 2150 600 2150
+ 550 2200 550 2150 550 4450
+ 550 4400 550 2200 550 2150
+ 600 2150 550 2200 550 2200
+ 500 2200 550 4450 550 2150
+ 550 4450 550 4400 550
+
+ name lock
+ 9000 4400 600 2150 550 4400
+ 600 4400 550 2200 550 4400
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 4400 550 2200
+ 550 2150 550 4450 550
+
+ name exit
+ 9000 4400 550 2200 550 4400
+ 550 2200 550 2200 550 4400
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 4400 550 2200
+ 550 4400 550 4450 550
+
+ name up
+ 9000 4450 550 2150 550 2200
+ 550 4400 550 2200 550 4400
+ 550 4450 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 4400 550 2200
+ 550 2200 500 4450 550
+ name down
+ 9000 4400 600 4400 550 2200
+ 550 4400 550 2200 550 4400
+ 550 4400 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 4450 550
+
+ name left
+ 9000 4400 550 2200 550 4400
+ 550 4400 600 2150 550 4450
+ 550 4400 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 4400 550 4450
+ 550 4400 550 2200 550
+
+ name right
+ 9050 4400 550 4400 550 4450
+ 550 4400 550 2200 550 4400
+ 550 4400 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 4450
+ 500 4450 550 2200 550
+
+ name ok
+ 9050 4400 550 4400 550 2200
+ 550 2200 550 2150 550 4450
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 4400
+ 550 4450 550 4400 550
+
+ name ch+
+ 9000 4400 550 4400 550 4450
+ 550 2150 600 4400 550 2150
+ 600 2150 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 4450 500 2200
+ 550 4450 550 2150 550
+
+ name ch-
+ 9050 4400 550 2150 600 2150
+ 550 4450 550 4400 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 4400 550 2200 550
+
+ name last
+ 9000 4400 550 4450 550 4400
+ 550 2200 550 2150 550 4450
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 4400 550 4450 500
+
+ name fav
+ 9000 4400 550 4450 550 2150
+ 550 4450 550 2150 550 4450
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 4450
+ 500 2200 550 4450 500
+
+ name enter
+ 9000 4400 600 2150 550 2200
+ 550 2150 550 2200 550 4400
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 4450 500 4450
+ 550 4400 550 4450 550
+
+ name music
+ 9000 4400 550 2200 550 2200
+ 550 2150 550 2200 550 4400
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 4400 550 4450
+ 550 4400 550 4450 500
+
+ name p
+ 9000 4400 600 4400 550 4400
+ 550 4450 550 2150 550 4450
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 4450 550
+
+ name x1
+ 9050 4400 550 4400 550 4450
+ 550 4400 550 2200 550 2150
+ 550 4450 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 4400 550 4450
+ 500 4450 550 2200 550
+
+ name x2
+ 9050 4400 550 2150 550 2200
+ 550 2200 550 4400 550 2200
+ 550 4400 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 550 4400
+ 550 4450 550 2150 550
+
+ name 1
+ 9000 4400 550 4450 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 4400 550 4450
+ 550 4400 550 4450 550
+
+ name 2
+ 9000 4400 550 2200 550 4400
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 4450
+ 550 4400 550 4450 500
+
+ name 3
+ 9000 4400 550 4450 550 4400
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 4400 550 2200
+ 550 4400 550 4450 500
+
+ name 4
+ 9000 4400 550 2200 550 2150
+ 550 4450 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 4400 550 4450 550
+
+ name 5
+ 9000 4450 550 4400 550 2200
+ 550 4400 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 2200 550 2150
+ 550 2200 550 4400 550 4450
+ 550 2200 500 4450 550
+
+ name 6
+ 9000 4400 550 2200 550 4400
+ 550 4400 600 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 500 2200 550 2200
+ 550 2200 500 2200 550 4450
+ 550 2150 550 4450 550
+
+ name 7
+ 9000 4400 550 4400 600 4400
+ 550 4400 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 4450 550 2150
+ 550 2200 550 4400 550
+
+ name 8
+ 9000 4400 550 2200 550 2150
+ 550 2200 550 4400 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 2150 550 2200
+ 550 2200 550 4400 550
+
+ name 9
+ 9050 4400 550 4400 550 2200
+ 550 2150 600 4400 550 2150
+ 600 2150 550 2200 550 2200
+ 500 2200 550 2200 550 2200
+ 500 2200 550 4450 550 4400
+ 550 4400 550 2200 550
+
+ name 0
+ 9000 4400 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 2200
+ 550 2150 550 2200 550 42050
+ 9000 2250 500
+
+ end raw_codes
+
+end remote
diff --git a/abs/core-testing/vdpinfo-71xx/PKGBUILD b/abs/core-testing/vdpauinfo-legacy/PKGBUILD
index bf20d32..7e7fe26 100644
--- a/abs/core-testing/vdpinfo-71xx/PKGBUILD
+++ b/abs/core-testing/vdpauinfo-legacy/PKGBUILD
@@ -2,18 +2,18 @@
# 'vdpinfo' to return something when users run it, even if the real 'vdpinfo' won't build
# for their nVidia driver version.
-pkgname=vdpinfo-71xx
+pkgname=vdpauinfo-legacy
pkgver=1
-pkgrel=1
+pkgrel=4
pkgdesc="tells the user they can't handle vdpau"
license=('GPLv2')
arch=('i686' 'x86_64')
-depends=('nvidia-71xx-utils' 'nvidia-71xx')
+depends=('')
# Just let the dependency on the right nvidia and nvidia-utils versions
# handle conflicts via those packages conflicts.
-# conflicts=()
-provides=('vdpinfo')
-source=(vdpinfo)
+conflicts=(vdpauinfo)
+provides=('vpinfo' 'vdpauinfo')
+source=(vdpauinfo)
md5sums=()
build() {
@@ -21,5 +21,6 @@ build() {
mkdir -p $startdir/pkg/$LH_ROOT/bin/
cd $startdir
- install -m0755 -D vdpinfo $startdir/pkg/$LH_ROOT/bin/
-} \ No newline at end of file
+ install -m0755 -D vdpauinfo $startdir/pkg/$LH_ROOT/bin/
+}
+md5sums=('502f0a21bd1232e5a6bccb17cd63116d')
diff --git a/abs/core-testing/vdpinfo-96xx/vdpinfo b/abs/core-testing/vdpauinfo-legacy/vdpauinfo
index 9b237dc..9b237dc 100755
--- a/abs/core-testing/vdpinfo-96xx/vdpinfo
+++ b/abs/core-testing/vdpauinfo-legacy/vdpauinfo
diff --git a/abs/core-testing/vdpauinfo/PKGBUILD b/abs/core-testing/vdpauinfo/PKGBUILD
index 4881bc3..35e8419 100644
--- a/abs/core-testing/vdpauinfo/PKGBUILD
+++ b/abs/core-testing/vdpauinfo/PKGBUILD
@@ -1,14 +1,14 @@
# Contributor: Nathan Harris
pkgname=vdpauinfo
pkgver=0.0.6
-pkgrel=2
+pkgrel=5
pkgdesc="NVIDIA VDPAU capability query utility"
arch=('i686' 'x86_64')
url="url=http://cgit.freedesktop.org/~aplattner/vdpauinfo"
license=('custom')
-depends=('nvidia' 'libvdpau' 'xorg-server')
+depends=('libvdpau' 'xorg-server')
makedepends=('gcc' 'autoconf' 'make')
-optdepends=()
+optdepends=(nvidia-utils)
install=()
source=(http://cgit.freedesktop.org/~aplattner/${pkgname}/snapshot/${pkgname}-${pkgver}.tar.gz)
#md5sums=('d5aff9786b44ac5c70b5dd6faea37a67')
@@ -21,3 +21,4 @@ build() {
make DESTDIR="${pkgdir}" install || return 1
install -D -m644 $srcdir/$pkgname-$pkgver/LICENSE $pkgdir/usr/share/licenses/$pkgname/license || return 1
}
+md5sums=('9f9d387ab981b7a7e4460c70e7bab402')
diff --git a/abs/core-testing/vdpauinfo/__changelog b/abs/core-testing/vdpauinfo/__changelog
new file mode 100644
index 0000000..3acad6e
--- /dev/null
+++ b/abs/core-testing/vdpauinfo/__changelog
@@ -0,0 +1,2 @@
+made nvidia-utils an optional dep. Otherwise this program could drag in the nividia drivers when we don't want them.
+
diff --git a/abs/core-testing/vdpinfo-71xx/vdpinfo b/abs/core-testing/vdpinfo-71xx/vdpinfo
deleted file mode 100755
index 9b237dc..0000000
--- a/abs/core-testing/vdpinfo-71xx/vdpinfo
+++ /dev/null
@@ -1,2 +0,0 @@
-#!/bin/bash
-echo "vdpau is unsupported"
diff --git a/abs/core-testing/vdpinfo-96xx/PKGBUILD b/abs/core-testing/vdpinfo-96xx/PKGBUILD
deleted file mode 100644
index 34391dd..0000000
--- a/abs/core-testing/vdpinfo-96xx/PKGBUILD
+++ /dev/null
@@ -1,25 +0,0 @@
-# It is not expected that vdpau will work with the 71xx nVidia drivers, but we still want
-# 'vdpinfo' to return something when users run it, even if the real 'vdpinfo' won't build
-# for their nVidia driver version.
-
-pkgname=vdpinfo-96xx
-pkgver=1
-pkgrel=1
-pkgdesc="tells the user they can't handle vdpau"
-license=('GPLv2')
-arch=('i686' 'x86_64')
-depends=('nvidia-96xx-utils' 'nvidia-96xx')
-# Just let the dependency on the right nvidia and nvidia-utils versions
-# handle conflicts via those packages conflicts.
-# conflicts=()
-provides=('vdpinfo')
-source=(vdpinfo)
-md5sums=()
-
-build() {
- LH_ROOT=/usr/LH
- mkdir -p $startdir/pkg/$LH_ROOT/bin/
-
- cd $startdir
- install -m0755 -D vdpinfo $startdir/pkg/$LH_ROOT/bin/
-} \ No newline at end of file
diff --git a/abs/extra-testing/alpine/2.00-lpam.patch b/abs/extra-testing/alpine/2.00-lpam.patch
new file mode 100644
index 0000000..69e66d7
--- /dev/null
+++ b/abs/extra-testing/alpine/2.00-lpam.patch
@@ -0,0 +1,13 @@
+--- alpine-2.00.orig/alpine/Makefile.in
++++ alpine-2.00/alpine/Makefile.in
+@@ -169,7 +169,7 @@
+ LIBICONV = @LIBICONV@
+ LIBINTL = @LIBINTL@
+ LIBOBJS = @LIBOBJS@
+-LIBS = @LIBS@
++LIBS = @LIBS@ -lpam
+ LIBTOOL = @LIBTOOL@
+ LN = @LN@
+ LN_S = @LN_S@
+ LTLIBICONV = @LTLIBICONV@
+ LTLIBINTL = @LTLIBINTL@
diff --git a/abs/extra-testing/alpine/CVE-2008-5514.patch b/abs/extra-testing/alpine/CVE-2008-5514.patch
new file mode 100644
index 0000000..594bea0
--- /dev/null
+++ b/abs/extra-testing/alpine/CVE-2008-5514.patch
@@ -0,0 +1,20 @@
+--- alpine-2.00/imap/src/c-client/rfc822.c
++++ alpine-2.00/imap/src/c-client/rfc822.c
+@@ -1351,6 +1351,7 @@
+
+ static long rfc822_output_char (RFC822BUFFER *buf,int c)
+ {
++ if ((buf->cur == buf->end) && !rfc822_output_flush (buf)) return NIL;
+ *buf->cur++ = c; /* add character, soutr buffer if full */
+ return (buf->cur == buf->end) ? rfc822_output_flush (buf) : LONGT;
+ }
+@@ -1374,7 +1375,8 @@
+ len -= i;
+ }
+ /* soutr buffer now if full */
+- if (len && !rfc822_output_flush (buf)) return NIL;
++ if ((len || (buf->cur == buf->end)) && !rfc822_output_flush (buf))
++ return NIL;
+ }
+ return LONGT;
+ }
diff --git a/abs/extra-testing/alpine/ChangeLog b/abs/extra-testing/alpine/ChangeLog
new file mode 100644
index 0000000..4c3bf81
--- /dev/null
+++ b/abs/extra-testing/alpine/ChangeLog
@@ -0,0 +1,43 @@
+2010-01-23 Eric Belanger <eric@archlinux.org>
+
+ * alpine 2.00-7
+ * Updated patchset to level 53
+
+2009-09-18 Eric Belanger <eric@archlinux.org>
+
+ * alpine 2.00-6
+ * libldap-2.4 rebuild
+
+2009-09-18 Eric Belanger <eric@archlinux.org>
+
+ * alpine 2.00-5
+ * Updated patchset to level 52
+ * Security fix
+
+2009-09-17 Allan McRae <allan@archlinux.org>
+
+ * alpine 2.00-4
+ * libldap-2.4 rebuild
+
+2009-02-07 Eric Belanger <eric@archlinux.org>
+
+ * alpine 2.00-3
+ * Updated patchset to level 20
+
+2008-12-05 Eric Belanger <eric@archlinux.org>
+
+ * alpine 2.00-2
+ * Rebuilt against heimdal 1.2.1
+ * Placed copy of all.patch.gz patch on local ftp (close FS#11964)
+
+2008-09-04 Eric Belanger <eric@archlinux.org>
+
+ * alpine 2.00-1
+ * Upstream update
+ * Replaced install scriptlet with optdepends
+
+2008-03-26 Eric Belanger <eric@archlinux.org>
+
+ * alpine 1.10-1
+ * Upstream update
+ * Added ChangeLog
diff --git a/abs/extra-testing/alpine/PKGBUILD b/abs/extra-testing/alpine/PKGBUILD
new file mode 100644
index 0000000..1d75c85
--- /dev/null
+++ b/abs/extra-testing/alpine/PKGBUILD
@@ -0,0 +1,37 @@
+# $Id: PKGBUILD 64978 2010-01-23 22:24:15Z eric $
+# Maintainer: Eric Belanger <eric@archlinux.org>
+# Contributor: Fabio Scotoni <fabio@esse.ch>
+
+pkgname=alpine
+pkgver=2.00
+pkgrel=7
+_patchlevel=53
+pkgdesc="The Apache-licensed PINE (a tool for reading, sending, and managing electronic messages)"
+arch=('i686' 'x86_64')
+url="http://www.washington.edu/alpine/"
+license=('APACHE')
+depends=('libldap>=2.4.11' 'heimdal>=1.2.1' 'gettext')
+optdepends=('aspell: for spell-checking support')
+provides=('pine')
+conflicts=('pine')
+replaces=('pine')
+options=('!makeflags')
+source=(ftp://ftp.cac.washington.edu/${pkgname}/${pkgname}.tar.bz2 \
+ http://staff.washington.edu/chappa/alpine/patches/alpine-${pkgver}/all_${_patchlevel}.patch.gz \
+ 2.00-lpam.patch CVE-2008-5514.patch)
+md5sums=('84e44cbf71ed674800a5d57eed9c1c52' 'c4a85b865f59c095f838617d08b1b123'\
+ 'cd3911c16fc6a072e853c0ccfc35857c' '1b52a54a656979116c09fb1d948a4325')
+sha1sums=('dcbd3c5419954f484ccf706feaba31ce48cdebc4' '7396ed92062924c126087dc32b98ccebf98e17cc'\
+ '1b39525f91ebd5a9de5a1e04f5554f6fa5f58ae3' 'bc61d76a237ff42b00b3f60f2e6fc5c45e261dbb')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -p1 < ../all_${_patchlevel}.patch || return 1
+ patch -p1 < ../2.00-lpam.patch || return 1
+ patch -p1 < ../CVE-2008-5514.patch || return 1
+ ./configure --prefix=/usr --without-passfile --without-tcl \
+ --disable-shared --with-system-pinerc=/etc/alpine.d/pine.conf \
+ --with-system-fixed-pinerc=/etc/alpine.d/pine.conf.fixed || return 1
+ make || return 1
+ make DESTDIR="${pkgdir}" install || return 1
+}
diff --git a/abs/extra-testing/bluez/PKGBUILD b/abs/extra-testing/bluez/PKGBUILD
index 46af613..83ad50d 100644
--- a/abs/extra-testing/bluez/PKGBUILD
+++ b/abs/extra-testing/bluez/PKGBUILD
@@ -1,6 +1,6 @@
# Maintainer: Geoffroy Carrier <geoffroy@archlinux.org>
pkgname=bluez
-pkgver=4.62
+pkgver=4.63
pkgrel=1
pkgdesc="Libraries and tools for the Bluetooth protocol stack"
url="http://www.bluez.org/"
@@ -12,11 +12,13 @@ optdepends=('gstreamer0.10-base' 'alsa-lib' 'libusb')
conflicts=('bluez-libs' 'bluez-utils')
provides=('bluez-libs' 'bluez-utils')
replaces=('bluez-libs' 'bluez-utils')
+install='bluez.install'
backup=(etc/bluetooth/{main,rfcomm,audio,network,input}.conf
etc/conf.d/bluetooth)
source=("http://www.kernel.org/pub/linux/bluetooth/$pkgname-$pkgver.tar.bz2"
- 'bluetooth.conf.d'
- 'runit.bluetooth')
+ bluetooth.conf.d run.bluetoothd run.hidd run.dund run.pand
+ run.rfcomm)
+
build() {
cd "$srcdir/$pkgname-$pkgver"
./configure --prefix=/usr \
@@ -45,9 +47,17 @@ build() {
install -D -m644 "$srcdir/$pkgname-$pkgver/network/network.conf" "$pkgdir/etc/bluetooth/" || return 1
install -D -m644 "$srcdir/$pkgname-$pkgver/input/input.conf" "$pkgdir/etc/bluetooth/" || return 1
install -D -m644 "$srcdir/$pkgname-$pkgver/audio/audio.conf" "$pkgdir/etc/bluetooth/" || return 1
- install -D -m755 "$srcdir/runit.bluetooth" "$pkgdir/etc/sv/bluetooth/run" || return 1
- install -D -m644 "$srcdir/bluetooth.conf.d" "$pkgdir/etc/conf.d/bluetooth" || return 1
+ install -D -m644 "$srcdir/bluetooth.conf.d" "$pkgdir/etc/conf.d/bluetooth" || return 1
+ install -D -m755 "$srcdir/run.bluetoothd" "$pkgdir/etc/sv/bluetoothd/run" || return 1
+ install -D -m755 "$srcdir/run.hidd" "$pkgdir/etc/sv/hidd/run" || return 1
+ install -D -m755 "$srcdir/run.dund" "$pkgdir/etc/sv/dund/run" || return 1
+ install -D -m755 "$srcdir/run.pand" "$pkgdir/etc/sv/pand/run" || return 1
+ install -D -m755 "$srcdir/run.rfcomm" "$pkgdir/etc/sv/rfcomm/run" || return 1
}
-md5sums=('3c2187a97f5b43ae84b4bbd4b34671e0'
+md5sums=('bb388f3dbb69cd253f23fc32b0f49ffa'
'd12be5b494525bb1ba6eac5c3983dd3e'
- 'af1037c8e96dda60a1fea29140afb8f4')
+ '1c88fcd455920ad8ee0c7cae3fe15771'
+ 'a9c1b4da8b5a3969865272bd0fb01da2'
+ '89c073f43a074844b87e28103e48623d'
+ '8ee99afea417561d01012b8047fd06d5'
+ '934a9eaa25c275d18115068101fb75e8')
diff --git a/abs/extra-testing/bluez/__Changelog b/abs/extra-testing/bluez/__Changelog
index af8c597..124d0eb 100644
--- a/abs/extra-testing/bluez/__Changelog
+++ b/abs/extra-testing/bluez/__Changelog
@@ -2,3 +2,10 @@
I really have no idea how this bluetooth stuff works. If anyone wants to
take a stab at getting this working properly with runit, feel free. I
only need this package to get mythpywii working.
+
+2010-04-01:
+Make this package work with runit. All daemons were seperated into their
+own run scripts. Of particular interest is rfcomm and hid2hci utilities.
+They are not daemons and I added "/sbin/sv <executable> down ." in their
+respective run files. All based on this thread:
+http://article.gmane.org/gmane.comp.sysutils.supervision.general/1585/
diff --git a/abs/extra-testing/bluez/bluez.install b/abs/extra-testing/bluez/bluez.install
new file mode 100644
index 0000000..f9b757b
--- /dev/null
+++ b/abs/extra-testing/bluez/bluez.install
@@ -0,0 +1,15 @@
+post_install() {
+ add_service.sh bluetoothd
+ echo ">>> Only the bluetoothd daemon is started by default."
+ echo ">>> You can optionally add the following as required:"
+ echo ">>> hidd dund pand rfcomm"
+ echo ">>> $ sudo add_service.sh <service_name>"
+}
+
+pre_remove() {
+ for d in { bluetoothd,hidd,dund,pand,rfcomm } ; do
+ if [ -d /var/service/${d} ] ; then
+ remove_servcie.sh $d
+ fi
+ done
+}
diff --git a/abs/extra-testing/bluez/rc.bluetooth b/abs/extra-testing/bluez/rc.bluetooth
deleted file mode 100644
index 38b6216..0000000
--- a/abs/extra-testing/bluez/rc.bluetooth
+++ /dev/null
@@ -1,106 +0,0 @@
-#!/bin/sh
-#
-# Start/stop the Bluetooth daemons
-#
-
-. /etc/rc.conf
-. /etc/rc.d/functions
-
-DAEMON_NAME="bluetoothd"
-HID2HCI_NAME="hid2hci"
-HIDD_NAME="hidd"
-RFCOMM_NAME="rfcomm"
-PAND_NAME="pand"
-DUND_NAME="dund"
-
-DAEMON_EXEC="/usr/sbin/bluetoothd"
-HID2HCI_EXEC="/usr/sbin/hid2hci"
-HIDD_EXEC="/usr/bin/hidd"
-RFCOMM_EXEC="/usr/bin/rfcomm"
-PAND_EXEC="/usr/bin/pand"
-DUND_EXEC="/usr/bin/dund"
-
-DAEMON_ENABLE="true"
-HID2HCI_ENABLE="false"
-HIDD_ENABLE="false"
-RFCOMM_ENABLE="false"
-DUND_ENABLE="false"
-PAND_ENABLE="false"
-
-RFCOMM_CONFIG="/etc/bluetooth/rfcomm.conf"
-
-HIDD_OPTIONS=""
-DUND_OPTIONS=""
-PAND_OPTIONS=""
-
-[ -f /etc/conf.d/bluetooth ] && . /etc/conf.d/bluetooth
-
-case "$1" in
- start)
- stat_busy "Starting bluetooth subsystem:"
- if [ "$DAEMON_ENABLE" = "true" -a -x "$DAEMON_EXEC" ] ; then
- stat_append " $DAEMON_NAME"
- $DAEMON_EXEC
- fi
- if [ "$HID2HCI_ENABLE" = "true" -a -x "$HID2HCI_EXEC" ] ; then
- stat_append " $HID2HCI_NAME"
- $HID2HCI_EXEC --tohci > /dev/null 2>&1 || true
- fi
- if [ "$SDPD_ENABLE" = "true" -a -x "$SDPD_EXEC" ] ; then
- stat_append " $SDPD_NAME"
- $SDPD_EXEC
- fi
- if [ "$HIDD_ENABLE" = "true" -a -x "$HIDD_EXEC" ]; then
- stat_append " $HIDD_NAME"
- $HIDD_EXEC $HIDD_OPTIONS --server
- fi
- if [ "$RFCOMM_ENABLE" = "true" -a -x "$RFCOMM_EXEC" -a -f "$RFCOMM_CONFIG" ]; then
- stat_append " $RFCOMM_NAME"
- $RFCOMM_EXEC -f $RFCOMM_CONFIG bind all
- fi
- if [ "$DUND_ENABLE" = "true" -a -x "$DUND_EXEC" -a -n "$DUND_OPTIONS" ]; then
- stat_append " $DUND_NAME"
- $DUND_EXEC $DUND_OPTIONS
- fi
- if [ "$PAND_ENABLE" = "true" -a -x "$PAND_EXEC" -a -n "$PAND_OPTIONS" ]; then
- stat_append " $PAND_NAME"
- $PAND_EXEC $PAND_OPTIONS
- fi
- add_daemon bluetooth
- stat_done
- ;;
- stop)
- stat_busy "Stopping bluetooth subsystem:"
-
- stat_append " $PAND_NAME"
- killall $PAND_NAME >/dev/null 2>&1
-
- stat_append " $DUND_NAME"
- killall $DUND_NAME >/dev/null 2>&1
-
- if [ -x "$RFCOMM_EXEC" ]; then
- stat_append " $RFCOMM_NAME"
- $RFCOMM_EXEC release all >/dev/null 2>&1
- fi
-
- stat_append " $HIDD_NAME"
- killall $HIDD_NAME >/dev/null 2>&1
-
- stat_append " $SDPD_NAME"
- killall $SDPD_NAME >/dev/null 2>&1
-
- stat_append " $DAEMON_NAME"
- killall $DAEMON_NAME >/dev/null 2>&1
-
- rm_daemon bluetooth
- stat_done
- ;;
- restart)
- $0 stop
- sleep 1
- $0 start
- ;;
- *)
- echo "usage: $0 {start|stop|restart}"
-esac
-exit 0
diff --git a/abs/extra-testing/bluez/run.bluetoothd b/abs/extra-testing/bluez/run.bluetoothd
new file mode 100644
index 0000000..7a92437
--- /dev/null
+++ b/abs/extra-testing/bluez/run.bluetoothd
@@ -0,0 +1,12 @@
+#!/bin/sh
+#
+# Start/stop the Bluetooth daemons
+#
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+[ -f /etc/conf.d/bluetooth ] && . /etc/conf.d/bluetooth
+
+ stat_runit "Starting bluetooth subsystem:"
+ exec /usr/sbin/bluetoothd -n
diff --git a/abs/extra-testing/bluez/run.dund b/abs/extra-testing/bluez/run.dund
new file mode 100644
index 0000000..c42cfa1
--- /dev/null
+++ b/abs/extra-testing/bluez/run.dund
@@ -0,0 +1,14 @@
+#!/bin/sh
+#
+# Start/stop the Bluetooth daemons
+#
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+[ -f /etc/conf.d/bluetooth ] && . /etc/conf.d/bluetooth
+
+svwaitup -s 3 /var/service/bluetoothd || exit 1
+
+ stat_runit "Starting BlueZ Bluetooth dial-up networking daemon"
+ exec /usr/bin/dund -n -s
diff --git a/abs/extra-testing/bluez/run.hidd b/abs/extra-testing/bluez/run.hidd
new file mode 100644
index 0000000..e4f66d3
--- /dev/null
+++ b/abs/extra-testing/bluez/run.hidd
@@ -0,0 +1,14 @@
+#!/bin/sh
+#
+# Start/stop the Bluetooth daemons
+#
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+[ -f /etc/conf.d/bluetooth ] && . /etc/conf.d/bluetooth
+
+svwaitup -s 3 /var/service/bluetoothd || exit 1
+
+ stat_runit "Starting Bluetooth HID daemon:"
+ exec /usr/bin/hidd -n --server
diff --git a/abs/extra-testing/bluez/run.pand b/abs/extra-testing/bluez/run.pand
new file mode 100644
index 0000000..ab15ef6
--- /dev/null
+++ b/abs/extra-testing/bluez/run.pand
@@ -0,0 +1,14 @@
+#!/bin/sh
+#
+# Start/stop the Bluetooth daemons
+#
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+[ -f /etc/conf.d/bluetooth ] && . /etc/conf.d/bluetooth
+
+svwaitup -s 3 /var/service/bluetoothd || exit 1
+
+ stat_runit "Starting BlueZ Bluetooth PAN daemon"
+ exec /usr/bin/pand -n -s
diff --git a/abs/extra-testing/bluez/run.rfcomm b/abs/extra-testing/bluez/run.rfcomm
new file mode 100644
index 0000000..8bc619b
--- /dev/null
+++ b/abs/extra-testing/bluez/run.rfcomm
@@ -0,0 +1,17 @@
+#!/bin/sh
+#
+# Start/stop the Bluetooth daemons
+#
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+[ -f /etc/conf.d/bluetooth ] && . /etc/conf.d/bluetooth
+
+RFCOMM_CONFIG="/etc/bluetooth/rfcomm.conf"
+
+svwaitup -s 3 /var/service/bluetoothd || exit 1
+
+ stat_runit "Starting RFCOMM for the bluetooth subsystem"
+ /usr/bin/rfcomm -f $RFCOMM_CONFIG bind all
+ /sbin/sv down .
diff --git a/abs/extra-testing/bluez/runit.bluetooth b/abs/extra-testing/bluez/runit.bluetooth
deleted file mode 100644
index 4b443db..0000000
--- a/abs/extra-testing/bluez/runit.bluetooth
+++ /dev/null
@@ -1,65 +0,0 @@
-#!/bin/sh
-#
-# Start/stop the Bluetooth daemons
-#
-
-. /etc/rc.conf
-. /etc/rc.d/functions
-
-DAEMON_NAME="bluetoothd"
-HID2HCI_NAME="hid2hci"
-HIDD_NAME="hidd"
-RFCOMM_NAME="rfcomm"
-PAND_NAME="pand"
-DUND_NAME="dund"
-
-DAEMON_EXEC="/usr/sbin/bluetoothd -n"
-HID2HCI_EXEC="/usr/sbin/hid2hci"
-HIDD_EXEC="/usr/bin/hidd"
-RFCOMM_EXEC="/usr/bin/rfcomm"
-PAND_EXEC="/usr/bin/pand"
-DUND_EXEC="/usr/bin/dund"
-
-DAEMON_ENABLE="true"
-HID2HCI_ENABLE="false"
-HIDD_ENABLE="false"
-RFCOMM_ENABLE="false"
-DUND_ENABLE="false"
-PAND_ENABLE="false"
-
-RFCOMM_CONFIG="/etc/bluetooth/rfcomm.conf"
-
-HIDD_OPTIONS="-n"
-DUND_OPTIONS="-n"
-PAND_OPTIONS="-n"
-
-[ -f /etc/conf.d/bluetooth ] && . /etc/conf.d/bluetooth
-
- stat_runit "Starting bluetooth subsystem:"
- if [ "$DAEMON_ENABLE" = "true" -a -x "$DAEMON_EXEC" ] ; then
- exec $DAEMON_EXEC
- fi
-# if [ "$HID2HCI_ENABLE" = "true" -a -x "$HID2HCI_EXEC" ] ; then
-# stat_append " $HID2HCI_NAME"
-# $HID2HCI_EXEC --tohci > /dev/null 2>&1 || true
-# fi
-# if [ "$SDPD_ENABLE" = "true" -a -x "$SDPD_EXEC" ] ; then
-# stat_append " $SDPD_NAME"
-# $SDPD_EXEC
-# fi
-# if [ "$HIDD_ENABLE" = "true" -a -x "$HIDD_EXEC" ]; then
-# stat_append " $HIDD_NAME"
-# $HIDD_EXEC $HIDD_OPTIONS --server
-# fi
-# if [ "$RFCOMM_ENABLE" = "true" -a -x "$RFCOMM_EXEC" -a -f "$RFCOMM_CONFIG" ]; then
-# stat_append " $RFCOMM_NAME"
-# $RFCOMM_EXEC -f $RFCOMM_CONFIG bind all
-# fi
-# if [ "$DUND_ENABLE" = "true" -a -x "$DUND_EXEC" -a -n "$DUND_OPTIONS" ]; then
-# stat_append " $DUND_NAME"
-# $DUND_EXEC $DUND_OPTIONS
-# fi
-# if [ "$PAND_ENABLE" = "true" -a -x "$PAND_EXEC" -a -n "$PAND_OPTIONS" ]; then
-# stat_append " $PAND_NAME"
-# $PAND_EXEC $PAND_OPTIONS
-# fi
diff --git a/abs/extra-testing/community/mythtv-contrib/PKGBUILD b/abs/extra-testing/community/mythtv-contrib/PKGBUILD
index e4a84f7..4e5bf12 100644
--- a/abs/extra-testing/community/mythtv-contrib/PKGBUILD
+++ b/abs/extra-testing/community/mythtv-contrib/PKGBUILD
@@ -1,8 +1,8 @@
# Contributor: Michael Hanson <hansonorders@verizon.net>
# Maintainer: Michael Hanson <hansonorders@verizon.net>
pkgname=mythtv-contrib
-pkgver=0.22
-pkgrel=1
+pkgver=0.23
+pkgrel=2
pkgdesc="User contributed scripts and utilities for mythtv."
arch=('i686' 'x86_64')
url="http://mythtv.org"
@@ -16,7 +16,7 @@ source=('http://www.pdp8.net/directv/directv.pl' \
'mythchanger.10f.beta.tar')
patches=('sa3250cmd_make.patch' '6200ch.c.r21651.patch'
'mythchanger_make.patch')
-_svntrunk=http://cvs.mythtv.org/svn/branches/release-0-22-fixes/mythtv/contrib
+_svntrunk=http://cvs.mythtv.org/svn/branches/release-0-23-fixes/mythtv/contrib
_svnver=23566
_svnmod=contrib
@@ -46,7 +46,7 @@ build() {
cd $srcdir/contrib/channel_changers/dct-channel || return 1
make || return 1
install -D -m755 channel $startdir/pkg/usr/bin || return 1
- install -D -m644 channel.1 $startdir/pkg/usr/man/man1 || return 1
+ install -D -m644 channel.1 $startdir/pkg/usr/man/man1/channel.1 || return 1
install -D -m644 README $startdir/pkg/usr/share/doc/mythtv-contrib/README.dct-channel
install -D -m644 COPYING $startdir/pkg/usr/share/licenses/mythtv-contrib/COPYING.dct-channel
@@ -71,6 +71,7 @@ build() {
cd $srcdir/contrib/development/tsc-calibrate || return 1
gcc -o tsc-calibrate tsc-calibrate.c || return 1
+ install -D -m755 tsc-calibrate $startdir/pkg/usr/bin || return 1
cd $srcdir/contrib/info/mythname || return 1
install -D -m755 mythname.pl $startdir/pkg/usr/bin || return 1
diff --git a/abs/extra-testing/community/transmission-cli/PKGBUILD b/abs/extra-testing/community/transmission-cli/PKGBUILD
index 6cbe7e5..5a25df8 100644
--- a/abs/extra-testing/community/transmission-cli/PKGBUILD
+++ b/abs/extra-testing/community/transmission-cli/PKGBUILD
@@ -4,7 +4,7 @@
pkgname=transmission-cli
pkgver=1.92
-pkgrel=1
+pkgrel=3
pkgdesc="Fast, easy, and free BitTorrent client (CLI tools, daemon and web client)"
arch=('i686' 'x86_64')
url="http://www.transmissionbt.com/"
@@ -15,9 +15,9 @@ replaces=('transmission')
backup=('etc/conf.d/transmissiond')
install=transmission-cli.install
source=(http://mirrors.m0k.org/transmission/files/transmission-$pkgver.tar.bz2
- run
- finish
+ run.transmissiond
transmission-cli.install
+ transmission.include
transmissiond.conf)
build() {
@@ -29,14 +29,13 @@ build() {
mkdir -p -m744 "$pkgdir/etc/sv/transmissiond" || return 1
mkdir -p -m777 "$pkgdir/myth/transmission" || return 1
- install -D -m755 "$srcdir/run" "$pkgdir/etc/sv/transmissiond/run" || return 1
- install -D -m755 "$srcdir/finish" "$pkgdir/etc/sv/transmissiond/finish" || return 1
+ install -D -m755 "$srcdir/run.transmissiond" "$pkgdir/etc/sv/transmissiond/run" || return 1
install -D -m644 "$srcdir/transmissiond.conf" "$pkgdir/etc/conf.d/transmissiond" || return 1
-
+ install -D -m644 "$srcdir/transmission.include" "$pkgdir/etc/transmission/transmission.include" || return 1
install -D -m644 COPYING "$pkgdir/usr/share/licenses/transmission-cli/COPYING" || return 1
}
md5sums=('561357621331f294c87f78e22783a283'
- 'fd5ec0a496b6833074fd125b1fb70e47'
- 'f0e4e06f7307c75ceda6ccd4e74975b5'
- 'f1a15f339515f522c5895e6f40491a46'
+ 'b91534aaf2e403331c611c615ab2c03d'
+ 'ff22c13dbd52565f9e88b1de22514eb9'
+ 'b5a49ea375333cd0fee40f70dbac4c2e'
'd05567c7a4f9df9f28602d1356d5c05c')
diff --git a/abs/extra-testing/community/transmission-cli/finish b/abs/extra-testing/community/transmission-cli/finish
deleted file mode 100755
index 7a09e4f..0000000
--- a/abs/extra-testing/community/transmission-cli/finish
+++ /dev/null
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-. /etc/rc.conf
-. /etc/rc.d/functions
-. /etc/conf.d/transmissiond
-
-PID=`pidof -o %PPID /usr/bin/transmission-daemon`
- stat_runit "Stopping Transmission Daemon"
- [ ! -z "$PID" ] && kill $PID &> /dev/null
- if [ $? -ne 0 ]; then
- stat_fail
- else
- rm_daemon transmissiond
- stat_done
- fi
diff --git a/abs/extra-testing/community/transmission-cli/run b/abs/extra-testing/community/transmission-cli/run.transmissiond
index 6bcab36..714c946 100755
--- a/abs/extra-testing/community/transmission-cli/run
+++ b/abs/extra-testing/community/transmission-cli/run.transmissiond
@@ -26,10 +26,4 @@ PID=`pidof -o %PPID /usr/bin/transmission-daemon`
cd - 2>&1 >/dev/null
fi
stat_runit "Starting Transmission Daemon"
- [ -z "$PID" ] && su -l -c "/usr/bin/nice -n 19 /usr/bin/transmission-daemon $TRANS_OPTS" $TRANS_USER 2>/dev/null
- if [ $? -ne 0 ]; then
- stat_fail
- else
- add_daemon transmissiond
- stat_done
- fi
+ [ -z "$PID" ] && exec su -l -c "/usr/bin/nice -n 19 /usr/bin/transmission-daemon $TRANS_OPTS" $TRANS_USER 2>/dev/null
diff --git a/abs/extra-testing/community/transmission-cli/transmission-cli.install b/abs/extra-testing/community/transmission-cli/transmission-cli.install
index d69601d..088ecc6 100644
--- a/abs/extra-testing/community/transmission-cli/transmission-cli.install
+++ b/abs/extra-testing/community/transmission-cli/transmission-cli.install
@@ -1,19 +1,28 @@
post_install() {
+ /bin/echo 'include "/etc/transmission/transmission.include"' >> /etc/lighttpd/conf.include
+ killall -HUP lighttpd
+
+ add_service.sh transmissiond
+
cat << _EOF
- If you want to run the Transmission daemon at boot,
- run add_service.sh transmissiond as root.
-
You can edit the user and options in /etc/conf.d/transmissiond.
- There is a lot of good information on setting up a web
- interface proxy through lighttpd at:
- http://mybookworld.wikidot.com/transmission
+ To access the web interface:
+ http://localhost/transmission
Configuration file editing information can be found at:
http://trac.transmissionbt.com/wiki/ConfigFiles
-
_EOF
}
+
+pre_upgrade() {
+ rm -f /usr/share/man/man1/transmission*
+
+}
+
+pre_remove() {
+ remove_service.sh transmissiond
+}
diff --git a/abs/extra-testing/community/transmission-cli/transmission.include b/abs/extra-testing/community/transmission-cli/transmission.include
new file mode 100644
index 0000000..5cbf399
--- /dev/null
+++ b/abs/extra-testing/community/transmission-cli/transmission.include
@@ -0,0 +1,15 @@
+#Redirect from /transmission to /transmission/web
+url.rewrite-once += ( "^/transmission[/]?$" => "/transmission/web" )
+$HTTP["url"] =~ "^/transmission/" {
+ #Serve static files from /usr/share/transmission
+ server.document-root = "/usr/share/"
+ #Forward RPC requests to the Transmission daemon
+ proxy.server = (
+ "/transmission/rpc" => (
+ (
+ "host" => "127.0.0.1",
+ "port" => 9091
+ )
+ )
+ )
+}
diff --git a/abs/extra-testing/gnupg/PKGBUILD b/abs/extra-testing/gnupg/PKGBUILD
new file mode 100644
index 0000000..cb980ce
--- /dev/null
+++ b/abs/extra-testing/gnupg/PKGBUILD
@@ -0,0 +1,25 @@
+# $Id: PKGBUILD 52155 2009-09-16 11:08:07Z allan $
+# Maintainer: Andreas Radke <andyrtr at archlinux.org>
+# Committer: Judd Vinet <jvinet@zeroflux.org>
+pkgname=gnupg
+pkgver=1.4.10
+pkgrel=2
+pkgdesc="GNU Privacy Guard - a PGP replacement tool"
+arch=('i686' 'x86_64')
+license=('GPL3')
+depends=('zlib' 'bzip2' 'libldap>=2.4.11' 'libusb' 'curl>=7.16.2' 'readline>=5.0.00')
+source=(ftp://ftp.franken.de/pub/crypt/mirror/ftp.gnupg.org/gcrypt/gnupg/$pkgname-$pkgver.tar.bz2)
+install=gnupg.install
+url="http://www.gnupg.org/"
+md5sums=('dcf7ed712997888d616e029637bfc303')
+
+build() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+ ./configure --prefix=/usr --libexecdir=/usr/lib # docdir can't be set properly
+ make || return 1
+ ln -s ${pkgname}-${pkgver}/scripts ..
+ make DESTDIR=${pkgdir} install || return 1
+
+ # fix fileconflict with gnupg2 pkg
+ rm ${pkgdir}/usr/share/man/man1/gpg-zip.1
+}
diff --git a/abs/extra-testing/gnupg/gnupg.install b/abs/extra-testing/gnupg/gnupg.install
new file mode 100644
index 0000000..5a67047
--- /dev/null
+++ b/abs/extra-testing/gnupg/gnupg.install
@@ -0,0 +1,21 @@
+info_dir=/usr/share/info
+info_files=(gnupg1.info)
+
+post_install() {
+ [ -x usr/bin/install-info ] || return 0
+ for f in ${info_files[@]}; do
+ usr/bin/install-info ${info_dir}/$f.gz ${info_dir}/dir 2> /dev/null
+ done
+}
+
+post_upgrade() {
+ post_install $1
+}
+
+pre_remove() {
+ [ -x usr/bin/install-info ] || return 0
+ for f in ${info_files[@]}; do
+ usr/bin/install-info --delete ${info_dir}/$f.gz ${info_dir}/dir 2> /dev/null
+ done
+}
+# vim:set ts=2 sw=2 et:
diff --git a/abs/extra-testing/gpgme/PKGBUILD b/abs/extra-testing/gpgme/PKGBUILD
new file mode 100644
index 0000000..ce03d89
--- /dev/null
+++ b/abs/extra-testing/gpgme/PKGBUILD
@@ -0,0 +1,25 @@
+# $Id: PKGBUILD 48153 2009-07-31 20:34:25Z tpowa $
+# Maintainer: Roman Kyrylych <roman@archlinux.org>
+# Contributor: Sarah Hay <sarah@archlinux.org>
+
+pkgname=gpgme
+pkgver=1.2.0
+pkgrel=1
+pkgdesc="A C wrapper library for GnuPG."
+arch=('i686' 'x86_64')
+url="http://www.gnupg.org/related_software/gpgme/"
+license=('GPL')
+depends=('libgpg-error>=1.5' 'pth' 'gnupg')
+install=gpgme.install
+options=('!libtool' '!emptydirs')
+source=(ftp://ftp.gnupg.org/gcrypt/${pkgname}/${pkgname}-${pkgver}.tar.gz)
+md5sums=('3164bbbd49f94863f2849f39c343521e')
+
+build() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+ ./configure --prefix=/usr
+ make || return 1
+ make DESTDIR=${pkgdir} install
+ rm ${pkgdir}/usr/share/info/dir
+ gzip ${pkgdir}/usr/share/info/*
+}
diff --git a/abs/extra-testing/gpgme/__changelog b/abs/extra-testing/gpgme/__changelog
new file mode 100644
index 0000000..4074d1b
--- /dev/null
+++ b/abs/extra-testing/gpgme/__changelog
@@ -0,0 +1 @@
+removed gnupg2 requirement
diff --git a/abs/extra-testing/gpgme/gpgme.install b/abs/extra-testing/gpgme/gpgme.install
new file mode 100644
index 0000000..b54620d
--- /dev/null
+++ b/abs/extra-testing/gpgme/gpgme.install
@@ -0,0 +1,18 @@
+infodir=/usr/share/info
+filelist=(gpgme.info gpgme.info-1 gpgme.info-2)
+
+post_install() {
+ for file in ${filelist[@]}; do
+ install-info $infodir/$file $infodir/dir 2> /dev/null
+ done
+}
+
+post_upgrade() {
+ post_install $1
+}
+
+pre_remove() {
+ for file in ${filelist[@]}; do
+ install-info --delete $infodir/$file $infodir/dir 2> /dev/null
+ done
+}
diff --git a/abs/extra-testing/lcdproc/PKGBUILD b/abs/extra-testing/lcdproc/PKGBUILD
index 7ee6e50..e5cc719 100644
--- a/abs/extra-testing/lcdproc/PKGBUILD
+++ b/abs/extra-testing/lcdproc/PKGBUILD
@@ -1,29 +1,26 @@
# Contributor: Bernhard Walle <bernhard.walle@gmx.de>
pkgname=lcdproc
-pkgver=0.5.2
-pkgrel=2
+pkgver=0.5.3
+pkgrel=3
pkgdesc="LCDproc is a utility to drive one or more LCD (and LCD-like) devices attached to a host."
url="http://lcdproc.omnipotent.net/"
license="GPL"
depends=(libusb serdisplib libftdi autoconf automake lirc libnxml libmrss pkgconfig xosd)
backup=(etc/LCDd.conf)
arch=(i686 x86_64)
+install=lcdproc.install
source=(http://switch.dl.sourceforge.net/sourceforge/$pkgname/$pkgname-$pkgver.tar.gz
- lcdd
lcdproc-add-serdisplib
)
-md5sums=('860f192d061d87dda6512b11b79daac2'
- '56f52dcccd6e129a9cf84cd1a0452d56'
- '274322642740ad323c43ec5d324519d4')
build() {
cd $startdir/src/$pkgname-$pkgver
- patch -p1 < ../lcdproc-add-serdisplib
+# patch -p1 < ../lcdproc-add-serdisplib
autoreconf
./configure --prefix=/usr --sysconfdir=/etc --enable-libusb --enable-lcdproc-menus --enable-stat-smbfs --enable-drivers=all
make
make DESTDIR=$startdir/pkg install
- sed -e "s/server\/drivers\//\/usr\/lib\/lcdproc\//g" LCDd.conf > $startdir/pkg/etc/LCDd.conf
- mkdir -p $startdir/pkg/etc/rc.d
- install -m 755 $startdir/src/lcdd $startdir/pkg/etc/rc.d
+ sed -e "s/server\/drivers\//\/usr\/lib\/lcdproc\//g" LCDd.conf > $pkgdir/etc/LCDd.conf
}
+md5sums=('fe9a7c9d8f2c5e76250ce2ea8f644921'
+ '274322642740ad323c43ec5d324519d4')
diff --git a/abs/extra-testing/lcdproc/__changelog b/abs/extra-testing/lcdproc/__changelog
index 52c2d35..96fd954 100644
--- a/abs/extra-testing/lcdproc/__changelog
+++ b/abs/extra-testing/lcdproc/__changelog
@@ -1 +1,4 @@
-add xosd \ No newline at end of file
+add xosd
+# mihanson 2010-04-05
+updated to 0.5.3
+removed lcdproc-add-serdisplib as it does not appear to be needed anymore
diff --git a/abs/extra-testing/lcdproc/lcdd b/abs/extra-testing/lcdproc/lcdd
deleted file mode 100755
index a124c00..0000000
--- a/abs/extra-testing/lcdproc/lcdd
+++ /dev/null
@@ -1,38 +0,0 @@
-#!/bin/bash
-
-. /etc/rc.conf
-. /etc/rc.d/functions
-
-PID=`pidof -o %PPID /usr/sbin/LCDd`
-case "$1" in
- start)
- stat_busy "Starting LCDd daemon"
- [ -z "$PID" ] && /usr/sbin/LCDd -c /etc/LCDd.conf
- if [ $? -gt 0 ]; then
- stat_fail
- else
- echo $PID > /var/run/lcdd.pid
- add_daemon lcdd
- stat_done
- fi
- ;;
- stop)
- stat_busy "Stopping LCDd daemon"
- [ ! -z "$PID" ] && kill $PID &> /dev/null
- if [ $? -gt 0 ]; then
- stat_fail
- else
- rm /var/run/lcdd.pid
- rm_daemon lcdd
- stat_done
- fi
- ;;
- restart)
- $0 stop
- sleep 1
- $0 start
- ;;
- *)
- echo "usage: $0 {start|stop|restart}"
-esac
-exit 0
diff --git a/abs/extra-testing/lcdproc/lcdproc.install b/abs/extra-testing/lcdproc/lcdproc.install
new file mode 100644
index 0000000..bd3c85e
--- /dev/null
+++ b/abs/extra-testing/lcdproc/lcdproc.install
@@ -0,0 +1,7 @@
+post_install() {
+ add_service.sh lcdd
+}
+
+pre_remove() {
+ remove_service.sh lcdd
+}
diff --git a/abs/extra-testing/mime-types/PKGBUILD b/abs/extra-testing/mime-types/PKGBUILD
new file mode 100644
index 0000000..563857d
--- /dev/null
+++ b/abs/extra-testing/mime-types/PKGBUILD
@@ -0,0 +1,17 @@
+# $Id: PKGBUILD 35674 2009-04-15 05:29:19Z eric $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+pkgname=mime-types
+pkgver=1.0
+pkgrel=2
+pkgdesc="Provides /etc/mime.types"
+arch=('i686' 'x86_64')
+url="http://www.archlinux.org/"
+license=('GPL2')
+backup=('etc/mime.types')
+source=(mime.types)
+md5sums=('aa90248272ba2e9dca0a243746686739')
+
+build() {
+ cd ${srcdir}
+ install -D -m644 mime.types ${pkgdir}/etc/mime.types || return 1
+}
diff --git a/abs/extra-testing/mime-types/mime.types b/abs/extra-testing/mime-types/mime.types
new file mode 100644
index 0000000..5a6bbd4
--- /dev/null
+++ b/abs/extra-testing/mime-types/mime.types
@@ -0,0 +1,758 @@
+###############################################################################
+#
+# MIME-TYPES and the extensions that represent them
+#
+# This file is part of the mime-types package, which is based on
+# gentoo's "app-misc/mime-types". If you would like new types and/or
+# extensions to be added here, please file a bug on http://bugs.archlinux.org
+#
+# The reason that all types are managed by the mime-support package instead
+# allowing individual packages to install types in much the same way as they
+# add entries in to the mailcap file is so these types can be referenced by
+# other programs (such as a web server) even if the specific support package
+# for that type is not installed.
+#
+# Users can add their own types if they wish by creating a ".mime.types"
+# file in their home directory. Definitions included there will take
+# precedence over those listed here.
+#
+# Note: Compression schemes like "gzip", "bzip", and "compress" are not
+# actually "mime-types". They are "encodings" and hence must _not_ have
+# entries in this file to map their extensions. The "mime-type" of an
+# encoded file refers to the type of data that has been encoded, not the
+# type of encoding.
+#
+###############################################################################
+
+
+application/activemessage
+application/andrew-inset ez
+application/applefile
+application/atomicmail
+application/batch-SMTP
+application/beep+xml
+application/cals-1840
+application/commonground
+application/cu-seeme cu
+application/cybercash
+application/dca-rft
+application/dec-dx
+application/docbook+xml
+application/dsptype tsp
+application/dvcs
+application/edi-consent
+application/edi-x12
+application/edifact
+application/eshop
+application/font-tdpfr
+application/futuresplash spl
+application/ghostview
+application/hta hta
+application/http
+application/hyperstudio
+application/iges
+application/index
+application/index.cmd
+application/index.obj
+application/index.response
+application/index.vnd
+application/iotp
+application/ipp
+application/isup
+application/java-archive jar
+application/java-serialized-object ser
+application/java-vm class
+application/mac-binhex40 hqx
+application/mac-compactpro cpt
+application/macwriteii
+application/marc
+application/mathematica nb
+application/mathematica-old
+application/msaccess mdb
+application/msword doc dot
+application/news-message-id
+application/news-transmission
+application/ocsp-request
+application/ocsp-response
+application/octet-stream bin
+application/oda oda
+application/ogg ogg
+application/parityfec
+application/pdf pdf
+application/pgp-encrypted
+application/pgp-keys key
+application/pgp-signature pgp
+application/pics-rules prf
+application/pkcs10
+application/pkcs7-mime
+application/pkcs7-signature
+application/pkix-cert
+application/pkix-crl
+application/pkixcmp
+application/postscript ps ai eps
+application/prs.alvestrand.titrax-sheet
+application/prs.cww
+application/prs.nprend
+application/qsig
+application/rar rar
+application/rdf+xml rdf
+application/remote-printing
+application/riscos
+application/rss+xml rss
+application/rtf
+application/sdp
+application/set-payment
+application/set-payment-initiation
+application/set-registration
+application/set-registration-initiation
+application/sgml
+application/sgml-open-catalog
+application/sieve
+application/slate
+application/smil smi smil
+application/timestamp-query
+application/timestamp-reply
+application/vemmi
+application/whoispp-query
+application/whoispp-response
+application/wita
+application/wordperfect wpd
+application/wordperfect5.1 wp5
+application/x400-bp
+application/xhtml+xml xhtml xht
+application/xml xml xsl
+application/xml-dtd
+application/xml-external-parsed-entity
+application/zip zip
+application/vnd.3M.Post-it-Notes
+application/vnd.accpac.simply.aso
+application/vnd.accpac.simply.imp
+application/vnd.acucobol
+application/vnd.aether.imp
+application/vnd.anser-web-certificate-issue-initiation
+application/vnd.anser-web-funds-transfer-initiation
+application/vnd.audiograph
+application/vnd.bmi
+application/vnd.businessobjects
+application/vnd.canon-cpdl
+application/vnd.canon-lips
+application/vnd.cinderella cdy
+application/vnd.claymore
+application/vnd.commerce-battelle
+application/vnd.commonspace
+application/vnd.comsocaller
+application/vnd.contact.cmsg
+application/vnd.cosmocaller
+application/vnd.ctc-posml
+application/vnd.cups-postscript
+application/vnd.cups-raster
+application/vnd.cups-raw
+application/vnd.cybank
+application/vnd.dna
+application/vnd.dpgraph
+application/vnd.dxr
+application/vnd.ecdis-update
+application/vnd.ecowin.chart
+application/vnd.ecowin.filerequest
+application/vnd.ecowin.fileupdate
+application/vnd.ecowin.series
+application/vnd.ecowin.seriesrequest
+application/vnd.ecowin.seriesupdate
+application/vnd.enliven
+application/vnd.epson.esf
+application/vnd.epson.msf
+application/vnd.epson.quickanime
+application/vnd.epson.salt
+application/vnd.epson.ssf
+application/vnd.ericsson.quickcall
+application/vnd.eudora.data
+application/vnd.fdf
+application/vnd.ffsns
+application/vnd.flographit
+application/vnd.framemaker
+application/vnd.fsc.weblaunch
+application/vnd.fujitsu.oasys
+application/vnd.fujitsu.oasys2
+application/vnd.fujitsu.oasys3
+application/vnd.fujitsu.oasysgp
+application/vnd.fujitsu.oasysprs
+application/vnd.fujixerox.ddd
+application/vnd.fujixerox.docuworks
+application/vnd.fujixerox.docuworks.binder
+application/vnd.fut-misnet
+application/vnd.grafeq
+application/vnd.groove-account
+application/vnd.groove-identity-message
+application/vnd.groove-injector
+application/vnd.groove-tool-message
+application/vnd.groove-tool-template
+application/vnd.groove-vcard
+application/vnd.hhe.lesson-player
+application/vnd.hp-HPGL
+application/vnd.hp-PCL
+application/vnd.hp-PCLXL
+application/vnd.hp-hpid
+application/vnd.hp-hps
+application/vnd.httphone
+application/vnd.hzn-3d-crossword
+application/vnd.ibm.MiniPay
+application/vnd.ibm.afplinedata
+application/vnd.ibm.modcap
+application/vnd.informix-visionary
+application/vnd.intercon.formnet
+application/vnd.intertrust.digibox
+application/vnd.intertrust.nncp
+application/vnd.intu.qbo
+application/vnd.intu.qfx
+application/vnd.irepository.package+xml
+application/vnd.is-xpr
+application/vnd.japannet-directory-service
+application/vnd.japannet-jpnstore-wakeup
+application/vnd.japannet-payment-wakeup
+application/vnd.japannet-registration
+application/vnd.japannet-registration-wakeup
+application/vnd.japannet-setstore-wakeup
+application/vnd.japannet-verification
+application/vnd.japannet-verification-wakeup
+application/vnd.koan
+application/vnd.lotus-1-2-3
+application/vnd.lotus-approach
+application/vnd.lotus-freelance
+application/vnd.lotus-notes
+application/vnd.lotus-organizer
+application/vnd.lotus-screencam
+application/vnd.lotus-wordpro
+application/vnd.mcd
+application/vnd.mediastation.cdkey
+application/vnd.meridian-slingshot
+application/vnd.mif
+application/vnd.minisoft-hp3000-save
+application/vnd.mitsubishi.misty-guard.trustweb
+application/vnd.mobius.daf
+application/vnd.mobius.dis
+application/vnd.mobius.msl
+application/vnd.mobius.plc
+application/vnd.mobius.txf
+application/vnd.motorola.flexsuite
+application/vnd.motorola.flexsuite.adsi
+application/vnd.motorola.flexsuite.fis
+application/vnd.motorola.flexsuite.gotap
+application/vnd.motorola.flexsuite.kmr
+application/vnd.motorola.flexsuite.ttc
+application/vnd.motorola.flexsuite.wem
+application/vnd.mozilla.xul+xml xul
+application/vnd.ms-artgalry
+application/vnd.ms-asf
+application/vnd.ms-excel xls xlb xlt
+application/vnd.ms-lrm
+application/vnd.ms-pki.seccat cat
+application/vnd.ms-pki.stl stl
+application/vnd.ms-powerpoint ppt pps
+application/vnd.ms-project
+application/vnd.ms-tnef
+application/vnd.ms-works
+application/vnd.mseq
+application/vnd.msign
+application/vnd.music-niff
+application/vnd.musician
+application/vnd.netfpx
+application/vnd.noblenet-directory
+application/vnd.noblenet-sealer
+application/vnd.noblenet-web
+application/vnd.novadigm.EDM
+application/vnd.novadigm.EDX
+application/vnd.novadigm.EXT
+application/vnd.oasis.opendocument.chart odc
+application/vnd.oasis.opendocument.database odb
+application/vnd.oasis.opendocument.formula odf
+application/vnd.oasis.opendocument.graphics odg
+application/vnd.oasis.opendocument.graphics-template otg
+application/vnd.oasis.opendocument.image odi
+application/vnd.oasis.opendocument.presentation odp
+application/vnd.oasis.opendocument.presentation-template otp
+application/vnd.oasis.opendocument.spreadsheet ods
+application/vnd.oasis.opendocument.spreadsheet-template ots
+application/vnd.oasis.opendocument.text odt
+application/vnd.oasis.opendocument.text-master odm
+application/vnd.oasis.opendocument.text-template ott
+application/vnd.oasis.opendocument.text-web oth
+application/vnd.osa.netdeploy
+application/vnd.palm
+application/vnd.pg.format
+application/vnd.pg.osasli
+application/vnd.powerbuilder6
+application/vnd.powerbuilder6-s
+application/vnd.powerbuilder7
+application/vnd.powerbuilder7-s
+application/vnd.powerbuilder75
+application/vnd.powerbuilder75-s
+application/vnd.previewsystems.box
+application/vnd.publishare-delta-tree
+application/vnd.pvi.ptid1
+application/vnd.pwg-xhtml-print+xml
+application/vnd.rapid
+application/vnd.rim.cod cod
+application/vnd.s3sms
+application/vnd.seemail
+application/vnd.shana.informed.formdata
+application/vnd.shana.informed.formtemplate
+application/vnd.shana.informed.interchange
+application/vnd.shana.informed.package
+application/vnd.smaf mmf
+application/vnd.sss-cod
+application/vnd.sss-dtf
+application/vnd.sss-ntf
+application/vnd.stardivision.calc sdc
+application/vnd.stardivision.draw sda
+application/vnd.stardivision.impress sdd sdp
+application/vnd.stardivision.math smf
+application/vnd.stardivision.writer sdw vor
+application/vnd.stardivision.writer-global sgl
+application/vnd.street-stream
+application/vnd.sun.xml.calc sxc
+application/vnd.sun.xml.calc.template stc
+application/vnd.sun.xml.draw sxd
+application/vnd.sun.xml.draw.template std
+application/vnd.sun.xml.impress sxi
+application/vnd.sun.xml.impress.template sti
+application/vnd.sun.xml.math sxm
+application/vnd.sun.xml.writer sxw
+application/vnd.sun.xml.writer.global sxg
+application/vnd.sun.xml.writer.template stw
+application/vnd.svd
+application/vnd.swiftview-ics
+application/vnd.symbian.install sis
+application/vnd.triscape.mxs
+application/vnd.trueapp
+application/vnd.truedoc
+application/vnd.tve-trigger
+application/vnd.ufdl
+application/vnd.uplanet.alert
+application/vnd.uplanet.alert-wbxml
+application/vnd.uplanet.bearer-choice
+application/vnd.uplanet.bearer-choice-wbxml
+application/vnd.uplanet.cacheop
+application/vnd.uplanet.cacheop-wbxml
+application/vnd.uplanet.channel
+application/vnd.uplanet.channel-wbxml
+application/vnd.uplanet.list
+application/vnd.uplanet.list-wbxml
+application/vnd.uplanet.listcmd
+application/vnd.uplanet.listcmd-wbxml
+application/vnd.uplanet.signal
+application/vnd.vcx
+application/vnd.vectorworks
+application/vnd.vidsoft.vidconference
+application/vnd.visio vsd
+application/vnd.vividence.scriptfile
+application/vnd.wap.sic
+application/vnd.wap.slc
+application/vnd.wap.wbxml wbxml
+application/vnd.wap.wmlc wmlc
+application/vnd.wap.wmlscriptc wmlsc
+application/vnd.webturbo
+application/vnd.wrq-hp3000-labelled
+application/vnd.wt.stf
+application/vnd.xara
+application/vnd.xfdl
+application/vnd.yellowriver-custom-menu
+application/x-123 wk
+application/x-abiword abw
+application/x-apple-diskimage dmg
+application/x-bcpio bcpio
+application/x-bittorrent torrent
+application/x-cdf cdf
+application/x-cdlink vcd
+application/x-chess-pgn pgn
+application/x-core
+application/x-cpio cpio
+application/x-csh csh
+application/x-debian-package deb udeb
+application/x-director dcr dir dxr
+application/x-dms dms
+application/x-doom wad
+application/x-dvi dvi
+application/x-executable
+application/x-flac flac
+application/x-font pfa pfb gsf pcf pcf.Z
+application/x-freemind mm
+application/x-futuresplash spl
+application/x-gnumeric gnumeric
+application/x-go-sgf sgf
+application/x-graphing-calculator gcf
+application/x-gtar gtar tgz taz
+application/x-hdf hdf
+application/x-ica ica
+application/x-internet-signup ins isp
+application/x-iphone iii
+application/x-iso9660-image iso
+application/x-java-applet
+application/x-java-bean
+application/x-java-jnlp-file jnlp
+application/x-javascript js
+application/x-jmol jmz
+application/x-kchart chrt
+application/x-kdelnk
+application/x-killustrator kil
+application/x-koan skp skd skt skm
+application/x-kpresenter kpr kpt
+application/x-kspread ksp
+application/x-kword kwd kwt
+application/x-latex latex
+application/x-lha lha
+application/x-lzh lzh
+application/x-lzx lzx
+application/x-maker frm maker frame fm fb book fbdoc
+application/x-mif mif
+application/x-ms-wmd wmd
+application/x-ms-wmz wmz
+application/x-msdos-program com exe bat dll
+application/x-msi msi
+application/x-netcdf nc
+application/x-ns-proxy-autoconfig pac
+application/x-nwc nwc
+application/x-object o
+application/x-oz-application oza
+application/x-pkcs7-certreqresp p7r
+application/x-pkcs7-crl crl
+application/x-python-code pyc pyo
+application/x-quicktimeplayer qtl
+application/x-redhat-package-manager rpm
+application/x-rx
+application/x-sh sh
+application/x-shar shar
+application/x-shellscript
+application/x-shockwave-flash swf swfl
+application/x-stuffit sit
+application/x-sv4cpio sv4cpio
+application/x-sv4crc sv4crc
+application/x-tar tar
+application/x-tcl tcl
+application/x-tex-gf gf
+application/x-tex-pk pk
+application/x-texinfo texinfo texi
+application/x-trash ~ % bak old sik
+application/x-troff t tr roff
+application/x-troff-man man
+application/x-troff-me me
+application/x-troff-ms ms
+application/x-ustar ustar
+application/x-videolan
+application/x-wais-source src
+application/x-wingz wz
+application/x-x509-ca-cert crt
+application/x-xcf xcf
+application/x-xfig fig
+application/x-xpinstall xpi
+
+audio/32kadpcm
+audio/basic au snd
+audio/dvi4
+audio/g.722.1
+audio/g722
+audio/g723
+audio/g726-16
+audio/g726-24
+audio/g726-32
+audio/g726-40
+audio/g728
+audio/g729
+audio/g729d
+audio/g729e
+audio/gsm
+audio/gsm-efr
+audio/l8
+audio/l16
+audio/lpc
+audio/midi mid midi kar
+audio/mp4a-latm
+audio/mpa
+audio/mpa-robust
+audio/mpeg mpga mpega mp2 mp3 m4a
+audio/mpegurl m3u
+audio/parityfec
+audio/pcma
+audio/pcmu
+audio/prs.sid sid
+audio/qcelp
+audio/red
+audio/telephone-event
+audio/tone
+audio/vdvi
+audio/vnd.cisco.nse
+audio/vnd.cns.anp1
+audio/vnd.cns.inf1
+audio/vnd.digital-winds
+audio/vnd.everad.plj
+audio/vnd.lucent.voice
+audio/vnd.nortel.vbk
+audio/vnd.nuera.ecelp4800
+audio/vnd.nuera.ecelp7470
+audio/vnd.nuera.ecelp9600
+audio/vnd.octel.sbc
+audio/vnd.qcelp
+audio/vnd.rhetorex.32kadpcm
+audio/vnd.vmx.cvsd
+audio/x-aiff aif aiff aifc
+audio/x-gsm gsm
+audio/x-mpegurl m3u
+audio/x-ms-wma wma
+audio/x-ms-wax wax
+audio/x-pn-realaudio-plugin
+audio/x-pn-realaudio ra rm ram
+audio/x-realaudio ra
+audio/x-scpls pls
+audio/x-sd2 sd2
+audio/x-wav wav
+
+chemical/x-alchemy alc
+chemical/x-cache cac cache
+chemical/x-cache-csf csf
+chemical/x-cactvs-binary cbin cascii ctab
+chemical/x-cdx cdx
+chemical/x-cerius cer
+chemical/x-chem3d c3d
+chemical/x-chemdraw chm
+chemical/x-cif cif
+chemical/x-cmdf cmdf
+chemical/x-cml cml
+chemical/x-compass cpa
+chemical/x-crossfire bsd
+chemical/x-csml csml csm
+chemical/x-ctx ctx
+chemical/x-cxf cxf cef
+#chemical/x-daylight-smiles smi
+chemical/x-embl-dl-nucleotide emb embl
+chemical/x-galactic-spc spc
+chemical/x-gamess-input inp gam gamin
+chemical/x-gaussian-checkpoint fch fchk
+chemical/x-gaussian-cube cub
+chemical/x-gaussian-input gau gjc gjf
+chemical/x-gaussian-log gal
+chemical/x-gcg8-sequence gcg
+chemical/x-genbank gen
+chemical/x-hin hin
+chemical/x-isostar istr ist
+chemical/x-jcamp-dx jdx dx
+chemical/x-kinemage kin
+chemical/x-macmolecule mcm
+chemical/x-macromodel-input mmd mmod
+chemical/x-mdl-molfile mol
+chemical/x-mdl-rdfile rd
+chemical/x-mdl-rxnfile rxn
+chemical/x-mdl-sdfile sd sdf
+chemical/x-mdl-tgf tgf
+#chemical/x-mif mif
+chemical/x-mmcif mcif
+chemical/x-mol2 mol2
+chemical/x-molconn-Z b
+chemical/x-mopac-graph gpt
+chemical/x-mopac-input mop mopcrt mpc dat zmt
+chemical/x-mopac-out moo
+chemical/x-mopac-vib mvb
+chemical/x-ncbi-asn1 asn
+chemical/x-ncbi-asn1-ascii prt ent
+chemical/x-ncbi-asn1-binary val aso
+chemical/x-ncbi-asn1-spec asn
+chemical/x-pdb pdb ent
+chemical/x-rosdal ros
+chemical/x-swissprot sw
+chemical/x-vamas-iso14976 vms
+chemical/x-vmd vmd
+chemical/x-xtel xtel
+chemical/x-xyz xyz
+
+image/cgm
+image/g3fax
+image/gif gif
+image/ief ief
+image/jpeg jpeg jpg jpe
+image/naplps
+image/pcx pcx
+image/png png
+image/prs.btif
+image/prs.pti
+image/svg+xml svg svgz
+image/tiff tiff tif
+image/vnd.cns.inf2
+image/vnd.djvu djvu djv
+image/vnd.dwg
+image/vnd.dxf
+image/vnd.fastbidsheet
+image/vnd.fpx
+image/vnd.fst
+image/vnd.fujixerox.edmics-mmr
+image/vnd.fujixerox.edmics-rlc
+image/vnd.mix
+image/vnd.net-fpx
+image/vnd.svf
+image/vnd.wap.wbmp wbmp
+image/vnd.xiff
+image/x-cmu-raster ras
+image/x-coreldraw cdr
+image/x-coreldrawpattern pat
+image/x-coreldrawtemplate cdt
+image/x-corelphotopaint cpt
+image/x-icon ico
+image/x-jg art
+image/x-jng jng
+image/x-ms-bmp bmp
+image/x-photoshop psd
+image/x-portable-anymap pnm
+image/x-portable-bitmap pbm
+image/x-portable-graymap pgm
+image/x-portable-pixmap ppm
+image/x-rgb rgb
+image/x-xbitmap xbm
+image/x-xpixmap xpm
+image/x-xwindowdump xwd
+
+inode/chardevice
+inode/blockdevice
+inode/directory-locked
+inode/directory
+inode/fifo
+inode/socket
+
+message/delivery-status
+message/disposition-notification
+message/external-body
+message/http
+message/s-http
+message/news
+message/partial
+message/rfc822
+
+model/iges igs iges
+model/mesh msh mesh silo
+model/vnd.dwf
+model/vnd.flatland.3dml
+model/vnd.gdl
+model/vnd.gs-gdl
+model/vnd.gtw
+model/vnd.mts
+model/vnd.vtu
+model/vrml wrl vrml
+
+multipart/alternative
+multipart/appledouble
+multipart/byteranges
+multipart/digest
+multipart/encrypted
+multipart/form-data
+multipart/header-set
+multipart/mixed
+multipart/parallel
+multipart/related
+multipart/report
+multipart/signed
+multipart/voice-message
+
+text/calendar ics icz
+text/comma-separated-values csv
+text/css css
+text/directory
+text/english
+text/enriched
+text/h323 323
+text/html html htm shtml
+text/iuls uls
+text/mathml mml
+text/parityfec
+text/plain asc txt text diff pot
+text/prs.lines.tag
+text/x-psp psp
+text/rfc822-headers
+text/richtext rtx
+text/rtf rtf
+text/scriptlet sct wsc
+text/t140
+text/texmacs tm ts
+text/tab-separated-values tsv
+text/uri-list
+text/vnd.abc
+text/vnd.curl
+text/vnd.DMClientScript
+text/vnd.flatland.3dml
+text/vnd.fly
+text/vnd.fmi.flexstor
+text/vnd.in3d.3dml
+text/vnd.in3d.spot
+text/vnd.IPTC.NewsML
+text/vnd.IPTC.NITF
+text/vnd.latex-z
+text/vnd.motorola.reflex
+text/vnd.ms-mediapackage
+text/vnd.sun.j2me.app-descriptor jad
+text/vnd.wap.si
+text/vnd.wap.sl
+text/vnd.wap.wml wml
+text/vnd.wap.wmlscript wmls
+text/x-bibtex bib
+text/x-c++hdr h++ hpp hxx hh
+text/x-c++src c++ cpp cxx cc
+text/x-chdr h
+text/x-crontab
+text/x-csh csh
+text/x-csrc c
+text/x-haskell hs
+text/x-java java
+text/x-literate-haskell lhs
+text/x-makefile
+text/x-moc moc
+text/x-pascal p pas
+text/x-pcs-gcd gcd
+text/x-perl pl pm
+text/x-python py
+text/x-server-parsed-html
+text/x-setext etx
+text/x-sh sh
+text/x-tcl tcl tk
+text/x-tex tex ltx sty cls
+text/x-vcalendar vcs
+text/x-vcard vcf
+
+video/bmpeg
+video/bt656
+video/celb
+video/dl dl
+video/dv dif dv
+video/fli fli
+video/gl gl
+video/jpeg
+video/h261
+video/h263
+video/h263-1998
+video/h263-2000
+video/mp1s
+video/mp2p
+video/mp2t
+video/mp4 mp4
+video/mp4v-es
+video/mpeg mpeg mpg mpe
+video/mpv
+video/nv
+video/parityfec
+video/pointer
+video/quicktime qt mov
+video/vnd.fvt
+video/vnd.motorola.video
+video/vnd.motorola.videop
+video/vnd.mpegurl mxu
+video/vnd.mts
+video/vnd.nokia.interleaved-multimedia
+video/vnd.vivo
+video/x-la-asf lsf lsx
+video/x-mng mng
+video/x-ms-asf asf asx
+video/x-ms-wm wm
+video/x-ms-wmv wmv
+video/x-ms-wmx wmx
+video/x-ms-wvx wvx
+video/x-msvideo avi
+video/x-sgi-movie movie
+video/x-flv flv
+
+x-conference/x-cooltalk ice
+
+x-world/x-vrml vrm vrml wrl
diff --git a/abs/extra-testing/mutt/PKGBUILD b/abs/extra-testing/mutt/PKGBUILD
new file mode 100644
index 0000000..c481eec
--- /dev/null
+++ b/abs/extra-testing/mutt/PKGBUILD
@@ -0,0 +1,39 @@
+# $Id: PKGBUILD 50055 2009-08-19 01:49:30Z thayer $
+# Maintainer: tobias [tobias [at] archlinux.org]
+pkgname=mutt
+pkgver=1.5.20
+pkgrel=2
+pkgdesc="A small but very powerful text-based mail client"
+arch=(i686 x86_64)
+license=('GPL')
+url="http://www.mutt.org/"
+depends=('slang' 'openssl>=0.9.8e' 'gdbm' 'mime-types' 'zlib' 'libsasl' 'gpgme')
+makedepends=('gnupg')
+install=${pkgname}.install
+source=(ftp://ftp.mutt.org/mutt/devel/${pkgname}-${pkgver}.tar.gz
+ mutt-unmailbox.patch)
+url="http://www.mutt.org/"
+md5sums=('027cdd9959203de0c3c64149a7ee351c'
+ 'fa8e03a49a2fa7b294dc8237d928cdb7')
+
+build() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+
+ # patch a segfault bug in 1.5.20 -- remove for next release
+ patch -p1 < ${srcdir}/mutt-unmailbox.patch || return 1
+ #patch -Np1 -i ../mutt-unmailbox.patch || exit 1
+
+ ./configure --prefix=/usr --sysconfdir=/etc \
+ --enable-pop --enable-imap --enable-smtp \
+ --with-sasl --with-ssl=/usr --without-idn \
+ --enable-hcache --enable-pgp --enable-inodesort \
+ --enable-compressed --with-regex \
+ --enable-gpgme --with-slang=/usr
+ make || return 1
+ make DESTDIR=${pkgdir} install
+ rm -f ${pkgdir}/usr/bin/{flea,muttbug}
+ rm -f ${pkgdir}/usr/share/man/man1/{flea,muttbug}.1
+ rm -f ${pkgdir}/etc/mime.types*
+ install -Dm644 contrib/gpg.rc ${pkgdir}/etc/Muttrc.gpg.dist
+}
+
diff --git a/abs/extra-testing/mutt/mutt-unmailbox.patch b/abs/extra-testing/mutt/mutt-unmailbox.patch
new file mode 100644
index 0000000..cbb3210
--- /dev/null
+++ b/abs/extra-testing/mutt/mutt-unmailbox.patch
@@ -0,0 +1,10 @@
+--- a/buffy.c 2009-08-10 08:23:12.731846990 -0400
++++ b/buffy.c 2009-08-10 08:23:50.541878087 -0400
+@@ -236,7 +236,6 @@
+ {
+ if(*tmp)
+ {
+- FREE (&((*tmp)->path));
+ tmp1=(*tmp)->next;
+ FREE (tmp); /* __FREE_CHECKED__ */
+ *tmp=tmp1;
diff --git a/abs/extra-testing/mutt/mutt.install b/abs/extra-testing/mutt/mutt.install
new file mode 100644
index 0000000..98ece96
--- /dev/null
+++ b/abs/extra-testing/mutt/mutt.install
@@ -0,0 +1,15 @@
+# arg 1: the new package version
+post_install() {
+ cat << EOM
+
+--> to support gpg, please use the following line in your ~/.muttrc
+
+source /etc/Muttrc.gpg.dist
+
+EOM
+}
+
+post_upgrade() {
+ post_install $1
+}
+
diff --git a/abs/extra-testing/postfix/PKGBUILD b/abs/extra-testing/postfix/PKGBUILD
new file mode 100644
index 0000000..1b2fa06
--- /dev/null
+++ b/abs/extra-testing/postfix/PKGBUILD
@@ -0,0 +1,52 @@
+# $Id: PKGBUILD 70372 2010-02-26 13:35:23Z paul $
+# Contributor: Jeff Brodnax <tullyarcher@bellsouth.net>
+# Maintainer: Paul Mattal <paul@archlinux.org>
+pkgname=postfix
+pkgver=2.7.0
+pkgrel=1
+pkgdesc="Secure, fast, easy to administer drop in replacement for Sendmail (MTA)"
+arch=('i686' 'x86_64')
+license=('custom')
+depends=('pcre' 'libsasl' 'db>=4.7')
+backup=(etc/postfix/aliases etc/postfix/virtual etc/postfix/relocated \
+ etc/postfix/access etc/postfix/header_checks etc/postfix/transport \
+ etc/postfix/generic etc/postfix/canonical \
+ etc/postfix/main.cf etc/postfix/master.cf)
+install="${pkgname}.install"
+provides=('smtp-server' 'smtp-forwarder')
+replaces=('postfix-mysql' 'postfix-pgsql')
+conflicts=('postfix-mysql' 'postfix-pgsql' 'smtp-server' 'smtp-forwarder')
+url="http://www.postfix.org/"
+source=(ftp://ftp.porcupine.org/mirrors/postfix-release/official/${pkgname}-${pkgver}.tar.gz \
+ ${pkgname}.patch.bz2 \
+ ${pkgname})
+md5sums=('df648f59421604e895cce56325f00bae'
+ 'a3c45ff23ef036143711793fcf2478c3'
+ 'c847b96f08925f08b0f610468a8e21f6')
+
+build() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+
+ make makefiles \
+ CCARGS="-DUSE_SASL_AUTH -I/usr/include/sasl \
+ -DUSE_CYRUS_SASL \
+ -DUSE_TLS" \
+ AUXLIBS="-lsasl2 -lssl -lcrypto -llber -lz -lm "
+ make OPT="${CFLAGS}" || return 1
+
+ sh postfix-install -non-interactive \
+ install_root="${pkgdir}" \
+ daemon_directory="/usr/lib/${pkgname}" \
+ sample_directory="/etc/${pkgname}/sample" \
+ manpage_directory="/usr/share/man"
+
+ cd ${pkgdir}
+ cat ${srcdir}/${pkgname}.patch |patch -Np0 || return 1
+ rm -f etc/${pkgname}/main.cf~
+
+ cd ${pkgdir}
+ mkdir etc/rc.d
+ install -m 0755 ${srcdir}/${pkgname} etc/rc.d/${pkgname}
+
+ install -Dm644 ${srcdir}/${pkgname}-${pkgver}/LICENSE ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
+}
diff --git a/abs/extra-testing/postfix/__changelog b/abs/extra-testing/postfix/__changelog
new file mode 100644
index 0000000..25ca6b4
--- /dev/null
+++ b/abs/extra-testing/postfix/__changelog
@@ -0,0 +1 @@
+remove ldap/mysql/pg support
diff --git a/abs/extra-testing/postfix/postfix b/abs/extra-testing/postfix/postfix
new file mode 100755
index 0000000..37dd6a8
--- /dev/null
+++ b/abs/extra-testing/postfix/postfix
@@ -0,0 +1,58 @@
+#!/bin/bash
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+PID=`pgrep -f /usr/lib/postfix/master`
+
+start() {
+ stat_busy "Starting Postfix"
+ [ -z "$PID" ] && /usr/sbin/postfix start &> /dev/null
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ add_daemon postfix
+ stat_done
+ fi
+}
+
+stop() {
+ stat_busy "Stopping Postfix"
+ [ ! -z "$PID" ] && /usr/sbin/postfix stop &> /dev/null
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ rm_daemon postfix
+ stat_done
+ fi
+}
+
+reload() {
+ stat_busy "Reloading Postfix"
+ [ ! -z "$PID" ] && kill -HUP $PID &> /dev/null
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ stat_done
+ fi
+}
+
+case "$1" in
+ start)
+ start
+ ;;
+ stop)
+ stop
+ ;;
+ restart)
+ # calling 'stop' and 'start' without the $0 fails...
+ $0 stop
+ $0 start
+ ;;
+ reload)
+ reload
+ ;;
+ *)
+ echo "usage: $0 {start|stop|restart|reload}"
+esac
+exit 0
diff --git a/abs/extra-testing/postfix/postfix.install b/abs/extra-testing/postfix/postfix.install
new file mode 100644
index 0000000..bac3e1d
--- /dev/null
+++ b/abs/extra-testing/postfix/postfix.install
@@ -0,0 +1,38 @@
+# arg 1: the new package version
+post_install() {
+ if [ -z "`grep '^postdrop::' /etc/group`" ]; then
+ groupadd -g 75 postdrop >& /dev/null
+ fi
+ if [ -z "`grep '^postfix::' /etc/group`" ]; then
+ groupadd -g 73 postfix >& /dev/null
+ fi
+ if [ -z "`grep '^postfix:' /etc/passwd`" ]; then
+ useradd -u 73 -d /var/spool/postfix -g postfix -s /bin/false postfix
+ else
+ # fix a packaging bug from before (postfix should have no shell)
+ usermod -s /bin/false postfix
+ fi
+
+ chown postfix var/spool/postfix/{active,bounce,corrupt,defer,deferred,\
+flush,hold,incoming,private,public,maildrop,trace,saved}
+ chown postfix var/lib/postfix
+ chgrp postdrop var/spool/postfix/{public,maildrop}
+ chgrp postdrop usr/sbin/postqueue
+ chgrp postdrop usr/sbin/postdrop
+ chmod g+s usr/sbin/{postqueue,postdrop}
+
+ newaliases
+}
+
+# arg 1: the new package version
+# arg 2: the old package version
+post_upgrade() {
+ post_install $1
+}
+
+# arg 1: the old package version
+pre_remove() {
+ userdel postfix &> /dev/null
+ groupdel postfix &> /dev/null
+ groupdel postdrop &> /dev/null
+}
diff --git a/abs/extra-testing/postfix/postfix.patch.bz2 b/abs/extra-testing/postfix/postfix.patch.bz2
new file mode 100644
index 0000000..dbc0950
--- /dev/null
+++ b/abs/extra-testing/postfix/postfix.patch.bz2
Binary files differ
diff --git a/abs/extra-testing/procmail/PKGBUILD b/abs/extra-testing/procmail/PKGBUILD
new file mode 100644
index 0000000..356a147
--- /dev/null
+++ b/abs/extra-testing/procmail/PKGBUILD
@@ -0,0 +1,21 @@
+# $Id: PKGBUILD 35774 2009-04-17 03:11:54Z eric $
+# Maintainer: dorphell <dorphell@archlinux.org>
+# Committer: Judd Vinet <jvinet@zeroflux.org>
+pkgname=procmail
+pkgver=3.22
+pkgrel=2
+pkgdesc="Highly configurable auto mail processing."
+arch=(i686 x86_64)
+url="http://www.procmail.org"
+license=('GPL' 'custom:Artistic')
+depends=('glibc')
+source=(http://www.procmail.org/${pkgname}-${pkgver}.tar.gz)
+source=(ftp://ftp.psg.com/pub/unix/procmail/procmail-3.22.tar.gz)
+md5sums=('1678ea99b973eb77eda4ecf6acae53f1')
+
+build() {
+ cd $srcdir/$pkgname-$pkgver
+ yes n | make LOCKINGTEST="/tmp ." || return 1
+ make BASENAME=$pkgdir/usr MANDIR=$pkgdir/usr/share/man install || return 1
+ install -D -m644 Artistic ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
+}
diff --git a/abs/extra-testing/pth/PKGBUILD b/abs/extra-testing/pth/PKGBUILD
new file mode 100644
index 0000000..2e0f66b
--- /dev/null
+++ b/abs/extra-testing/pth/PKGBUILD
@@ -0,0 +1,22 @@
+# $Id: PKGBUILD 35785 2009-04-17 05:07:12Z eric $
+# Maintainer: damir <damir@archlinux.org>
+
+pkgname=pth
+pkgver=2.0.7
+pkgrel=2
+pkgdesc="The GNU Portable Threads."
+arch=('i686' 'x86_64')
+url="http://www.gnu.org/software/pth/"
+license=('LGPL')
+depends=('glibc')
+options=('!libtool' '!makeflags')
+source=(ftp://ftp.gnu.org/gnu/pth/${pkgname}-${pkgver}.tar.gz)
+md5sums=('9cb4a25331a4c4db866a31cbe507c793')
+
+build() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+ ./configure --prefix=/usr --sysconfdir=/etc \
+ --localstatedir=/var --mandir=/usr/share/man || return 1
+ make || return 1
+ make DESTDIR=${pkgdir} install || return 1
+}