mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
update access denied exceptions
This commit is contained in:
parent
294281602e
commit
ad38cf4783
17 changed files with 154 additions and 138 deletions
|
@ -724,7 +724,7 @@
|
|||
var deferred = DeferredBuilder.Deferred();
|
||||
|
||||
require(['serverdiscovery'], function () {
|
||||
ServerDiscovery.findServers(2500).done(function (foundServers) {
|
||||
ServerDiscovery.findServers(1500).done(function (foundServers) {
|
||||
|
||||
var servers = foundServers.map(function (foundServer) {
|
||||
|
||||
|
|
9
dashboard-ui/cordova/ios/backgroundfetch.js
vendored
9
dashboard-ui/cordova/ios/backgroundfetch.js
vendored
|
@ -7,7 +7,7 @@
|
|||
var fetcher = window.BackgroundFetch;
|
||||
|
||||
fetcher.configure(onBackgroundFetch, onBackgroundFetchFailed, {
|
||||
stopOnTerminate: true // <-- false is default
|
||||
stopOnTerminate: false // <-- false is default
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -55,7 +55,7 @@
|
|||
Logger.log('- BackgroundFetch failed');
|
||||
}
|
||||
|
||||
var syncInterval = 1800000;
|
||||
var syncInterval = 3600000;
|
||||
|
||||
function restartInterval() {
|
||||
|
||||
|
@ -65,11 +65,12 @@
|
|||
|
||||
}, syncInterval);
|
||||
|
||||
if (lastStart > 0 && (now - lastStart) >= syncInterval) {
|
||||
if (lastStart > 0 && (new Date().getTime() - lastStart) >= syncInterval) {
|
||||
|
||||
setTimeout(function () {
|
||||
startSync();
|
||||
}, 3000);
|
||||
|
||||
}, 5000);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
11
dashboard-ui/cordova/ios/tabbar.js
vendored
11
dashboard-ui/cordova/ios/tabbar.js
vendored
|
@ -98,13 +98,20 @@
|
|||
TabBar.show();
|
||||
}
|
||||
|
||||
var isFirstHide = true;
|
||||
function hideTabs() {
|
||||
|
||||
if (!initComplete) {
|
||||
return;
|
||||
}
|
||||
|
||||
TabBar.hide();
|
||||
var hide = function () { TabBar.hide(); };
|
||||
if (isFirstHide) {
|
||||
isFirstHide = false;
|
||||
setTimeout(hide, 1000);
|
||||
} else {
|
||||
hide();
|
||||
}
|
||||
}
|
||||
|
||||
Dashboard.ready(function () {
|
||||
|
@ -113,7 +120,7 @@
|
|||
|
||||
Events.on(ConnectionManager, 'localusersignedin', showTabs);
|
||||
Events.on(ConnectionManager, 'localusersignedout', hideTabs);
|
||||
Events.on(MediaController, 'playbackstart', onPlaybackStart);
|
||||
Events.on(MediaController, 'beforeplaybackstart', onPlaybackStart);
|
||||
Events.on(MediaController, 'playbackstop', onPlaybackStop);
|
||||
});
|
||||
|
||||
|
|
164
dashboard-ui/cordova/localassetmanager.js
vendored
164
dashboard-ui/cordova/localassetmanager.js
vendored
|
@ -350,7 +350,7 @@
|
|||
var deferred = DeferredBuilder.Deferred();
|
||||
|
||||
Logger.log('Deleting ' + path);
|
||||
resolveFile(path, function (fileEntry) {
|
||||
resolveFile(path, null, function (fileEntry) {
|
||||
|
||||
fileEntry.remove(function () {
|
||||
Logger.log('Deleted ' + path);
|
||||
|
@ -370,18 +370,27 @@
|
|||
return deferred.promise();
|
||||
}
|
||||
|
||||
function resolveFile(path, success, fail) {
|
||||
function resolveFile(path, options, success, fail) {
|
||||
|
||||
getFileSystem().done(function (fileSystem) {
|
||||
|
||||
fileSystem.root.getFile(path, { create: false }, success, fail);
|
||||
fileSystem.root.getFile(path, options || { create: false }, success, fail);
|
||||
});
|
||||
}
|
||||
|
||||
function createLocalItem(libraryItem, serverInfo, originalFileName) {
|
||||
|
||||
var path = getDirectoryPath(libraryItem, serverInfo);
|
||||
path.push(getLocalFileName(libraryItem, originalFileName));
|
||||
var enableFriendlyPath = false;
|
||||
|
||||
var path = getDirectoryPath(libraryItem, serverInfo, enableFriendlyPath);
|
||||
|
||||
if (enableFriendlyPath) {
|
||||
path.push(getLocalFileName(libraryItem, originalFileName));
|
||||
} else {
|
||||
var nameParts = originalFileName.split('.');
|
||||
var ext = nameParts.length > 1 ? ('.' + nameParts[nameParts.length - 1]) : '';
|
||||
path.push('media' + ext);
|
||||
}
|
||||
|
||||
var item = {};
|
||||
|
||||
|
@ -407,7 +416,11 @@
|
|||
return deferred.promise();
|
||||
}
|
||||
|
||||
function getDirectoryPath(item, server) {
|
||||
function getDirectoryPath(item, server, enableFriendlyPath) {
|
||||
|
||||
if (!enableFriendlyPath) {
|
||||
return ['sync', item.Id];
|
||||
}
|
||||
|
||||
var parts = [];
|
||||
parts.push("sync");
|
||||
|
@ -462,58 +475,6 @@
|
|||
function downloadFile(url, localPath, enableBackground) {
|
||||
|
||||
return downloadWithFileTransfer(url, localPath, enableBackground);
|
||||
if (!enableBackground) {
|
||||
return downloadWithFileTransfer(url, localPath);
|
||||
}
|
||||
|
||||
var deferred = DeferredBuilder.Deferred();
|
||||
|
||||
if (localStorage.getItem('sync-' + url) == '1') {
|
||||
Logger.log('file was downloaded previously');
|
||||
deferred.resolveWith(null, [localPath]);
|
||||
return deferred.promise();
|
||||
}
|
||||
|
||||
Logger.log('downloading: ' + url + ' to ' + localPath);
|
||||
|
||||
getFileSystem().done(function (fileSystem) {
|
||||
|
||||
createDirectory(getParentDirectoryPath(localPath)).done(function () {
|
||||
|
||||
fileSystem.root.getFile(localPath, { create: true }, function (targetFile) {
|
||||
|
||||
var downloader = new BackgroundTransfer.BackgroundDownloader();
|
||||
// Create a new download operation.
|
||||
var download = downloader.createDownload(url, targetFile);
|
||||
|
||||
var isQueued = true;
|
||||
|
||||
// Start the download and persist the promise to be able to cancel the download.
|
||||
var downloadPromise = download.startAsync().then(function () {
|
||||
|
||||
// on success
|
||||
Logger.log('Downloaded local url: ' + localPath);
|
||||
localStorage.setItem('sync-' + url, '1');
|
||||
isQueued = false;
|
||||
|
||||
}, function () {
|
||||
|
||||
// on error
|
||||
Logger.log('download failed: ' + url + ' to ' + localPath);
|
||||
deferred.reject();
|
||||
|
||||
}, function (value) {
|
||||
|
||||
// on progress
|
||||
//Logger.log('download progress: ' + value);
|
||||
});
|
||||
});
|
||||
|
||||
}).fail(getOnFail(deferred));;
|
||||
|
||||
}).fail(getOnFail(deferred));
|
||||
|
||||
return deferred.promise();
|
||||
}
|
||||
|
||||
var activeDownloads = [];
|
||||
|
@ -544,57 +505,58 @@
|
|||
|
||||
Logger.log('downloading: ' + url + ' to ' + localPath);
|
||||
|
||||
getFileSystem().done(function (fileSystem) {
|
||||
createDirectory(getParentDirectoryPath(localPath)).done(function () {
|
||||
|
||||
createDirectory(getParentDirectoryPath(localPath)).done(function () {
|
||||
resolveFile(localPath, { create: true }, function (targetFile) {
|
||||
|
||||
fileSystem.root.getFile(localPath, { create: true }, function (targetFile) {
|
||||
var isQueued = enableBackground;
|
||||
var isError = false;
|
||||
|
||||
var isQueued = enableBackground;
|
||||
var isError = false;
|
||||
var ft = new FileTransfer();
|
||||
activeDownloads.push(downloadKey);
|
||||
ft.download(url, targetFile.toURL(), function (entry) {
|
||||
|
||||
var ft = new FileTransfer();
|
||||
ft.download(url, targetFile.toURL(), function (entry) {
|
||||
|
||||
removeDownload(downloadKey);
|
||||
|
||||
if (enableBackground) {
|
||||
Logger.log('Downloaded local url: ' + localPath);
|
||||
localStorage.setItem('sync-' + url, '1');
|
||||
isQueued = false;
|
||||
} else {
|
||||
deferred.resolveWith(null, [localPath]);
|
||||
}
|
||||
|
||||
}, function () {
|
||||
|
||||
removeDownload(downloadKey);
|
||||
|
||||
Logger.log('Error downloading url: ' + url);
|
||||
|
||||
if (enableBackground) {
|
||||
isError = true;
|
||||
} else {
|
||||
deferred.reject();
|
||||
}
|
||||
});
|
||||
activeDownloads.push(downloadKey);
|
||||
removeDownload(downloadKey);
|
||||
|
||||
if (enableBackground) {
|
||||
// Give it a short period of time to see if it has already been completed before. Either way, move on and resolve it.
|
||||
setTimeout(function () {
|
||||
Logger.log('Downloaded local url: ' + localPath);
|
||||
localStorage.setItem('sync-' + url, '1');
|
||||
isQueued = false;
|
||||
} else {
|
||||
deferred.resolveWith(null, [localPath]);
|
||||
}
|
||||
|
||||
if (isError) {
|
||||
deferred.reject();
|
||||
} else {
|
||||
// true indicates that it's queued
|
||||
deferred.resolveWith(null, [localPath, isQueued]);
|
||||
}
|
||||
}, 1500);
|
||||
}, function () {
|
||||
|
||||
removeDownload(downloadKey);
|
||||
|
||||
Logger.log('Error downloading url: ' + url);
|
||||
|
||||
if (enableBackground) {
|
||||
isError = true;
|
||||
} else {
|
||||
deferred.reject();
|
||||
}
|
||||
});
|
||||
|
||||
}).fail(getOnFail(deferred));
|
||||
if (enableBackground) {
|
||||
// Give it a short period of time to see if it has already been completed before. Either way, move on and resolve it.
|
||||
setTimeout(function () {
|
||||
|
||||
if (isError) {
|
||||
deferred.reject();
|
||||
} else {
|
||||
// true indicates that it's queued
|
||||
deferred.resolveWith(null, [localPath, isQueued]);
|
||||
}
|
||||
}, 2000);
|
||||
}
|
||||
|
||||
}, function () {
|
||||
|
||||
Logger.log('getFile failed for ' + localPath);
|
||||
deferred.reject();
|
||||
});
|
||||
|
||||
}).fail(getOnFail(deferred));
|
||||
|
||||
|
@ -761,7 +723,7 @@
|
|||
return deferred.promise();
|
||||
}
|
||||
|
||||
resolveFile(path, function (fileEntry) {
|
||||
resolveFile(path, null, function (fileEntry) {
|
||||
Logger.log('fileExists: true - path: ' + path);
|
||||
deferred.resolveWith(null, [true]);
|
||||
|
||||
|
@ -806,7 +768,7 @@
|
|||
return deferred.promise();
|
||||
}
|
||||
|
||||
resolveFile(path, function (fileEntry) {
|
||||
resolveFile(path, null, function (fileEntry) {
|
||||
Logger.log('translateFilePath fileExists: true - path: ' + path);
|
||||
Logger.log('translateFilePath resolving with: ' + fileEntry.toURL());
|
||||
deferred.resolveWith(null, [fileEntry.toURL()]);
|
||||
|
|
|
@ -6,13 +6,15 @@
|
|||
<body>
|
||||
<div id="nowPlayingPage" data-role="page" class="page libraryPage nowPlayingPage noSecondaryNavPage" data-contextname="${TitleRemoteControl}" data-theme="b" data-require="jqmcollapsible,scripts/nowplayingpage,paperbuttonstyle">
|
||||
|
||||
<paper-tabs selected="{{selected}}" class="nowPlayingPagePaperTabs" hidescrollbuttons noink>
|
||||
<div class="libraryViewNav">
|
||||
<paper-tabs class="nowPlayingPagePaperTabs" hidescrollbuttons noink>
|
||||
|
||||
<paper-tab>${TabNowPlaying}</paper-tab>
|
||||
<paper-tab>${TabControls}</paper-tab>
|
||||
<paper-tab>${TabPlaylist}</paper-tab>
|
||||
<paper-tab>${TabNowPlaying}</paper-tab>
|
||||
<paper-tab>${TabControls}</paper-tab>
|
||||
<paper-tab>${TabPlaylist}</paper-tab>
|
||||
|
||||
</paper-tabs>
|
||||
</paper-tabs>
|
||||
</div>
|
||||
|
||||
<div data-role="content" style="overflow:visible;">
|
||||
|
||||
|
|
|
@ -256,7 +256,7 @@
|
|||
var link = '<a href="http://emby.media" target="_blank">http://emby.media</a>';
|
||||
$('.embyIntroDownloadMessage', page).html(Globalize.translate('EmbyIntroDownloadMessage', link));
|
||||
|
||||
}).on('pageshowready', "#connectLoginPage", function () {
|
||||
}).on('pageshow', "#connectLoginPage", function () {
|
||||
|
||||
var page = this;
|
||||
loadPage(page);
|
||||
|
|
|
@ -1003,7 +1003,7 @@
|
|||
}
|
||||
};
|
||||
|
||||
$(document).on('pageshowready', "#dashboardPage", DashboardPage.onPageShow).on('pagebeforehide', "#dashboardPage", DashboardPage.onPageHide);
|
||||
$(document).on('pageshow', "#dashboardPage", DashboardPage.onPageShow).on('pagebeforehide', "#dashboardPage", DashboardPage.onPageHide);
|
||||
|
||||
(function ($, document, window) {
|
||||
|
||||
|
@ -1287,7 +1287,7 @@ $(document).on('pageshowready', "#dashboardPage", DashboardPage.onPageShow).on('
|
|||
result.CustomPrefs[welcomeTourKey] = welcomeDismissValue;
|
||||
ApiClient.updateDisplayPreferences('dashboard', result, userId, 'dashboard');
|
||||
|
||||
$(page).off('pageshowready', onPageShowReadyCheckTour);
|
||||
$(page).off('pageshow', onPageShowCheckTour);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -1344,7 +1344,7 @@ $(document).on('pageshowready', "#dashboardPage", DashboardPage.onPageShow).on('
|
|||
});
|
||||
}
|
||||
|
||||
function onPageShowReadyCheckTour() {
|
||||
function onPageShowCheckTour() {
|
||||
var page = this;
|
||||
|
||||
var apiClient = ApiClient;
|
||||
|
@ -1362,13 +1362,13 @@ $(document).on('pageshowready', "#dashboardPage", DashboardPage.onPageShow).on('
|
|||
takeTour(page, Dashboard.getCurrentUserId());
|
||||
});
|
||||
|
||||
}).on('pageshowready', "#dashboardPage", onPageShowReadyCheckTour);
|
||||
}).on('pageshow', "#dashboardPage", onPageShowCheckTour);
|
||||
|
||||
})(jQuery, document, window);
|
||||
|
||||
(function () {
|
||||
|
||||
$(document).on('pageshowready', ".type-interior", function () {
|
||||
$(document).on('pageshow', ".type-interior", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
|
|
|
@ -250,7 +250,7 @@
|
|||
$('.libraryViewNav', ownerpage).removeClass('libraryViewNavWithMinHeight');
|
||||
}
|
||||
|
||||
$(ownerpage).on('pageshow', LibraryBrowser.onTabbedpagebeforeshow);
|
||||
$(ownerpage).on('pagebeforeshow', LibraryBrowser.onTabbedpagebeforeshow);
|
||||
|
||||
pages.addEventListener('iron-select', function () {
|
||||
// When transition animations are used, add a content loading delay to allow the animations to finish
|
||||
|
@ -406,7 +406,7 @@
|
|||
|
||||
afterNavigate.call($($.mobile.activePage)[0]);
|
||||
} else {
|
||||
$(document).one('pageshow', '.page', afterNavigate);
|
||||
$(document).one('pagebeforeshow', '.page', afterNavigate);
|
||||
Dashboard.navigate(url);
|
||||
}
|
||||
},
|
||||
|
|
|
@ -249,9 +249,13 @@
|
|||
}
|
||||
|
||||
Events.on(player, 'playbackstop', onPlaybackStop);
|
||||
Events.on(player, 'playbackstart', onPlaybackStart);
|
||||
Events.on(player, 'beforeplaybackstart', onBeforePlaybackStart);
|
||||
};
|
||||
|
||||
function onBeforePlaybackStart(e, state) {
|
||||
$(self).trigger('beforeplaybackstart', [state, this]);
|
||||
}
|
||||
|
||||
function onPlaybackStart(e, state) {
|
||||
$(self).trigger('playbackstart', [state, this]);
|
||||
}
|
||||
|
@ -450,7 +454,12 @@
|
|||
return deferred.promise();
|
||||
};
|
||||
|
||||
function doWithPlaybackValidation(fn) {
|
||||
function doWithPlaybackValidation(player, fn) {
|
||||
|
||||
if (!player.isLocalPlayer) {
|
||||
fn();
|
||||
return;
|
||||
}
|
||||
|
||||
requirejs(["scripts/registrationservices"], function () {
|
||||
RegistrationServices.validateFeature('playback').done(fn);
|
||||
|
@ -479,7 +488,7 @@
|
|||
|
||||
self.play = function (options) {
|
||||
|
||||
doWithPlaybackValidation(function () {
|
||||
doWithPlaybackValidation(currentPlayer, function () {
|
||||
if (typeof (options) === 'string') {
|
||||
options = { ids: [options] };
|
||||
}
|
||||
|
@ -490,13 +499,13 @@
|
|||
|
||||
self.shuffle = function (id) {
|
||||
|
||||
doWithPlaybackValidation(function () {
|
||||
doWithPlaybackValidation(currentPlayer, function () {
|
||||
currentPlayer.shuffle(id);
|
||||
});
|
||||
};
|
||||
|
||||
self.instantMix = function (id) {
|
||||
doWithPlaybackValidation(function () {
|
||||
doWithPlaybackValidation(currentPlayer, function () {
|
||||
currentPlayer.instantMix(id);
|
||||
});
|
||||
};
|
||||
|
|
|
@ -1078,6 +1078,8 @@
|
|||
|
||||
mediaRenderer.init().done(function () {
|
||||
|
||||
self.onBeforePlaybackStart(mediaRenderer, item, mediaSource);
|
||||
|
||||
self.setSrcIntoRenderer(mediaRenderer, streamInfo, item, self.currentMediaSource);
|
||||
self.streamInfo = streamInfo;
|
||||
|
||||
|
|
|
@ -1721,6 +1721,13 @@
|
|||
// Nothing to setup here
|
||||
};
|
||||
|
||||
self.onBeforePlaybackStart = function (mediaRenderer, item, mediaSource) {
|
||||
|
||||
var state = self.getPlayerStateInternal(mediaRenderer, item, mediaSource);
|
||||
|
||||
Events.trigger(self, 'beforeplaybackstart', [state]);
|
||||
};
|
||||
|
||||
self.onPlaybackStart = function (mediaRenderer, item, mediaSource) {
|
||||
|
||||
var state = self.getPlayerStateInternal(mediaRenderer, item, mediaSource);
|
||||
|
@ -1942,6 +1949,8 @@
|
|||
// Set volume first to avoid an audible change
|
||||
mediaRenderer.volume(initialVolume);
|
||||
|
||||
self.onBeforePlaybackStart(mediaRenderer, item, mediaSource);
|
||||
|
||||
mediaRenderer.setCurrentSrc(streamInfo, item, mediaSource);
|
||||
self.streamInfo = streamInfo;
|
||||
});
|
||||
|
|
|
@ -777,8 +777,10 @@
|
|||
if (AppInfo.enableNowPlayingPageBottomTabs) {
|
||||
tabs.alignBottom = true;
|
||||
tabs.classList.add('bottom');
|
||||
//page.classList.add('noSecondaryNavPage');
|
||||
} else {
|
||||
tabs.classList.remove('bottom');
|
||||
//page.classList.remove('noSecondaryNavPage');
|
||||
}
|
||||
|
||||
LibraryBrowser.configureSwipeTabs(page, tabs, page.querySelectorAll('neon-animated-pages')[0]);
|
||||
|
|
|
@ -59,6 +59,10 @@
|
|||
return enableScrollX() ? 'overflowPortrait' : 'portrait';
|
||||
}
|
||||
|
||||
function getSquareShape() {
|
||||
return enableScrollX() ? 'overflowSquare' : 'square';
|
||||
}
|
||||
|
||||
function getLibraryButtonsHtml(items) {
|
||||
|
||||
var html = "";
|
||||
|
@ -612,9 +616,14 @@
|
|||
html += '</div>';
|
||||
}
|
||||
|
||||
if (enableScrollX()) {
|
||||
html += '<div class="hiddenScrollX itemsContainer">';
|
||||
} else {
|
||||
html += '<div class="itemsContainer">';
|
||||
}
|
||||
html += LibraryBrowser.getPosterViewHtml({
|
||||
items: result.Items,
|
||||
shape: "autohome",
|
||||
shape: getSquareShape(),
|
||||
showTitle: true,
|
||||
showParentTitle: true,
|
||||
coverImage: true,
|
||||
|
@ -622,9 +631,11 @@
|
|||
showDetailsMenu: true,
|
||||
centerText: true
|
||||
});
|
||||
html += '</div>';
|
||||
|
||||
elem.innerHTML = html;
|
||||
ImageLoader.lazyChildren(elem);
|
||||
$(elem).createCardMenus();
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -1747,11 +1747,15 @@ var AppInfo = {};
|
|||
AppInfo.enableNavDrawer = false;
|
||||
AppInfo.enableSearchInTopMenu = false;
|
||||
AppInfo.enableHomeFavorites = false;
|
||||
AppInfo.enableNowPlayingBar = false;
|
||||
AppInfo.enableCustomHomeSections = false;
|
||||
AppInfo.enableHomeTabs = false;
|
||||
AppInfo.enableNowPlayingPageBottomTabs = false;
|
||||
|
||||
// Disable the now playing bar for the iphone since we already have the now playing tab at the bottom
|
||||
if (navigator.userAgent.toString().toLowerCase().indexOf('iphone') != -1) {
|
||||
AppInfo.enableNowPlayingBar = false;
|
||||
}
|
||||
|
||||
} else {
|
||||
if (isMobile) {
|
||||
|
||||
|
@ -2479,8 +2483,6 @@ pageClassOn('pageshow', "page", function () {
|
|||
}
|
||||
}
|
||||
|
||||
Events.trigger(page, 'pageshowready');
|
||||
|
||||
Dashboard.ensureHeader(page);
|
||||
|
||||
if (apiClient && !apiClient.isWebSocketOpen()) {
|
||||
|
|
|
@ -326,6 +326,8 @@
|
|||
|
||||
function reloadData(page) {
|
||||
|
||||
lastDataLoad = 0;
|
||||
|
||||
Dashboard.showLoadingMsg();
|
||||
|
||||
var options = {};
|
||||
|
@ -344,9 +346,6 @@
|
|||
|
||||
loadData(page, response.Items);
|
||||
|
||||
setTimeout(function () {
|
||||
loadData(page, response.Items);
|
||||
}, 2000);
|
||||
Dashboard.hideLoadingMsg();
|
||||
|
||||
});
|
||||
|
@ -396,7 +395,6 @@
|
|||
$(document).on('pageshow', ".syncActivityPage", function () {
|
||||
|
||||
var page = this;
|
||||
lastDataLoad = 0;
|
||||
|
||||
Dashboard.getPluginSecurityInfo().done(function (pluginSecurityInfo) {
|
||||
|
||||
|
|
|
@ -225,3 +225,11 @@ paper-tab {
|
|||
.nowPlayingPageBackButton {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.nowPlayingPage .libraryViewNav {
|
||||
top: 0 !important;
|
||||
}
|
||||
|
||||
.nowPlayingPage {
|
||||
padding-top: 40px !important;
|
||||
}
|
||||
|
|
|
@ -3193,10 +3193,13 @@ $.widget( "mobile.page", {
|
|||
|
||||
if (from) {
|
||||
from[0].style.display = 'none';
|
||||
//var pages = document.querySelectorAll("div[data-role='page']");
|
||||
//for (var i = 0, length = pages.length; i < length; i++) {
|
||||
// pages[i].style.display = 'none';
|
||||
//}
|
||||
var pages = this.element[0].childNodes;
|
||||
for (var i = 0, length = pages.length; i < length; i++) {
|
||||
var pg = pages[i];
|
||||
if (pg.getAttribute && pg.getAttribute('data-role') == 'page') {
|
||||
pg.style.display = 'none';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
var toPage = to[0];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue