37 lines
1.7 KiB
JavaScript
Executable File
37 lines
1.7 KiB
JavaScript
Executable File
$(document).ready(function() {
|
|
var FixedTopValue = $('#nse_main_div').offset();
|
|
FixedTopValue = FixedTopValue.top;
|
|
var GettingDocumentScrollTop = true;
|
|
var DocumentScrollTopValue = 0;
|
|
$.fn.FixingScheduleBox();
|
|
});
|
|
$(window).scroll(function() {
|
|
$.fn.FixingScheduleBox();
|
|
});
|
|
$(window).resize(function() {
|
|
$.fn.FixingScheduleBox();
|
|
});
|
|
$.fn.FixingScheduleBox = function() {
|
|
var scrollTop = true;
|
|
// if(IDrive.UserName !=''){ return true;}
|
|
var CurrentTopValueschedule = $('#nse_main_div').offset();
|
|
CurrentTopValueschedule = CurrentTopValueschedule.top + $('#nse_main_div').innerHeight();
|
|
|
|
var CurrentMenuTopValue = $('.leftnav.trash-page-ltNav.syno-oly').offset();
|
|
CurrentMenuTopValue = CurrentMenuTopValue.top + $('.leftnav.trash-page-ltNav.syno-oly > ul').innerHeight();
|
|
|
|
if (window.innerHeight < 600) {
|
|
$('.next-schdule-box').removeClass('schedule-box-wrap-bottom schedule-box-wrap-fixed');
|
|
$('.next-schdule-box').addClass('schedule-box-wrap-top');
|
|
// } else if ($(document).innerHeight() - $('footer').innerHeight() === $('footer').offset().top) {
|
|
// $('.next-schdule-box').removeClass('schedule-box-wrap-fixed schedule-box-wrap-top');
|
|
// $('.next-schdule-box').addClass('schedule-box-wrap-bottom');
|
|
// } else if ($(document).innerHeight() - $('footer').innerHeight() !== $('footer').offset().top) {
|
|
// $('.next-schdule-box').removeClass('schedule-box-wrap-bottom schedule-box-wrap-top');
|
|
// $('.next-schdule-box').addClass('schedule-box-wrap-fixed');
|
|
} else {
|
|
$('.next-schdule-box').removeClass('schedule-box-wrap-bottom schedule-box-wrap-top');
|
|
$('.next-schdule-box').addClass('schedule-box-wrap-fixed');
|
|
}
|
|
}
|