1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

add mono CreateWebRequest workaround

This commit is contained in:
Luke Pulverenti 2015-06-07 17:21:30 -04:00
parent 386e63ee64
commit ec469a7b05
18 changed files with 184 additions and 106 deletions

View file

@ -38,7 +38,7 @@
// html += '<button class="headerButtonViewMenu headerButton headerButtonRight" type="button" data-role="none"><i class="material-icons">more_vert</i></button>';
//}
if (!$.browser.mobile && !AppInfo.isTouchPreferred) {
if (!$.browser.mobile && !AppInfo.isNativeApp) {
html += '<a href="dashboard.html" class="headerButton headerButtonRight dashboardEntryHeaderButton" style="display:none;"><i class="material-icons">settings</i></a>';
}
@ -101,6 +101,21 @@
$(initViewMenuBarHeadroom);
//$('.headerButtonViewMenu').off('click', onViewButtonClick).on('click', onViewButtonClick);
if (AppInfo.isNativeApp) {
$(document).off('swiperight.drawer').on('swiperight.drawer', '.libraryPage', onSwipeRight);
}
}
function onSwipeRight(event) {
if (event.swipestop && event.swipestop.coords) {
var x = event.swipestop.coords[0];
if (x < 50) {
showLibraryMenu();
}
}
}
//function onViewButtonClick() {
@ -155,7 +170,7 @@
html += Globalize.translate('HeaderAdmin');
html += '</div>';
html += '<a class="sidebarLink lnkMediaFolder" data-itemid="dashboard" href="dashboard.html"><span class="fa fa-server sidebarLinkIcon"></span>' + Globalize.translate('ButtonManageServer') + '</a>';
html += '<a class="sidebarLink lnkMediaFolder lnkManageServer" data-itemid="dashboard" href="#"><span class="fa fa-server sidebarLinkIcon"></span>' + Globalize.translate('ButtonManageServer') + '</a>';
html += '<a class="sidebarLink lnkMediaFolder editorViewMenu" data-itemid="editor" href="edititemmetadata.html"><span class="fa fa-edit sidebarLinkIcon"></span>' + Globalize.translate('ButtonMetadataManager') + '</a>';
if (!$.browser.mobile && !AppInfo.isTouchPreferred) {
@ -412,6 +427,8 @@
panel = $('#libraryPanel').panel({}).lazyChildren().trigger('create');
$('.lnkManageServer', panel).on('click', onManageServerClicked);
updateLibraryMenu();
}
else if (requiresLibraryMenuRefresh) {
@ -422,6 +439,17 @@
return panel;
}
function onManageServerClicked() {
requirejs(["scripts/registrationservices"], function () {
RegistrationServices.validateFeature('manageserver').done(function () {
Dashboard.navigate('dashboard.html');
});
});
}
function getDashboardMenu(page) {
var panel = $('#dashboardPanel', page);