mirror of
https://github.com/Emupedia/emupedia.github.io.git
synced 2026-12-02 04:20:08 +08:00
More work
This commit is contained in:
@@ -28,28 +28,6 @@
|
||||
var versionCheckInterval = null;
|
||||
var $window = $(window);
|
||||
|
||||
if (typeof $.fn.getSelector === 'undefined') {
|
||||
$.fn.getSelector = function() {
|
||||
if ($(this).attr('id')) {
|
||||
return '#' + $(this).attr('id');
|
||||
}
|
||||
|
||||
if ($(this).prop('tagName').toLowerCase() === 'body') {
|
||||
return 'body';
|
||||
}
|
||||
|
||||
var myOwn = $(this).attr('class');
|
||||
|
||||
if (!myOwn) {
|
||||
myOwn = '>' + $(this).prop('tagName');
|
||||
} else {
|
||||
myOwn = '.' + myOwn.split(' ').join('.');
|
||||
}
|
||||
|
||||
return $(this).parent().getSelector() + ' ' + myOwn;
|
||||
}
|
||||
}
|
||||
|
||||
if (typeof $.fn.hasScrollBar === 'undefined') {
|
||||
$.fn.hasScrollBar = function() {
|
||||
var el = this.get(0);
|
||||
|
||||
Reference in New Issue
Block a user