diff --git a/dashboard-ui/scripts/actionsheet.js b/dashboard-ui/scripts/actionsheet.js
index d167ed665b..cc2d0082ab 100644
--- a/dashboard-ui/scripts/actionsheet.js
+++ b/dashboard-ui/scripts/actionsheet.js
@@ -15,7 +15,11 @@
var style = "";
- if (options.positionTo) {
+ var windowHeight = $(window).height();
+
+ // If the window height is under a certain amount, don't bother trying to position
+ // based on an element.
+ if (options.positionTo && windowHeight > 600) {
var pos = $(options.positionTo).offset();
@@ -27,7 +31,7 @@
pos.left -= 24;
// Account for popup size - we can't predict this yet so just estimate
- pos.top -= 100;
+ pos.top -= (55 * options.items.length) / 2;
pos.left -= 80;
// Account for scroll position
@@ -53,7 +57,13 @@
html += '';
}
- html += '
';
+ // There seems to be a bug with this in safari causing it to immediately roll up to 0 height
+ var isScrollable = !$.browser.safari;
+
+ if (isScrollable) {
+ html += '';
+ }
+
for (var i = 0, length = options.items.length; i < length; i++) {
var option = options.items[i];
@@ -67,7 +77,7 @@
html += '';
}
- html += ' ';
+ //html += ' ';
if (options.showCancel) {
html += '
';
@@ -75,16 +85,18 @@
html += '
';
}
- html += '';
+ if (isScrollable) {
+ html += '';
+ }
- $(html).appendTo(document.body);
+ $(document.body).append(html);
setTimeout(function () {
var dlg = document.getElementById(id);
dlg.open();
// Has to be assigned a z-index after the call to .open()
- $(dlg).css('z-index', '999999').on('iron-overlay-closed', onClosed);
+ $(dlg).on('iron-overlay-closed', onClosed);
$('.btnOption', dlg).on('click', function () {
diff --git a/dashboard-ui/scripts/autoorganizelog.js b/dashboard-ui/scripts/autoorganizelog.js
index d6d78e6323..e509bac735 100644
--- a/dashboard-ui/scripts/autoorganizelog.js
+++ b/dashboard-ui/scripts/autoorganizelog.js
@@ -368,7 +368,7 @@
$(ApiClient).on("websocketmessage.autoorganizelog", onWebSocketMessage);
- }).on('pagehide', "#libraryFileOrganizerLogPage", function () {
+ }).on('pagebeforehide', "#libraryFileOrganizerLogPage", function () {
var page = this;
diff --git a/dashboard-ui/scripts/backdrops.js b/dashboard-ui/scripts/backdrops.js
index 646a781c2a..019ac14664 100644
--- a/dashboard-ui/scripts/backdrops.js
+++ b/dashboard-ui/scripts/backdrops.js
@@ -2,14 +2,14 @@
function getElement() {
- var elem = $('.backdropContainer');
+ //var elem = $('.backdropContainer');
- if (!elem.length) {
+ //if (!elem.length) {
- elem = $('
').prependTo(document.body);
- }
+ // elem = $('
').prependTo(document.body);
+ //}
- return elem;
+ return $(document.documentElement).addClass('backdropContainer');
}
function getRandom(min, max) {
@@ -112,7 +112,7 @@
function clearBackdrop() {
- $('.backdropContainer').css('backgroundImage', '');
+ $('.backdropContainer').css('backgroundImage', '').removeClass('backdropContainer');
}
function isEnabledByDefault() {
@@ -122,12 +122,6 @@
return false;
}
- // It flickers too much in IE
- if ($.browser.msie) {
-
- return false;
- }
-
if ($.browser.android && AppInfo.isNativeApp) {
return screen.availWidth >= 1200;
}
diff --git a/dashboard-ui/scripts/dashboardpage.js b/dashboard-ui/scripts/dashboardpage.js
index 4b5e2cf274..cee52bf056 100644
--- a/dashboard-ui/scripts/dashboardpage.js
+++ b/dashboard-ui/scripts/dashboardpage.js
@@ -1009,7 +1009,7 @@
}
};
-$(document).on('pageshowready', "#dashboardPage", DashboardPage.onPageShow).on('pagehide', "#dashboardPage", DashboardPage.onPageHide);
+$(document).on('pageshowready', "#dashboardPage", DashboardPage.onPageShow).on('pagebeforehide', "#dashboardPage", DashboardPage.onPageHide);
(function ($, document, window) {
diff --git a/dashboard-ui/scripts/editcollectionitems.js b/dashboard-ui/scripts/editcollectionitems.js
index 567e0eb23f..e5f897ceae 100644
--- a/dashboard-ui/scripts/editcollectionitems.js
+++ b/dashboard-ui/scripts/editcollectionitems.js
@@ -289,7 +289,7 @@
$("#txtLookupName").focus().select();
});
- }).on('pagehide', "#editCollectionTitlesPage", function () {
+ }).on('pagebeforehide', "#editCollectionTitlesPage", function () {
var page = this;
diff --git a/dashboard-ui/scripts/edititemimages.js b/dashboard-ui/scripts/edititemimages.js
index 561fe709f8..6e5b52901b 100644
--- a/dashboard-ui/scripts/edititemimages.js
+++ b/dashboard-ui/scripts/edititemimages.js
@@ -596,7 +596,7 @@
return false;
});
- }).on('pagehide', "#editItemImagesPage", function () {
+ }).on('pagebeforehide', "#editItemImagesPage", function () {
var page = this;
diff --git a/dashboard-ui/scripts/edititemmetadata.js b/dashboard-ui/scripts/edititemmetadata.js
index 592d62bda9..7ebf40ffed 100644
--- a/dashboard-ui/scripts/edititemmetadata.js
+++ b/dashboard-ui/scripts/edititemmetadata.js
@@ -1462,7 +1462,7 @@
}
});
- }).on('pagehide', "#editItemMetadataPage", function () {
+ }).on('pagebeforehide', "#editItemMetadataPage", function () {
var page = this;
$(LibraryBrowser).off('itemdeleting.editor');
diff --git a/dashboard-ui/scripts/edititemsubtitles.js b/dashboard-ui/scripts/edititemsubtitles.js
index e1812d763c..49b2308f5a 100644
--- a/dashboard-ui/scripts/edititemsubtitles.js
+++ b/dashboard-ui/scripts/edititemsubtitles.js
@@ -343,7 +343,7 @@
$(ApiClient).on("websocketmessage", onWebSocketMessageReceived);
- }).on('pagehide', "#editItemSubtitlesPage", function () {
+ }).on('pagebeforehide', "#editItemSubtitlesPage", function () {
var page = this;
diff --git a/dashboard-ui/scripts/homelatest.js b/dashboard-ui/scripts/homelatest.js
index 24cd2a692e..059ac32545 100644
--- a/dashboard-ui/scripts/homelatest.js
+++ b/dashboard-ui/scripts/homelatest.js
@@ -23,9 +23,16 @@
var latestMediElem = $('.section0', page);
- Sections.loadRecentlyAdded(latestMediElem, user, context);
- Sections.loadLatestLiveTvRecordings($(".section1", page), userId);
- Sections.loadLatestChannelItems($(".section2", page), userId);
+ Dashboard.showLoadingMsg();
+ var promises = [];
+
+ promises.push(Sections.loadRecentlyAdded(latestMediElem, user, context));
+ promises.push(Sections.loadLatestLiveTvRecordings($(".section1", page), userId));
+ promises.push(Sections.loadLatestChannelItems($(".section2", page), userId));
+
+ $.when(promises).done(function() {
+ Dashboard.hideLoadingMsg();
+ });
}
$(document).on('pagebeforeshowready', "#homeLatestPage", function () {
diff --git a/dashboard-ui/scripts/itembynamedetailpage.js b/dashboard-ui/scripts/itembynamedetailpage.js
index 8f3e42c26e..0f12ba395d 100644
--- a/dashboard-ui/scripts/itembynamedetailpage.js
+++ b/dashboard-ui/scripts/itembynamedetailpage.js
@@ -77,9 +77,9 @@
Dashboard.getCurrentUser().done(function (user) {
if (MediaController.canPlay(item)) {
- $('.btnPlay', page).show();
+ $('.btnPlay', page).visible(true);
} else {
- $('.btnPlay', page).hide();
+ $('.btnPlay', page).visible(false);
}
if (SyncManager.isAvailable(item, user)) {
@@ -93,9 +93,9 @@
$('#itemImage', page).html(LibraryBrowser.getDetailImageHtml(item, editImagesHref, true));
if (LibraryBrowser.getMoreCommands(item, user).length) {
- $('.btnMoreCommands', page).show();
+ $('.btnMoreCommands', page).visible(true);
} else {
- $('.btnMoreCommands', page).show();
+ $('.btnMoreCommands', page).visible(false);
}
});
@@ -593,7 +593,7 @@
reload(page);
- }).on('pagehide', "#itemByNameDetailPage", function () {
+ }).on('pagebeforehide', "#itemByNameDetailPage", function () {
currentItem = null;
});
diff --git a/dashboard-ui/scripts/itemdetailpage.js b/dashboard-ui/scripts/itemdetailpage.js
index dcfe93b172..c7ea2522aa 100644
--- a/dashboard-ui/scripts/itemdetailpage.js
+++ b/dashboard-ui/scripts/itemdetailpage.js
@@ -1664,7 +1664,7 @@
}
});
- }).on('pagehide', "#itemDetailPage", function () {
+ }).on('pagebeforehide', "#itemDetailPage", function () {
$(LibraryBrowser).off('itemdeleting.detailpage');
diff --git a/dashboard-ui/scripts/itemlistpage.js b/dashboard-ui/scripts/itemlistpage.js
index a132d773cc..602e904234 100644
--- a/dashboard-ui/scripts/itemlistpage.js
+++ b/dashboard-ui/scripts/itemlistpage.js
@@ -270,7 +270,7 @@
updateFilterControls(page);
- }).on('pagehide', "#itemListPage", function () {
+ }).on('pagebeforehide', "#itemListPage", function () {
currentItem = null;
diff --git a/dashboard-ui/scripts/librarylist.js b/dashboard-ui/scripts/librarylist.js
index 6faf7e0a93..efe9a18caf 100644
--- a/dashboard-ui/scripts/librarylist.js
+++ b/dashboard-ui/scripts/librarylist.js
@@ -185,169 +185,6 @@
return false;
}
- function onAddToCollectionButtonClick() {
-
- var id = this.getAttribute('data-itemid');
-
- closeContextMenu();
-
- BoxSetEditor.showPanel([id]);
-
- return false;
- }
-
- function onAddToPlaylistButtonClick() {
-
- var id = this.getAttribute('data-itemid');
-
- closeContextMenu();
-
- PlaylistManager.showPanel([id]);
-
- return false;
- }
-
- function onShuffleButtonClick() {
-
- var id = this.getAttribute('data-itemid');
-
- MediaController.shuffle(id);
-
- closeContextMenu();
-
- return false;
- }
-
- function onInstantMixButtonClick() {
-
- var id = this.getAttribute('data-itemid');
-
- MediaController.instantMix(id);
-
- closeContextMenu();
-
- return false;
- }
-
- function onQueueButtonClick() {
-
- var id = this.getAttribute('data-itemid');
-
- MediaController.queue(id);
-
- closeContextMenu();
-
- return false;
- }
-
- function onPlayButtonClick() {
-
- var id = this.getAttribute('data-itemid');
-
- MediaController.play(id);
-
- closeContextMenu();
-
- return false;
- }
-
- function onDeleteButtonClick() {
-
- var id = this.getAttribute('data-itemid');
-
- closeContextMenu();
-
- LibraryBrowser.deleteItem(id);
-
- return false;
- }
-
- function onSyncButtonClick() {
-
- var id = this.getAttribute('data-itemid');
-
- closeContextMenu();
-
- SyncManager.showMenu({
- items: [
- {
- Id: id
- }]
- });
-
- return false;
- }
-
- function onExternalPlayerButtonClick() {
-
- closeContextMenu();
-
- var id = this.getAttribute('data-itemid');
-
- LibraryBrowser.playInExternalPlayer(id);
-
- return false;
- }
-
- function onPlayAllFromHereButtonClick() {
-
- var index = this.getAttribute('data-index');
-
- var page = $(this).parents('.page');
-
- var itemsContainer = $('.hasContextMenu', page).parents('.itemsContainer');
-
- closeContextMenu();
-
- itemsContainer.trigger('playallfromhere', [index]);
-
- return false;
- }
-
- function onQueueAllFromHereButtonClick() {
-
- var index = this.getAttribute('data-index');
-
- var page = $(this).parents('.page');
-
- var itemsContainer = $('.hasContextMenu', page).parents('.itemsContainer');
-
- closeContextMenu();
-
- itemsContainer.trigger('queueallfromhere', [index]);
-
- return false;
- }
-
- function onRemoveFromPlaylistButtonClick() {
-
- var playlistItemId = this.getAttribute('data-playlistitemid');
-
- var page = $(this).parents('.page');
-
- var itemsContainer = $('.hasContextMenu', page).parents('.itemsContainer');
-
- itemsContainer.trigger('removefromplaylist', [playlistItemId]);
-
- closeContextMenu();
-
- return false;
- }
-
- function onResumeButtonClick() {
-
- var id = this.getAttribute('data-itemid');
-
- MediaController.play({
- ids: [id],
- startPositionTicks: parseInt(this.getAttribute('data-ticks'))
- });
-
- closeContextMenu();
-
- return false;
- }
-
function onCardTapHold(e) {
showContextMenu(this, {});
@@ -379,116 +216,256 @@
var albumid = card.getAttribute('data-albumid');
var artistid = card.getAttribute('data-artistid');
- $(card).addClass('hasContextMenu');
-
Dashboard.getCurrentUser().done(function (user) {
- var html = '';
+ require(['actionsheet'], function () {
- $($.mobile.activePage).append(html);
+ ActionSheetElement.show({
+ items: items,
+ positionTo: displayContextItem,
+ callback: function (id) {
- var elem = $('.tapHoldMenu').popup({ positionTo: displayContextItem }).trigger('create').popup("open").on("popupafterclose", function () {
+ switch (id) {
+
+ case 'addtocollection':
+ BoxSetEditor.showPanel([itemId]);
+ break;
+ case 'playlist':
+ PlaylistManager.showPanel([itemId]);
+ break;
+ case 'delete':
+ LibraryBrowser.deleteItem(itemId);
+ break;
+ case 'download':
+ {
+ var downloadHref = ApiClient.getUrl("Items/" + itemId + "/Download", {
+ api_key: ApiClient.accessToken()
+ });
+ window.location.href = downloadHref;
+
+ break;
+ }
+ case 'edit':
+ Dashboard.navigate('edititemmetadata.html?id=' + itemId);
+ break;
+ case 'refresh':
+ ApiClient.refreshItem(itemId, {
+
+ Recursive: true,
+ ImageRefreshMode: 'FullRefresh',
+ MetadataRefreshMode: 'FullRefresh',
+ ReplaceAllImages: false,
+ ReplaceAllMetadata: true
+ });
+ break;
+ case 'instantmix':
+ MediaController.instantMix(itemId);
+ break;
+ case 'shuffle':
+ MediaController.shuffle(itemId);
+ break;
+ case 'open':
+ Dashboard.navigate(href);
+ break;
+ case 'album':
+ Dashboard.navigate('itemdetails.html?id=' + albumid);
+ break;
+ case 'artist':
+ Dashboard.navigate('tembynamedetails.html?context=music&id=' + artistid);
+ break;
+ case 'play':
+ MediaController.MediaController(itemId);
+ break;
+ case 'playallfromhere':
+ $(card).parents('.itemsContainer').trigger('playallfromhere', [index]);
+ break;
+ case 'queue':
+ MediaController.queue(itemId);
+ break;
+ case 'trailer':
+ ApiClient.getLocalTrailers(Dashboard.getCurrentUserId(), itemId).done(function (trailers) {
+ MediaController.play({ items: trailers });
+ });
+ break;
+ case 'resume':
+ MediaController.play({
+ ids: [itemId],
+ startPositionTicks: playbackPositionTicks
+ });
+ break;
+ case 'queueallfromhere':
+ $(card).parents('.itemsContainer').trigger('queueallfromhere', [index]);
+ break;
+ case 'sync':
+ SyncManager.showMenu({
+ items: [
+ {
+ Id: itemId
+ }]
+ });
+ break;
+ case 'externalplayer':
+ LibraryBrowser.playInExternalPlayer(itemId);
+ break;
+ case 'removefromplaylist':
+ $(card).parents('.itemsContainer').trigger('removefromplaylist', [playlistItemId]);
+ break;
+ default:
+ break;
+ }
+ }
+ });
- $(this).off("popupafterclose").remove();
- $(card).removeClass('hasContextMenu');
});
-
- $('.btnPlay', elem).on('click', onPlayButtonClick);
- $('.btnResume', elem).on('click', onResumeButtonClick);
- $('.btnQueue', elem).on('click', onQueueButtonClick);
- $('.btnInstantMix', elem).on('click', onInstantMixButtonClick);
- $('.btnShuffle', elem).on('click', onShuffleButtonClick);
- $('.btnPlayTrailer', elem).on('click', onTrailerButtonClick);
- $('.btnAddToPlaylist', elem).on('click', onAddToPlaylistButtonClick);
- $('.btnRemoveFromPlaylist', elem).on('click', onRemoveFromPlaylistButtonClick);
- $('.btnPlayAllFromHere', elem).on('click', onPlayAllFromHereButtonClick);
- $('.btnQueueAllFromHere', elem).on('click', onQueueAllFromHereButtonClick);
- $('.btnExternalPlayer', elem).on('click', onExternalPlayerButtonClick);
- $('.btnDelete', elem).on('click', onDeleteButtonClick);
- $('.btnSync', elem).on('click', onSyncButtonClick);
- $('.btnAddToCollection', elem).on('click', onAddToCollectionButtonClick);
});
}
@@ -506,8 +483,6 @@
var itemId = card.getAttribute('data-itemid');
var context = card.getAttribute('data-context');
- $(card).addClass('hasContextMenu');
-
var userId = Dashboard.getCurrentUserId();
var options = {
@@ -816,10 +791,6 @@
elem = $('a', elem)[0];
- if ($(elem).hasClass('hasContextMenu')) {
- return;
- }
-
if ($('.itemSelectionPanel:visible', elem).length) {
return;
}
diff --git a/dashboard-ui/scripts/librarymenu.js b/dashboard-ui/scripts/librarymenu.js
index 8b7056eb0d..20be1c8e31 100644
--- a/dashboard-ui/scripts/librarymenu.js
+++ b/dashboard-ui/scripts/librarymenu.js
@@ -675,7 +675,7 @@
onPageShowDocumentReady(page);
- }).on('pagehide', ".page", function () {
+ }).on('pagebeforehide', ".page", function () {
if (addNextToBackStack) {
var text = $('.libraryMenuButtonText').text() || document.title;
@@ -685,8 +685,6 @@
addNextToBackStack = true;
- }).on('pagebeforehide', ".page", function () {
-
$('.headroomEnabled').addClass('headroomDisabled');
});
diff --git a/dashboard-ui/scripts/librarypathmapping.js b/dashboard-ui/scripts/librarypathmapping.js
index 0bba54ecfb..0146651035 100644
--- a/dashboard-ui/scripts/librarypathmapping.js
+++ b/dashboard-ui/scripts/librarypathmapping.js
@@ -129,7 +129,7 @@
});
- }).on('pagehide', "#libraryPathMappingPage", function () {
+ }).on('pagebeforehide', "#libraryPathMappingPage", function () {
currentConfig = null;
diff --git a/dashboard-ui/scripts/livetvchannel.js b/dashboard-ui/scripts/livetvchannel.js
index ebbca9b4d5..5f1a4f582a 100644
--- a/dashboard-ui/scripts/livetvchannel.js
+++ b/dashboard-ui/scripts/livetvchannel.js
@@ -166,12 +166,12 @@
var page = this;
- $('#btnPlay', page).on('click', function () {
+ $('.btnPlay', page).on('click', function () {
var userdata = currentItem.UserData || {};
LibraryBrowser.showPlayMenu(null, currentItem.Id, currentItem.Type, false, currentItem.MediaType, userdata.PlaybackPositionTicks);
});
- $('#btnEdit', page).on('click', function () {
+ $('.btnEdit', page).on('click', function () {
Dashboard.navigate("edititemmetadata.html?channelid=" + currentItem.Id);
});
@@ -182,7 +182,7 @@
reload(page);
- }).on('pagehide', "#liveTvChannelPage", function () {
+ }).on('pagebeforehide', "#liveTvChannelPage", function () {
currentItem = null;
programs = null;
diff --git a/dashboard-ui/scripts/livetvnewrecording.js b/dashboard-ui/scripts/livetvnewrecording.js
index 692a3d14fa..0218ed5801 100644
--- a/dashboard-ui/scripts/livetvnewrecording.js
+++ b/dashboard-ui/scripts/livetvnewrecording.js
@@ -175,7 +175,7 @@
reload(page);
- }).on('pagehide', "#liveTvNewRecordingPage", function () {
+ }).on('pagebeforehide', "#liveTvNewRecordingPage", function () {
currentProgram = null;
diff --git a/dashboard-ui/scripts/livetvprogram.js b/dashboard-ui/scripts/livetvprogram.js
index 7df553ce31..6d5e99d8be 100644
--- a/dashboard-ui/scripts/livetvprogram.js
+++ b/dashboard-ui/scripts/livetvprogram.js
@@ -98,7 +98,7 @@
var page = this;
- $('#btnRecord', page).on('click', function() {
+ $('.btnRecord', page).on('click', function() {
var id = getParameterByName('id');
@@ -106,7 +106,7 @@
});
- $('#btnPlay', page).on('click', function () {
+ $('.btnPlay', page).on('click', function () {
ApiClient.getLiveTvChannel(currentItem.ChannelId, Dashboard.getCurrentUserId()).done(function (channel) {
@@ -116,7 +116,7 @@
});
});
- $('#btnCancelRecording', page).on('click', function () {
+ $('.btnCancelRecording', page).on('click', function () {
deleteTimer(page, currentItem.TimerId);
});
@@ -127,7 +127,7 @@
reload(page);
- }).on('pagehide', "#liveTvProgramPage", function () {
+ }).on('pagebeforehide', "#liveTvProgramPage", function () {
currentItem = null;
});
diff --git a/dashboard-ui/scripts/livetvrecording.js b/dashboard-ui/scripts/livetvrecording.js
index cb9ec7c1c5..fa6d62591d 100644
--- a/dashboard-ui/scripts/livetvrecording.js
+++ b/dashboard-ui/scripts/livetvrecording.js
@@ -106,8 +106,8 @@
var page = this;
- $('#btnDelete', page).on('click', deleteRecording);
- $('#btnPlay', page).on('click', play);
+ $('.btnDelete', page).on('click', deleteRecording);
+ $('.btnPlay', page).on('click', play);
$('.btnSync', page).on('click', function () {
@@ -122,7 +122,7 @@
reload(page);
- }).on('pagehide', "#liveTvRecordingPage", function () {
+ }).on('pagebeforehide', "#liveTvRecordingPage", function () {
currentItem = null;
});
diff --git a/dashboard-ui/scripts/livetvseriestimer.js b/dashboard-ui/scripts/livetvseriestimer.js
index 5c57d49c87..165645abe5 100644
--- a/dashboard-ui/scripts/livetvseriestimer.js
+++ b/dashboard-ui/scripts/livetvseriestimer.js
@@ -285,7 +285,7 @@
reload(page);
- }).on('pagehide', "#liveTvSeriesTimerPage", function () {
+ }).on('pagebeforehide', "#liveTvSeriesTimerPage", function () {
currentItem = null;
});
diff --git a/dashboard-ui/scripts/livetvstatus.js b/dashboard-ui/scripts/livetvstatus.js
index 1b84c53bc6..4b4de3fedc 100644
--- a/dashboard-ui/scripts/livetvstatus.js
+++ b/dashboard-ui/scripts/livetvstatus.js
@@ -190,7 +190,7 @@
taskKey: 'RefreshGuide'
});
- }).on('pagehide', "#liveTvStatusPage", function () {
+ }).on('pagebeforehide', "#liveTvStatusPage", function () {
var page = this;
diff --git a/dashboard-ui/scripts/livetvtimer.js b/dashboard-ui/scripts/livetvtimer.js
index 2d7347f3b3..acde2b74f0 100644
--- a/dashboard-ui/scripts/livetvtimer.js
+++ b/dashboard-ui/scripts/livetvtimer.js
@@ -121,7 +121,7 @@
reload(page);
- }).on('pagehide', "#liveTvTimerPage", function () {
+ }).on('pagebeforehide', "#liveTvTimerPage", function () {
currentItem = null;
});
diff --git a/dashboard-ui/scripts/medialibrarypage.js b/dashboard-ui/scripts/medialibrarypage.js
index 2a13ef6a3e..e47f611517 100644
--- a/dashboard-ui/scripts/medialibrarypage.js
+++ b/dashboard-ui/scripts/medialibrarypage.js
@@ -383,7 +383,7 @@ var WizardLibraryPage = {
taskKey: 'RefreshLibrary'
});
- }).on('pagehide', "#mediaLibraryPage", function () {
+ }).on('pagebeforehide', "#mediaLibraryPage", function () {
var page = this;
diff --git a/dashboard-ui/scripts/mypreferencesdisplay.js b/dashboard-ui/scripts/mypreferencesdisplay.js
index f0a6c5ecec..37a5a0c37c 100644
--- a/dashboard-ui/scripts/mypreferencesdisplay.js
+++ b/dashboard-ui/scripts/mypreferencesdisplay.js
@@ -236,8 +236,7 @@
ApiClient.updateUserConfiguration(user.Id, user.Configuration).done(function () {
Dashboard.alert(Globalize.translate('SettingsSaved'));
- loadForm(page, user, false);
-
+ loadForm(page, user);
});
}
diff --git a/dashboard-ui/scripts/nowplayingbar.js b/dashboard-ui/scripts/nowplayingbar.js
index 9c68a1a504..3d91ec75b1 100644
--- a/dashboard-ui/scripts/nowplayingbar.js
+++ b/dashboard-ui/scripts/nowplayingbar.js
@@ -29,8 +29,8 @@
html += '
';
// The onclicks are needed due to the return false above
- html += '
';
- html += '
';
+ html += '
';
+ html += '
';
html += '
';
diff --git a/dashboard-ui/scripts/nowplayingpage.js b/dashboard-ui/scripts/nowplayingpage.js
index 3ec6cf54cf..d227ef3d65 100644
--- a/dashboard-ui/scripts/nowplayingpage.js
+++ b/dashboard-ui/scripts/nowplayingpage.js
@@ -749,7 +749,7 @@
showIntro();
loadPlaylist(page);
- }).on('pagehide', "#nowPlayingPage", function () {
+ }).on('pagebeforehide', "#nowPlayingPage", function () {
releaseCurrentPlayer();
diff --git a/dashboard-ui/scripts/scheduledtaskspage.js b/dashboard-ui/scripts/scheduledtaskspage.js
index da2c6d587b..76cb0ad5af 100644
--- a/dashboard-ui/scripts/scheduledtaskspage.js
+++ b/dashboard-ui/scripts/scheduledtaskspage.js
@@ -215,7 +215,7 @@
$(ApiClient).on("websocketmessage", onWebSocketMessage).on("websocketopen", onWebSocketConnectionOpen);
- }).on('pagehide', "#scheduledTasksPage", function () {
+ }).on('pagebeforehide', "#scheduledTasksPage", function () {
var page = this;
diff --git a/dashboard-ui/scripts/search.js b/dashboard-ui/scripts/search.js
index 8a5d697dc5..3a5b969e8d 100644
--- a/dashboard-ui/scripts/search.js
+++ b/dashboard-ui/scripts/search.js
@@ -239,7 +239,7 @@
});
}
- $(document).on('pagehide', ".libraryPage", function () {
+ $(document).on('pagebeforehide', ".libraryPage", function () {
$('#txtSearch', this).val('');
$('#searchHints', this).empty();
diff --git a/dashboard-ui/scripts/site.js b/dashboard-ui/scripts/site.js
index cfd572976d..a3d7f8f36d 100644
--- a/dashboard-ui/scripts/site.js
+++ b/dashboard-ui/scripts/site.js
@@ -1661,7 +1661,7 @@ var AppInfo = {};
if (isCordova) {
AppInfo.enableBottomTabs = true;
AppInfo.cardMargin = 'mediumCardMargin';
- AppInfo.enableSectionTransitions = true;
+ //AppInfo.enableSectionTransitions = true;
} else {
if (isMobile) {
diff --git a/dashboard-ui/scripts/syncactivity.js b/dashboard-ui/scripts/syncactivity.js
index 1cbcf77031..9b956fd3f0 100644
--- a/dashboard-ui/scripts/syncactivity.js
+++ b/dashboard-ui/scripts/syncactivity.js
@@ -314,7 +314,7 @@
startListening(page);
$(ApiClient).on("websocketmessage.syncactivity", onWebSocketMessage);
- }).on('pagehide', ".syncActivityPage", function () {
+ }).on('pagebeforehide', ".syncActivityPage", function () {
var page = this;
diff --git a/dashboard-ui/scripts/syncjob.js b/dashboard-ui/scripts/syncjob.js
index f93620dc5c..3299338fc8 100644
--- a/dashboard-ui/scripts/syncjob.js
+++ b/dashboard-ui/scripts/syncjob.js
@@ -395,7 +395,7 @@
startListening(page);
$(ApiClient).on("websocketmessage.syncJobPage", onWebSocketMessage);
- }).on('pagehide', ".syncJobPage", function () {
+ }).on('pagebeforehide', ".syncJobPage", function () {
var page = this;
diff --git a/dashboard-ui/thirdparty/emby-icons.html b/dashboard-ui/thirdparty/emby-icons.html
index 71a98728c8..fa946ea05a 100644
--- a/dashboard-ui/thirdparty/emby-icons.html
+++ b/dashboard-ui/thirdparty/emby-icons.html
@@ -38,6 +38,7 @@ See [iron-iconset](#iron-iconset) and [iron-iconset-svg](#iron-iconset-svg) for
+
@@ -49,17 +50,20 @@ See [iron-iconset](#iron-iconset) and [iron-iconset-svg](#iron-iconset-svg) for
+
+
+
diff --git a/dashboard-ui/thirdparty/jquery.unveil-custom.js b/dashboard-ui/thirdparty/jquery.unveil-custom.js
index f53f271b02..c88e275f0c 100644
--- a/dashboard-ui/thirdparty/jquery.unveil-custom.js
+++ b/dashboard-ui/thirdparty/jquery.unveil-custom.js
@@ -20,7 +20,7 @@
// Need to fix those before this can be set to 0
if (window.AppInfo && AppInfo.isNativeApp && $.browser.safari) {
- return 8000;
+ return 7500;
}
var screens = $.browser.mobile ? 2.5 : 1;
@@ -102,7 +102,7 @@
function setImageIntoElement(elem, url) {
- if (elem.tagName === "DIV") {
+ if (elem.tagName !== "IMG") {
elem.style.backgroundImage = "url('" + url + "')";
diff --git a/dashboard-ui/thirdparty/jquerymobile-1.4.5/jquery.mobile.custom.js b/dashboard-ui/thirdparty/jquerymobile-1.4.5/jquery.mobile.custom.js
index 8a5f845cc3..95d435eabd 100644
--- a/dashboard-ui/thirdparty/jquerymobile-1.4.5/jquery.mobile.custom.js
+++ b/dashboard-ui/thirdparty/jquerymobile-1.4.5/jquery.mobile.custom.js
@@ -4903,6 +4903,112 @@ $.fn.grid = function( options ) {
$.mobile.pageContainer.toggleClass( "ui-mobile-viewport-transitioning viewport-" + this.name );
},
+ slide: function (Velocity) {
+
+ var trans = this;
+
+ if (trans.reverse) {
+
+ $(trans.$from).show().css('left', '0').css('right', '0');
+
+ Velocity.animate($(trans.$from)[0], { "left": "100%", "right": "-100%" },
+ {
+ easing: "ease-in-out",
+ duration: 800,
+
+ begin: function (elements, complete, remaining, start, tweenValue) {
+
+ $(trans.$to).show().css('left', '-100%').css('right', '100%');
+
+ Velocity.animate($(trans.$to)[0], { "left": "0", "right": "0" },
+ {
+ complete: function () {
+ $(trans.$from).hide();
+ trans.toggleViewportClass();
+ trans.deferred.resolve(trans.name, trans.reverse, trans.$to, trans.$from, true);
+ },
+
+ easing: "ease-in-out",
+ duration: 800
+
+ });
+ }
+
+ });
+
+ } else {
+
+ Velocity.animate($(trans.$from)[0], {
+ "left": "-100%",
+ "right": "100%"
+ },
+ {
+ easing: "ease-in-out",
+ duration: 800,
+
+ begin: function (elements, complete, remaining, start, tweenValue) {
+
+ $(trans.$to).show().css('left', '100%');
+
+ Velocity.animate($(trans.$to)[0], { "left": "0px" },
+ {
+ complete: function () {
+ $(trans.$from).hide();
+ trans.toggleViewportClass();
+ trans.deferred.resolve(trans.name, trans.reverse, trans.$to, trans.$from, true);
+ },
+
+ easing: "ease-in-out",
+ duration: 800
+
+ });
+ }
+
+ });
+
+ }
+ },
+
+ slideUp: function (Velocity) {
+
+ var trans = this;
+
+ if (trans.reverse) {
+
+ $(trans.$to).show();
+
+ Velocity.animate($(trans.$from)[0], { "top": "100%", bottom: '-100%' },
+ {
+ complete: function () {
+ $(trans.$from).hide();
+ trans.toggleViewportClass();
+ trans.deferred.resolve(trans.name, trans.reverse, trans.$to, trans.$from, true);
+ },
+
+ easing: "ease-in-out",
+ duration: 800
+
+ });
+
+ } else {
+
+ $(trans.$to).show().css('top', '100%').css('bottom', '-100%');
+
+ Velocity.animate($(trans.$to)[0], { "top": "0px", bottom: 0 },
+ {
+ complete: function () {
+ $(trans.$from).hide();
+ trans.toggleViewportClass();
+ trans.deferred.resolve(trans.name, trans.reverse, trans.$to, trans.$from, true);
+ },
+
+ easing: "ease-in-out",
+ duration: 800
+
+ });
+ }
+ },
+
transition: function() {
// NOTE many of these could be calculated/recorded in the constructor, it's my
// opinion that binding them as late as possible has value with regards to
@@ -4924,11 +5030,25 @@ $.fn.grid = function( options ) {
this.toggleViewportClass();
- if ( this.$from && !none ) {
- this.startOut( screenHeight, reverseClass, none );
- } else {
- this.doneOut( screenHeight, reverseClass, none, true );
- }
+ if (none) {
+ if (this.$from && !none) {
+ this.startOut(screenHeight, reverseClass, none);
+ } else {
+ this.doneOut(screenHeight, reverseClass, none, true);
+ }
+ } else {
+
+ var trans = this;
+
+ require(["jquery", "velocity"], function (d, Velocity) {
+
+ if (trans.name == 'slideup') {
+ trans.slideUp(Velocity);
+ } else {
+ trans.slide(Velocity);
+ }
+ });
+ }
return this.deferred.promise();
}
diff --git a/dashboard-ui/thirdparty/jquerymobile-1.4.5/jquery.mobile.custom.min.js b/dashboard-ui/thirdparty/jquerymobile-1.4.5/jquery.mobile.custom.min.js
index 792e97e7e3..9921b5d000 100644
--- a/dashboard-ui/thirdparty/jquerymobile-1.4.5/jquery.mobile.custom.min.js
+++ b/dashboard-ui/thirdparty/jquerymobile-1.4.5/jquery.mobile.custom.min.js
@@ -1,3 +1,6 @@
-/*! jQuery Mobile v1.4.5 | Copyright 2010, 2014 jQuery Foundation, Inc. | jquery.org/license */
-
-(function(e,t,n){typeof define=="function"&&define.amd?define(["jquery"],function(r){return n(r,e,t),r.mobile}):n(e.jQuery,e,t)})(this,document,function(e,t,n,r){(function(e,t,r){"$:nomunge";function l(e){return e=e||location.href,"#"+e.replace(/^[^#]*#?(.*)$/,"$1")}var i="hashchange",s=n,o,u=e.event.special,a=s.documentMode,f="on"+i in t&&(a===r||a>7);e.fn[i]=function(e){return e?this.bind(i,e):this.trigger(i)},e.fn[i].delay=50,u[i]=e.extend(u[i],{setup:function(){if(f)return!1;e(o.start)},teardown:function(){if(f)return!1;e(o.stop)}}),o=function(){function p(){var n=l(),r=h(u);n!==u?(c(u=n,r),e(t).trigger(i)):r!==u&&(location.href=location.href.replace(/#.*/,"")+r),o=setTimeout(p,e.fn[i].delay)}var n={},o,u=l(),a=function(e){return e},c=a,h=a;return n.start=function(){o||p()},n.stop=function(){o&&clearTimeout(o),o=r},t.attachEvent&&!t.addEventListener&&!f&&function(){var t,r;n.start=function(){t||(r=e.fn[i].src,r=r&&r+l(),t=e('
').hide().one("load",function(){r||c(l()),p()}).attr("src",r||"javascript:0").insertAfter("body")[0].contentWindow,s.onpropertychange=function(){try{event.propertyName==="title"&&(t.document.title=s.title)}catch(e){}})},n.stop=a,h=function(){return l(t.location.href)},c=function(n,r){var o=t.document,u=e.fn[i].domain;n!==r&&(o.title=s.title,o.open(),u&&o.write(''),o.close(),t.location.hash=n)}}(),n}()})(e,this),function(e){e.mobile={}}(e),function(e,t,n){e.extend(e.mobile,{version:"1.4.5",subPageUrlKey:"ui-page",hideUrlBar:!0,keepNative:":jqmData(role='none'), :jqmData(role='nojs')",activePageClass:"ui-page-active",activeBtnClass:"ui-btn-active",focusClass:"ui-focus",ajaxEnabled:!0,hashListeningEnabled:!0,linkBindingEnabled:!0,defaultPageTransition:"fade",maxTransitionWidth:!1,minScrollBack:0,defaultDialogTransition:"pop",pageLoadErrorMessage:"Error Loading Page",pageLoadErrorMessageTheme:"a",phonegapNavigationEnabled:!1,autoInitializePage:!0,pushStateEnabled:!0,ignoreContentEnabled:!1,buttonMarkup:{hoverDelay:200},dynamicBaseEnabled:!0,pageContainer:e(),allowCrossDomainPages:!1,dialogHashKey:"&ui-state=dialog"})}(e,this),function(e,t,n){var r={},i=e.find,s=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,o=/:jqmData\(([^)]*)\)/g;e.extend(e.mobile,{ns:"",getAttribute:function(t,n){var r;t=t.jquery?t[0]:t,t&&t.getAttribute&&(r=t.getAttribute("data-"+e.mobile.ns+n));try{r=r==="true"?!0:r==="false"?!1:r==="null"?null:+r+""===r?+r:s.test(r)?JSON.parse(r):r}catch(i){}return r},nsNormalizeDict:r,nsNormalize:function(t){return r[t]||(r[t]=e.camelCase(e.mobile.ns+t))},closestPageData:function(e){return e.closest(":jqmData(role='page'), :jqmData(role='dialog')").data("mobile-page")}}),e.fn.jqmData=function(t,r){var i;return typeof t!="undefined"&&(t&&(t=e.mobile.nsNormalize(t)),arguments.length<2||r===n?i=this.data(t):i=this.data(t,r)),i},e.jqmData=function(t,n,r){var i;return typeof n!="undefined"&&(i=e.data(t,n?e.mobile.nsNormalize(n):n,r)),i},e.fn.jqmRemoveData=function(t){return this.removeData(e.mobile.nsNormalize(t))},e.jqmRemoveData=function(t,n){return e.removeData(t,e.mobile.nsNormalize(n))},e.find=function(t,n,r,s){return t.indexOf(":jqmData")>-1&&(t=t.replace(o,"[data-"+(e.mobile.ns||"")+"$1]")),i.call(this,t,n,r,s)},e.extend(e.find,i)}(e,this),function(e,t){function s(t,n){var r,i,s,u=t.nodeName.toLowerCase();return"area"===u?(r=t.parentNode,i=r.name,!t.href||!i||r.nodeName.toLowerCase()!=="map"?!1:(s=e("img[usemap=#"+i+"]")[0],!!s&&o(s))):(/input|select|textarea|button|object/.test(u)?!t.disabled:"a"===u?t.href||n:n)&&o(t)}function o(t){return e.expr.filters.visible(t)&&!e(t).parents().addBack().filter(function(){return e.css(this,"visibility")==="hidden"}).length}var r=0,i=/^ui-id-\d+$/;e.ui=e.ui||{},e.extend(e.ui,{version:"c0ab71056b936627e8a7821f03c044aec6280a40",keyCode:{BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38}}),e.fn.extend({focus:function(t){return function(n,r){return typeof n=="number"?this.each(function(){var t=this;setTimeout(function(){e(t).focus(),r&&r.call(t)},n)}):t.apply(this,arguments)}}(e.fn.focus),scrollParent:function(){var t;return e.ui.ie&&/(static|relative)/.test(this.css("position"))||/absolute/.test(this.css("position"))?t=this.parents().filter(function(){return/(relative|absolute|fixed)/.test(e.css(this,"position"))&&/(auto|scroll)/.test(e.css(this,"overflow")+e.css(this,"overflow-y")+e.css(this,"overflow-x"))}).eq(0):t=this.parents().filter(function(){return/(auto|scroll)/.test(e.css(this,"overflow")+e.css(this,"overflow-y")+e.css(this,"overflow-x"))}).eq(0),/fixed/.test(this.css("position"))||!t.length?e(this[0].ownerDocument||n):t},uniqueId:function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++r)})},removeUniqueId:function(){return this.each(function(){i.test(this.id)&&e(this).removeAttr("id")})}}),e.extend(e.expr[":"],{data:e.expr.createPseudo?e.expr.createPseudo(function(t){return function(n){return!!e.data(n,t)}}):function(t,n,r){return!!e.data(t,r[3])},focusable:function(t){return s(t,!isNaN(e.attr(t,"tabindex")))},tabbable:function(t){var n=e.attr(t,"tabindex"),r=isNaN(n);return(r||n>=0)&&s(t,!r)}}),e("
").outerWidth(1).jquery||e.each(["Width","Height"],function(n,r){function u(t,n,r,s){return e.each(i,function(){n-=parseFloat(e.css(t,"padding"+this))||0,r&&(n-=parseFloat(e.css(t,"border"+this+"Width"))||0),s&&(n-=parseFloat(e.css(t,"margin"+this))||0)}),n}var i=r==="Width"?["Left","Right"]:["Top","Bottom"],s=r.toLowerCase(),o={innerWidth:e.fn.innerWidth,innerHeight:e.fn.innerHeight,outerWidth:e.fn.outerWidth,outerHeight:e.fn.outerHeight};e.fn["inner"+r]=function(n){return n===t?o["inner"+r].call(this):this.each(function(){e(this).css(s,u(this,n)+"px")})},e.fn["outer"+r]=function(t,n){return typeof t!="number"?o["outer"+r].call(this,t):this.each(function(){e(this).css(s,u(this,t,!0,n)+"px")})}}),e.fn.addBack||(e.fn.addBack=function(e){return this.add(e==null?this.prevObject:this.prevObject.filter(e))}),e(" ").data("a-b","a").removeData("a-b").data("a-b")&&(e.fn.removeData=function(t){return function(n){return arguments.length?t.call(this,e.camelCase(n)):t.call(this)}}(e.fn.removeData)),e.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase()),e.support.selectstart="onselectstart"in n.createElement("div"),e.fn.extend({disableSelection:function(){return this.bind((e.support.selectstart?"selectstart":"mousedown")+".ui-disableSelection",function(e){e.preventDefault()})},enableSelection:function(){return this.unbind(".ui-disableSelection")},zIndex:function(r){if(r!==t)return this.css("zIndex",r);if(this.length){var i=e(this[0]),s,o;while(i.length&&i[0]!==n){s=i.css("position");if(s==="absolute"||s==="relative"||s==="fixed"){o=parseInt(i.css("zIndex"),10);if(!isNaN(o)&&o!==0)return o}i=i.parent()}}return 0}}),e.ui.plugin={add:function(t,n,r){var i,s=e.ui[t].prototype;for(i in r)s.plugins[i]=s.plugins[i]||[],s.plugins[i].push([n,r[i]])},call:function(e,t,n,r){var i,s=e.plugins[t];if(!s)return;if(!r&&(!e.element[0].parentNode||e.element[0].parentNode.nodeType===11))return;for(i=0;i0&&(i=i.concat(o.toArray())),f.length===0&&a.length>0&&(i=i.concat(a.toArray())),e.each(i,function(t,r){n-=e(r).outerHeight()}),Math.max(0,n)};e.extend(e.mobile,{window:e(t),document:e(n),keyCode:e.ui.keyCode,behaviors:{},silentScroll:function(n){e.type(n)!=="number"&&(n=e.mobile.defaultHomeScroll),e.event.special.scrollstart.enabled=!1,setTimeout(function(){t.scrollTo(0,n),e.mobile.document.trigger("silentscroll",{x:0,y:n})},20),setTimeout(function(){e.event.special.scrollstart.enabled=!0},150)},getClosestBaseUrl:function(t){var n=e(t).closest(".ui-page").jqmData("url"),r=e.mobile.path.documentBase.hrefNoHash;if(!e.mobile.dynamicBaseEnabled||!n||!e.mobile.path.isPath(n))n=r;return e.mobile.path.makeUrlAbsolute(n,r)},removeActiveLinkClass:function(t){!!e.mobile.activeClickedLink&&(!e.mobile.activeClickedLink.closest("."+e.mobile.activePageClass).length||t)&&e.mobile.activeClickedLink.removeClass(e.mobile.activeBtnClass),e.mobile.activeClickedLink=null},getInheritedTheme:function(e,t){var n=e[0],r="",i=/ui-(bar|body|overlay)-([a-z])\b/,s,o;while(n){s=n.className||"";if(s&&(o=i.exec(s))&&(r=o[2]))break;n=n.parentNode}return r||t||"a"},enhanceable:function(e){return this.haveParents(e,"enhance")},hijackable:function(e){return this.haveParents(e,"ajax")},haveParents:function(t,n){if(!e.mobile.ignoreContentEnabled)return t;var r=t.length,i=e(),s,o,u,a,f;for(a=0;a0&&(o=o.not(r)),o.length>0&&(n[s.prototype.widgetName]=o)}});for(t in n)n[t][t]();return this},addDependents:function(t){e.addDependents(this,t)},getEncodedText:function(){return e("").text(this.text()).html()},jqmEnhanceable:function(){return e.mobile.enhanceable(this)},jqmHijackable:function(){return e.mobile.hijackable(this)}}),e.removeWithDependents=function(t){var n=e(t);(n.jqmData("dependents")||e()).remove(),n.remove()},e.addDependents=function(t,n){var r=e(t),i=r.jqmData("dependents")||e();r.jqmData("dependents",e(i).add(n))},e.find.matches=function(t,n){return e.find(t,null,null,n)},e.find.matchesSelector=function(t,n){return e.find(n,null,null,[t]).length>0}}(e,this),function(e,r){t.matchMedia=t.matchMedia||function(e,t){var n,r=e.documentElement,i=r.firstElementChild||r.firstChild,s=e.createElement("body"),o=e.createElement("div");return o.id="mq-test-1",o.style.cssText="position:absolute;top:-100em",s.style.background="none",s.appendChild(o),function(e){return o.innerHTML='',r.insertBefore(s,i),n=o.offsetWidth===42,r.removeChild(s),{matches:n,media:e}}}(n),e.mobile.media=function(e){return t.matchMedia(e).matches}}(e),function(e,t){var r={touch:"ontouchend"in n};e.mobile.support=e.mobile.support||{},e.extend(e.support,r),e.extend(e.mobile.support,r)}(e),function(e,n){e.extend(e.support,{orientation:"orientation"in t&&"onorientationchange"in t})}(e),function(e,r){function i(e){var t=e.charAt(0).toUpperCase()+e.substr(1),n=(e+" "+u.join(t+" ")+t).split(" "),i;for(i in n)if(o[n[i]]!==r)return!0}function h(){var n=t,r=!!n.document.createElementNS&&!!n.document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect&&(!n.opera||navigator.userAgent.indexOf("Chrome")!==-1),i=function(t){(!t||!r)&&e("html").addClass("ui-nosvg")},s=new n.Image;s.onerror=function(){i(!1)},s.onload=function(){i(s.width===1&&s.height===1)},s.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw=="}function p(){var i="transform-3d",o=e.mobile.media("(-"+u.join("-"+i+"),(-")+"-"+i+"),("+i+")"),a,f,l;if(o)return!!o;a=n.createElement("div"),f={MozTransform:"-moz-transform",transform:"transform"},s.append(a);for(l in f)a.style[l]!==r&&(a.style[l]="translate3d( 100px, 1px, 1px )",o=t.getComputedStyle(a).getPropertyValue(f[l]));return!!o&&o!=="none"}function d(){var t=location.protocol+"//"+location.host+location.pathname+"ui-dir/",n=e("head base"),r=null,i="",o,u;return n.length?i=n.attr("href"):n=r=e(" ",{href:t}).appendTo("head"),o=e(" ").prependTo(s),u=o[0].href,n[0].href=i||location.pathname,r&&r.remove(),u.indexOf(t)===0}function v(){var e=n.createElement("x"),r=n.documentElement,i=t.getComputedStyle,s;return"pointerEvents"in e.style?(e.style.pointerEvents="auto",e.style.pointerEvents="x",r.appendChild(e),s=i&&i(e,"").pointerEvents==="auto",r.removeChild(e),!!s):!1}function m(){var e=n.createElement("div");return typeof e.getBoundingClientRect!="undefined"}function g(){var e=t,n=navigator.userAgent,r=navigator.platform,i=n.match(/AppleWebKit\/([0-9]+)/),s=!!i&&i[1],o=n.match(/Fennec\/([0-9]+)/),u=!!o&&o[1],a=n.match(/Opera Mobi\/([0-9]+)/),f=!!a&&a[1];return(r.indexOf("iPhone")>-1||r.indexOf("iPad")>-1||r.indexOf("iPod")>-1)&&s&&s<534||e.operamini&&{}.toString.call(e.operamini)==="[object OperaMini]"||a&&f<7458||n.indexOf("Android")>-1&&s&&s<533||u&&u<6||"palmGetResource"in t&&s&&s<534||n.indexOf("MeeGo")>-1&&n.indexOf("NokiaBrowser/8.5.0")>-1?!1:!0}var s=e("").prependTo("html"),o=s[0].style,u=["Webkit","Moz","O"],a="palmGetResource"in t,f=t.operamini&&{}.toString.call(t.operamini)==="[object OperaMini]",l=t.blackberry&&!i("-webkit-transform"),c;e.extend(e.mobile,{browser:{}}),e.mobile.browser.oldIE=function(){var e=3,t=n.createElement("div"),r=t.all||[];do t.innerHTML="";while(r[0]);return e>4?e:!e}(),e.extend(e.support,{pushState:"pushState"in history&&"replaceState"in history&&!(t.navigator.userAgent.indexOf("Firefox")>=0&&t.top!==t)&&t.navigator.userAgent.search(/CriOS/)===-1,mediaquery:e.mobile.media("only all"),cssPseudoElement:!!i("content"),touchOverflow:!!i("overflowScrolling"),cssTransform3d:p(),boxShadow:!!i("boxShadow")&&!l,fixedPosition:g(),scrollTop:("pageXOffset"in t||"scrollTop"in n.documentElement||"scrollTop"in s[0])&&!a&&!f,dynamicBaseTag:d(),cssPointerEvents:v(),boundingRect:m(),inlineSVG:h}),s.remove(),c=function(){var e=t.navigator.userAgent;return e.indexOf("Nokia")>-1&&(e.indexOf("Symbian/3")>-1||e.indexOf("Series60/5")>-1)&&e.indexOf("AppleWebKit")>-1&&e.match(/(BrowserNG|NokiaBrowser)\/7\.[0-3]/)}(),e.mobile.gradeA=function(){return(e.support.mediaquery&&e.support.cssPseudoElement||e.mobile.browser.oldIE&&e.mobile.browser.oldIE>=8)&&(e.support.boundingRect||e.fn.jquery.match(/1\.[0-7+]\.[0-9+]?/)!==null)},e.mobile.ajaxBlacklist=t.blackberry&&!t.WebKitPoint||f||c,c&&e(function(){e("head link[rel='stylesheet']").attr("rel","alternate stylesheet").attr("rel","stylesheet")}),e.support.boxShadow||e("html").addClass("ui-noboxshadow")}(e),function(e,t){var n=e.mobile.window,r,i=function(){};e.event.special.beforenavigate={setup:function(){n.on("navigate",i)},teardown:function(){n.off("navigate",i)}},e.event.special.navigate=r={bound:!1,pushStateEnabled:!0,originalEventName:t,isPushStateEnabled:function(){return e.support.pushState&&e.mobile.pushStateEnabled===!0&&this.isHashChangeEnabled()},isHashChangeEnabled:function(){return e.mobile.hashListeningEnabled===!0},popstate:function(t){var r=new e.Event("navigate"),i=new e.Event("beforenavigate"),s=t.originalEvent.state||{};i.originalEvent=t,n.trigger(i);if(i.isDefaultPrevented())return;t.historyState&&e.extend(s,t.historyState),r.originalEvent=t,setTimeout(function(){n.trigger(r,{state:s})},0)},hashchange:function(t){var r=new e.Event("navigate"),i=new e.Event("beforenavigate");i.originalEvent=t,n.trigger(i);if(i.isDefaultPrevented())return;r.originalEvent=t,n.trigger(r,{state:t.hashchangeState||{}})},setup:function(){if(r.bound)return;r.bound=!0,r.isPushStateEnabled()?(r.originalEventName="popstate",n.bind("popstate.navigate",r.popstate)):r.isHashChangeEnabled()&&(r.originalEventName="hashchange",n.bind("hashchange.navigate",r.hashchange))}}}(e),function(e){e.event.special.throttledresize={setup:function(){e(this).bind("resize",n)},teardown:function(){e(this).unbind("resize",n)}};var t=250,n=function(){s=(new Date).getTime(),o=s-r,o>=t?(r=s,e(this).trigger("throttledresize")):(i&&clearTimeout(i),i=setTimeout(n,t-o))},r=0,i,s,o}(e),function(e,t){function p(){var e=s();e!==o&&(o=e,r.trigger(i))}var r=e(t),i="orientationchange",s,o,u,a,f={0:!0,180:!0},l,c,h;if(e.support.orientation){l=t.innerWidth||r.width(),c=t.innerHeight||r.height(),h=50,u=l>c&&l-c>h,a=f[t.orientation];if(u&&a||!u&&!a)f={"-90":!0,90:!0}}e.event.special.orientationchange=e.extend({},e.event.special.orientationchange,{setup:function(){if(e.support.orientation&&!e.event.special.orientationchange.disabled)return!1;o=s(),r.bind("throttledresize",p)},teardown:function(){if(e.support.orientation&&!e.event.special.orientationchange.disabled)return!1;r.unbind("throttledresize",p)},add:function(e){var t=e.handler;e.handler=function(e){return e.orientation=s(),t.apply(this,arguments)}}}),e.event.special.orientationchange.orientation=s=function(){var r=!0,i=n.documentElement;return e.support.orientation?r=f[t.orientation]:r=i&&i.clientWidth/i.clientHeight<1.1,r?"portrait":"landscape"},e.fn[i]=function(e){return e?this.bind(i,e):this.trigger(i)},e.attrFn&&(e.attrFn[i]=!0)}(e,this),function(e,t,n,r){function T(e){while(e&&typeof e.originalEvent!="undefined")e=e.originalEvent;return e}function N(t,n){var i=t.type,s,o,a,l,c,h,p,d,v;t=e.Event(t),t.type=n,s=t.originalEvent,o=e.event.props,i.search(/^(mouse|click)/)>-1&&(o=f);if(s)for(p=o.length,l;p;)l=o[--p],t[l]=s[l];i.search(/mouse(down|up)|click/)>-1&&!t.which&&(t.which=1);if(i.search(/^touch/)!==-1){a=T(s),i=a.touches,c=a.changedTouches,h=i&&i.length?i[0]:c&&c.length?c[0]:r;if(h)for(d=0,v=u.length;di||Math.abs(n.pageY-p)>i,d&&!r&&P("vmousecancel",t,s),P("vmousemove",t,s),_()}function I(e){if(g)return;A();var t=C(e.target),n,r;P("vmouseup",e,t),d||(n=P("vclick",e,t),n&&n.isDefaultPrevented()&&(r=T(e).changedTouches[0],v.push({touchID:E,x:r.clientX,y:r.clientY}),m=!0)),P("vmouseout",e,t),d=!1,_()}function q(t){var n=e.data(t,i),r;if(n)for(r in n)if(n[r])return!0;return!1}function R(){}function U(t){var n=t.substr(1);return{setup:function(){q(this)||e.data(this,i,{});var r=e.data(this,i);r[t]=!0,l[t]=(l[t]||0)+1,l[t]===1&&b.bind(n,H),e(this).bind(n,R),y&&(l.touchstart=(l.touchstart||0)+1,l.touchstart===1&&b.bind("touchstart",B).bind("touchend",I).bind("touchmove",F).bind("scroll",j))},teardown:function(){--l[t],l[t]||b.unbind(n,H),y&&(--l.touchstart,l.touchstart||b.unbind("touchstart",B).unbind("touchmove",F).unbind("touchend",I).unbind("scroll",j));var r=e(this),s=e.data(this,i);s&&(s[t]=!1),r.unbind(n,R),q(this)||r.removeData(i)}}}var i="virtualMouseBindings",s="virtualTouchID",o="vmouseover vmousedown vmousemove vmouseup vclick vmouseout vmousecancel".split(" "),u="clientX clientY pageX pageY screenX screenY".split(" "),a=e.event.mouseHooks?e.event.mouseHooks.props:[],f=e.event.props.concat(a),l={},c=0,h=0,p=0,d=!1,v=[],m=!1,g=!1,y="addEventListener"in n,b=e(n),w=1,E=0,S,x;e.vmouse={moveDistanceThreshold:10,clickDistanceThreshold:10,resetTimerDuration:1500};for(x=0;xMath.floor(e.pageY)||e.pageX===0&&Math.floor(i)>Math.floor(e.pageX))i-=n,s-=r;else if(se.event.special.swipe.horizontalDistanceThreshold&&Math.abs(t.coords[1]-n.coords[1])n.coords[0]?"swipeleft":"swiperight";return l(r,"swipe",e.Event("swipe",{target:i,swipestart:t,swipestop:n}),!0),l(r,s,e.Event(s,{target:i,swipestart:t,swipestop:n}),!0),!0}return!1},eventInProgress:!1,setup:function(){var t,n=this,r=e(n),s={};t=e.data(this,"mobile-events"),t||(t={length:0},e.data(this,"mobile-events",t)),t.length++,t.swipe=s,s.start=function(t){if(e.event.special.swipe.eventInProgress)return;e.event.special.swipe.eventInProgress=!0;var r,o=e.event.special.swipe.start(t),u=t.target,l=!1;s.move=function(t){if(!o||t.isDefaultPrevented())return;r=e.event.special.swipe.stop(t),l||(l=e.event.special.swipe.handleSwipe(o,r,n,u),l&&(e.event.special.swipe.eventInProgress=!1)),Math.abs(o.coords[0]-r.coords[0])>e.event.special.swipe.scrollSupressionThreshold&&t.preventDefault()},s.stop=function(){l=!0,e.event.special.swipe.eventInProgress=!1,i.off(f,s.move),s.move=null},i.on(f,s.move).one(a,s.stop)},r.on(u,s.start)},teardown:function(){var t,n;t=e.data(this,"mobile-events"),t&&(n=t.swipe,delete t.swipe,t.length--,t.length===0&&e.removeData(this,"mobile-events")),n&&(n.start&&e(this).off(u,n.start),n.move&&i.off(f,n.move),n.stop&&i.off(a,n.stop))}},e.each({scrollstop:"scrollstart",taphold:"tap",swipeleft:"swipe.left",swiperight:"swipe.right"},function(t,n){e.event.special[t]={setup:function(){e(this).bind(n,e.noop)},teardown:function(){e(this).unbind(n)}}})}(e,this),function(e,t){var r={animation:{},transition:{}},i=n.createElement("a"),s=["","webkit-","moz-","o-"];e.each(["animation","transition"],function(n,o){var u=n===0?o+"-"+"name":o;e.each(s,function(n,s){if(i.style[e.camelCase(s+u)]!==t)return r[o].prefix=s,!1}),r[o].duration=e.camelCase(r[o].prefix+o+"-"+"duration"),r[o].event=e.camelCase(r[o].prefix+o+"-"+"end"),r[o].prefix===""&&(r[o].event=r[o].event.toLowerCase())}),e.support.cssTransitions=r.transition.prefix!==t,e.support.cssAnimations=r.animation.prefix!==t,e(i).remove(),e.fn.animationComplete=function(i,s,o){var u,a,f=this,l=function(){clearTimeout(u),i.apply(this,arguments)},c=!s||s==="animation"?"animation":"transition";if(e.support.cssTransitions&&c==="transition"||e.support.cssAnimations&&c==="animation"){if(o===t){e(this).context!==n&&(a=parseFloat(e(this).css(r[c].duration))*3e3);if(a===0||a===t||isNaN(a))a=e.fn.animationComplete.defaultDuration}return u=setTimeout(function(){e(f).off(r[c].event,l),i.apply(f)},a),e(this).one(r[c].event,l)}return setTimeout(e.proxy(i,this),0),e(this)},e.fn.animationComplete.defaultDuration=1e3}(e),function(e,t){function s(e,t){var n=t?t:[];return n.push("ui-btn"),e.theme&&n.push("ui-btn-"+e.theme),e.icon&&(n=n.concat(["ui-icon-"+e.icon,"ui-btn-icon-"+e.iconpos]),e.iconshadow&&n.push("ui-shadow-icon")),e.inline&&n.push("ui-btn-inline"),e.shadow&&n.push("ui-shadow"),e.corners&&n.push("ui-corner-all"),e.mini&&n.push("ui-mini"),n}function o(e){var r,i,s,o=!1,u=!0,a={icon:"",inline:!1,shadow:!1,corners:!1,iconshadow:!1,mini:!1},f=[];e=e.split(" ");for(r=0;r a, .ui-bar > :jqmData(role='controlgroup') > a, button:not(:jqmData(role='navbar') button)"})}(e),function(e,t){var n=0,r=Array.prototype.slice,i=e.cleanData;e.cleanData=function(t){for(var n=0,r;(r=t[n])!=null;n++)try{e(r).triggerHandler("remove")}catch(s){}i(t)},e.widget=function(t,n,r){var i,s,o,u,a={},f=t.split(".")[0];return t=t.split(".")[1],i=f+"-"+t,r||(r=n,n=e.Widget),e.expr[":"][i.toLowerCase()]=function(t){return!!e.data(t,i)},e[f]=e[f]||{},s=e[f][t],o=e[f][t]=function(e,t){if(!this._createWidget)return new o(e,t);arguments.length&&this._createWidget(e,t)},e.extend(o,s,{version:r.version,_proto:e.extend({},r),_childConstructors:[]}),u=new n,u.options=e.widget.extend({},u.options),e.each(r,function(t,r){if(!e.isFunction(r)){a[t]=r;return}a[t]=function(){var e=function(){return n.prototype[t].apply(this,arguments)},i=function(e){return n.prototype[t].apply(this,e)};return function(){var t=this._super,n=this._superApply,s;return this._super=e,this._superApply=i,s=r.apply(this,arguments),this._super=t,this._superApply=n,s}}()}),o.prototype=e.widget.extend(u,{widgetEventPrefix:s?u.widgetEventPrefix||t:t},a,{constructor:o,namespace:f,widgetName:t,widgetFullName:i}),s?(e.each(s._childConstructors,function(t,n){var r=n.prototype;e.widget(r.namespace+"."+r.widgetName,o,n._proto)}),delete s._childConstructors):n._childConstructors.push(o),e.widget.bridge(t,o),o},e.widget.extend=function(n){var i=r.call(arguments,1),s=0,o=i.length,u,a;for(;s",options:{disabled:!1,create:null},_createWidget:function(t,r){r=e(r||this.defaultElement||this)[0],this.element=e(r),this.uuid=n++,this.eventNamespace="."+this.widgetName+this.uuid,this.options=e.widget.extend({},this.options,this._getCreateOptions(),t),this.bindings=e(),this.hoverable=e(),this.focusable=e(),r!==this&&(e.data(r,this.widgetFullName,this),this._on(!0,this.element,{remove:function(e){e.target===r&&this.destroy()}}),this.document=e(r.style?r.ownerDocument:r.document||r),this.window=e(this.document[0].defaultView||this.document[0].parentWindow)),this._create(),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:e.noop,_getCreateEventData:e.noop,_create:e.noop,_init:e.noop,destroy:function(){this._destroy(),this.element.unbind(this.eventNamespace).removeData(this.widgetFullName).removeData(e.camelCase(this.widgetFullName)),this.widget().unbind(this.eventNamespace).removeAttr("aria-disabled").removeClass(this.widgetFullName+"-disabled "+"ui-state-disabled"),this.bindings.unbind(this.eventNamespace),this.hoverable.removeClass("ui-state-hover"),this.focusable.removeClass("ui-state-focus")},_destroy:e.noop,widget:function(){return this.element},option:function(n,r){var i=n,s,o,u;if(arguments.length===0)return e.widget.extend({},this.options);if(typeof n=="string"){i={},s=n.split("."),n=s.shift();if(s.length){o=i[n]=e.widget.extend({},this.options[n]);for(u=0;u").html(t.clone()).html(),s=i.indexOf(" type=")>-1,o=s?/\s+type=["']?\w+['"]?/:/\/?>/,u=' type="'+r+'" data-'+e.mobile.ns+'type="'+n+'"'+(s?"":">"),t.replaceWith(i.replace(o,u)))})}}(e),function(e,t){e.fn.fieldcontain=function(){return this.addClass("ui-field-contain")}}(e),function(e,t){e.fn.grid=function(t){return this.each(function(){var n=e(this),r=e.extend({grid:null},t),i=n.children(),s={solo:1,a:2,b:3,c:4,d:5},o=r.grid,u,a;if(!o)if(i.length<=5)for(a in s)s[a]===i.length&&(o=a);else o="a",n.addClass("ui-grid-duo");u=s[o],n.addClass("ui-grid-"+o),i.filter(":nth-child("+u+"n+1)").addClass("ui-block-a"),u>1&&i.filter(":nth-child("+u+"n+2)").addClass("ui-block-b"),u>2&&i.filter(":nth-child("+u+"n+3)").addClass("ui-block-c"),u>3&&i.filter(":nth-child("+u+"n+4)").addClass("ui-block-d"),u>4&&i.filter(":nth-child("+u+"n+5)").addClass("ui-block-e")})}}(e),function(e,n){var r,i,s="&ui-state=dialog";e.mobile.path=r={uiStateKey:"&ui-state",urlParseRE:/^\s*(((([^:\/#\?]+:)?(?:(\/\/)((?:(([^:@\/#\?]+)(?:\:([^:@\/#\?]+))?)@)?(([^:\/#\?\]\[]+|\[[^\/\]@#?]+\])(?:\:([0-9]+))?))?)?)?((\/?(?:[^\/\?#]+\/+)*)([^\?#]*)))?(\?[^#]+)?)(#.*)?/,getLocation:function(e){var t=this.parseUrl(e||location.href),n=e?t:location,r=t.hash;return r=r==="#"?"":r,n.protocol+t.doubleSlash+n.host+(n.protocol!==""&&n.pathname.substring(0,1)!=="/"?"/":"")+n.pathname+n.search+r},getDocumentUrl:function(t){return t?e.extend({},r.documentUrl):r.documentUrl.href},parseLocation:function(){return this.parseUrl(this.getLocation())},parseUrl:function(t){if(e.type(t)==="object")return t;var n=r.urlParseRE.exec(t||"")||[];return{href:n[0]||"",hrefNoHash:n[1]||"",hrefNoSearch:n[2]||"",domain:n[3]||"",protocol:n[4]||"",doubleSlash:n[5]||"",authority:n[6]||"",username:n[8]||"",password:n[9]||"",host:n[10]||"",hostname:n[11]||"",port:n[12]||"",pathname:n[13]||"",directory:n[14]||"",filename:n[15]||"",search:n[16]||"",hash:n[17]||""}},makePathAbsolute:function(e,t){var n,r,i,s;if(e&&e.charAt(0)==="/")return e;e=e||"",t=t?t.replace(/^\/|(\/[^\/]*|[^\/]+)$/g,""):"",n=t?t.split("/"):[],r=e.split("/");for(i=0;i-1&&(c=i.slice(o),i=i.slice(0,o)),n=r.makeUrlAbsolute(i,t),s=this.parseUrl(n).search;if(a){if(r.isPath(l)||l.replace("#","").indexOf(this.uiStateKey)===0)l="";c&&l.indexOf(this.uiStateKey)===-1&&(l+=c),l.indexOf("#")===-1&&l!==""&&(l="#"+l),n=r.parseUrl(n),n=n.protocol+n.doubleSlash+n.host+n.pathname+s+l}else n+=n.indexOf("#")>-1?c:"#"+c;return n},isPreservableHash:function(e){return e.replace("#","").indexOf(this.uiStateKey)===0},hashToSelector:function(e){var t=e.substring(0,1)==="#";return t&&(e=e.substring(1)),(t?"#":"")+e.replace(/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g,"\\$1")},getFilePath:function(e){return e&&e.split(s)[0]},isFirstPageUrl:function(t){var i=r.parseUrl(r.makeUrlAbsolute(t,this.documentBase)),s=i.hrefNoHash===this.documentUrl.hrefNoHash||this.documentBaseDiffers&&i.hrefNoHash===this.documentBase.hrefNoHash,o=e.mobile.firstPage,u=o&&o[0]?o[0].id:n;return s&&(!i.hash||i.hash==="#"||u&&i.hash.replace(/^#/,"")===u)},isPermittedCrossDomainRequest:function(t,n){return e.mobile.allowCrossDomainPages&&(t.protocol==="file:"||t.protocol==="content:")&&n.search(/^https?:/)!==-1}},r.documentUrl=r.parseLocation(),i=e("head").find("base"),r.documentBase=i.length?r.parseUrl(r.makeUrlAbsolute(i.attr("href"),r.documentUrl.href)):r.documentUrl,r.documentBaseDiffers=r.documentUrl.hrefNoHash!==r.documentBase.hrefNoHash,r.getDocumentBase=function(t){return t?e.extend({},r.documentBase):r.documentBase.href},e.extend(e.mobile,{getDocumentUrl:r.getDocumentUrl,getDocumentBase:r.getDocumentBase})}(e),function(e,t){e.mobile.History=function(e,t){this.stack=e||[],this.activeIndex=t||0},e.extend(e.mobile.History.prototype,{getActive:function(){return this.stack[this.activeIndex]},getLast:function(){return this.stack[this.previousIndex]},getNext:function(){return this.stack[this.activeIndex+1]},getPrev:function(){return this.stack[this.activeIndex-1]},add:function(e,t){t=t||{},this.getNext()&&this.clearForward(),t.hash&&t.hash.indexOf("#")===-1&&(t.hash="#"+t.hash),t.url=e,this.stack.push(t),this.activeIndex=this.stack.length-1},clearForward:function(){this.stack=this.stack.slice(0,this.activeIndex+1)},find:function(e,t,n){t=t||this.stack;var r,i,s=t.length,o;for(i=0;ii?(n.present||n.forward||e.noop)(this.getActive(),"forward"):r===t&&n.missing&&n.missing(this.getActive())}})}(e),function(e,r){var i=e.mobile.path,s=location.href;e.mobile.Navigator=function(t){this.history=t,this.ignoreInitialHashChange=!0,e.mobile.window.bind({"popstate.history":e.proxy(this.popstate,this),"hashchange.history":e.proxy(this.hashchange,this)})},e.extend(e.mobile.Navigator.prototype,{squash:function(r,s){var o,u,a=i.isPath(r)?i.stripHash(r):r;return u=i.squash(r),o=e.extend({hash:a,url:u},s),t.history.replaceState(o,o.title||n.title,u),o},hash:function(e,t){var n,r,s,o;return n=i.parseUrl(e),r=i.parseLocation(),r.pathname+r.search===n.pathname+n.search?s=n.hash?n.hash:n.pathname+n.search:i.isPath(e)?(o=i.parseUrl(t),s=o.pathname+o.search+(i.isPreservableHash(o.hash)?o.hash.replace("#",""):"")):s=e,s},go:function(r,s,o){var u,a,f,l,c=e.event.special.navigate.isPushStateEnabled();a=i.squash(r),f=this.hash(r,a),o&&f!==i.stripHash(i.parseLocation().hash)&&(this.preventNextHashChange=o),this.preventHashAssignPopState=!0,t.location.hash=f,this.preventHashAssignPopState=!1,u=e.extend({url:a,hash:f,title:n.title},s),c&&(l=new e.Event("popstate"),l.originalEvent={type:"popstate",state:null},this.squash(r,u),o||(this.ignorePopState=!0,e.mobile.window.trigger(l))),this.history.add(u.url,u)},popstate:function(t){var n,r;if(!e.event.special.navigate.isPushStateEnabled())return;if(this.preventHashAssignPopState){this.preventHashAssignPopState=!1,t.stopImmediatePropagation();return}if(this.ignorePopState){this.ignorePopState=!1;return}if(!t.originalEvent.state&&this.history.stack.length===1&&this.ignoreInitialHashChange){this.ignoreInitialHashChange=!1;if(location.href===s){t.preventDefault();return}}n=i.parseLocation().hash;if(!t.originalEvent.state&&n){r=this.squash(n),this.history.add(r.url,r),t.historyState=r;return}this.history.direct({url:(t.originalEvent.state||{}).url||n,present:function(n,r){t.historyState=e.extend({},n),t.historyState.direction=r}})},hashchange:function(t){var r,s;if(!e.event.special.navigate.isHashChangeEnabled()||e.event.special.navigate.isPushStateEnabled())return;if(this.preventNextHashChange){this.preventNextHashChange=!1,t.stopImmediatePropagation();return}r=this.history,s=i.parseLocation().hash,this.history.direct({url:s,present:function(n,r){t.hashchangeState=e.extend({},n),t.hashchangeState.direction=r},missing:function(){r.add(s,{hash:s,title:n.title})}})}})}(e),function(e,t){e.mobile.navigate=function(t,n,r){e.mobile.navigate.navigator.go(t,n,r)},e.mobile.navigate.history=new e.mobile.History,e.mobile.navigate.navigator=new e.mobile.Navigator(e.mobile.navigate.history);var n=e.mobile.path.parseLocation();e.mobile.navigate.history.add(n.href,{hash:n.hash})}(e),function(e,t){var n=e("head").children("base"),r={element:n.length?n:e(" ",{href:e.mobile.path.documentBase.hrefNoHash}).prependTo(e("head")),linkSelector:"[src], link[href], a[rel='external'], :jqmData(ajax='false'), a[target]",set:function(t){if(!e.mobile.dynamicBaseEnabled)return;e.support.dynamicBaseTag&&r.element.attr("href",e.mobile.path.makeUrlAbsolute(t,e.mobile.path.documentBase))},rewrite:function(t,n){var i=e.mobile.path.get(t);n.find(r.linkSelector).each(function(t,n){var r=e(n).is("[href]")?"href":e(n).is("[src]")?"src":"action",s=e.mobile.path.parseLocation(),o=e(n).attr(r);o=o.replace(s.protocol+s.doubleSlash+s.host+s.pathname,""),/^(\w+:|#|\/)/.test(o)||e(n).attr(r,i+o)})},reset:function(){r.element.attr("href",e.mobile.path.documentBase.hrefNoSearch)}};e.mobile.base=r}(e),function(e,t,n){e.mobile.Transition=function(){this.init.apply(this,arguments)},e.extend(e.mobile.Transition.prototype,{toPreClass:" ui-page-pre-in",init:function(t,n,r,i){e.extend(this,{name:t,reverse:n,$to:r,$from:i,deferred:new e.Deferred})},cleanFrom:function(){this.$from.removeClass(e.mobile.activePageClass+" out in reverse "+this.name).height("")},beforeDoneIn:function(){},beforeDoneOut:function(){},beforeStartOut:function(){},doneIn:function(){this.beforeDoneIn(),this.$to.removeClass("out in reverse "+this.name).height(""),this.toggleViewportClass(),e.mobile.window.scrollTop()!==this.toScroll&&this.scrollPage(),this.sequential||this.$to.addClass(e.mobile.activePageClass),this.deferred.resolve(this.name,this.reverse,this.$to,this.$from,!0)},doneOut:function(e,t,n,r){this.beforeDoneOut(),this.startIn(e,t,n,r)},hideIn:function(e){this.$to.css("z-index",-10),e.call(this),this.$to.css("z-index","")},scrollPage:function(){e.event.special.scrollstart.enabled=!1,(e.mobile.hideUrlBar||this.toScroll!==e.mobile.defaultHomeScroll)&&t.scrollTo(0,this.toScroll),setTimeout(function(){e.event.special.scrollstart.enabled=!0},150)},startIn:function(t,n,r,i){this.hideIn(function(){this.$to.addClass(e.mobile.activePageClass+this.toPreClass),i||e.mobile.focusPage(this.$to),this.$to.height(t+this.toScroll),r||this.scrollPage()}),this.$to.removeClass(this.toPreClass).addClass(this.name+" in "+n),r?this.doneIn():this.$to.animationComplete(e.proxy(function(){this.doneIn()},this))},startOut:function(t,n,r){this.beforeStartOut(t,n,r),this.$from.height(t+e.mobile.window.scrollTop()).addClass(this.name+" out"+n)},toggleViewportClass:function(){e.mobile.pageContainer.toggleClass("ui-mobile-viewport-transitioning viewport-"+this.name)},transition:function(){var t,n=this.reverse?" reverse":"",r=e.mobile.getScreenHeight(),i=e.mobile.maxTransitionWidth!==!1&&e.mobile.window.width()>e.mobile.maxTransitionWidth;return this.toScroll=e.mobile.navigate.history.getActive().lastScroll||e.mobile.defaultHomeScroll,t=!e.support.cssTransitions||!e.support.cssAnimations||i||!this.name||this.name==="none"||Math.max(e.mobile.window.scrollTop(),this.toScroll)>e.mobile.getMaxScrollForTransition(),this.toggleViewportClass(),this.$from&&!t?this.startOut(r,n,t):this.doneOut(r,n,t,!0),this.deferred.promise()}})}(e,this),function(e){e.mobile.SerialTransition=function(){this.init.apply(this,arguments)},e.extend(e.mobile.SerialTransition.prototype,e.mobile.Transition.prototype,{sequential:!0,beforeDoneOut:function(){this.$from&&this.cleanFrom()},beforeStartOut:function(t,n,r){this.$from.animationComplete(e.proxy(function(){this.doneOut(t,n,r)},this))}})}(e),function(e){e.mobile.ConcurrentTransition=function(){this.init.apply(this,arguments)},e.extend(e.mobile.ConcurrentTransition.prototype,e.mobile.Transition.prototype,{sequential:!1,beforeDoneIn:function(){this.$from&&this.cleanFrom()},beforeStartOut:function(e,t,n){this.doneOut(e,t,n)}})}(e),function(e){var t=function(){return e.mobile.getScreenHeight()*3};e.mobile.transitionHandlers={sequential:e.mobile.SerialTransition,simultaneous:e.mobile.ConcurrentTransition},e.mobile.defaultTransitionHandler=e.mobile.transitionHandlers.sequential,e.mobile.transitionFallbacks={},e.mobile._maybeDegradeTransition=function(t){return t&&!e.support.cssTransform3d&&e.mobile.transitionFallbacks[t]&&(t=e.mobile.transitionFallbacks[t]),t},e.mobile.getMaxScrollForTransition=e.mobile.getMaxScrollForTransition||t}(e),function(e,r){e.widget("mobile.pagecontainer",{options:{theme:"a"},initSelector:!1,_create:function(){this._trigger("beforecreate"),this.setLastScrollEnabled=!0,this._on(this.window,{navigate:"_disableRecordScroll",scrollstop:"_delayedRecordScroll"}),this._on(this.window,{navigate:"_filterNavigateEvents"}),this._on({pagechange:"_afterContentChange"}),this.window.one("navigate",e.proxy(function(){this.setLastScrollEnabled=!0},this))},_setOptions:function(e){e.theme!==r&&e.theme!=="none"?this.element.removeClass("ui-overlay-"+this.options.theme).addClass("ui-overlay-"+e.theme):e.theme!==r&&this.element.removeClass("ui-overlay-"+this.options.theme),this._super(e)},_disableRecordScroll:function(){this.setLastScrollEnabled=!1},_enableRecordScroll:function(){this.setLastScrollEnabled=!0},_afterContentChange:function(){this.setLastScrollEnabled=!0,this._off(this.window,"scrollstop"),this._on(this.window,{scrollstop:"_delayedRecordScroll"})},_recordScroll:function(){if(!this.setLastScrollEnabled)return;var e=this._getActiveHistory(),t,n,r;e&&(t=this._getScroll(),n=this._getMinScroll(),r=this._getDefaultScroll(),e.lastScroll=t-1?n.state.hash:n.state.url,r||(r=this._getHash());if(!r||r==="#"||r.indexOf("#"+e.mobile.path.uiStateKey)===0)r=location.href;this._handleNavigate(r,n.state)},_getHash:function(){return e.mobile.path.parseLocation().hash},getActivePage:function(){return this.activePage},_getInitialContent:function(){return e.mobile.firstPage},_getHistory:function(){return e.mobile.navigate.history},_getActiveHistory:function(){return this._getHistory().getActive()},_getDocumentBase:function(){return e.mobile.path.documentBase},back:function(){this.go(-1)},forward:function(){this.go(1)},go:function(n){if(e.mobile.hashListeningEnabled)t.history.go(n);else{var r=e.mobile.navigate.history.activeIndex,i=r+parseInt(n,10),s=e.mobile.navigate.history.stack[i].url,o=n>=1?"forward":"back";e.mobile.navigate.history.activeIndex=i,e.mobile.navigate.history.previousIndex=r,this.change(s,{direction:o,changeHash:!1,fromHashChange:!0})}},_handleDestination:function(t){var n;return e.type(t)==="string"&&(t=e.mobile.path.stripHash(t)),t&&(n=this._getHistory(),t=e.mobile.path.isPath(t)?t:e.mobile.path.makeUrlAbsolute("#"+t,this._getDocumentBase())),t||this._getInitialContent()},_transitionFromHistory:function(e,t){var n=this._getHistory(),r=e==="back"?n.getLast():n.getActive();return r&&r.transition||t},_handleDialog:function(t,n){var r,i,s=this.getActivePage();return s&&!s.data("mobile-dialog")?(n.direction==="back"?this.back():this.forward(),!1):(r=n.pageUrl,i=this._getActiveHistory(),e.extend(t,{role:i.role,transition:this._transitionFromHistory(n.direction,t.transition),reverse:n.direction==="back"}),r)},_handleNavigate:function(t,n){var r=e.mobile.path.stripHash(t),i=this._getHistory(),s=i.stack.length===0?"none":this._transitionFromHistory(n.direction),o={changeHash:!1,fromHashChange:!0,reverse:n.direction==="back"};e.extend(o,n,{transition:s});if(i.activeIndex>0&&r.indexOf(e.mobile.dialogHashKey)>-1){r=this._handleDialog(o,n);if(r===!1)return}this._changeContent(this._handleDestination(r),o)},_changeContent:function(t,n){e.mobile.changePage(t,n)},_getBase:function(){return e.mobile.base},_getNs:function(){return e.mobile.ns},_enhance:function(e,t){return e.page({role:t})},_include:function(e,t){e.appendTo(this.element),this._enhance(e,t.role),e.page("bindRemove")},_find:function(t){var n=this._createFileUrl(t),r=this._createDataUrl(t),i,s=this._getInitialContent();return i=this.element.children("[data-"+this._getNs()+"url='"+e.mobile.path.hashToSelector(r)+"']"),i.length===0&&r&&!e.mobile.path.isPath(r)&&(i=this.element.children(e.mobile.path.hashToSelector("#"+r)).attr("data-"+this._getNs()+"url",r).jqmData("url",r)),i.length===0&&e.mobile.path.isFirstPageUrl(n)&&s&&s.parent().length&&(i=e(s)),i},_getLoader:function(){return e.mobile.loading()},_showLoading:function(t,n,r,i){if(this._loadMsg)return;this._loadMsg=setTimeout(e.proxy(function(){this._getLoader().loader("show",n,r,i),this._loadMsg=0},this),t)},_hideLoading:function(){clearTimeout(this._loadMsg),this._loadMsg=0,this._getLoader().loader("hide")},_showError:function(){this._hideLoading(),this._showLoading(0,e.mobile.pageLoadErrorMessageTheme,e.mobile.pageLoadErrorMessage,!0),setTimeout(e.proxy(this,"_hideLoading"),1500)},_parse:function(t,n){var r,i=e("
");return i.get(0).innerHTML=t,r=i.find(":jqmData(role='page'), :jqmData(role='dialog')").first(),r.length||(r=e(""+(t.split(/<\/?body[^>]*>/gmi)[1]||"")+"
")),r.attr("data-"+this._getNs()+"url",this._createDataUrl(n)).attr("data-"+this._getNs()+"external-page",!0),r},_setLoadedTitle:function(t,n){var r=n.match(/]*>([^<]*)/)&&RegExp.$1;r&&!t.jqmData("title")&&(r=e(""+r+"
").text(),t.jqmData("title",r))},_isRewritableBaseTag:function(){return e.mobile.dynamicBaseEnabled&&!e.support.dynamicBaseTag},_createDataUrl:function(t){return e.mobile.path.convertUrlToDataUrl(t)},_createFileUrl:function(t){return e.mobile.path.getFilePath(t)},_triggerWithDeprecated:function(t,n,r){var i=e.Event("page"+t),s=e.Event(this.widgetName+t);return(r||this.element).trigger(i,n),this._trigger(t,s,n),{deprecatedEvent:i,event:s}},_loadSuccess:function(t,n,i,s){var o=this._createFileUrl(t);return e.proxy(function(u,a,f){var l,c=new RegExp("(<[^>]+\\bdata-"+this._getNs()+"role=[\"']?page[\"']?[^>]*>)"),h=new RegExp("\\bdata-"+this._getNs()+"url=[\"']?([^\"'>]*)[\"']?");c.test(u)&&RegExp.$1&&h.test(RegExp.$1)&&RegExp.$1&&(o=e.mobile.path.getFilePath(e(""+RegExp.$1+"
").text()),o=this.window[0].encodeURIComponent(o)),i.prefetch===r&&this._getBase().set(o),l=this._parse(u,o),this._setLoadedTitle(l,u),n.xhr=f,n.textStatus=a,n.page=l,n.content=l,n.toPage=l;if(this._triggerWithDeprecated("load",n).event.isDefaultPrevented())return;this._isRewritableBaseTag()&&l&&this._getBase().rewrite(o,l),this._include(l,i),i.showLoadMsg&&this._hideLoading(),s.resolve(t,i,l)},this)},_loadDefaults:{type:"get",data:r,reloadPage:!1,reload:!1,role:r,showLoadMsg:!1,loadMsgDelay:50},load:function(t,n){var i=n&&n.deferred||e.Deferred(),s=n&&n.reload===r&&n.reloadPage!==r?{reload:n.reloadPage}:{},o=e.extend({},this._loadDefaults,n,s),u=null,a=e.mobile.path.makeUrlAbsolute(t,this._findBaseWithDefault()),f,l,c,h;return o.data&&o.type==="get"&&(a=e.mobile.path.addSearchParams(a,o.data),o.data=r),o.data&&o.type==="post"&&(o.reload=!0),f=this._createFileUrl(a),l=this._createDataUrl(a),u=this._find(a),u.length===0&&e.mobile.path.isEmbeddedPage(f)&&!e.mobile.path.isFirstPageUrl(f)?(i.reject(a,o),i.promise()):(this._getBase().reset(),u.length&&!o.reload?(this._enhance(u,o.role),i.resolve(a,o,u),o.prefetch||this._getBase().set(t),i.promise()):(h={url:t,absUrl:a,toPage:t,prevPage:n?n.fromPage:r,dataUrl:l,deferred:i,options:o},c=this._triggerWithDeprecated("beforeload",h),c.deprecatedEvent.isDefaultPrevented()||c.event.isDefaultPrevented()?i.promise():(o.showLoadMsg&&this._showLoading(o.loadMsgDelay),o.prefetch===r&&this._getBase().reset(),!e.mobile.allowCrossDomainPages&&!e.mobile.path.isSameDomain(e.mobile.path.documentUrl,a)?(i.reject(a,o),i.promise()):(e.ajax({url:f,type:o.type,data:o.data,contentType:o.contentType,dataType:"html",success:this._loadSuccess(a,h,o,i),error:this._loadError(a,h,o,i)}),i.promise()))))},_loadError:function(t,n,r,i){return e.proxy(function(s,o,u){this._getBase().set(e.mobile.path.get()),n.xhr=s,n.textStatus=o,n.errorThrown=u;var a=this._triggerWithDeprecated("loadfailed",n);if(a.deprecatedEvent.isDefaultPrevented()||a.event.isDefaultPrevented())return;r.showLoadMsg&&this._showError(),i.reject(t,r)},this)},_getTransitionHandler:function(t){return t=e.mobile._maybeDegradeTransition(t),e.mobile.transitionHandlers[t]||e.mobile.defaultTransitionHandler},_triggerCssTransitionEvents:function(t,n,r){var i=!1;r=r||"",n&&(t[0]===n[0]&&(i=!0),this._triggerWithDeprecated(r+"hide",{nextPage:t,toPage:t,prevPage:n,samePage:i},n)),this._triggerWithDeprecated(r+"show",{prevPage:n||e(""),toPage:t},t)},_cssTransition:function(t,n,r){var i=r.transition,s=r.reverse,o=r.deferred,u,a;this._triggerCssTransitionEvents(t,n,"before"),this._hideLoading(),u=this._getTransitionHandler(i),a=(new u(i,s,t,n)).transition(),a.done(e.proxy(function(){this._triggerCssTransitionEvents(t,n)},this)),a.done(function(){o.resolve.apply(o,arguments)})},_releaseTransitionLock:function(){s=!1,i.length>0&&e.mobile.changePage.apply(null,i.pop())},_removeActiveLinkClass:function(t){e.mobile.removeActiveLinkClass(t)},_loadUrl:function(t,n,r){r.target=t,r.deferred=e.Deferred(),this.load(t,r),r.deferred.done(e.proxy(function(e,t,r){s=!1,t.absUrl=n.absUrl,this.transition(r,n,t)},this)),r.deferred.fail(e.proxy(function(){this._removeActiveLinkClass(!0),this._releaseTransitionLock(),this._triggerWithDeprecated("changefailed",n)},this))},_triggerPageBeforeChange:function(t,n,r){var i;return n.prevPage=this.activePage,e.extend(n,{toPage:t,options:r}),e.type(t)==="string"?n.absUrl=e.mobile.path.makeUrlAbsolute(t,this._findBaseWithDefault()):n.absUrl=r.absUrl,i=this._triggerWithDeprecated("beforechange",n),i.event.isDefaultPrevented()||i.deprecatedEvent.isDefaultPrevented()?!1:!0},change:function(t,n){if(s){i.unshift(arguments);return}var r=e.extend({},e.mobile.changePage.defaults,n),o={};r.fromPage=r.fromPage||this.activePage;if(!this._triggerPageBeforeChange(t,o,r))return;t=o.toPage,e.type(t)==="string"?(s=!0,this._loadUrl(t,o,r)):this.transition(t,o,r)},transition:function(t,o,u){var a,f,l,c,h,p,d,v,m,g,y,b,w,E;if(s){i.unshift([t,u]);return}if(!this._triggerPageBeforeChange(t,o,u))return;o.prevPage=u.fromPage,E=this._triggerWithDeprecated("beforetransition",o);if(E.deprecatedEvent.isDefaultPrevented()||E.event.isDefaultPrevented())return;s=!0,t[0]===e.mobile.firstPage[0]&&!u.dataUrl&&(u.dataUrl=e.mobile.path.documentUrl.hrefNoHash),a=u.fromPage,f=u.dataUrl&&e.mobile.path.convertUrlToDataUrl(u.dataUrl)||t.jqmData("url"),l=f,c=e.mobile.path.getFilePath(f),h=e.mobile.navigate.history.getActive(),p=e.mobile.navigate.history.activeIndex===0,d=0,v=n.title,m=(u.role==="dialog"||t.jqmData("role")==="dialog")&&t.jqmData("dialog")!==!0;if(a&&a[0]===t[0]&&!u.allowSamePageTransition){s=!1,this._triggerWithDeprecated("transition",o),this._triggerWithDeprecated("change",o),u.fromHashChange&&e.mobile.navigate.history.direct({url:f});return}t.page({role:u.role}),u.fromHashChange&&(d=u.direction==="back"?-1:1);try{n.activeElement&&n.activeElement.nodeName.toLowerCase()!=="body"?e(n.activeElement).blur():e("input:focus, textarea:focus, select:focus").blur()}catch(S){}g=!1,m&&h&&(h.url&&h.url.indexOf(e.mobile.dialogHashKey)>-1&&this.activePage&&!this.activePage.hasClass("ui-dialog")&&e.mobile.navigate.history.activeIndex>0&&(u.changeHash=!1,g=!0),f=h.url||"",!g&&f.indexOf("#")>-1?f+=e.mobile.dialogHashKey:f+="#"+e.mobile.dialogHashKey),y=h?t.jqmData("title")||t.children(":jqmData(role='header')").find(".ui-title").text():v,!!y&&v===n.title&&(v=y),t.jqmData("title")||t.jqmData("title",v),u.transition=u.transition||(d&&!p?h.transition:r)||(m?e.mobile.defaultDialogTransition:e.mobile.defaultPageTransition),!d&&g&&(e.mobile.navigate.history.getActive().pageUrl=l),f&&!u.fromHashChange&&(!e.mobile.path.isPath(f)&&f.indexOf("#")<0&&(f="#"+f),b={transition:u.transition,title:v,pageUrl:l,role:u.role},u.changeHash!==!1&&e.mobile.hashListeningEnabled?e.mobile.navigate(this.window[0].encodeURI(f),b,!0):t[0]!==e.mobile.firstPage[0]&&e.mobile.navigate.history.add(f,b)),n.title=v,e.mobile.activePage=t,this.activePage=t,u.reverse=u.reverse||d<0,w=e.Deferred(),this._cssTransition(t,a,{transition:u.transition,reverse:u.reverse,deferred:w}),w.done(e.proxy(function(n,r,i,s,a){e.mobile.removeActiveLinkClass(),u.duplicateCachedPage&&u.duplicateCachedPage.remove(),a||e.mobile.focusPage(t),this._releaseTransitionLock(),this._triggerWithDeprecated("transition",o),this._triggerWithDeprecated("change",o)},this))},_findBaseWithDefault:function(){var t=this.activePage&&e.mobile.getClosestBaseUrl(this.activePage);return t||e.mobile.path.documentBase.hrefNoHash}}),e.mobile.navreadyDeferred=e.Deferred();var i=[],s=!1}(e),function(e,r){function f(e){while(e){if(typeof e.nodeName=="string"&&e.nodeName.toLowerCase()==="a")break;e=e.parentNode}return e}var i=e.Deferred(),s=e.Deferred(),o=function(){s.resolve(),s=null},u=e.mobile.path.documentUrl,a=null;e.mobile.loadPage=function(t,n){var r;return n=n||{},r=n.pageContainer||e.mobile.pageContainer,n.deferred=e.Deferred(),r.pagecontainer("load",t,n),n.deferred.promise()},e.mobile.back=function(){var n=t.navigator;this.phonegapNavigationEnabled&&n&&n.app&&n.app.backHistory?n.app.backHistory():e.mobile.pageContainer.pagecontainer("back")},e.mobile.focusPage=function(e){var t=e.find("[autofocus]"),n=e.find(".ui-title:eq(0)");if(t.length){t.focus();return}n.length?n.focus():e.focus()},e.mobile._maybeDegradeTransition=e.mobile._maybeDegradeTransition||function(e){return e},e.mobile.changePage=function(t,n){e.mobile.pageContainer.pagecontainer("change",t,n)},e.mobile.changePage.defaults={transition:r,reverse:!1,changeHash:!0,fromHashChange:!1,role:r,duplicateCachedPage:r,pageContainer:r,showLoadMsg:!0,dataUrl:r,fromPage:r,allowSamePageTransition:!1},e.mobile._registerInternalEvents=function(){var n=function(t,n){var r,i=!0,s,o,f;return!e.mobile.ajaxEnabled||t.is(":jqmData(ajax='false')")||!t.jqmHijackable().length||t.attr("target")?!1:(r=a&&a.attr("formaction")||t.attr("action"),f=(t.attr("method")||"get").toLowerCase(),r||(r=e.mobile.getClosestBaseUrl(t),f==="get"&&(r=e.mobile.path.parseUrl(r).hrefNoSearch),r===e.mobile.path.documentBase.hrefNoHash&&(r=u.hrefNoSearch)),r=e.mobile.path.makeUrlAbsolute(r,e.mobile.getClosestBaseUrl(t)),e.mobile.path.isExternal(r)&&!e.mobile.path.isPermittedCrossDomainRequest(u,r)?!1:(n||(s=t.serializeArray(),a&&a[0].form===t[0]&&(o=a.attr("name"),o&&(e.each(s,function(e,t){if(t.name===o)return o="",!1}),o&&s.push({name:o,value:a.attr("value")}))),i={url:r,options:{type:f,data:e.param(s),transition:t.jqmData("transition"),reverse:t.jqmData("direction")==="reverse",reloadPage:!0}}),i))};e.mobile.document.delegate("form","submit",function(t){var r;t.isDefaultPrevented()||(r=n(e(this)),r&&(e.mobile.changePage(r.url,r.options),t.preventDefault()))}),e.mobile.document.bind("vclick",function(t){var r,i,s=t.target,o=!1;if(t.which>1||!e.mobile.linkBindingEnabled)return;a=e(s);if(e.data(s,"mobile-button")){if(!n(e(s).closest("form"),!0))return;s.parentNode&&(s=s.parentNode)}else{s=f(s);if(!s||e.mobile.path.parseUrl(s.getAttribute("href")||"#").hash==="#")return;if(!e(s).jqmHijackable().length)return}~s.className.indexOf("ui-link-inherit")?s.parentNode&&(i=e.data(s.parentNode,"buttonElements")):i=e.data(s,"buttonElements"),i?s=i.outer:o=!0,r=e(s),o&&(r=r.closest(".ui-btn")),r.length>0&&!r.hasClass("ui-state-disabled")&&(e.mobile.removeActiveLinkClass(!0),e.mobile.activeClickedLink=r,e.mobile.activeClickedLink.addClass(e.mobile.activeBtnClass))}),e.mobile.document.bind("click",function(n){if(!e.mobile.linkBindingEnabled||n.isDefaultPrevented())return;var i=f(n.target),s=e(i),o=function(){t.setTimeout(function(){e.mobile.removeActiveLinkClass(!0)},200)},a,l,c,h,p,d,v;e.mobile.activeClickedLink&&e.mobile.activeClickedLink[0]===n.target.parentNode&&o();if(!i||n.which>1||!s.jqmHijackable().length)return;if(s.is(":jqmData(rel='back')"))return e.mobile.back(),!1;a=e.mobile.getClosestBaseUrl(s),l=e.mobile.path.makeUrlAbsolute(s.attr("href")||"#",a);if(!e.mobile.ajaxEnabled&&!e.mobile.path.isEmbeddedPage(l)){o();return}if(l.search("#")!==-1&&(!e.mobile.path.isExternal(l)||!e.mobile.path.isAbsoluteUrl(l))){l=l.replace(/[^#]*#/,"");if(!l){n.preventDefault();return}e.mobile.path.isPath(l)?l=e.mobile.path.makeUrlAbsolute(l,a):l=e.mobile.path.makeUrlAbsolute("#"+l,u.hrefNoHash)}c=s.is("[rel='external']")||s.is(":jqmData(ajax='false')")||s.is("[target]"),h=c||e.mobile.path.isExternal(l)&&!e.mobile.path.isPermittedCrossDomainRequest(u,l);if(h){o();return}p=s.jqmData("transition"),d=s.jqmData("direction")==="reverse"||s.jqmData("back"),v=s.attr("data-"+e.mobile.ns+"rel")||r,e.mobile.changePage(l,{transition:p,reverse:d,role:v,link:s}),n.preventDefault()}),e.mobile.document.delegate(".ui-page","pageshow.prefetch",function(){var t=[];e(this).find("a:jqmData(prefetch)").each(function(){var n=e(this),r=n.attr("href");r&&e.inArray(r,t)===-1&&(t.push(r),e.mobile.loadPage(r,{role:n.attr("data-"+e.mobile.ns+"rel"),prefetch:!0}))})}),e.mobile.pageContainer.pagecontainer(),e.mobile.document.bind("pageshow",function(){s?s.done(e.mobile.resetActivePageHeight):e.mobile.resetActivePageHeight()}),e.mobile.window.bind("throttledresize",e.mobile.resetActivePageHeight)},e(function(){i.resolve()}),n.readyState==="complete"?o():e.mobile.window.load(o),e.when(i,e.mobile.navreadyDeferred).done(function(){e.mobile._registerInternalEvents()})}(e),function(e){var t="ui-loader",n=e("html");e.widget("mobile.loader",{options:{theme:"a",textVisible:!1,html:"",text:"loading"},defaultHtml:""+" "+"
"+"",fakeFixLoader:function(){var t=e("."+e.mobile.activeBtnClass).first();this.element.css({top:e.support.scrollTop&&this.window.scrollTop()+this.window.height()/2||t.length&&t.offset().top||100})},checkLoaderPosition:function(){var t=this.element.offset(),n=this.window.scrollTop(),r=e.mobile.getScreenHeight();if(t.topr)this.element.addClass("ui-loader-fakefix"),this.fakeFixLoader(),this.window.unbind("scroll",this.checkLoaderPosition).bind("scroll",e.proxy(this.fakeFixLoader,this))},resetHtml:function(){this.element.html(e(this.defaultHtml).html())},show:function(r,i,s){var o,u,a;this.resetHtml(),e.type(r)==="object"?(a=e.extend({},this.options,r),r=a.theme):(a=this.options,r=r||a.theme),u=i||(a.text===!1?"":a.text),n.addClass("ui-loading"),o=a.textVisible,this.element.attr("class",t+" ui-corner-all ui-body-"+r+" ui-loader-"+(o||i||r.text?"verbose":"default")+(a.textonly||s?" ui-loader-textonly":"")),a.html?this.element.html(a.html):this.element.find("h1").text(u),this.element.appendTo(e.mobile.pagecontainer?e(":mobile-pagecontainer"):e("body")),this.checkLoaderPosition(),this.window.bind("scroll",e.proxy(this.checkLoaderPosition,this))},hide:function(){n.removeClass("ui-loading"),this.options.text&&this.element.removeClass("ui-loader-fakefix"),this.window.unbind("scroll",this.fakeFixLoader),this.window.unbind("scroll",this.checkLoaderPosition)}})}(e,this),function(e,t,r){function o(){i.removeClass("ui-mobile-rendering")}var i=e("html"),s=e.mobile.window;e(t.document).trigger("mobileinit");if(!e.mobile.gradeA())return;e.mobile.ajaxBlacklist&&(e.mobile.ajaxEnabled=!1),i.addClass("ui-mobile ui-mobile-rendering"),setTimeout(o,5e3),e.extend(e.mobile,{initializePage:function(){var t=e.mobile.path,i=e(":jqmData(role='page'), :jqmData(role='dialog')"),u=t.stripHash(t.stripQueryParams(t.parseLocation().hash)),a=e.mobile.path.parseLocation(),f=u?n.getElementById(u):r;i.length||(i=e("body").wrapInner("
").children(0)),i.each(function(){var n=e(this);n[0].getAttribute("data-"+e.mobile.ns+"url")||n.attr("data-"+e.mobile.ns+"url",n.attr("id")||t.convertUrlToDataUrl(a.pathname+a.search))}),e.mobile.firstPage=i.first(),e.mobile.pageContainer=e.mobile.firstPage.parent().addClass("ui-mobile-viewport").pagecontainer(),e.mobile.navreadyDeferred.resolve(),s.trigger("pagecontainercreate"),e.mobile.loading("show"),o(),!e.mobile.hashListeningEnabled||!e.mobile.path.isHashValid(location.hash)||!e(f).is(":jqmData(role='page')")&&!e.mobile.path.isPath(u)&&u!==e.mobile.dialogHashKey?(e.event.special.navigate.isPushStateEnabled()&&e.mobile.navigate.navigator.squash(t.parseLocation().href),e.mobile.changePage(e.mobile.firstPage,{transition:"none",reverse:!0,changeHash:!1,fromHashChange:!0})):e.event.special.navigate.isPushStateEnabled()?(e.mobile.navigate.history.stack=[],e.mobile.navigate(e.mobile.path.isPath(location.hash)?location.hash:location.href)):s.trigger("hashchange",[!0])}}),e(function(){e.support.inlineSVG(),e.mobile.hideUrlBar&&t.scrollTo(0,1),e.mobile.defaultHomeScroll=!e.support.scrollTop||e.mobile.window.scrollTop()===1?0:1,e.mobile.autoInitializePage&&e.mobile.initializePage(),e.mobile.hideUrlBar&&s.load(e.mobile.silentScroll),e.support.cssPointerEvents||e.mobile.document.delegate(".ui-state-disabled,.ui-disabled","vclick",function(e){e.preventDefault(),e.stopImmediatePropagation()})})}(e,this),function(e,t){e.mobile.links=function(t){e(t).find("a").jqmEnhanceable().filter(":jqmData(rel='popup')[href][href!='']").each(function(){var e=this,t=e.getAttribute("href").substring(1);t&&(e.setAttribute("aria-haspopup",!0),e.setAttribute("aria-owns",t),e.setAttribute("aria-expanded",!1))}).end().not(".ui-btn, :jqmData(role='none'), :jqmData(role='nojs')").addClass("ui-link")}}(e),function(e,t){e.mobile.nojs=function(t){e(":jqmData(role='nojs')",t).addClass("ui-nojs")}}(e),function(e){var t=e("meta[name=viewport]"),n=t.attr("content"),r=n+",maximum-scale=1, user-scalable=no",i=n+",maximum-scale=10, user-scalable=yes",s=/(user-scalable[\s]*=[\s]*no)|(maximum-scale[\s]*=[\s]*1)[$,\s]/.test(n);e.mobile.zoom=e.extend({},{enabled:!s,locked:!1,disable:function(n){!s&&!e.mobile.zoom.locked&&(t.attr("content",r),e.mobile.zoom.enabled=!1,e.mobile.zoom.locked=n||!1)},enable:function(n){!s&&(!e.mobile.zoom.locked||n===!0)&&(t.attr("content",i),e.mobile.zoom.enabled=!0,e.mobile.zoom.locked=!1)},restore:function(){s||(t.attr("content",n),e.mobile.zoom.enabled=!0)}})}(e),function(e,t,n){e.mobile.transitionFallbacks.pop="fade"}(e,this),function(e,t,n){e.mobile.transitionHandlers.slide=e.mobile.transitionHandlers.simultaneous,e.mobile.transitionFallbacks.slide="fade"}(e,this),function(e,t,n){e.mobile.transitionFallbacks.slidedown="fade"}(e,this),function(e,t,n){e.mobile.transitionFallbacks.slideup="fade"}(e,this),function(e,t){function r(t){var r,i=t.length,s=[];for(r=0;r ").children(".ui-collapsible-content"),n.heading=n.originalHeading,n.heading.is("legend")&&(n.heading=e("
"+n.heading.html()+"
"),n.placeholder=e("
").insertBefore(n.originalHeading),n.originalHeading.remove()),i=s.collapsed?s.collapsedIcon?"ui-icon-"+s.collapsedIcon:"":s.expandedIcon?"ui-icon-"+s.expandedIcon:"",n.status=e("
"),n.anchor=n.heading.detach().addClass("ui-collapsible-heading").append(n.status).wrapInner("
").find("a").first().addClass("ui-btn "+(i?i+" ":"")+(i?r(s.iconpos)+" ":"")+this._themeClassFromOption("ui-btn-",s.theme)+" "+(s.mini?"ui-mini ":"")),n.heading.insertBefore(n.content),this._handleExpandCollapse(this.options.collapsed),n},refresh:function(){this._applyOptions(this.options),this._renderedOptions=this._getOptions(this.options)},_applyOptions:function(e){var n,i,s,o,u,a=this.element,f=this._renderedOptions,l=this._ui,c=l.anchor,h=l.status,p=this._getOptions(e);e.collapsed!==t&&this._handleExpandCollapse(e.collapsed),n=a.hasClass("ui-collapsible-collapsed"),n?p.expandCueText!==t&&h.text(p.expandCueText):p.collapseCueText!==t&&h.text(p.collapseCueText),u=p.collapsedIcon!==t?p.collapsedIcon!==!1:f.collapsedIcon!==!1;if(p.iconpos!==t||p.collapsedIcon!==t||p.expandedIcon!==t)c.removeClass([r(f.iconpos)].concat(f.expandedIcon?["ui-icon-"+f.expandedIcon]:[]).concat(f.collapsedIcon?["ui-icon-"+f.collapsedIcon]:[]).join(" ")),u&&c.addClass([r(p.iconpos!==t?p.iconpos:f.iconpos)].concat(n?["ui-icon-"+(p.collapsedIcon!==t?p.collapsedIcon:f.collapsedIcon)]:["ui-icon-"+(p.expandedIcon!==t?p.expandedIcon:f.expandedIcon)]).join(" "));p.theme!==t&&(s=this._themeClassFromOption("ui-btn-",f.theme),i=this._themeClassFromOption("ui-btn-",p.theme),c.removeClass(s).addClass(i)),p.contentTheme!==t&&(s=this._themeClassFromOption("ui-body-",f.contentTheme),i=this._themeClassFromOption("ui-body-",p.contentTheme),l.content.removeClass(s).addClass(i)),p.inset!==t&&(a.toggleClass("ui-collapsible-inset",p.inset),o=!(!p.inset||!p.corners&&!f.corners)),p.corners!==t&&(o=!(!p.corners||!p.inset&&!f.inset)),o!==t&&a.toggleClass("ui-corner-all",o),p.mini!==t&&c.toggleClass("ui-mini",p.mini)},_setOptions:function(e){this._applyOptions(e),this._super(e),this._renderedOptions=this._getOptions(this.options)},_handleExpandCollapse:function(t){var n=this._renderedOptions,r=this._ui;r.status.text(t?n.expandCueText:n.collapseCueText),r.heading.toggleClass("ui-collapsible-heading-collapsed",t).find("a").first().toggleClass("ui-icon-"+n.expandedIcon,!t).toggleClass("ui-icon-"+n.collapsedIcon,t||n.expandedIcon===n.collapsedIcon).removeClass(e.mobile.activeBtnClass),this.element.toggleClass("ui-collapsible-collapsed",t),r.content.toggleClass("ui-collapsible-content-collapsed",t).attr("aria-hidden",t).trigger("updatelayout"),this.options.collapsed=t,this._trigger(t?"collapse":"expand")},expand:function(){this._handleExpandCollapse(!1)},collapse:function(){this._handleExpandCollapse(!0)},_destroy:function(){var e=this._ui,t=this.options;if(t.enhanced)return;e.placeholder?(e.originalHeading.insertBefore(e.placeholder),e.placeholder.remove(),e.heading.remove()):(e.status.remove(),e.heading.removeClass("ui-collapsible-heading ui-collapsible-heading-collapsed").children().contents().unwrap()),e.anchor.contents().unwrap(),e.content.contents().unwrap(),this.element.removeClass("ui-collapsible ui-collapsible-collapsed ui-collapsible-themed-content ui-collapsible-inset ui-corner-all")}}),e.mobile.collapsible.defaults={expandCueText:" click to expand contents",collapseCueText:" click to collapse contents",collapsedIcon:"plus",contentTheme:"inherit",expandedIcon:"minus",iconpos:"left",inset:!0,corners:!0,theme:"inherit",mini:!1}}(e),function(e,t){e.widget("mobile.controlgroup",e.extend({options:{enhanced:!1,theme:null,shadow:!1,corners:!0,excludeInvisible:!0,type:"vertical",mini:!1},_create:function(){var t=this.element,n=this.options,r=e.mobile.page.prototype.keepNativeSelector();e.fn.buttonMarkup&&this.element.find(e.fn.buttonMarkup.initSelector).not(r).buttonMarkup(),e.each(this._childWidgets,e.proxy(function(t,n){e.mobile[n]&&this.element.find(e.mobile[n].initSelector).not(r)[n]()},this)),e.extend(this,{_ui:null,_initialRefresh:!0}),n.enhanced?this._ui={groupLegend:t.children(".ui-controlgroup-label").children(),childWrapper:t.children(".ui-controlgroup-controls")}:this._ui=this._enhance()},_childWidgets:["checkboxradio","selectmenu","button"],_themeClassFromOption:function(e){return e?e==="none"?"":"ui-group-theme-"+e:""},_enhance:function(){var t=this.element,n=this.options,r={groupLegend:t.children("legend"),childWrapper:t.addClass("ui-controlgroup ui-controlgroup-"+(n.type==="horizontal"?"horizontal":"vertical")+" "+this._themeClassFromOption(n.theme)+" "+(n.corners?"ui-corner-all ":"")+(n.mini?"ui-mini ":"")).wrapInner("
").children()};return r.groupLegend.length>0&&e("
").append(r.groupLegend).prependTo(t),r},_init:function(){this.refresh()},_setOptions:function(e){var n,r,i=this.element;return e.type!==t&&(i.removeClass("ui-controlgroup-horizontal ui-controlgroup-vertical").addClass("ui-controlgroup-"+(e.type==="horizontal"?"horizontal":"vertical")),n=!0),e.theme!==t&&i.removeClass(this._themeClassFromOption(this.options.theme)).addClass(this._themeClassFromOption(e.theme)),e.corners!==t&&i.toggleClass("ui-corner-all",e.corners),e.mini!==t&&i.toggleClass("ui-mini",e.mini),e.shadow!==t&&this._ui.childWrapper.toggleClass("ui-shadow",e.shadow),e.excludeInvisible!==t&&(this.options.excludeInvisible=e.excludeInvisible,n=!0),r=this._super(e),n&&this.refresh(),r},container:function(){return this._ui.childWrapper},refresh:function(){var t=this.container(),n=t.find(".ui-btn").not(".ui-slider-handle"),r=this._initialRefresh;e.mobile.checkboxradio&&t.find(":mobile-checkboxradio").checkboxradio("refresh"),this._addFirstLastClasses(n,this.options.excludeInvisible?this._getVisibles(n,r):n,r),this._initialRefresh=!1},_destroy:function(){var e,t,n=this.options;if(n.enhanced)return this;e=this._ui,t=this.element.removeClass("ui-controlgroup ui-controlgroup-horizontal ui-controlgroup-vertical ui-corner-all ui-mini "+this._themeClassFromOption(n.theme)).find(".ui-btn").not(".ui-slider-handle"),this._removeFirstLastClasses(t),e.groupLegend.unwrap(),e.childWrapper.children().unwrap()}},e.mobile.behaviors.addFirstLastClasses))}(e),function(e,t,n){e.widget("mobile.dialog",{options:{closeBtn:"left",closeBtnText:"Close",overlayTheme:"a",corners:!0},_handlePageBeforeShow:function(){this._isCloseable=!0,this.options.overlayTheme&&this.element.page("removeContainerBackground").page("setContainerBackground",this.options.overlayTheme)},_handlePageBeforeHide:function(){this._isCloseable=!1},_handleVClickSubmit:function(t){var n,r=e(t.target).closest(t.type==="vclick"?"a":"form");r.length&&!r.jqmData("transition")&&(n={},n["data-"+e.mobile.ns+"transition"]=(e.mobile.navigate.history.getActive()||{}).transition||e.mobile.defaultDialogTransition,n["data-"+e.mobile.ns+"direction"]="reverse",r.attr(n))},_create:function(){var t=this.element,n=this.options;t.addClass("ui-dialog").wrapInner(e("
",{role:"dialog","class":"ui-dialog-contain ui-overlay-shadow"+(n.corners?" ui-corner-all":"")})),e.extend(this,{_isCloseable:!1,_inner:t.children(),_headerCloseButton:null}),this._on(t,{vclick:"_handleVClickSubmit",submit:"_handleVClickSubmit",pagebeforeshow:"_handlePageBeforeShow",pagebeforehide:"_handlePageBeforeHide"}),this._setCloseBtn(n.closeBtn)},_setOptions:function(t){var r,i,s=this.options;t.corners!==n&&this._inner.toggleClass("ui-corner-all",!!t.corners),t.overlayTheme!==n&&e.mobile.activePage[0]===this.element[0]&&(s.overlayTheme=t.overlayTheme,this._handlePageBeforeShow()),t.closeBtnText!==n&&(r=s.closeBtn,i=t.closeBtnText),t.closeBtn!==n&&(r=t.closeBtn),r&&this._setCloseBtn(r,i),this._super(t)},_setCloseBtn:function(t,n){var r,i=this._headerCloseButton;t="left"===t?"left":"right"===t?"right":"none","none"===t?i&&(i.remove(),i=null):i?(i.removeClass("ui-btn-left ui-btn-right").addClass("ui-btn-"+t),n&&i.text(n)):(r=this._inner.find(":jqmData(role='header')").first(),i=e("
",{role:"button",href:"#","class":"ui-btn ui-corner-all ui-icon-delete ui-btn-icon-notext ui-btn-"+t}).text(n||this.options.closeBtnText||"").prependTo(r),this._on(i,{click:"close"})),this._headerCloseButton=i},close:function(){var t=e.mobile.navigate.history;this._isCloseable&&(this._isCloseable=!1,e.mobile.hashListeningEnabled&&t.activeIndex>0?e.mobile.back():e.mobile.pageContainer.pagecontainer("back"))}})}(e,this),function(e,t){e.widget("mobile.textinput",{initSelector:"input[type='text'],input[type='search'],:jqmData(type='search'),input[type='number'],:jqmData(type='number'),input[type='password'],input[type='email'],input[type='url'],input[type='tel'],textarea,input[type='time'],input[type='date'],input[type='month'],input[type='week'],input[type='datetime'],input[type='datetime-local'],input[type='color'],input:not([type]),input[type='file']",options:{theme:null,corners:!0,mini:!1,preventFocusZoom:/iPhone|iPad|iPod/.test(navigator.platform)&&navigator.userAgent.indexOf("AppleWebKit")>-1,wrapperClass:"",enhanced:!1},_create:function(){var t=this.options,n=this.element.is("[type='search'], :jqmData(type='search')"),r=this.element[0].tagName==="TEXTAREA",i=this.element.is("[data-"+(e.mobile.ns||"")+"type='range']"),s=(this.element.is("input")||this.element.is("[data-"+(e.mobile.ns||"")+"type='search']"))&&!i;this.element.prop("disabled")&&(t.disabled=!0),e.extend(this,{classes:this._classesFromOptions(),isSearch:n,isTextarea:r,isRange:i,inputNeedsWrap:s}),this._autoCorrect(),t.enhanced||this._enhance(),this._on({focus:"_handleFocus",blur:"_handleBlur"})},refresh:function(){this.setOptions({disabled:this.element.is(":disabled")})},_enhance:function(){var e=[];this.isTextarea&&e.push("ui-input-text"),(this.isTextarea||this.isRange)&&e.push("ui-shadow-inset"),this.inputNeedsWrap?this.element.wrap(this._wrap()):e=e.concat(this.classes),this.element.addClass(e.join(" "))},widget:function(){return this.inputNeedsWrap?this.element.parent():this.element},_classesFromOptions:function(){var e=this.options,t=[];return t.push("ui-body-"+(e.theme===null?"inherit":e.theme)),e.corners&&t.push("ui-corner-all"),e.mini&&t.push("ui-mini"),e.disabled&&t.push("ui-state-disabled"),e.wrapperClass&&t.push(e.wrapperClass),t},_wrap:function(){return e("
")},_autoCorrect:function(){typeof this.element[0].autocorrect!="undefined"&&!e.support.touchOverflow&&(this.element[0].setAttribute("autocorrect","off"),this.element[0].setAttribute("autocomplete","off"))},_handleBlur:function(){this.widget().removeClass(e.mobile.focusClass),this.options.preventFocusZoom&&e.mobile.zoom.enable(!0)},_handleFocus:function(){this.options.preventFocusZoom&&e.mobile.zoom.disable(!0),this.widget().addClass(e.mobile.focusClass)},_setOptions:function(e){var n=this.widget();this._super(e);if(e.disabled!==t||e.mini!==t||e.corners!==t||e.theme!==t||e.wrapperClass!==t)n.removeClass(this.classes.join(" ")),this.classes=this._classesFromOptions(),n.addClass(this.classes.join(" "));e.disabled!==t&&this.element.prop("disabled",!!e.disabled)},_destroy:function(){if(this.options.enhanced)return;this.inputNeedsWrap&&this.element.unwrap(),this.element.removeClass("ui-input-text "+this.classes.join(" "))}})}(e),function(e,t){e.widget("mobile.textinput",e.mobile.textinput,{options:{autogrow:!0,keyupTimeoutBuffer:100},_create:function(){this._super(),this.options.autogrow&&this.isTextarea&&this._autogrow()},_autogrow:function(){this.element.addClass("ui-textinput-autogrow"),this._on({keyup:"_timeout",change:"_timeout",input:"_timeout",paste:"_timeout"}),this._on(!0,this.document,{pageshow:"_handleShow",popupbeforeposition:"_handleShow",updatelayout:"_handleShow",panelopen:"_handleShow"})},_handleShow:function(t){e.contains(t.target,this.element[0])&&this.element.is(":visible")&&(t.type!=="popupbeforeposition"&&this.element.addClass("ui-textinput-autogrow-resize").animationComplete(e.proxy(function(){this.element.removeClass("ui-textinput-autogrow-resize")},this),"transition"),this._prepareHeightUpdate())},_unbindAutogrow:function(){this.element.removeClass("ui-textinput-autogrow"),this._off(this.element,"keyup change input paste"),this._off(this.document,"pageshow popupbeforeposition updatelayout panelopen")},keyupTimeout:null,_prepareHeightUpdate:function(e){this.keyupTimeout&&clearTimeout(this.keyupTimeout),e===t?this._updateHeight():this.keyupTimeout=this._delay("_updateHeight",e)},_timeout:function(){this._prepareHeightUpdate(this.options.keyupTimeoutBuffer)},_updateHeight:function(){var e,t,n,r,i,s,o,u,a,f=this.window.scrollTop();this.keyupTimeout=0,"onpage"in this.element[0]||this.element.css({height:0,"min-height":0,"max-height":0}),r=this.element[0].scrollHeight,i=this.element[0].clientHeight,s=parseFloat(this.element.css("border-top-width")),o=parseFloat(this.element.css("border-bottom-width")),u=s+o,a=r+u+15,i===0&&(e=parseFloat(this.element.css("padding-top")),t=parseFloat(this.element.css("padding-bottom")),n=e+t,a+=n),this.element.css({height:a,"min-height":"","max-height":""}),this.window.scrollTop(f)},refresh:function(){this.options.autogrow&&this.isTextarea&&this._updateHeight()},_setOptions:function(e){this._super(e),e.autogrow!==t&&this.isTextarea&&(e.autogrow?this._autogrow():this._unbindAutogrow())}})}(e),function(e,t){e.widget("mobile.button",{initSelector:"input[type='button'], input[type='submit'], input[type='reset']",options:{theme:null,icon:null,iconpos:"left",iconshadow:!1,corners:!0,shadow:!0,inline:null,mini:null,wrapperClass:null,enhanced:!1},_create:function(){this.element.is(":disabled")&&(this.options.disabled=!0),this.options.enhanced||this._enhance(),e.extend(this,{wrapper:this.element.parent()}),this._on({focus:function(){this.widget().addClass(e.mobile.focusClass)},blur:function(){this.widget().removeClass(e.mobile.focusClass)}}),this.refresh(!0)},_enhance:function(){this.element.wrap(this._button())},_button:function(){var t=this.options,n=this._getIconClasses(this.options);return e("
"+this.element.val()+"
")},widget:function(){return this.wrapper},_destroy:function(){this.element.insertBefore(this.wrapper),this.wrapper.remove()},_getIconClasses:function(e){return e.icon?"ui-icon-"+e.icon+(e.iconshadow?" ui-shadow-icon":"")+" ui-btn-icon-"+e.iconpos:""},_setOptions:function(n){var r=this.widget();n.theme!==t&&r.removeClass(this.options.theme).addClass("ui-btn-"+n.theme),n.corners!==t&&r.toggleClass("ui-corner-all",n.corners),n.shadow!==t&&r.toggleClass("ui-shadow",n.shadow),n.inline!==t&&r.toggleClass("ui-btn-inline",n.inline),n.mini!==t&&r.toggleClass("ui-mini",n.mini),n.disabled!==t&&(this.element.prop("disabled",n.disabled),r.toggleClass("ui-state-disabled",n.disabled)),(n.icon!==t||n.iconshadow!==t||n.iconpos!==t)&&r.removeClass(this._getIconClasses(this.options)).addClass(this._getIconClasses(e.extend({},this.options,n))),this._super(n)},refresh:function(t){var n,r=this.element.prop("disabled");this.options.icon&&this.options.iconpos==="notext"&&this.element.attr("title")&&this.element.attr("title",this.element.val()),t||(n=this.element.detach(),e(this.wrapper).text(this.element.val()).append(n)),this.options.disabled!==r&&this._setOptions({disabled:r})}})}(e),function(e,t){e.mobile.behaviors.formReset={_handleFormReset:function(){this._on(this.element.closest("form"),{reset:function(){this._delay("_reset")}})}}}(e),function(e,t){var n=e.mobile.path.hashToSelector;e.widget("mobile.checkboxradio",e.extend({initSelector:"input:not( :jqmData(role='flipswitch' ) )[type='checkbox'],input[type='radio']:not( :jqmData(role='flipswitch' ))",options:{theme:"inherit",mini:!1,wrapperClass:null,enhanced:!1,iconpos:"left"},_create:function(){var t=this.element,n=this.options,r=function(e,t){return e.jqmData(t)||e.closest("form, fieldset").jqmData(t)},i=this.options.enhanced?{element:this.element.siblings("label"),isParent:!1}:this._findLabel(),s=t[0].type,o="ui-"+s+"-on",u="ui-"+s+"-off";if(s!=="checkbox"&&s!=="radio")return;this.element[0].disabled&&(this.options.disabled=!0),n.iconpos=r(t,"iconpos")||i.element.attr("data-"+e.mobile.ns+"iconpos")||n.iconpos,n.mini=r(t,"mini")||n.mini,e.extend(this,{input:t,label:i.element,labelIsParent:i.isParent,inputtype:s,checkedClass:o,uncheckedClass:u}),this.options.enhanced||this._enhance(),this._on(i.element,{vmouseover:"_handleLabelVMouseOver",vclick:"_handleLabelVClick"}),this._on(t,{vmousedown:"_cacheVals",vclick:"_handleInputVClick",focus:"_handleInputFocus",blur:"_handleInputBlur"}),this._handleFormReset(),this.refresh()},_findLabel:function(){var t,r,i,s=this.element,o=s[0].labels;return o&&o.length>0?(r=e(o[0]),i=e.contains(r[0],s[0])):(t=s.closest("label"),i=t.length>0,r=i?t:e(this.document[0].getElementsByTagName("label")).filter("[for='"+n(s[0].id)+"']").first()),{element:r,isParent:i}},_enhance:function(){this.label.addClass("ui-btn ui-corner-all"),this.labelIsParent?this.input.add(this.label).wrapAll(this._wrapper()):(this.element.wrap(this._wrapper()),this.element.parent().prepend(this.label)),this._setOptions({theme:this.options.theme,iconpos:this.options.iconpos,mini:this.options.mini})},_wrapper:function(){return e("
")},_handleInputFocus:function(){this.label.addClass(e.mobile.focusClass)},_handleInputBlur:function(){this.label.removeClass(e.mobile.focusClass)},_handleInputVClick:function(){this.element.prop("checked",this.element.is(":checked")),this._getInputSet().not(this.element).prop("checked",!1),this._updateAll(!0)},_handleLabelVMouseOver:function(e){this.label.parent().hasClass("ui-state-disabled")&&e.stopPropagation()},_handleLabelVClick:function(e){var t=this.element;if(t.is(":disabled")){e.preventDefault();return}return this._cacheVals(),t.prop("checked",this.inputtype==="radio"&&!0||!t.prop("checked")),t.triggerHandler("click"),this._getInputSet().not(t).prop("checked",!1),this._updateAll(),!1},_cacheVals:function(){this._getInputSet().each(function(){e(this).attr("data-"+e.mobile.ns+"cacheVal",this.checked)})},_getInputSet:function(){var t,r,i=this.element[0],s=i.name,o=i.form,u=this.element.parents().last().get(0),a=this.element;return s&&this.inputtype==="radio"&&u&&(t="input[type='radio'][name='"+n(s)+"']",o?(r=o.getAttribute("id"),r&&(a=e(t+"[form='"+n(r)+"']",u)),a=e(o).find(t).filter(function(){return this.form===o}).add(a)):a=e(t,u).filter(function(){return!this.form})),a},_updateAll:function(t){var n=this;this._getInputSet().each(function(){var r=e(this);(this.checked||n.inputtype==="checkbox")&&!t&&r.trigger("change")}).checkboxradio("refresh")},_reset:function(){this.refresh()},_hasIcon:function(){var t,n,r=e.mobile.controlgroup;if(r){t=this.element.closest(":mobile-controlgroup,"+r.prototype.initSelector);if(t.length>0)return n=e.data(t[0],"mobile-controlgroup"),(n?n.options.type:t.attr("data-"+e.mobile.ns+"type"))!=="horizontal"}return!0},refresh:function(){var t=this.element[0].checked,n=e.mobile.activeBtnClass,r="ui-btn-icon-"+this.options.iconpos,i=[],s=[];this._hasIcon()?(s.push(n),i.push(r)):(s.push(r),(t?i:s).push(n)),t?(i.push(this.checkedClass),s.push(this.uncheckedClass)):(i.push(this.uncheckedClass),s.push(this.checkedClass)),this.widget().toggleClass("ui-state-disabled",this.element.prop("disabled")),this.label.addClass(i.join(" ")).removeClass(s.join(" "))},widget:function(){return this.label.parent()},_setOptions:function(e){var n=this.label,r=this.options,i=this.widget(),s=this._hasIcon();e.disabled!==t&&(this.input.prop("disabled",!!e.disabled),i.toggleClass("ui-state-disabled",!!e.disabled)),e.mini!==t&&i.toggleClass("ui-mini",!!e.mini),e.theme!==t&&n.removeClass("ui-btn-"+r.theme).addClass("ui-btn-"+e.theme),e.wrapperClass!==t&&i.removeClass(r.wrapperClass).addClass(e.wrapperClass),e.iconpos!==t&&s?n.removeClass("ui-btn-icon-"+r.iconpos).addClass("ui-btn-icon-"+e.iconpos):s||n.removeClass("ui-btn-icon-"+r.iconpos),this._super(e)}},e.mobile.behaviors.formReset))}(e),function(e,t){e.widget("mobile.textinput",e.mobile.textinput,{options:{clearBtn:!1,clearBtnText:"Clear text"},_create:function(){this._super(),this.isSearch&&(this.options.clearBtn=!0),!!this.options.clearBtn&&this.inputNeedsWrap&&this._addClearBtn()},clearButton:function(){return e("
").attr("title",this.options.clearBtnText).text(this.options.clearBtnText)},_clearBtnClick:function(e){this.element.val("").focus().trigger("change"),this._clearBtn.addClass("ui-input-clear-hidden"),e.preventDefault()},_addClearBtn:function(){this.options.enhanced||this._enhanceClear(),e.extend(this,{_clearBtn:this.widget().find("a.ui-input-clear")}),this._bindClearEvents(),this._toggleClear()},_enhanceClear:function(){this.clearButton().appendTo(this.widget()),this.widget().addClass("ui-input-has-clear")},_bindClearEvents:function(){this._on(this._clearBtn,{click:"_clearBtnClick"}),this._on({keyup:"_toggleClear",change:"_toggleClear",input:"_toggleClear",focus:"_toggleClear",blur:"_toggleClear",cut:"_toggleClear",paste:"_toggleClear"})},_unbindClear:function(){this._off(this._clearBtn,"click"),this._off(this.element,"keyup change input focus blur cut paste")},_setOptions:function(e){this._super(e),e.clearBtn!==t&&!this.element.is("textarea, :jqmData(type='range')")&&(e.clearBtn?this._addClearBtn():this._destroyClear()),e.clearBtnText!==t&&this._clearBtn!==t&&this._clearBtn.text(e.clearBtnText).attr("title",e.clearBtnText)},_toggleClear:function(){this._delay("_toggleClearClass",0)},_toggleClearClass:function(){this._clearBtn.toggleClass("ui-input-clear-hidden",!this.element.val())},_destroyClear:function(){this.widget().removeClass("ui-input-has-clear"),this._unbindClear(),this._clearBtn.remove()},_destroy:function(){this._super(),this.options.clearBtn&&this._destroyClear()}})}(e),function(e,t){e.widget("mobile.flipswitch",e.extend({options:{onText:"On",offText:"Off",theme:null,enhanced:!1,wrapperClass:null,corners:!0,mini:!1},_create:function(){this.options.enhanced?e.extend(this,{flipswitch:this.element.parent(),on:this.element.find(".ui-flipswitch-on").eq(0),off:this.element.find(".ui-flipswitch-off").eq(0),type:this.element.get(0).tagName}):this._enhance(),this._handleFormReset(),this._originalTabIndex=this.element.attr("tabindex"),this._originalTabIndex!=null&&this.on.attr("tabindex",this._originalTabIndex),this.element.attr("tabindex","-1"),this._on({focus:"_handleInputFocus"}),this.element.is(":disabled")&&this._setOptions({disabled:!0}),this._on(this.flipswitch,{click:"_toggle",swipeleft:"_left",swiperight:"_right"}),this._on(this.on,{keydown:"_keydown"}),this._on({change:"refresh"})},_handleInputFocus:function(){this.on.focus()},widget:function(){return this.flipswitch},_left:function(){this.flipswitch.removeClass("ui-flipswitch-active"),this.type==="SELECT"?this.element.get(0).selectedIndex=0:this.element.prop("checked",!1),this.element.trigger("change")},_right:function(){this.flipswitch.addClass("ui-flipswitch-active"),this.type==="SELECT"?this.element.get(0).selectedIndex=1:this.element.prop("checked",!0),this.element.trigger("change")},_enhance:function(){var t=e("
"),n=this.options,r=this.element,i=n.theme?n.theme:"inherit",s=e("
",{href:"#"}),o=e("
"),u=r.get(0).tagName,a=u==="INPUT"?n.onText:r.find("option").eq(1).text(),f=u==="INPUT"?n.offText:r.find("option").eq(0).text();s.addClass("ui-flipswitch-on ui-btn ui-shadow ui-btn-inherit").text(a),o.addClass("ui-flipswitch-off").text(f),t.addClass("ui-flipswitch ui-shadow-inset ui-bar-"+i+" "+(n.wrapperClass?n.wrapperClass:"")+" "+(r.is(":checked")||r.find("option").eq(1).is(":selected")?"ui-flipswitch-active":"")+(r.is(":disabled")?" ui-state-disabled":"")+(n.corners?" ui-corner-all":"")+(n.mini?" ui-mini":"")).append(s,o),r.addClass("ui-flipswitch-input").after(t).appendTo(t),e.extend(this,{flipswitch:t,on:s,off:o,type:u})},_reset:function(){this.refresh()},refresh:function(){var e,t=this.flipswitch.hasClass("ui-flipswitch-active")?"_right":"_left";this.type==="SELECT"?e=this.element.get(0).selectedIndex>0?"_right":"_left":e=this.element.prop("checked")?"_right":"_left",e!==t&&this[e]()},_toggle:function(){var e=this.flipswitch.hasClass("ui-flipswitch-active")?"_left":"_right";this[e]()},_keydown:function(t){t.which===e.mobile.keyCode.LEFT?this._left():t.which===e.mobile.keyCode.RIGHT?this._right():t.which===e.mobile.keyCode.SPACE&&(this._toggle(),t.preventDefault())},_setOptions:function(e){if(e.theme!==t){var n=e.theme?e.theme:"inherit",r=e.theme?e.theme:"inherit";this.widget().removeClass("ui-bar-"+n).addClass("ui-bar-"+r)}e.onText!==t&&this.on.text(e.onText),e.offText!==t&&this.off.text(e.offText),e.disabled!==t&&this.widget().toggleClass("ui-state-disabled",e.disabled),e.mini!==t&&this.widget().toggleClass("ui-mini",e.mini),e.corners!==t&&this.widget().toggleClass("ui-corner-all",e.corners),this._super(e)},_destroy:function(){if(this.options.enhanced)return;this._originalTabIndex!=null?this.element.attr("tabindex",this._originalTabIndex):this.element.removeAttr("tabindex"),this.on.remove(),this.off.remove(),this.element.unwrap(),this.flipswitch.remove(),this.removeClass("ui-flipswitch-input")}},e.mobile.behaviors.formReset))}(e),function(e,r){e.widget("mobile.slider",e.extend({initSelector:"input[type='range'], :jqmData(type='range'), :jqmData(role='slider')",widgetEventPrefix:"slide",options:{theme:null,trackTheme:null,corners:!0,mini:!1,highlight:!1},_create:function(){var i=this,s=this.element,o=this.options.trackTheme||e.mobile.getAttribute(s[0],"theme"),u=o?" ui-bar-"+o:" ui-bar-inherit",a=this.options.corners||s.jqmData("corners")?" ui-corner-all":"",f=this.options.mini||s.jqmData("mini")?" ui-mini":"",l=s[0].nodeName.toLowerCase(),c=l==="select",h=s.parent().is(":jqmData(role='rangeslider')"),p=c?"ui-slider-switch":"",d=s.attr("id"),v=e("[for='"+d+"']"),m=v.attr("id")||d+"-label",g=c?0:parseFloat(s.attr("min")),y=c?s.find("option").length-1:parseFloat(s.attr("max")),b=t.parseFloat(s.attr("step")||1),w=n.createElement("a"),E=e(w),S=n.createElement("div"),x=e(S),T=this.options.highlight&&!c?function(){var t=n.createElement("div");return t.className="ui-slider-bg "+e.mobile.activeBtnClass,e(t).prependTo(x)}():!1,N,C,k,L,A,O,M,_,D,P;v.attr("id",m),this.isToggleSwitch=c,w.setAttribute("href","#"),S.setAttribute("role","application"),S.className=[this.isToggleSwitch?"ui-slider ui-slider-track ui-shadow-inset ":"ui-slider-track ui-shadow-inset ",p,u,a,f].join(""),w.className="ui-slider-handle",S.appendChild(w),E.attr({role:"slider","aria-valuemin":g,"aria-valuemax":y,"aria-valuenow":this._value(),"aria-valuetext":this._value(),title:this._value(),"aria-labelledby":m}),e.extend(this,{slider:x,handle:E,control:s,type:l,step:b,max:y,min:g,valuebg:T,isRangeslider:h,dragging:!1,beforeStart:null,userModified:!1,mouseMoved:!1});if(c){M=s.attr("tabindex"),M&&E.attr("tabindex",M),s.attr("tabindex","-1").focus(function(){e(this).blur(),E.focus()}),C=n.createElement("div"),C.className="ui-slider-inneroffset";for(k=0,L=S.childNodes.length;k
":"",s.add(x).wrapAll(C)),this._on(this.handle,{vmousedown:"_handleVMouseDown",keydown:"_handleKeydown",keyup:"_handleKeyup"}),this.handle.bind("vclick",!1),this._handleFormReset(),this.refresh(r,r,!0)},_setOptions:function(e){e.theme!==r&&this._setTheme(e.theme),e.trackTheme!==r&&this._setTrackTheme(e.trackTheme),e.corners!==r&&this._setCorners(e.corners),e.mini!==r&&this._setMini(e.mini),e.highlight!==r&&this._setHighlight(e.highlight),e.disabled!==r&&this._setDisabled(e.disabled),this._super(e)},_controlChange:function(e){if(this._trigger("controlchange",e)===!1)return!1;this.mouseMoved||this.refresh(this._value(),!0)},_controlKeyup:function(){this.refresh(this._value(),!0,!0)},_controlBlur:function(){this.refresh(this._value(),!0)},_controlVMouseUp:function(){this._checkedRefresh()},_handleVMouseDown:function(){this.handle.focus()},_handleKeydown:function(t){var n=this._value();if(this.options.disabled)return;switch(t.keyCode){case e.mobile.keyCode.HOME:case e.mobile.keyCode.END:case e.mobile.keyCode.PAGE_UP:case e.mobile.keyCode.PAGE_DOWN:case e.mobile.keyCode.UP:case e.mobile.keyCode.RIGHT:case e.mobile.keyCode.DOWN:case e.mobile.keyCode.LEFT:t.preventDefault(),this._keySliding||(this._keySliding=!0,this.handle.addClass("ui-state-active"))}switch(t.keyCode){case e.mobile.keyCode.HOME:this.refresh(this.min);break;case e.mobile.keyCode.END:this.refresh(this.max);break;case e.mobile.keyCode.PAGE_UP:case e.mobile.keyCode.UP:case e.mobile.keyCode.RIGHT:this.refresh(n+this.step);break;case e.mobile.keyCode.PAGE_DOWN:case e.mobile.keyCode.DOWN:case e.mobile.keyCode.LEFT:this.refresh(n-this.step)}},_handleKeyup:function(){this._keySliding&&(this._keySliding=!1,this.handle.removeClass("ui-state-active"))},_sliderVMouseDown:function(e){return this.options.disabled||e.which!==1&&e.which!==0&&e.which!==r?!1:this._trigger("beforestart",e)===!1?!1:(this.dragging=!0,this.userModified=!1,this.mouseMoved=!1,this.isToggleSwitch&&(this.beforeStart=this.element[0].selectedIndex),this.refresh(e),this._trigger("start"),!1)},_sliderVMouseUp:function(){if(this.dragging)return this.dragging=!1,this.isToggleSwitch&&(this.handle.addClass("ui-slider-handle-snapping"),this.mouseMoved?this.userModified?this.refresh(this.beforeStart===0?1:0):this.refresh(this.beforeStart):this.refresh(this.beforeStart===0?1:0)),this.mouseMoved=!1,this._trigger("stop"),!1},_preventDocumentDrag:function(e){if(this._trigger("drag",e)===!1)return!1;if(this.dragging&&!this.options.disabled)return this.mouseMoved=!0,this.isToggleSwitch&&this.handle.removeClass("ui-slider-handle-snapping"),this.refresh(e),this.userModified=this.beforeStart!==this.element[0].selectedIndex,!1},_checkedRefresh:function(){this.value!==this._value()&&this.refresh(this._value())},_value:function(){return this.isToggleSwitch?this.element[0].selectedIndex:parseFloat(this.element.val())},_reset:function(){this.refresh(r,!1,!0)},refresh:function(t,r,i){var s=this,o=e.mobile.getAttribute(this.element[0],"theme"),u=this.options.theme||o,a=u?" ui-btn-"+u:"",f=this.options.trackTheme||o,l=f?" ui-bar-"+f:" ui-bar-inherit",c=this.options.corners?" ui-corner-all":"",h=this.options.mini?" ui-mini":"",p,d,v,m,g,y,b,w,E,S,x,T,N,C,k,L,A,O,M,_;s.slider[0].className=[this.isToggleSwitch?"ui-slider ui-slider-switch ui-slider-track ui-shadow-inset":"ui-slider-track ui-shadow-inset",l,c,h].join(""),(this.options.disabled||this.element.prop("disabled"))&&this.disable(),this.value=this._value(),this.options.highlight&&!this.isToggleSwitch&&this.slider.find(".ui-slider-bg").length===0&&(this.valuebg=function(){var t=n.createElement("div");return t.className="ui-slider-bg "+e.mobile.activeBtnClass,e(t).prependTo(s.slider)}()),this.handle.addClass("ui-btn"+a+" ui-shadow"),b=this.element,w=!this.isToggleSwitch,E=w?[]:b.find("option"),S=w?parseFloat(b.attr("min")):0,x=w?parseFloat(b.attr("max")):E.length-1,T=w&&parseFloat(b.attr("step"))>0?parseFloat(b.attr("step")):1;if(typeof t=="object"){v=t,m=8,p=this.slider.offset().left,d=this.slider.width(),g=d/((x-S)/T);if(!this.dragging||v.pageX
p+d+m)return;g>1?y=(v.pageX-p)/d*100:y=Math.round((v.pageX-p)/d*100)}else t==null&&(t=w?parseFloat(b.val()||0):b[0].selectedIndex),y=(parseFloat(t)-S)/(x-S)*100;if(isNaN(y))return;N=y/100*(x-S)+S,C=(N-S)%T,k=N-C,Math.abs(C)*2>=T&&(k+=C>0?T:-T),L=100/((x-S)/T),N=parseFloat(k.toFixed(5)),typeof g=="undefined"&&(g=d/((x-S)/T)),g>1&&w&&(y=(N-S)*L*(1/T)),y<0&&(y=0),y>100&&(y=100),Nx&&(N=x),this.handle.css("left",y+"%"),this.handle[0].setAttribute("aria-valuenow",w?N:E.eq(N).attr("value")),this.handle[0].setAttribute("aria-valuetext",w?N:E.eq(N).getEncodedText()),this.handle[0].setAttribute("title",w?N:E.eq(N).getEncodedText()),this.valuebg&&this.valuebg.css("width",y+"%"),this._labels&&(A=this.handle.width()/this.slider.width()*100,O=y&&A+(100-A)*y/100,M=y===100?0:Math.min(A+100-O,100),this._labels.each(function(){var t=e(this).hasClass("ui-slider-label-a");e(this).width((t?O:M)+"%")}));if(!i){_=!1,w?(_=parseFloat(b.val())!==N,b.val(N)):(_=b[0].selectedIndex!==N,b[0].selectedIndex=N);if(this._trigger("beforechange",t)===!1)return!1;!r&&_&&b.trigger("change")}},_setHighlight:function(e){e=!!e,e?(this.options.highlight=!!e,this.refresh()):this.valuebg&&(this.valuebg.remove(),this.valuebg=!1)},_setTheme:function(e){this.handle.removeClass("ui-btn-"+this.options.theme).addClass("ui-btn-"+e);var t=this.options.theme?this.options.theme:"inherit",n=e?e:"inherit";this.control.removeClass("ui-body-"+t).addClass("ui-body-"+n)},_setTrackTheme:function(e){var t=this.options.trackTheme?this.options.trackTheme:"inherit",n=e?e:"inherit";this.slider.removeClass("ui-body-"+t).addClass("ui-body-"+n)},_setMini:function(e){e=!!e,!this.isToggleSwitch&&!this.isRangeslider&&(this.slider.parent().toggleClass("ui-mini",e),this.element.toggleClass("ui-mini",e)),this.slider.toggleClass("ui-mini",e)},_setCorners:function(e){this.slider.toggleClass("ui-corner-all",e),this.isToggleSwitch||this.control.toggleClass("ui-corner-all",e)},_setDisabled:function(e){e=!!e,this.element.prop("disabled",e),this.slider.toggleClass("ui-state-disabled",e).attr("aria-disabled",e),this.element.toggleClass("ui-state-disabled",e)}},e.mobile.behaviors.formReset))}(e),function(e,t){e.widget("mobile.rangeslider",e.extend({options:{theme:null,trackTheme:null,corners:!0,mini:!1,highlight:!0},_create:function(){var t=this.element,n=this.options.mini?"ui-rangeslider ui-mini":"ui-rangeslider",r=t.find("input").first(),i=t.find("input").last(),s=t.find("label").first(),o=e.data(r.get(0),"mobile-slider")||e.data(r.slider().get(0),"mobile-slider"),u=e.data(i.get(0),"mobile-slider")||e.data(i.slider().get(0),"mobile-slider"),a=o.slider,f=u.slider,l=o.handle,c=e("
").appendTo(t);r.addClass("ui-rangeslider-first"),i.addClass("ui-rangeslider-last"),t.addClass(n),a.appendTo(c),f.appendTo(c),s.insertBefore(t),l.prependTo(f),e.extend(this,{_inputFirst:r,_inputLast:i,_sliderFirst:a,_sliderLast:f,_label:s,_targetVal:null,_sliderTarget:!1,_sliders:c,_proxy:!1}),this.refresh(),this._on(this.element.find("input.ui-slider-input"),{slidebeforestart:"_slidebeforestart",slidestop:"_slidestop",slidedrag:"_slidedrag",slidebeforechange:"_change",blur:"_change",keyup:"_change"}),this._on({mousedown:"_change"}),this._on(this.element.closest("form"),{reset:"_handleReset"}),this._on(l,{vmousedown:"_dragFirstHandle"})},_handleReset:function(){var e=this;setTimeout(function(){e._updateHighlight()},0)},_dragFirstHandle:function(t){return e.data(this._inputFirst.get(0),"mobile-slider").dragging=!0,e.data(this._inputFirst.get(0),"mobile-slider").refresh(t),e.data(this._inputFirst.get(0),"mobile-slider")._trigger("start"),!1},_slidedrag:function(t){var n=e(t.target).is(this._inputFirst),r=n?this._inputLast:this._inputFirst;this._sliderTarget=!1;if(this._proxy==="first"&&n||this._proxy==="last"&&!n)return e.data(r.get(0),"mobile-slider").dragging=!0,e.data(r.get(0),"mobile-slider").refresh(t),!1},_slidestop:function(t){var n=e(t.target).is(this._inputFirst);this._proxy=!1,this.element.find("input").trigger("vmouseup"),this._sliderFirst.css("z-index",n?1:"")},_slidebeforestart:function(t){this._sliderTarget=!1,e(t.originalEvent.target).hasClass("ui-slider-track")&&(this._sliderTarget=!0,this._targetVal=e(t.target).val())},_setOptions:function(e){e.theme!==t&&this._setTheme(e.theme),e.trackTheme!==t&&this._setTrackTheme(e.trackTheme),e.mini!==t&&this._setMini(e.mini),e.highlight!==t&&this._setHighlight(e.highlight),e.disabled!==t&&this._setDisabled(e.disabled),this._super(e),this.refresh()},refresh:function(){var e=this.element,t=this.options;if(this._inputFirst.is(":disabled")||this._inputLast.is(":disabled"))this.options.disabled=!0;e.find("input").slider({theme:t.theme,trackTheme:t.trackTheme,disabled:t.disabled,corners:t.corners,mini:t.mini,highlight:t.highlight}).slider("refresh"),this._updateHighlight()},_change:function(t){if(t.type==="keyup")return this._updateHighlight(),!1;var n=this,r=parseFloat(this._inputFirst.val(),10),i=parseFloat(this._inputLast.val(),10),s=e(t.target).hasClass("ui-rangeslider-first"),o=s?this._inputFirst:this._inputLast,u=s?this._inputLast:this._inputFirst;if(this._inputFirst.val()>this._inputLast.val()&&t.type==="mousedown"&&!e(t.target).hasClass("ui-slider-handle"))o.blur();else if(t.type==="mousedown")return;r>i&&!this._sliderTarget?(o.val(s?i:r).slider("refresh"),this._trigger("normalize")):r>i&&(o.val(this._targetVal).slider("refresh"),setTimeout(function(){u.val(s?r:i).slider("refresh"),e.data(u.get(0),"mobile-slider").handle.focus(),n._sliderFirst.css("z-index",s?"":1),n._trigger("normalize")},0),this._proxy=s?"first":"last"),r===i?(e.data(o.get(0),"mobile-slider").handle.css("z-index",1),e.data(u.get(0),"mobile-slider").handle.css("z-index",0)):(e.data(u.get(0),"mobile-slider").handle.css("z-index",""),e.data(o.get(0),"mobile-slider").handle.css("z-index","")),this._updateHighlight();if(r>=i)return!1},_updateHighlight:function(){var t=parseInt(e.data(this._inputFirst.get(0),"mobile-slider").handle.get(0).style.left,10),n=parseInt(e.data(this._inputLast.get(0),"mobile-slider").handle.get(0).style.left,10),r=n-t;this.element.find(".ui-slider-bg").css({"margin-left":t+"%",width:r+"%"})},_setTheme:function(e){this._inputFirst.slider("option","theme",e),this._inputLast.slider("option","theme",e)},_setTrackTheme:function(e){this._inputFirst.slider("option","trackTheme",e),this._inputLast.slider("option","trackTheme",e)},_setMini:function(e){this._inputFirst.slider("option","mini",e),this._inputLast.slider("option","mini",e),this.element.toggleClass("ui-mini",!!e)},_setHighlight:function(e){this._inputFirst.slider("option","highlight",e),this._inputLast.slider("option","highlight",e)},_setDisabled:function(e){this._inputFirst.prop("disabled",e),this._inputLast.prop("disabled",e)},_destroy:function(){this._label.prependTo(this.element),this.element.removeClass("ui-rangeslider ui-mini"),this._inputFirst.after(this._sliderFirst),this._inputLast.after(this._sliderLast),this._sliders.remove(),this.element.find("input").removeClass("ui-rangeslider-first ui-rangeslider-last").slider("destroy")}},e.mobile.behaviors.formReset))}(e),function(e,r){e.widget("mobile.selectmenu",e.extend({initSelector:"select:not( :jqmData(role='slider')):not( :jqmData(role='flipswitch') )",options:{theme:null,icon:"carat-d",iconpos:"right",inline:!1,corners:!0,shadow:!0,iconshadow:!1,overlayTheme:null,dividerTheme:null,hidePlaceholderMenuItems:!0,closeText:"Close",nativeMenu:!0,preventFocusZoom:/iPhone|iPad|iPod/.test(navigator.platform)&&navigator.userAgent.indexOf("AppleWebKit")>-1,mini:!1},_button:function(){return e("
")},_setDisabled:function(e){return this.element.attr("disabled",e),this.button.attr("aria-disabled",e),this._setOption("disabled",e)},_focusButton:function(){var e=this;setTimeout(function(){e.button.focus()},40)},_selectOptions:function(){return this.select.find("option")},_preExtension:function(){var t=this.options.inline||this.element.jqmData("inline"),n=this.options.mini||this.element.jqmData("mini"),r="";!~this.element[0].className.indexOf("ui-btn-left")||(r=" ui-btn-left"),!~this.element[0].className.indexOf("ui-btn-right")||(r=" ui-btn-right"),t&&(r+=" ui-btn-inline"),n&&(r+=" ui-mini"),this.select=this.element.removeClass("ui-btn-left ui-btn-right").wrap(""),this.selectId=this.select.attr("id")||"select-"+this.uuid,this.buttonId=this.selectId+"-button",this.label=e("label[for='"+this.selectId+"']"),this.isMultiple=this.select[0].multiple},_destroy:function(){var e=this.element.parents(".ui-select");e.length>0&&(e.is(".ui-btn-left, .ui-btn-right")&&this.element.addClass(e.hasClass("ui-btn-left")?"ui-btn-left":"ui-btn-right"),this.element.insertAfter(e),e.remove())},_create:function(){this._preExtension(),this.button=this._button();var n=this,r=this.options,i=r.icon?r.iconpos||this.select.jqmData("iconpos"):!1,s=this.button.insertBefore(this.select).attr("id",this.buttonId).addClass("ui-btn"+(r.icon?" ui-icon-"+r.icon+" ui-btn-icon-"+i+(r.iconshadow?" ui-shadow-icon":""):"")+(r.theme?" ui-btn-"+r.theme:"")+(r.corners?" ui-corner-all":"")+(r.shadow?" ui-shadow":""));this.setButtonText(),r.nativeMenu&&t.opera&&t.opera.version&&s.addClass("ui-select-nativeonly"),this.isMultiple&&(this.buttonCount=e("
").addClass("ui-li-count ui-body-inherit").hide().appendTo(s.addClass("ui-li-has-count"))),(r.disabled||this.element.attr("disabled"))&&this.disable(),this.select.change(function(){n.refresh(),!r.nativeMenu||n._delay(function(){n.select.blur()})}),this._handleFormReset(),this._on(this.button,{keydown:"_handleKeydown"}),this.build()},build:function(){var t=this;this.select.appendTo(t.button).bind("vmousedown",function(){t.button.addClass(e.mobile.activeBtnClass)}).bind("focus",function(){t.button.addClass(e.mobile.focusClass)}).bind("blur",function(){t.button.removeClass(e.mobile.focusClass)}).bind("focus vmouseover",function(){t.button.trigger("vmouseover")}).bind("vmousemove",function(){t.button.removeClass(e.mobile.activeBtnClass)}).bind("change blur vmouseout",function(){t.button.trigger("vmouseout").removeClass(e.mobile.activeBtnClass)}),t.button.bind("vmousedown",function(){t.options.preventFocusZoom&&e.mobile.zoom.disable(!0)}),t.label.bind("click focus",function(){t.options.preventFocusZoom&&e.mobile.zoom.disable(!0)}),t.select.bind("focus",function(){t.options.preventFocusZoom&&e.mobile.zoom.disable(!0)}),t.button.bind("mouseup",function(){t.options.preventFocusZoom&&setTimeout(function(){e.mobile.zoom.enable(!0)},0)}),t.select.bind("blur",function(){t.options.preventFocusZoom&&e.mobile.zoom.enable(!0)})},selected:function(){return this._selectOptions().filter(":selected")},selectedIndices:function(){var e=this;return this.selected().map(function(){return e._selectOptions().index(this)}).get()},setButtonText:function(){var t=this,r=this.selected(),i=this.placeholder,s=e(n.createElement("span"));this.button.children("span").not(".ui-li-count").remove().end().end().prepend(function(){return r.length?i=r.map(function(){return e(this).text()}).get().join(", "):i=t.placeholder,i?s.text(i):s.html(" "),s.addClass(t.select.attr("class")).addClass(r.attr("class")).removeClass("ui-screen-hidden")}())},setButtonCount:function(){var e=this.selected();this.isMultiple&&this.buttonCount[e.length>1?"show":"hide"]().text(e.length)},_handleKeydown:function(){this._delay("_refreshButton")},_reset:function(){this.refresh()},_refreshButton:function(){this.setButtonText(),this.setButtonCount()},refresh:function(){this._refreshButton()},open:e.noop,close:e.noop,disable:function(){this._setDisabled(!0),this.button.addClass("ui-state-disabled")},enable:function(){this._setDisabled(!1),this.button.removeClass("ui-state-disabled")}},e.mobile.behaviors.formReset))}(e),function(e,t){function r(){return n||(n=e("
",{"class":"ui-slider-popup ui-shadow ui-corner-all"})),n.clone()}var n;e.widget("mobile.slider",e.mobile.slider,{options:{popupEnabled:!1,showValue:!1},_create:function(){this._super(),e.extend(this,{_currentValue:null,_popup:null,_popupVisible:!1}),this._setOption("popupEnabled",this.options.popupEnabled),this._on(this.handle,{vmousedown:"_showPopup"}),this._on(this.slider.add(this.document),{vmouseup:"_hidePopup"}),this._refresh()},_positionPopup:function(){var e=this.handle.offset();this._popup.offset({left:e.left+(this.handle.width()-this._popup.width())/2,top:e.top-this._popup.outerHeight()-5})},_setOption:function(e,t){this._super(e,t),e==="showValue"?this.handle.html(t&&!this.options.mini?this._value():""):e==="popupEnabled"&&t&&!this._popup&&(this._popup=r().addClass("ui-body-"+(this.options.theme||"a")).hide().insertBefore(this.element))},refresh:function(){this._super.apply(this,arguments),this._refresh()},_refresh:function(){var e=this.options,t;e.popupEnabled&&this.handle.removeAttr("title"),t=this._value();if(t===this._currentValue)return;this._currentValue=t,e.popupEnabled&&this._popup&&(this._positionPopup(),this._popup.html(t)),e.showValue&&!this.options.mini&&this.handle.html(t)},_showPopup:function(){this.options.popupEnabled&&!this._popupVisible&&(this.handle.html(""),this._popup.show(),this._positionPopup(),this._popupVisible=!0)},_hidePopup:function(){var e=this.options;e.popupEnabled&&this._popupVisible&&(e.showValue&&!e.mini&&this.handle.html(this._value()),this._popup.hide(),this._popupVisible=!1)}})}(e),function(e,t){var n=e.mobile.getAttribute;e.widget("mobile.listview",e.extend({options:{theme:null,countTheme:null,dividerTheme:null,icon:"carat-r",splitIcon:"carat-r",splitTheme:null,corners:!0,shadow:!0,inset:!1},_create:function(){var e=this,t="";t+=e.options.inset?" ui-listview-inset":"",!e.options.inset||(t+=e.options.corners?" ui-corner-all":"",t+=e.options.shadow?" ui-shadow":""),e.element.addClass(" ui-listview"+t),e.refresh(!0)},_findFirstElementByTagName:function(e,t,n,r){var i={};i[n]=i[r]=!0;while(e){if(i[e.nodeName])return e;e=e[t]}return null},_addThumbClasses:function(t){var n,r,i=t.length;for(n=0;n1?(u="ui-li-has-alt",m=c.last(),g=n(m[0],"theme")||x.splitTheme||n(o[0],"theme",!0),y=g?" ui-btn-"+g:"",b=n(m[0],"icon")||n(o[0],"icon")||x.splitIcon,w="ui-btn ui-btn-icon-notext ui-icon-"+b+y,m.attr("title",e.trim(m.getEncodedText())).addClass(w).empty(),c=c.first()):l&&(r+=" ui-btn-icon-right ui-icon-"+l),c.addClass(r)):h?(E=n(o[0],"theme")||x.dividerTheme||x.theme,u="ui-li-divider ui-bar-"+(E?E:"inherit"),o.attr("role","heading")):c.length<=0&&(u="ui-li-static ui-body-"+(a?a:"inherit")),N&&v&&(d=parseInt(v,10)-1,o.css("counter-reset","listnumbering "+d));k[u]||(k[u]=[]),k[u].push(o[0])}for(u in k)e(k[u]).addClass(u);L.each(function(){e(this).closest("li").addClass("ui-li-has-count")}),O&&L.not("[class*='ui-body-']").addClass(O),this._addThumbClasses(S),this._addThumbClasses(S.find(".ui-btn")),this._afterListviewRefresh(),this._addFirstLastClasses(S,this._getVisibles(S,t),t)}},e.mobile.behaviors.addFirstLastClasses))}(e),function(e,t){function r(t){var n=e.trim(t.text())||null;return n?(n=n.slice(0,1).toUpperCase(),n):null}e.widget("mobile.listview",e.mobile.listview,{options:{autodividers:!1,autodividersSelector:r},_beforeListviewRefresh:function(){this.options.autodividers&&(this._replaceDividers(),this._superApply(arguments))},_replaceDividers:function(){var t,r,i,s,o=null,u=this.element,a;u.children("li:jqmData(role='list-divider')").remove(),r=u.children("li");for(t=0;t-1;t--)i=e[t],i.className.match(n)?(s&&(i.className=i.className+" ui-screen-hidden"),s=!0):i.className.match(r)||(s=!1)}}})}(e),function(e,t){e.widget("mobile.navbar",{options:{iconpos:"top",grid:null},_create:function(){var r=this.element,i=r.find("a, button"),s=i.filter(":jqmData(icon)").length?this.options.iconpos:t;r.addClass("ui-navbar").attr("role","navigation").find("ul").jqmEnhanceable().grid({grid:this.options.grid}),i.each(function(){var t=e.mobile.getAttribute(this,"icon"),n=e.mobile.getAttribute(this,"theme"),r="ui-btn";n&&(r+=" ui-btn-"+n),t&&(r+=" ui-icon-"+t+" ui-btn-icon-"+s),e(this).addClass(r)}),r.delegate("a","vclick",function(){var t=e(this);t.hasClass("ui-state-disabled")||t.hasClass("ui-disabled")||t.hasClass(e.mobile.activeBtnClass)||(i.removeClass(e.mobile.activeBtnClass),t.addClass(e.mobile.activeBtnClass),e(n).one("pagehide",function(){t.removeClass(e.mobile.activeBtnClass)}))}),r.closest(".ui-page").bind("pagebeforeshow",function(){i.filter(".ui-state-persist").addClass(e.mobile.activeBtnClass)})}})}(e),function(e,t,n){e.widget("mobile.page",e.mobile.page,{options:{closeBtn:"left",closeBtnText:"Close",overlayTheme:"a",corners:!0,dialog:!1},_create:function(){this._super(),this.options.dialog&&(e.extend(this,{_inner:this.element.children(),_headerCloseButton:null}),this.options.enhanced||this._setCloseBtn(this.options.closeBtn))},_enhance:function(){this._super(),this.options.dialog&&this.element.addClass("ui-dialog").wrapInner(e("
",{role:"dialog","class":"ui-dialog-contain ui-overlay-shadow"+(this.options.corners?" ui-corner-all":"")}))},_setOptions:function(t){var r,i,s=this.options;t.corners!==n&&this._inner.toggleClass("ui-corner-all",!!t.corners),t.overlayTheme!==n&&e.mobile.activePage[0]===this.element[0]&&(s.overlayTheme=t.overlayTheme,this._handlePageBeforeShow()),t.closeBtnText!==n&&(r=s.closeBtn,i=t.closeBtnText),t.closeBtn!==n&&(r=t.closeBtn),r&&this._setCloseBtn(r,i),this._super(t)},_handlePageBeforeShow:function(){this.options.overlayTheme&&this.options.dialog?(this.removeContainerBackground(),this.setContainerBackground(this.options.overlayTheme)):this._super()},_setCloseBtn:function(t,n){var r,i=this._headerCloseButton;t="left"===t?"left":"right"===t?"right":"none","none"===t?i&&(i.remove(),i=null):i?(i.removeClass("ui-btn-left ui-btn-right").addClass("ui-btn-"+t),n&&i.text(n)):(r=this._inner.find(":jqmData(role='header')").first(),i=e(" ",{href:"#","class":"ui-btn ui-corner-all ui-icon-delete ui-btn-icon-notext ui-btn-"+t}).attr("data-"+e.mobile.ns+"rel","back").text(n||this.options.closeBtnText||"").prependTo(r)),this._headerCloseButton=i}})}(e,this),function(e,n){e.widget("mobile.panel",{options:{classes:{panel:"ui-panel",panelOpen:"ui-panel-open",panelClosed:"ui-panel-closed",panelFixed:"ui-panel-fixed",panelInner:"ui-panel-inner",modal:"ui-panel-dismiss",modalOpen:"ui-panel-dismiss-open",pageContainer:"ui-panel-page-container",pageWrapper:"ui-panel-wrapper",pageFixedToolbar:"ui-panel-fixed-toolbar",pageContentPrefix:"ui-panel-page-content",animate:"ui-panel-animate"},animate:!0,theme:null,position:"left",dismissible:!0,display:"reveal",swipeClose:!0,positionFixed:!1},_closeLink:null,_parentPage:null,_page:null,_modal:null,_panelInner:null,_wrapper:null,_fixedToolbars:null,_create:function(){var t=this.element,n=t.closest(".ui-page, :jqmData(role='page')");e.extend(this,{_closeLink:t.find(":jqmData(rel='close')"),_parentPage:n.length>0?n:!1,_openedPage:null,_page:this._getPage,_panelInner:this._getPanelInner(),_fixedToolbars:this._getFixedToolbars}),this.options.display!=="overlay"&&this._getWrapper(),this._addPanelClasses(),e.support.cssTransform3d&&!!this.options.animate&&this.element.addClass(this.options.classes.animate),this._bindUpdateLayout(),this._bindCloseEvents(),this._bindLinkListeners(),this._bindPageEvents(),!this.options.dismissible||this._createModal(),this._bindSwipeEvents()},_getPanelInner:function(){var e=this.element.find("."+this.options.classes.panelInner);return e.length===0&&(e=this.element.children().wrapAll("
").parent()),e},_createModal:function(){var t=this,n=t._parentPage?t._parentPage.parent():t.element.parent();t._modal=e("
").on("mousedown",function(){t.close()}).appendTo(n)},_getPage:function(){var t=this._openedPage||this._parentPage||e("."+e.mobile.activePageClass);return t},_getWrapper:function(){var e=this._page().find("."+this.options.classes.pageWrapper);e.length===0&&(e=this._page().children(".ui-header:not(.ui-header-fixed), .ui-content:not(.ui-popup), .ui-footer:not(.ui-footer-fixed)").wrapAll("
").parent()),this._wrapper=e},_getFixedToolbars:function(){var t=e("body").children(".ui-header-fixed, .ui-footer-fixed"),n=this._page().find(".ui-header-fixed, .ui-footer-fixed"),r=t.add(n).addClass(this.options.classes.pageFixedToolbar);return r},_getPosDisplayClasses:function(e){return e+"-position-"+this.options.position+" "+e+"-display-"+this.options.display},_getPanelClasses:function(){var e=this.options.classes.panel+" "+this._getPosDisplayClasses(this.options.classes.panel)+" "+this.options.classes.panelClosed+" "+"ui-body-"+(this.options.theme?this.options.theme:"inherit");return!this.options.positionFixed||(e+=" "+this.options.classes.panelFixed),e},_addPanelClasses:function(){this.element.addClass(this._getPanelClasses())},_handleCloseClick:function(e){e.isDefaultPrevented()||this.close()},_bindCloseEvents:function(){this._on(this._closeLink,{click:"_handleCloseClick"}),this._on({"click a:jqmData(ajax='false')":"_handleCloseClick"})},_positionPanel:function(t){var n=this,r=n._panelInner.outerHeight(),i=r>e.mobile.getScreenHeight();i||!n.options.positionFixed?(i&&(n._unfixPanel(),e.mobile.resetActivePageHeight(r)),t&&this.window[0].scrollTo(0,e.mobile.defaultHomeScroll)):n._fixPanel()},_bindFixListener:function(){this._on(e(t),{throttledresize:"_positionPanel"})},_unbindFixListener:function(){this._off(e(t),"throttledresize")},_unfixPanel:function(){!!this.options.positionFixed&&e.support.fixedPosition&&this.element.removeClass(this.options.classes.panelFixed)},_fixPanel:function(){!!this.options.positionFixed&&e.support.fixedPosition&&this.element.addClass(this.options.classes.panelFixed)},_bindUpdateLayout:function(){var e=this;e.element.on("updatelayout",function(){e._open&&e._positionPanel()})},_bindLinkListeners:function(){this._on("body",{"click a":"_handleClick"})},_handleClick:function(t){var r,i=this.element.attr("id");t.currentTarget.href.split("#")[1]===i&&i!==n&&(t.preventDefault(),r=e(t.target),r.hasClass("ui-btn")&&(r.addClass(e.mobile.activeBtnClass),this.element.one("panelopen panelclose",function(){r.removeClass(e.mobile.activeBtnClass)})),this.toggle())},_bindSwipeEvents:function(){var e=this,t=e._modal?e.element.add(e._modal):e.element;!e.options.swipeClose||(e.options.position==="left"?t.on("swipeleft.panel",function(){e.close()}):t.on("swiperight.panel",function(){e.close()}))},_bindPageEvents:function(){var e=this;this.document.on("panelbeforeopen",function(t){e._open&&t.target!==e.element[0]&&e.close()}).on("keyup.panel",function(t){t.keyCode===27&&e._open&&e.close()}),!this._parentPage&&this.options.display!=="overlay"&&this._on(this.document,{pageshow:function(){this._openedPage=null,this._getWrapper()}}),e._parentPage?this.document.on("pagehide",":jqmData(role='page')",function(){e._open&&e.close(!0)}):this.document.on("pagebeforehide",function(){e._open&&e.close(!0)})},_open:!1,_pageContentOpenClasses:null,_modalOpenClasses:null,open:function(t){if(!this._open){var n=this,r=n.options,i=function(){n._off(n.document,"panelclose"),n._page().jqmData("panel","open"),e.support.cssTransform3d&&!!r.animate&&r.display!=="overlay"&&(n._wrapper.addClass(r.classes.animate),n._fixedToolbars().addClass(r.classes.animate)),!t&&e.support.cssTransform3d&&!!r.animate?(n._wrapper||n.element).animationComplete(s,"transition"):setTimeout(s,0),r.theme&&r.display!=="overlay"&&n._page().parent().addClass(r.classes.pageContainer+"-themed "+r.classes.pageContainer+"-"+r.theme),n.element.removeClass(r.classes.panelClosed).addClass(r.classes.panelOpen),n._positionPanel(!0),n._pageContentOpenClasses=n._getPosDisplayClasses(r.classes.pageContentPrefix),r.display!=="overlay"&&(n._page().parent().addClass(r.classes.pageContainer),n._wrapper.addClass(n._pageContentOpenClasses),n._fixedToolbars().addClass(n._pageContentOpenClasses)),n._modalOpenClasses=n._getPosDisplayClasses(r.classes.modal)+" "+r.classes.modalOpen,n._modal&&n._modal.addClass(n._modalOpenClasses).height(Math.max(n._modal.height(),n.document.height()))},s=function(){if(!n._open)return;r.display!=="overlay"&&(n._wrapper.addClass(r.classes.pageContentPrefix+"-open"),n._fixedToolbars().addClass(r.classes.pageContentPrefix+"-open")),n._bindFixListener(),n._trigger("open"),n._openedPage=n._page()};n._trigger("beforeopen"),n._page().jqmData("panel")==="open"?n._on(n.document,{panelclose:i}):i(),n._open=!0}},close:function(t){if(this._open){var n=this,r=this.options,i=function(){n.element.removeClass(r.classes.panelOpen),r.display!=="overlay"&&(n._wrapper.removeClass(n._pageContentOpenClasses),n._fixedToolbars().removeClass(n._pageContentOpenClasses)),!t&&e.support.cssTransform3d&&!!r.animate?(n._wrapper||n.element).animationComplete(s,"transition"):setTimeout(s,0),n._modal&&n._modal.removeClass(n._modalOpenClasses).height("")},s=function(){r.theme&&r.display!=="overlay"&&n._page().parent().removeClass(r.classes.pageContainer+"-themed "+r.classes.pageContainer+"-"+r.theme),n.element.addClass(r.classes.panelClosed),r.display!=="overlay"&&(n._page().parent().removeClass(r.classes.pageContainer),n._wrapper.removeClass(r.classes.pageContentPrefix+"-open"),n._fixedToolbars().removeClass(r.classes.pageContentPrefix+"-open")),e.support.cssTransform3d&&!!r.animate&&r.display!=="overlay"&&(n._wrapper.removeClass(r.classes.animate),n._fixedToolbars().removeClass(r.classes.animate)),n._fixPanel(),n._unbindFixListener(),e.mobile.resetActivePageHeight(),n._page().jqmRemoveData("panel"),n._trigger("close"),n._openedPage=null};n._trigger("beforeclose"),i(),n._open=!1}},toggle:function(){this[this._open?"close":"open"]()},_destroy:function(){var t,n=this.options,r=e("body > :mobile-panel").length+e.mobile.activePage.find(":mobile-panel").length>1;n.display!=="overlay"&&(t=e("body > :mobile-panel").add(e.mobile.activePage.find(":mobile-panel")),t.not(".ui-panel-display-overlay").not(this.element).length===0&&this._wrapper.children().unwrap(),this._open&&(this._fixedToolbars().removeClass(n.classes.pageContentPrefix+"-open"),e.support.cssTransform3d&&!!n.animate&&this._fixedToolbars().removeClass(n.classes.animate),this._page().parent().removeClass(n.classes.pageContainer),n.theme&&this._page().parent().removeClass(n.classes.pageContainer+"-themed "+n.classes.pageContainer+"-"+n.theme))),r||this.document.off("panelopen panelclose"),this._open&&this._page().jqmRemoveData("panel"),this._panelInner.children().unwrap(),this.element.removeClass([this._getPanelClasses(),n.classes.panelOpen,n.classes.animate].join(" ")).off("swipeleft.panel swiperight.panel").off("panelbeforeopen").off("panelhide").off("keyup.panel").off("updatelayout"),this._modal&&this._modal.remove()}})}(e),function(e,n){function r(e,t,n,r){var i=r;return e "),placeholder:e("
"),container:e("")},o=this.document[0].createDocumentFragment();return o.appendChild(s.screen[0]),o.appendChild(s.container[0]),n&&(s.screen.attr("id",n+"-screen"),s.container.attr("id",n+"-popup"),s.placeholder.attr("id",n+"-placeholder").html("")),this._page[0].appendChild(o),s.placeholder.insertAfter(t),t.detach().addClass("ui-popup "+this._themeClassFromOption("ui-body-",r.theme)+" "+(r.shadow?"ui-overlay-shadow ":"")+(r.corners?"ui-corner-all ":"")).appendTo(s.container),s},_eatEventAndClose:function(e){return e.preventDefault(),e.stopImmediatePropagation(),this.options.dismissible&&this.close(),!1},_resizeScreen:function(){var e=this._ui.screen,t=this._ui.container.outerHeight(!0),n=e.removeAttr("style").height(),r=this.document.height()-1;nn&&e.height(t)},_handleWindowKeyUp:function(t){if(this._isOpen&&t.keyCode===e.mobile.keyCode.ESCAPE)return this._eatEventAndClose(t)},_expectResizeEvent:function(){var e=i(this.window);if(this._resizeData){if(e.x===this._resizeData.windowCoordinates.x&&e.y===this._resizeData.windowCoordinates.y&&e.cx===this._resizeData.windowCoordinates.cx&&e.cy===this._resizeData.windowCoordinates.cy)return!1;clearTimeout(this._resizeData.timeoutId)}return this._resizeData={timeoutId:this._delay("_resizeTimeout",200),windowCoordinates:e},!0},_resizeTimeout:function(){this._isOpen?this._expectResizeEvent()||(this._ui.container.hasClass("ui-popup-hidden")&&(this._ui.container.removeClass("ui-popup-hidden ui-popup-truncate"),this.reposition({positionTo:"window"}),this._ignoreResizeEvents()),this._resizeScreen(),this._resizeData=null,this._orientationchangeInProgress=!1):(this._resizeData=null,this._orientationchangeInProgress=!1)},_stopIgnoringResizeEvents:function(){this._ignoreResizeTo=0},_ignoreResizeEvents:function(){this._ignoreResizeTo&&clearTimeout(this._ignoreResizeTo),this._ignoreResizeTo=this._delay("_stopIgnoringResizeEvents",1e3)},_handleWindowResize:function(){this._isOpen&&this._ignoreResizeTo===0&&(this._expectResizeEvent()||this._orientationchangeInProgress)&&!this._ui.container.hasClass("ui-popup-hidden")&&this._ui.container.addClass("ui-popup-hidden ui-popup-truncate").removeAttr("style")},_handleWindowOrientationchange:function(){!this._orientationchangeInProgress&&this._isOpen&&this._ignoreResizeTo===0&&(this._expectResizeEvent(),this._orientationchangeInProgress=!0)},_handleDocumentFocusIn:function(t){var n,r=t.target,i=this._ui;if(!this._isOpen)return;if(r!==i.container[0]){n=e(r);if(!e.contains(i.container[0],r))return e(this.document[0].activeElement).one("focus",e.proxy(function(){this._safelyBlur(r)},this)),i.focusElement.focus(),t.preventDefault(),t.stopImmediatePropagation(),!1;i.focusElement[0]===i.container[0]&&(i.focusElement=n)}this._ignoreResizeEvents()},_themeClassFromOption:function(e,t){return t?t==="none"?"":e+t:e+"inherit"},_applyTransition:function(t){return t&&(this._ui.container.removeClass(this._fallbackTransition),t!=="none"&&(this._fallbackTransition=e.mobile._maybeDegradeTransition(t),this._fallbackTransition==="none"&&(this._fallbackTransition=""),this._ui.container.addClass(this._fallbackTransition))),this},_setOptions:function(e){var t=this.options,r=this.element,i=this._ui.screen;return e.wrapperClass!==n&&this._ui.container.removeClass(t.wrapperClass).addClass(e.wrapperClass),e.theme!==n&&r.removeClass(this._themeClassFromOption("ui-body-",t.theme)).addClass(this._themeClassFromOption("ui-body-",e.theme)),e.overlayTheme!==n&&(i.removeClass(this._themeClassFromOption("ui-overlay-",t.overlayTheme)).addClass(this._themeClassFromOption("ui-overlay-",e.overlayTheme)),this._isOpen&&i.addClass("in")),e.shadow!==n&&r.toggleClass("ui-overlay-shadow",e.shadow),e.corners!==n&&r.toggleClass("ui-corner-all",e.corners),e.transition!==n&&(this._currentTransition||this._applyTransition(e.transition)),e.tolerance!==n&&this._setTolerance(e.tolerance),e.disabled!==n&&e.disabled&&this.close(),this._super(e)},_setTolerance:function(t){var r={t:30,r:15,b:30,l:15},i;if(t!==n){i=String(t).split(","),e.each(i,function(e,t){i[e]=parseInt(t,10)});switch(i.length){case 1:isNaN(i[0])||(r.t=r.r=r.b=r.l=i[0]);break;case 2:isNaN(i[0])||(r.t=r.b=i[0]),isNaN(i[1])||(r.l=r.r=i[1]);break;case 4:isNaN(i[0])||(r.t=i[0]),isNaN(i[1])||(r.r=i[1]),isNaN(i[2])||(r.b=i[2]),isNaN(i[3])||(r.l=i[3]);break;default:}}return this._tolerance=r,this},_clampPopupWidth:function(e){var t,n=i(this.window),r={x:this._tolerance.l,y:n.y+this._tolerance.t,cx:n.cx-this._tolerance.l-this._tolerance.r,cy:n.cy-this._tolerance.t-this._tolerance.b};return e||this._ui.container.css("max-width",r.cx),t={cx:this._ui.container.outerWidth(!0),cy:this._ui.container.outerHeight(!0)},{rc:r,menuSize:t}},_calculateFinalLocation:function(e,t){var n,i=t.rc,s=t.menuSize;return n={left:r(i.cx,s.cx,i.x,e.x),top:r(i.cy,s.cy,i.y,e.y)},n.top=Math.max(0,n.top),n.top-=Math.min(n.top,Math.max(0,n.top+s.cy-this.document.height())),n},_placementCoords:function(e){return this._calculateFinalLocation(e,this._clampPopupWidth())},_createPrerequisites:function(t,n,r){var i,s=this;i={screen:e.Deferred(),container:e.Deferred()},i.screen.then(function(){i===s._prerequisites&&t()}),i.container.then(function(){i===s._prerequisites&&n()}),e.when(i.screen,i.container).done(function(){i===s._prerequisites&&(s._prerequisites=null,r())}),s._prerequisites=i},_animate:function(t){this._ui.screen.removeClass(t.classToRemove).addClass(t.screenClassToAdd),t.prerequisites.screen.resolve();if(t.transition&&t.transition!=="none"){t.applyTransition&&this._applyTransition(t.transition);if(this._fallbackTransition){this._ui.container.addClass(t.containerClassToAdd).removeClass(t.classToRemove).animationComplete(e.proxy(t.prerequisites.container,"resolve"));return}}this._ui.container.removeClass(t.classToRemove),t.prerequisites.container.resolve()},_desiredCoords:function(t){var n,r=null,s=i(this.window),o=t.x,u=t.y,a=t.positionTo;if(a&&a!=="origin")if(a==="window")o=s.cx/2+s.x,u=s.cy/2+s.y;else{try{r=e(a)}catch(f){r=null}r&&(r.filter(":visible"),r.length===0&&(r=null))}r&&(n=r.offset(),o=n.left+r.outerWidth()/2,u=n.top+r.outerHeight()/2);if(e.type(o)!=="number"||isNaN(o))o=s.cx/2+s.x;if(e.type(u)!=="number"||isNaN(u))u=s.cy/2+s.y;return{x:o,y:u}},_reposition:function(e){e={x:e.x,y:e.y,positionTo:e.positionTo},this._trigger("beforeposition",n,e),this._ui.container.offset(this._placementCoords(this._desiredCoords(e)))},reposition:function(e){this._isOpen&&this._reposition(e)},_safelyBlur:function(t){t!==this.window[0]&&t.nodeName.toLowerCase()!=="body"&&e(t).blur()},_openPrerequisitesComplete:function(){var t=this.element.attr("id"),n=this._ui.container.find(":focusable").first();this._ui.container.addClass("ui-popup-active"),this._isOpen=!0,this._resizeScreen(),e.contains(this._ui.container[0],this.document[0].activeElement)||this._safelyBlur(this.document[0].activeElement),n.length>0&&(this._ui.focusElement=n),this._ignoreResizeEvents(),t&&this.document.find("[aria-haspopup='true'][aria-owns='"+t+"']").attr("aria-expanded",!0),this._trigger("afteropen")},_open:function(t){var n=e.extend({},this.options,t),r=function(){var e=navigator.userAgent,t=e.match(/AppleWebKit\/([0-9\.]+)/),n=!!t&&t[1],r=e.match(/Android (\d+(?:\.\d+))/),i=!!r&&r[1],s=e.indexOf("Chrome")>-1;return r!==null&&i==="4.0"&&n&&n>534.13&&!s?!0:!1}();this._createPrerequisites(e.noop,e.noop,e.proxy(this,"_openPrerequisitesComplete")),this._currentTransition=n.transition,this._applyTransition(n.transition),this._ui.screen.removeClass("ui-screen-hidden"),this._ui.container.removeClass("ui-popup-truncate"),this._reposition(n),this._ui.container.removeClass("ui-popup-hidden"),this.options.overlayTheme&&r&&this.element.closest(".ui-page").addClass("ui-popup-open"),this._animate({additionalCondition:!0,transition:n.transition,classToRemove:"",screenClassToAdd:"in",containerClassToAdd:"in",applyTransition:!1,prerequisites:this._prerequisites})},_closePrerequisiteScreen:function(){this._ui.screen.removeClass("out").addClass("ui-screen-hidden")},_closePrerequisiteContainer:function(){this._ui.container.removeClass("reverse out").addClass("ui-popup-hidden ui-popup-truncate").removeAttr("style")},_closePrerequisitesDone:function(){var t=this._ui.container,r=this.element.attr("id");e.mobile.popup.active=n,e(":focus",t[0]).add(t[0]).blur(),r&&this.document.find("[aria-haspopup='true'][aria-owns='"+r+"']").attr("aria-expanded",!1),this._trigger("afterclose")},_close:function(t){this._ui.container.removeClass("ui-popup-active"),this._page.removeClass("ui-popup-open"),this._isOpen=!1,this._createPrerequisites(e.proxy(this,"_closePrerequisiteScreen"),e.proxy(this,"_closePrerequisiteContainer"),e.proxy(this,"_closePrerequisitesDone")),this._animate({additionalCondition:this._ui.screen.hasClass("in"),transition:t?"none":this._currentTransition,classToRemove:"in",screenClassToAdd:"out",containerClassToAdd:"reverse out",applyTransition:!0,prerequisites:this._prerequisites})},_unenhance:function(){if(this.options.enhanced)return;this._setOptions({theme:e.mobile.popup.prototype.options.theme}),this.element.detach().insertAfter(this._ui.placeholder).removeClass("ui-popup ui-overlay-shadow ui-corner-all ui-body-inherit"),this._ui.screen.remove(),this._ui.container.remove(),this._ui.placeholder.remove()},_destroy:function(){return e.mobile.popup.active===this?(this.element.one("popupafterclose",e.proxy(this,"_unenhance")),this.close()):this._unenhance(),this},_closePopup:function(n,r){var i,s,o=this.options,u=!1;if(n&&n.isDefaultPrevented()||e.mobile.popup.active!==this)return;t.scrollTo(0,this._scrollTop),n&&n.type==="pagebeforechange"&&r&&(typeof r.toPage=="string"?i=r.toPage:i=r.toPage.jqmData("url"),i=e.mobile.path.parseUrl(i),s=i.pathname+i.search+i.hash,this._myUrl!==e.mobile.path.makeUrlAbsolute(s)?u=!0:n.preventDefault()),this.window.off(o.closeEvents),this.element.undelegate(o.closeLinkSelector,o.closeLinkEvents),this._close(u)},_bindContainerClose:function(){this.window.on(this.options.closeEvents,e.proxy(this,"_closePopup"))},widget:function(){return this._ui.container},open:function(t){var n,r,i,s,o,u,a=this,f=this.options;return e.mobile.popup.active||f.disabled?this:(e.mobile.popup.active=this,this._scrollTop=this.window.scrollTop(),f.history?(u=e.mobile.navigate.history,r=e.mobile.dialogHashKey,i=e.mobile.activePage,s=i?i.hasClass("ui-dialog"):!1,this._myUrl=n=u.getActive().url,o=n.indexOf(r)>-1&&!s&&u.activeIndex>0,o?(a._open(t),a._bindContainerClose(),this):(n.indexOf(r)===-1&&!s?n+=n.indexOf("#")>-1?r:"#"+r:n=e.mobile.path.parseLocation().hash+r,this.window.one("beforenavigate",function(e){e.preventDefault(),a._open(t),a._bindContainerClose()}),this.urlAltered=!0,e.mobile.navigate(n,{role:"dialog"}),this)):(a._open(t),a._bindContainerClose(),a.element.delegate(f.closeLinkSelector,f.closeLinkEvents,function(e){a.close(),e.preventDefault()}),this))},close:function(){return e.mobile.popup.active!==this?this:(this._scrollTop=this.window.scrollTop(),this.options.history&&this.urlAltered?(e.mobile.back(),this.urlAltered=!1):this._closePopup(),this)}}),e.mobile.popup.handleLink=function(t){var n,r=e.mobile.path,i=e(r.hashToSelector(r.parseUrl(t.attr("href")).hash)).first();i.length>0&&i.data("mobile-popup")&&(n=t.offset(),i.popup("open",{x:n.left+t.outerWidth()/2,y:n.top+t.outerHeight()/2,transition:t.jqmData("transition"),positionTo:t.jqmData("position-to")})),setTimeout(function(){t.removeClass(e.mobile.activeBtnClass)},300)},e.mobile.document.on("pagebeforechange",function(t,n){n.options.role==="popup"&&(e.mobile.popup.handleLink(n.options.link),t.preventDefault())})}(e),function(e,t){function i(){var e=r.clone(),t=e.eq(0),n=e.eq(1),i=n.children();return{arEls:n.add(t),gd:t,ct:n,ar:i}}var n=e.mobile.browser.oldIE&&e.mobile.browser.oldIE<=8,r=e("");e.widget("mobile.popup",e.mobile.popup,{options:{arrow:""},_create:function(){var e,t=this._super();return this.options.arrow&&(this._ui.arrow=e=this._addArrow()),t},_addArrow:function(){var e,t=this.options,n=i();return e=this._themeClassFromOption("ui-body-",t.theme),n.ar.addClass(e+(t.shadow?" ui-overlay-shadow":"")),n.arEls.hide().appendTo(this.element),n},_unenhance:function(){var e=this._ui.arrow;return e&&e.arEls.remove(),this._super()},_tryAnArrow:function(e,t,n,r,i){var s,o,u,a={},f={};if(r.arFull[e.dimKey]>r.guideDims[e.dimKey])return i;a[e.fst]=n[e.fst]+(r.arHalf[e.oDimKey]+r.menuHalf[e.oDimKey])*e.offsetFactor-r.contentBox[e.fst]+(r.clampInfo.menuSize[e.oDimKey]-r.contentBox[e.oDimKey])*e.arrowOffsetFactor,a[e.snd]=n[e.snd],s=r.result||this._calculateFinalLocation(a,r.clampInfo),o={x:s.left,y:s.top},f[e.fst]=o[e.fst]+r.contentBox[e.fst]+e.tipOffset,f[e.snd]=Math.max(s[e.prop]+r.guideOffset[e.prop]+r.arHalf[e.dimKey],Math.min(s[e.prop]+r.guideOffset[e.prop]+r.guideDims[e.dimKey]-r.arHalf[e.dimKey],n[e.snd])),u=Math.abs(n.x-f.x)+Math.abs(n.y-f.y);if(!i||u "+(a.children("abbr").first().attr("title")||a.text())+"").appendTo(o).children(0).checkboxradio({theme:s.columnPopupTheme})).jqmData("header",a).jqmData("cells",u),a.jqmData("input",t))}),n||t.controlgroup("refresh")},_menuInputChange:function(t){var n=e(t.target),r=n[0].checked;n.jqmData("cells").toggleClass("ui-table-cell-hidden",!r).toggleClass("ui-table-cell-visible",r)},_unlockCells:function(e){e.removeClass("ui-table-cell-hidden ui-table-cell-visible")},_enhanceColToggle:function(){var t,n,r,i,s=this.element,o=this.options,u=e.mobile.ns,a=this.document[0].createDocumentFragment();return t=this._id()+"-popup",n=e(""+o.columnBtnText+" "),r=e(""),i=e(" ").controlgroup(),this._addToggles(i,!1),i.appendTo(r),a.appendChild(r[0]),a.appendChild(n[0]),s.before(a),r.popup(),i},rebuild:function(){this._super(),this.options.mode==="columntoggle"&&this._refresh(!1)},_refresh:function(t){var n,r,i;this._super(t);if(!t&&this.options.mode==="columntoggle"){n=this.headers,r=[],this._menu.find("input").each(function(){var t=e(this),i=t.jqmData("header"),s=n.index(i[0]);s>-1&&!t.prop("checked")&&r.push(s)}),this._unlockCells(this.element.find(".ui-table-cell-hidden, .ui-table-cell-visible")),this._addToggles(this._menu,t);for(i=r.length-1;i>-1;i--)n.eq(r[i]).jqmData("input").prop("checked",!1).checkboxradio("refresh").trigger("change")}},_setToggleState:function(){this._menu.find("input").each(function(){var t=e(this);this.checked=t.jqmData("cells").eq(0).css("display")==="table-cell",t.checkboxradio("refresh")})},_destroy:function(){this._super()}})}(e),function(e,t){e.widget("mobile.table",e.mobile.table,{options:{mode:"reflow",classes:e.extend(e.mobile.table.prototype.options.classes,{reflowTable:"ui-table-reflow",cellLabels:"ui-table-cell-label"})},_create:function(){this._super();if(this.options.mode!=="reflow")return;this.options.enhanced||(this.element.addClass(this.options.classes.reflowTable),this._updateReflow())},rebuild:function(){this._super(),this.options.mode==="reflow"&&this._refresh(!1)},_refresh:function(e){this._super(e),!e&&this.options.mode==="reflow"&&this._updateReflow()},_updateReflow:function(){var t=this,n=this.options;e(t.allHeaders.get().reverse()).each(function(){var r=e(this).jqmData("cells"),i=e.mobile.getAttribute(this,"colstart"),s=r.not(this).filter("thead th").length&&" ui-table-cell-label-top",o=e(this).clone().contents(),u,a;o.length>0&&(s?(u=parseInt(this.getAttribute("colspan"),10),a="",u&&(a="td:nth-child("+u+"n + "+i+")"),t._addLabels(r.filter(a),n.classes.cellLabels+s,o)):t._addLabels(r,n.classes.cellLabels,o))})},_addLabels:function(t,n,r){r.length===1&&r[0].nodeName.toLowerCase()==="abbr"&&(r=r.eq(0).attr("title")),t.not(":has(b."+n+")").prepend(e(" ").append(r))}})}(e)});
\ No newline at end of file
+!function(e,t,i){"function"==typeof define&&define.amd?define(["jquery"],function(n){return i(n,e,t),n.mobile}):i(e.jQuery,e,t)}(this,document,function(e,t,i){!function(e,t,n){"$:nomunge";function s(e){return e=e||location.href,"#"+e.replace(/^[^#]*#?(.*)$/,"$1")}var o,a="hashchange",r=i,l=e.event.special,h=r.documentMode,c="on"+a in t&&(h===n||h>7);e.fn[a]=function(e){return e?this.bind(a,e):this.trigger(a)},e.fn[a].delay=50,l[a]=e.extend(l[a],{setup:function(){return c?!1:void e(o.start)},teardown:function(){return c?!1:void e(o.stop)}}),o=function(){function i(){var n=s(),r=p(h);n!==h?(d(h=n,r),e(t).trigger(a)):r!==h&&(location.href=location.href.replace(/#.*/,"")+r),o=setTimeout(i,e.fn[a].delay)}var o,l={},h=s(),u=function(e){return e},d=u,p=u;return l.start=function(){o||i()},l.stop=function(){o&&clearTimeout(o),o=n},t.attachEvent&&!t.addEventListener&&!c&&function(){var t,n;l.start=function(){t||(n=e.fn[a].src,n=n&&n+s(),t=e('').hide().one("load",function(){n||d(s()),i()}).attr("src",n||"javascript:0").insertAfter("body")[0].contentWindow,r.onpropertychange=function(){try{"title"===event.propertyName&&(t.document.title=r.title)}catch(e){}})},l.stop=u,p=function(){return s(t.location.href)},d=function(i,n){var s=t.document,o=e.fn[a].domain;i!==n&&(s.title=r.title,s.open(),o&&s.write(''),s.close(),t.location.hash=i)}}(),l}()}(e,this),function(e){e.mobile={}}(e),function(e){e.extend(e.mobile,{version:"1.4.5",subPageUrlKey:"ui-page",hideUrlBar:!0,keepNative:":jqmData(role='none'), :jqmData(role='nojs')",activePageClass:"ui-page-active",activeBtnClass:"ui-btn-active",focusClass:"ui-focus",ajaxEnabled:!0,hashListeningEnabled:!0,linkBindingEnabled:!0,defaultPageTransition:"fade",maxTransitionWidth:!1,minScrollBack:0,defaultDialogTransition:"pop",pageLoadErrorMessage:"Error Loading Page",pageLoadErrorMessageTheme:"a",phonegapNavigationEnabled:!1,autoInitializePage:!0,pushStateEnabled:!0,ignoreContentEnabled:!1,buttonMarkup:{hoverDelay:200},dynamicBaseEnabled:!0,pageContainer:e(),allowCrossDomainPages:!1,dialogHashKey:"&ui-state=dialog"})}(e,this),function(e,t,i){var n={},s=e.find,o=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,a=/:jqmData\(([^)]*)\)/g;e.extend(e.mobile,{ns:"",getAttribute:function(t,i){var n;t=t.jquery?t[0]:t,t&&t.getAttribute&&(n=t.getAttribute("data-"+e.mobile.ns+i));try{n="true"===n?!0:"false"===n?!1:"null"===n?null:+n+""===n?+n:o.test(n)?JSON.parse(n):n}catch(s){}return n},nsNormalizeDict:n,nsNormalize:function(t){return n[t]||(n[t]=e.camelCase(e.mobile.ns+t))},closestPageData:function(e){return e.closest(":jqmData(role='page'), :jqmData(role='dialog')").data("mobile-page")}}),e.fn.jqmData=function(t,n){var s;return"undefined"!=typeof t&&(t&&(t=e.mobile.nsNormalize(t)),s=arguments.length<2||n===i?this.data(t):this.data(t,n)),s},e.jqmData=function(t,i,n){var s;return"undefined"!=typeof i&&(s=e.data(t,i?e.mobile.nsNormalize(i):i,n)),s},e.fn.jqmRemoveData=function(t){return this.removeData(e.mobile.nsNormalize(t))},e.jqmRemoveData=function(t,i){return e.removeData(t,e.mobile.nsNormalize(i))},e.find=function(t,i,n,o){return t.indexOf(":jqmData")>-1&&(t=t.replace(a,"[data-"+(e.mobile.ns||"")+"$1]")),s.call(this,t,i,n,o)},e.extend(e.find,s)}(e,this),function(e,t){function n(t,i){var n,o,a,r=t.nodeName.toLowerCase();return"area"===r?(n=t.parentNode,o=n.name,t.href&&o&&"map"===n.nodeName.toLowerCase()?(a=e("img[usemap=#"+o+"]")[0],!!a&&s(a)):!1):(/input|select|textarea|button|object/.test(r)?!t.disabled:"a"===r?t.href||i:i)&&s(t)}function s(t){return e.expr.filters.visible(t)&&!e(t).parents().addBack().filter(function(){return"hidden"===e.css(this,"visibility")}).length}var o=0,a=/^ui-id-\d+$/;e.ui=e.ui||{},e.extend(e.ui,{version:"c0ab71056b936627e8a7821f03c044aec6280a40",keyCode:{BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38}}),e.fn.extend({focus:function(t){return function(i,n){return"number"==typeof i?this.each(function(){var t=this;setTimeout(function(){e(t).focus(),n&&n.call(t)},i)}):t.apply(this,arguments)}}(e.fn.focus),scrollParent:function(){var t;return t=e.ui.ie&&/(static|relative)/.test(this.css("position"))||/absolute/.test(this.css("position"))?this.parents().filter(function(){return/(relative|absolute|fixed)/.test(e.css(this,"position"))&&/(auto|scroll)/.test(e.css(this,"overflow")+e.css(this,"overflow-y")+e.css(this,"overflow-x"))}).eq(0):this.parents().filter(function(){return/(auto|scroll)/.test(e.css(this,"overflow")+e.css(this,"overflow-y")+e.css(this,"overflow-x"))}).eq(0),/fixed/.test(this.css("position"))||!t.length?e(this[0].ownerDocument||i):t},uniqueId:function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++o)})},removeUniqueId:function(){return this.each(function(){a.test(this.id)&&e(this).removeAttr("id")})}}),e.extend(e.expr[":"],{data:e.expr.createPseudo?e.expr.createPseudo(function(t){return function(i){return!!e.data(i,t)}}):function(t,i,n){return!!e.data(t,n[3])},focusable:function(t){return n(t,!isNaN(e.attr(t,"tabindex")))},tabbable:function(t){var i=e.attr(t,"tabindex"),s=isNaN(i);return(s||i>=0)&&n(t,!s)}}),e("").outerWidth(1).jquery||e.each(["Width","Height"],function(i,n){function s(t,i,n,s){return e.each(o,function(){i-=parseFloat(e.css(t,"padding"+this))||0,n&&(i-=parseFloat(e.css(t,"border"+this+"Width"))||0),s&&(i-=parseFloat(e.css(t,"margin"+this))||0)}),i}var o="Width"===n?["Left","Right"]:["Top","Bottom"],a=n.toLowerCase(),r={innerWidth:e.fn.innerWidth,innerHeight:e.fn.innerHeight,outerWidth:e.fn.outerWidth,outerHeight:e.fn.outerHeight};e.fn["inner"+n]=function(i){return i===t?r["inner"+n].call(this):this.each(function(){e(this).css(a,s(this,i)+"px")})},e.fn["outer"+n]=function(t,i){return"number"!=typeof t?r["outer"+n].call(this,t):this.each(function(){e(this).css(a,s(this,t,!0,i)+"px")})}}),e.fn.addBack||(e.fn.addBack=function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}),e(" ").data("a-b","a").removeData("a-b").data("a-b")&&(e.fn.removeData=function(t){return function(i){return arguments.length?t.call(this,e.camelCase(i)):t.call(this)}}(e.fn.removeData)),e.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase()),e.support.selectstart="onselectstart"in i.createElement("div"),e.fn.extend({disableSelection:function(){return this.bind((e.support.selectstart?"selectstart":"mousedown")+".ui-disableSelection",function(e){e.preventDefault()})},enableSelection:function(){return this.unbind(".ui-disableSelection")},zIndex:function(n){if(n!==t)return this.css("zIndex",n);if(this.length)for(var s,o,a=e(this[0]);a.length&&a[0]!==i;){if(s=a.css("position"),("absolute"===s||"relative"===s||"fixed"===s)&&(o=parseInt(a.css("zIndex"),10),!isNaN(o)&&0!==o))return o;a=a.parent()}return 0}}),e.ui.plugin={add:function(t,i,n){var s,o=e.ui[t].prototype;for(s in n)o.plugins[s]=o.plugins[s]||[],o.plugins[s].push([i,n[s]])},call:function(e,t,i,n){var s,o=e.plugins[t];if(o&&(n||e.element[0].parentNode&&11!==e.element[0].parentNode.nodeType))for(s=0;s0&&(s=s.concat(a.toArray())),0===h.length&&l.length>0&&(s=s.concat(l.toArray())),e.each(s,function(t,n){i-=e(n).outerHeight()}),Math.max(0,i)};e.extend(e.mobile,{window:e(t),document:e(i),keyCode:e.ui.keyCode,behaviors:{},silentScroll:function(i){"number"!==e.type(i)&&(i=e.mobile.defaultHomeScroll),e.event.special.scrollstart.enabled=!1,setTimeout(function(){t.scrollTo(0,i),e.mobile.document.trigger("silentscroll",{x:0,y:i})},20),setTimeout(function(){e.event.special.scrollstart.enabled=!0},150)},getClosestBaseUrl:function(t){var i=e(t).closest(".ui-page").jqmData("url"),n=e.mobile.path.documentBase.hrefNoHash;return e.mobile.dynamicBaseEnabled&&i&&e.mobile.path.isPath(i)||(i=n),e.mobile.path.makeUrlAbsolute(i,n)},removeActiveLinkClass:function(t){!e.mobile.activeClickedLink||e.mobile.activeClickedLink.closest("."+e.mobile.activePageClass).length&&!t||e.mobile.activeClickedLink.removeClass(e.mobile.activeBtnClass),e.mobile.activeClickedLink=null},getInheritedTheme:function(e,t){for(var i,n,s=e[0],o="",a=/ui-(bar|body|overlay)-([a-z])\b/;s&&(i=s.className||"",!(i&&(n=a.exec(i))&&(o=n[2])));)s=s.parentNode;return o||t||"a"},enhanceable:function(e){return this.haveParents(e,"enhance")},hijackable:function(e){return this.haveParents(e,"ajax")},haveParents:function(t,i){if(!e.mobile.ignoreContentEnabled)return t;var n,s,o,a,r,l=t.length,h=e();for(a=0;l>a;a++){for(s=t.eq(a),o=!1,n=t[a];n;){if(r=n.getAttribute?n.getAttribute("data-"+e.mobile.ns+i):"","false"===r){o=!0;break}n=n.parentNode}o||(h=h.add(s))}return h},getScreenHeight:function(){return t.innerHeight||e.mobile.window.height()},resetActivePageHeight:function(t){var i=e("."+e.mobile.activePageClass),s=i.height(),o=i.outerHeight(!0);t=n(i,"number"==typeof t?t:e.mobile.getScreenHeight()),i.css("min-height",""),i.height()0&&(a=a.not(n)),a.length>0&&(i[o.prototype.widgetName]=a)}});for(t in i)i[t][t]();return this},addDependents:function(t){e.addDependents(this,t)},getEncodedText:function(){return e("").text(this.text()).html()},jqmEnhanceable:function(){return e.mobile.enhanceable(this)},jqmHijackable:function(){return e.mobile.hijackable(this)}}),e.removeWithDependents=function(t){var i=e(t);(i.jqmData("dependents")||e()).remove(),i.remove()},e.addDependents=function(t,i){var n=e(t),s=n.jqmData("dependents")||e();n.jqmData("dependents",e(s).add(i))},e.find.matches=function(t,i){return e.find(t,null,null,i)},e.find.matchesSelector=function(t,i){return e.find(i,null,null,[t]).length>0}}(e,this),function(e){t.matchMedia=t.matchMedia||function(e){var t,i=e.documentElement,n=i.firstElementChild||i.firstChild,s=e.createElement("body"),o=e.createElement("div");return o.id="mq-test-1",o.style.cssText="position:absolute;top:-100em",s.style.background="none",s.appendChild(o),function(e){return o.innerHTML='',i.insertBefore(s,n),t=42===o.offsetWidth,i.removeChild(s),{matches:t,media:e}}}(i),e.mobile.media=function(e){return t.matchMedia(e).matches}}(e),function(e){var t={touch:"ontouchend"in i};e.mobile.support=e.mobile.support||{},e.extend(e.support,t),e.extend(e.mobile.support,t)}(e),function(e){e.extend(e.support,{orientation:"orientation"in t&&"onorientationchange"in t})}(e),function(e,n){function s(e){var t,i=e.charAt(0).toUpperCase()+e.substr(1),s=(e+" "+m.join(i+" ")+i).split(" ");for(t in s)if(p[s[t]]!==n)return!0}function o(){var i=t,n=!(!i.document.createElementNS||!i.document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect||i.opera&&-1===navigator.userAgent.indexOf("Chrome")),s=function(t){t&&n||e("html").addClass("ui-nosvg")},o=new i.Image;o.onerror=function(){s(!1)},o.onload=function(){s(1===o.width&&1===o.height)},o.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw=="}function a(){var s,o,a,r="transform-3d",l=e.mobile.media("(-"+m.join("-"+r+"),(-")+"-"+r+"),("+r+")");if(l)return!!l;s=i.createElement("div"),o={MozTransform:"-moz-transform",transform:"transform"},d.append(s);for(a in o)s.style[a]!==n&&(s.style[a]="translate3d( 100px, 1px, 1px )",l=t.getComputedStyle(s).getPropertyValue(o[a]));return!!l&&"none"!==l}function r(){var t,i,n=location.protocol+"//"+location.host+location.pathname+"ui-dir/",s=e("head base"),o=null,a="";return s.length?a=s.attr("href"):s=o=e(" ",{href:n}).appendTo("head"),t=e(" ").prependTo(d),i=t[0].href,s[0].href=a||location.pathname,o&&o.remove(),0===i.indexOf(n)}function l(){var e,n=i.createElement("x"),s=i.documentElement,o=t.getComputedStyle;return"pointerEvents"in n.style?(n.style.pointerEvents="auto",n.style.pointerEvents="x",s.appendChild(n),e=o&&"auto"===o(n,"").pointerEvents,s.removeChild(n),!!e):!1}function h(){var e=i.createElement("div");return"undefined"!=typeof e.getBoundingClientRect}function c(){var e=t,i=navigator.userAgent,n=navigator.platform,s=i.match(/AppleWebKit\/([0-9]+)/),o=!!s&&s[1],a=i.match(/Fennec\/([0-9]+)/),r=!!a&&a[1],l=i.match(/Opera Mobi\/([0-9]+)/),h=!!l&&l[1];return(n.indexOf("iPhone")>-1||n.indexOf("iPad")>-1||n.indexOf("iPod")>-1)&&o&&534>o||e.operamini&&"[object OperaMini]"==={}.toString.call(e.operamini)||l&&7458>h||i.indexOf("Android")>-1&&o&&533>o||r&&6>r||"palmGetResource"in t&&o&&534>o||i.indexOf("MeeGo")>-1&&i.indexOf("NokiaBrowser/8.5.0")>-1?!1:!0}var u,d=e("").prependTo("html"),p=d[0].style,m=["Webkit","Moz","O"],f="palmGetResource"in t,g=t.operamini&&"[object OperaMini]"==={}.toString.call(t.operamini),b=t.blackberry&&!s("-webkit-transform");e.extend(e.mobile,{browser:{}}),e.mobile.browser.oldIE=function(){var e=3,t=i.createElement("div"),n=t.all||[];do t.innerHTML="";while(n[0]);return e>4?e:!e}(),e.extend(e.support,{pushState:"pushState"in history&&"replaceState"in history&&!(t.navigator.userAgent.indexOf("Firefox")>=0&&t.top!==t)&&-1===t.navigator.userAgent.search(/CriOS/),mediaquery:e.mobile.media("only all"),cssPseudoElement:!!s("content"),touchOverflow:!!s("overflowScrolling"),cssTransform3d:a(),boxShadow:!!s("boxShadow")&&!b,fixedPosition:c(),scrollTop:("pageXOffset"in t||"scrollTop"in i.documentElement||"scrollTop"in d[0])&&!f&&!g,dynamicBaseTag:r(),cssPointerEvents:l(),boundingRect:h(),inlineSVG:o}),d.remove(),u=function(){var e=t.navigator.userAgent;return e.indexOf("Nokia")>-1&&(e.indexOf("Symbian/3")>-1||e.indexOf("Series60/5")>-1)&&e.indexOf("AppleWebKit")>-1&&e.match(/(BrowserNG|NokiaBrowser)\/7\.[0-3]/)}(),e.mobile.gradeA=function(){return(e.support.mediaquery&&e.support.cssPseudoElement||e.mobile.browser.oldIE&&e.mobile.browser.oldIE>=8)&&(e.support.boundingRect||null!==e.fn.jquery.match(/1\.[0-7+]\.[0-9+]?/))},e.mobile.ajaxBlacklist=t.blackberry&&!t.WebKitPoint||g||u,u&&e(function(){e("head link[rel='stylesheet']").attr("rel","alternate stylesheet").attr("rel","stylesheet")}),e.support.boxShadow||e("html").addClass("ui-noboxshadow")}(e),function(e,t){var i,n=e.mobile.window,s=function(){};e.event.special.beforenavigate={setup:function(){n.on("navigate",s)},teardown:function(){n.off("navigate",s)}},e.event.special.navigate=i={bound:!1,pushStateEnabled:!0,originalEventName:t,isPushStateEnabled:function(){return e.support.pushState&&e.mobile.pushStateEnabled===!0&&this.isHashChangeEnabled()},isHashChangeEnabled:function(){return e.mobile.hashListeningEnabled===!0},popstate:function(t){var i=new e.Event("navigate"),s=new e.Event("beforenavigate"),o=t.originalEvent.state||{};s.originalEvent=t,n.trigger(s),s.isDefaultPrevented()||(t.historyState&&e.extend(o,t.historyState),i.originalEvent=t,setTimeout(function(){n.trigger(i,{state:o})},0))},hashchange:function(t){var i=new e.Event("navigate"),s=new e.Event("beforenavigate");s.originalEvent=t,n.trigger(s),s.isDefaultPrevented()||(i.originalEvent=t,n.trigger(i,{state:t.hashchangeState||{}}))},setup:function(){i.bound||(i.bound=!0,i.isPushStateEnabled()?(i.originalEventName="popstate",n.bind("popstate.navigate",i.popstate)):i.isHashChangeEnabled()&&(i.originalEventName="hashchange",n.bind("hashchange.navigate",i.hashchange)))}}}(e),function(e){e.event.special.throttledresize={setup:function(){e(this).bind("resize",o)},teardown:function(){e(this).unbind("resize",o)}};var t,i,n,s=250,o=function(){i=(new Date).getTime(),n=i-a,n>=s?(a=i,e(this).trigger("throttledresize")):(t&&clearTimeout(t),t=setTimeout(o,s-n))},a=0}(e),function(e,t){function n(){var e=s();e!==o&&(o=e,u.trigger(d))}var s,o,a,r,l,h,c,u=e(t),d="orientationchange",p={0:!0,180:!0};e.support.orientation&&(l=t.innerWidth||u.width(),h=t.innerHeight||u.height(),c=50,a=l>h&&l-h>c,r=p[t.orientation],(a&&r||!a&&!r)&&(p={"-90":!0,90:!0})),e.event.special.orientationchange=e.extend({},e.event.special.orientationchange,{setup:function(){return e.support.orientation&&!e.event.special.orientationchange.disabled?!1:(o=s(),void u.bind("throttledresize",n))},teardown:function(){return e.support.orientation&&!e.event.special.orientationchange.disabled?!1:void u.unbind("throttledresize",n)},add:function(e){var t=e.handler;e.handler=function(e){return e.orientation=s(),t.apply(this,arguments)}}}),e.event.special.orientationchange.orientation=s=function(){var n=!0,s=i.documentElement;return n=e.support.orientation?p[t.orientation]:s&&s.clientWidth/s.clientHeight<1.1,n?"portrait":"landscape"},e.fn[d]=function(e){return e?this.bind(d,e):this.trigger(d)},e.attrFn&&(e.attrFn[d]=!0)}(e,this),function(e,t,i,n){function s(e){for(;e&&"undefined"!=typeof e.originalEvent;)e=e.originalEvent;return e}function o(t,i){var o,a,r,l,h,c,u,d,p,m=t.type;if(t=e.Event(t),t.type=i,o=t.originalEvent,a=e.event.props,m.search(/^(mouse|click)/)>-1&&(a=B),o)for(u=a.length,l;u;)l=a[--u],t[l]=o[l];if(m.search(/mouse(down|up)|click/)>-1&&!t.which&&(t.which=1),-1!==m.search(/^touch/)&&(r=s(o),m=r.touches,h=r.changedTouches,c=m&&m.length?m[0]:h&&h.length?h[0]:n))for(d=0,p=E.length;p>d;d++)l=E[d],t[l]=c[l];return t}function a(t){for(var i,n,s={};t;){i=e.data(t,k);for(n in i)i[n]&&(s[n]=s.hasVirtualBinding=!0);t=t.parentNode}return s}function r(t,i){for(var n;t;){if(n=e.data(t,k),n&&(!i||n[i]))return t;t=t.parentNode}return null}function l(){q=!1}function h(){q=!0}function c(){z=0,H.length=0,F=!1,h()}function u(){l()}function d(){p(),O=setTimeout(function(){O=0,c()},e.vmouse.resetTimerDuration)}function p(){O&&(clearTimeout(O),O=0)}function m(t,i,n){var s;return(n&&n[t]||!n&&r(i.target,t))&&(s=o(i,t),e(i.target).trigger(s)),s}function f(t){var i,n=e.data(t.target,P);F||z&&z===n||(i=m("v"+t.type,t),i&&(i.isDefaultPrevented()&&t.preventDefault(),i.isPropagationStopped()&&t.stopPropagation(),i.isImmediatePropagationStopped()&&t.stopImmediatePropagation()))}function g(t){var i,n,o,r=s(t).touches;r&&1===r.length&&(i=t.target,n=a(i),n.hasVirtualBinding&&(z=M++,e.data(i,P,z),p(),u(),L=!1,o=s(t).touches[0],A=o.pageX,N=o.pageY,m("vmouseover",t,n),m("vmousedown",t,n)))}function b(e){q||(L||m("vmousecancel",e,a(e.target)),L=!0,d())}function v(t){if(!q){var i=s(t).touches[0],n=L,o=e.vmouse.moveDistanceThreshold,r=a(t.target);L=L||Math.abs(i.pageX-A)>o||Math.abs(i.pageY-N)>o,L&&!n&&m("vmousecancel",t,r),m("vmousemove",t,r),d()}}function _(e){if(!q){h();var t,i,n=a(e.target);m("vmouseup",e,n),L||(t=m("vclick",e,n),t&&t.isDefaultPrevented()&&(i=s(e).changedTouches[0],H.push({touchID:z,x:i.clientX,y:i.clientY}),F=!0)),m("vmouseout",e,n),L=!1,d()}}function C(t){var i,n=e.data(t,k);if(n)for(i in n)if(n[i])return!0;return!1}function w(){}function y(t){var i=t.substr(1);return{setup:function(){C(this)||e.data(this,k,{});var n=e.data(this,k);n[t]=!0,I[t]=(I[t]||0)+1,1===I[t]&&U.bind(i,f),e(this).bind(i,w),j&&(I.touchstart=(I.touchstart||0)+1,1===I.touchstart&&U.bind("touchstart",g).bind("touchend",_).bind("touchmove",v).bind("scroll",b))},teardown:function(){--I[t],I[t]||U.unbind(i,f),j&&(--I.touchstart,I.touchstart||U.unbind("touchstart",g).unbind("touchmove",v).unbind("touchend",_).unbind("scroll",b));var n=e(this),s=e.data(this,k);s&&(s[t]=!1),n.unbind(i,w),C(this)||n.removeData(k)}}}var x,T,k="virtualMouseBindings",P="virtualTouchID",D="vmouseover vmousedown vmousemove vmouseup vclick vmouseout vmousecancel".split(" "),E="clientX clientY pageX pageY screenX screenY".split(" "),S=e.event.mouseHooks?e.event.mouseHooks.props:[],B=e.event.props.concat(S),I={},O=0,A=0,N=0,L=!1,H=[],F=!1,q=!1,j="addEventListener"in i,U=e(i),M=1,z=0;for(e.vmouse={moveDistanceThreshold:10,clickDistanceThreshold:10,resetTimerDuration:1500},T=0;To;o++)if(a=H[o],r=0,s===h&&Math.abs(a.x-i)Math.floor(e.pageY)||0===e.pageX&&Math.floor(s)>Math.floor(e.pageX)?(s-=i,o-=n):(oe.event.special.swipe.horizontalDistanceThreshold&&Math.abs(t.coords[1]-i.coords[1])i.coords[0]?"swipeleft":"swiperight";return s(n,"swipe",e.Event("swipe",{target:o,swipestart:t,swipestop:i}),!0),s(n,a,e.Event(a,{target:o,swipestart:t,swipestop:i}),!0),!0}return!1},eventInProgress:!1,setup:function(){var t,i=this,n=e(i),s={};t=e.data(this,"mobile-events"),t||(t={length:0},e.data(this,"mobile-events",t)),t.length++,t.swipe=s,s.start=function(t){if(!e.event.special.swipe.eventInProgress){e.event.special.swipe.eventInProgress=!0;var n,a=e.event.special.swipe.start(t),r=t.target,l=!1;s.move=function(t){a&&!t.isDefaultPrevented()&&(n=e.event.special.swipe.stop(t),l||(l=e.event.special.swipe.handleSwipe(a,n,i,r),l&&(e.event.special.swipe.eventInProgress=!1)),Math.abs(a.coords[0]-n.coords[0])>e.event.special.swipe.scrollSupressionThreshold&&t.preventDefault())},s.stop=function(){l=!0,e.event.special.swipe.eventInProgress=!1,o.off(c,s.move),s.move=null},o.on(c,s.move).one(h,s.stop)}},n.on(l,s.start)},teardown:function(){var t,i;t=e.data(this,"mobile-events"),t&&(i=t.swipe,delete t.swipe,t.length--,0===t.length&&e.removeData(this,"mobile-events")),i&&(i.start&&e(this).off(l,i.start),i.move&&o.off(c,i.move),i.stop&&o.off(h,i.stop))}},e.each({scrollstop:"scrollstart",taphold:"tap",swipeleft:"swipe.left",swiperight:"swipe.right"},function(t,i){e.event.special[t]={setup:function(){e(this).bind(i,e.noop)},teardown:function(){e(this).unbind(i)}}})}(e,this),function(e,t){var n={animation:{},transition:{}},s=i.createElement("a"),o=["","webkit-","moz-","o-"];e.each(["animation","transition"],function(i,a){var r=0===i?a+"-name":a;e.each(o,function(i,o){return s.style[e.camelCase(o+r)]!==t?(n[a].prefix=o,!1):void 0}),n[a].duration=e.camelCase(n[a].prefix+a+"-duration"),n[a].event=e.camelCase(n[a].prefix+a+"-end"),""===n[a].prefix&&(n[a].event=n[a].event.toLowerCase())}),e.support.cssTransitions=n.transition.prefix!==t,e.support.cssAnimations=n.animation.prefix!==t,e(s).remove(),e.fn.animationComplete=function(s,o,a){var r,l,h=this,c=function(){clearTimeout(r),s.apply(this,arguments)},u=o&&"animation"!==o?"transition":"animation";return e.support.cssTransitions&&"transition"===u||e.support.cssAnimations&&"animation"===u?(a===t&&(e(this).context!==i&&(l=3e3*parseFloat(e(this).css(n[u].duration))),(0===l||l===t||isNaN(l))&&(l=e.fn.animationComplete.defaultDuration)),r=setTimeout(function(){e(h).off(n[u].event,c),s.apply(h)},l),e(this).one(n[u].event,c)):(setTimeout(e.proxy(s,this),0),e(this))},e.fn.animationComplete.defaultDuration=1e3}(e),function(e,t){function i(e,t){var i=t?t:[];return i.push("ui-btn"),e.theme&&i.push("ui-btn-"+e.theme),e.icon&&(i=i.concat(["ui-icon-"+e.icon,"ui-btn-icon-"+e.iconpos]),e.iconshadow&&i.push("ui-shadow-icon")),e.inline&&i.push("ui-btn-inline"),e.shadow&&i.push("ui-shadow"),e.corners&&i.push("ui-corner-all"),e.mini&&i.push("ui-mini"),i}function n(e){var i,n,s,a=!1,r=!0,l={icon:"",inline:!1,shadow:!1,corners:!1,iconshadow:!1,mini:!1},h=[];for(e=e.split(" "),i=0;i a, .ui-bar > :jqmData(role='controlgroup') > a, button:not(:jqmData(role='navbar') button)"})}(e),function(e,t){var i=0,n=Array.prototype.slice,s=e.cleanData;e.cleanData=function(t){for(var i,n=0;null!=(i=t[n]);n++)try{e(i).triggerHandler("remove")}catch(o){}s(t)},e.widget=function(t,i,n){var s,o,a,r,l={},h=t.split(".")[0];return t=t.split(".")[1],s=h+"-"+t,n||(n=i,i=e.Widget),e.expr[":"][s.toLowerCase()]=function(t){return!!e.data(t,s)},e[h]=e[h]||{},o=e[h][t],a=e[h][t]=function(e,t){return this._createWidget?void(arguments.length&&this._createWidget(e,t)):new a(e,t)},e.extend(a,o,{version:n.version,_proto:e.extend({},n),_childConstructors:[]}),r=new i,r.options=e.widget.extend({},r.options),e.each(n,function(t,n){return e.isFunction(n)?void(l[t]=function(){var e=function(){return i.prototype[t].apply(this,arguments)},s=function(e){return i.prototype[t].apply(this,e)};return function(){var t,i=this._super,o=this._superApply;return this._super=e,this._superApply=s,t=n.apply(this,arguments),this._super=i,this._superApply=o,t}}()):void(l[t]=n)}),a.prototype=e.widget.extend(r,{widgetEventPrefix:o?r.widgetEventPrefix||t:t},l,{constructor:a,namespace:h,widgetName:t,widgetFullName:s}),o?(e.each(o._childConstructors,function(t,i){var n=i.prototype;e.widget(n.namespace+"."+n.widgetName,a,i._proto)}),delete o._childConstructors):i._childConstructors.push(a),e.widget.bridge(t,a),a},e.widget.extend=function(i){for(var s,o,a=n.call(arguments,1),r=0,l=a.length;l>r;r++)for(s in a[r])o=a[r][s],a[r].hasOwnProperty(s)&&o!==t&&(i[s]=e.isPlainObject(o)?e.isPlainObject(i[s])?e.widget.extend({},i[s],o):e.widget.extend({},o):o);return i},e.widget.bridge=function(i,s){var o=s.prototype.widgetFullName||i;e.fn[i]=function(a){var r="string"==typeof a,l=n.call(arguments,1),h=this;return a=!r&&l.length?e.widget.extend.apply(null,[a].concat(l)):a,this.each(r?function(){var n,s=e.data(this,o);return"instance"===a?(h=s,!1):s?e.isFunction(s[a])&&"_"!==a.charAt(0)?(n=s[a].apply(s,l),n!==s&&n!==t?(h=n&&n.jquery?h.pushStack(n.get()):n,!1):void 0):e.error("no such method '"+a+"' for "+i+" widget instance"):e.error("cannot call methods on "+i+" prior to initialization; attempted to call method '"+a+"'")}:function(){var t=e.data(this,o);t?t.option(a||{})._init():e.data(this,o,new s(a,this))}),h}},e.Widget=function(){},e.Widget._childConstructors=[],e.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"",options:{disabled:!1,create:null},_createWidget:function(t,n){n=e(n||this.defaultElement||this)[0],this.element=e(n),this.uuid=i++,this.eventNamespace="."+this.widgetName+this.uuid,this.options=e.widget.extend({},this.options,this._getCreateOptions(),t),this.bindings=e(),this.hoverable=e(),this.focusable=e(),n!==this&&(e.data(n,this.widgetFullName,this),this._on(!0,this.element,{remove:function(e){e.target===n&&this.destroy()}}),this.document=e(n.style?n.ownerDocument:n.document||n),this.window=e(this.document[0].defaultView||this.document[0].parentWindow)),this._create(),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:e.noop,_getCreateEventData:e.noop,_create:e.noop,_init:e.noop,destroy:function(){this._destroy(),this.element.unbind(this.eventNamespace).removeData(this.widgetFullName).removeData(e.camelCase(this.widgetFullName)),this.widget().unbind(this.eventNamespace).removeAttr("aria-disabled").removeClass(this.widgetFullName+"-disabled ui-state-disabled"),this.bindings.unbind(this.eventNamespace),this.hoverable.removeClass("ui-state-hover"),this.focusable.removeClass("ui-state-focus")},_destroy:e.noop,widget:function(){return this.element},option:function(i,n){var s,o,a,r=i;if(0===arguments.length)return e.widget.extend({},this.options);if("string"==typeof i)if(r={},s=i.split("."),i=s.shift(),s.length){for(o=r[i]=e.widget.extend({},this.options[i]),a=0;a
").html(o.clone()).html(),i=t.indexOf(" type=")>-1,n=i?/\s+type=["']?\w+['"]?/:/\/?>/,s=' type="'+r+'" data-'+e.mobile.ns+'type="'+a+'"'+(i?"":">"),o.replaceWith(t.replace(n,s)))})}}(e),function(e){e.fn.fieldcontain=function(){return this.addClass("ui-field-contain")}}(e),function(e){e.fn.grid=function(t){return this.each(function(){var i,n,s=e(this),o=e.extend({grid:null},t),a=s.children(),r={solo:1,a:2,b:3,c:4,d:5},l=o.grid;if(!l)if(a.length<=5)for(n in r)r[n]===a.length&&(l=n);else l="a",s.addClass("ui-grid-duo");i=r[l],s.addClass("ui-grid-"+l),a.filter(":nth-child("+i+"n+1)").addClass("ui-block-a"),i>1&&a.filter(":nth-child("+i+"n+2)").addClass("ui-block-b"),i>2&&a.filter(":nth-child("+i+"n+3)").addClass("ui-block-c"),i>3&&a.filter(":nth-child("+i+"n+4)").addClass("ui-block-d"),i>4&&a.filter(":nth-child("+i+"n+5)").addClass("ui-block-e")})}}(e),function(e,i){var n,s,o="&ui-state=dialog";e.mobile.path=n={uiStateKey:"&ui-state",urlParseRE:/^\s*(((([^:\/#\?]+:)?(?:(\/\/)((?:(([^:@\/#\?]+)(?:\:([^:@\/#\?]+))?)@)?(([^:\/#\?\]\[]+|\[[^\/\]@#?]+\])(?:\:([0-9]+))?))?)?)?((\/?(?:[^\/\?#]+\/+)*)([^\?#]*)))?(\?[^#]+)?)(#.*)?/,getLocation:function(e){var t=this.parseUrl(e||location.href),i=e?t:location,n=t.hash;return n="#"===n?"":n,i.protocol+t.doubleSlash+i.host+(""!==i.protocol&&"/"!==i.pathname.substring(0,1)?"/":"")+i.pathname+i.search+n},getDocumentUrl:function(t){return t?e.extend({},n.documentUrl):n.documentUrl.href},parseLocation:function(){return this.parseUrl(this.getLocation())},parseUrl:function(t){if("object"===e.type(t))return t;var i=n.urlParseRE.exec(t||"")||[];return{href:i[0]||"",hrefNoHash:i[1]||"",hrefNoSearch:i[2]||"",domain:i[3]||"",protocol:i[4]||"",doubleSlash:i[5]||"",authority:i[6]||"",username:i[8]||"",password:i[9]||"",host:i[10]||"",hostname:i[11]||"",port:i[12]||"",pathname:i[13]||"",directory:i[14]||"",filename:i[15]||"",search:i[16]||"",hash:i[17]||""}},makePathAbsolute:function(e,t){var i,n,s,o;if(e&&"/"===e.charAt(0))return e;for(e=e||"",t=t?t.replace(/^\/|(\/[^\/]*|[^\/]+)$/g,""):"",i=t?t.split("/"):[],n=e.split("/"),s=0;s-1&&(u=s.slice(a),s=s.slice(0,a)),i=n.makeUrlAbsolute(s,t),o=this.parseUrl(i).search,l?((n.isPath(c)||0===c.replace("#","").indexOf(this.uiStateKey))&&(c=""),u&&-1===c.indexOf(this.uiStateKey)&&(c+=u),-1===c.indexOf("#")&&""!==c&&(c="#"+c),i=n.parseUrl(i),i=i.protocol+i.doubleSlash+i.host+i.pathname+o+c):i+=i.indexOf("#")>-1?u:"#"+u,i},isPreservableHash:function(e){return 0===e.replace("#","").indexOf(this.uiStateKey)},hashToSelector:function(e){var t="#"===e.substring(0,1);return t&&(e=e.substring(1)),(t?"#":"")+e.replace(/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g,"\\$1")},getFilePath:function(e){return e&&e.split(o)[0]},isFirstPageUrl:function(t){var s=n.parseUrl(n.makeUrlAbsolute(t,this.documentBase)),o=s.hrefNoHash===this.documentUrl.hrefNoHash||this.documentBaseDiffers&&s.hrefNoHash===this.documentBase.hrefNoHash,a=e.mobile.firstPage,r=a&&a[0]?a[0].id:i;return o&&(!s.hash||"#"===s.hash||r&&s.hash.replace(/^#/,"")===r)},isPermittedCrossDomainRequest:function(t,i){return e.mobile.allowCrossDomainPages&&("file:"===t.protocol||"content:"===t.protocol)&&-1!==i.search(/^https?:/)}},n.documentUrl=n.parseLocation(),s=e("head").find("base"),n.documentBase=s.length?n.parseUrl(n.makeUrlAbsolute(s.attr("href"),n.documentUrl.href)):n.documentUrl,n.documentBaseDiffers=n.documentUrl.hrefNoHash!==n.documentBase.hrefNoHash,n.getDocumentBase=function(t){return t?e.extend({},n.documentBase):n.documentBase.href},e.extend(e.mobile,{getDocumentUrl:n.getDocumentUrl,getDocumentBase:n.getDocumentBase})}(e),function(e,t){e.mobile.History=function(e,t){this.stack=e||[],this.activeIndex=t||0},e.extend(e.mobile.History.prototype,{getActive:function(){return this.stack[this.activeIndex]},getLast:function(){return this.stack[this.previousIndex]},getNext:function(){return this.stack[this.activeIndex+1]},getPrev:function(){return this.stack[this.activeIndex-1]},add:function(e,t){t=t||{},this.getNext()&&this.clearForward(),t.hash&&-1===t.hash.indexOf("#")&&(t.hash="#"+t.hash),t.url=e,this.stack.push(t),this.activeIndex=this.stack.length-1},clearForward:function(){this.stack=this.stack.slice(0,this.activeIndex+1)},find:function(e,t,i){t=t||this.stack;var n,s,o,a=t.length;for(s=0;a>s;s++)if(n=t[s],(decodeURIComponent(e)===decodeURIComponent(n.url)||decodeURIComponent(e)===decodeURIComponent(n.hash))&&(o=s,i))return o;return o},closest:function(e){var i,n=this.activeIndex;return i=this.find(e,this.stack.slice(0,n)),i===t&&(i=this.find(e,this.stack.slice(n),!0),i=i===t?i:i+n),i},direct:function(i){var n=this.closest(i.url),s=this.activeIndex;n!==t&&(this.activeIndex=n,this.previousIndex=s),s>n?(i.present||i.back||e.noop)(this.getActive(),"back"):n>s?(i.present||i.forward||e.noop)(this.getActive(),"forward"):n===t&&i.missing&&i.missing(this.getActive())}})}(e),function(e){var n=e.mobile.path,s=location.href;e.mobile.Navigator=function(t){this.history=t,this.ignoreInitialHashChange=!0,e.mobile.window.bind({"popstate.history":e.proxy(this.popstate,this),"hashchange.history":e.proxy(this.hashchange,this)})},e.extend(e.mobile.Navigator.prototype,{squash:function(s,o){var a,r,l=n.isPath(s)?n.stripHash(s):s;return r=n.squash(s),a=e.extend({hash:l,url:r},o),t.history.replaceState(a,a.title||i.title,r),a},hash:function(e,t){var i,s,o,a;return i=n.parseUrl(e),s=n.parseLocation(),s.pathname+s.search===i.pathname+i.search?o=i.hash?i.hash:i.pathname+i.search:n.isPath(e)?(a=n.parseUrl(t),o=a.pathname+a.search+(n.isPreservableHash(a.hash)?a.hash.replace("#",""):"")):o=e,o},go:function(s,o,a){var r,l,h,c,u=e.event.special.navigate.isPushStateEnabled();l=n.squash(s),h=this.hash(s,l),a&&h!==n.stripHash(n.parseLocation().hash)&&(this.preventNextHashChange=a),this.preventHashAssignPopState=!0,t.location.hash=h,this.preventHashAssignPopState=!1,r=e.extend({url:l,hash:h,title:i.title},o),u&&(c=new e.Event("popstate"),c.originalEvent={type:"popstate",state:null},this.squash(s,r),a||(this.ignorePopState=!0,e.mobile.window.trigger(c))),this.history.add(r.url,r)},popstate:function(t){var i,o;if(e.event.special.navigate.isPushStateEnabled())return this.preventHashAssignPopState?(this.preventHashAssignPopState=!1,void t.stopImmediatePropagation()):this.ignorePopState?void(this.ignorePopState=!1):!t.originalEvent.state&&1===this.history.stack.length&&this.ignoreInitialHashChange&&(this.ignoreInitialHashChange=!1,location.href===s)?void t.preventDefault():(i=n.parseLocation().hash,!t.originalEvent.state&&i?(o=this.squash(i),this.history.add(o.url,o),void(t.historyState=o)):void this.history.direct({url:(t.originalEvent.state||{}).url||i,present:function(i,n){t.historyState=e.extend({},i),t.historyState.direction=n}}))},hashchange:function(t){var s,o;if(e.event.special.navigate.isHashChangeEnabled()&&!e.event.special.navigate.isPushStateEnabled()){if(this.preventNextHashChange)return this.preventNextHashChange=!1,void t.stopImmediatePropagation();s=this.history,o=n.parseLocation().hash,this.history.direct({url:o,present:function(i,n){t.hashchangeState=e.extend({},i),t.hashchangeState.direction=n},missing:function(){s.add(o,{hash:o,title:i.title})}})}}})}(e),function(e){e.mobile.navigate=function(t,i,n){e.mobile.navigate.navigator.go(t,i,n)},e.mobile.navigate.history=new e.mobile.History,e.mobile.navigate.navigator=new e.mobile.Navigator(e.mobile.navigate.history);var t=e.mobile.path.parseLocation();e.mobile.navigate.history.add(t.href,{hash:t.hash})}(e),function(e){var t=e("head").children("base"),i={element:t.length?t:e(" ",{href:e.mobile.path.documentBase.hrefNoHash}).prependTo(e("head")),linkSelector:"[src], link[href], a[rel='external'], :jqmData(ajax='false'), a[target]",set:function(t){e.mobile.dynamicBaseEnabled&&e.support.dynamicBaseTag&&i.element.attr("href",e.mobile.path.makeUrlAbsolute(t,e.mobile.path.documentBase))},rewrite:function(t,n){var s=e.mobile.path.get(t);n.find(i.linkSelector).each(function(t,i){var n=e(i).is("[href]")?"href":e(i).is("[src]")?"src":"action",o=e.mobile.path.parseLocation(),a=e(i).attr(n);a=a.replace(o.protocol+o.doubleSlash+o.host+o.pathname,""),/^(\w+:|#|\/)/.test(a)||e(i).attr(n,s+a)})},reset:function(){i.element.attr("href",e.mobile.path.documentBase.hrefNoSearch)}};e.mobile.base=i}(e),function(e,t){e.mobile.Transition=function(){this.init.apply(this,arguments)},e.extend(e.mobile.Transition.prototype,{toPreClass:" ui-page-pre-in",init:function(t,i,n,s){e.extend(this,{name:t,reverse:i,$to:n,$from:s,deferred:new e.Deferred})},cleanFrom:function(){this.$from.removeClass(e.mobile.activePageClass+" out in reverse "+this.name).height("")},beforeDoneIn:function(){},beforeDoneOut:function(){},beforeStartOut:function(){},doneIn:function(){this.beforeDoneIn(),this.$to.removeClass("out in reverse "+this.name).height(""),this.toggleViewportClass(),e.mobile.window.scrollTop()!==this.toScroll&&this.scrollPage(),this.sequential||this.$to.addClass(e.mobile.activePageClass),this.deferred.resolve(this.name,this.reverse,this.$to,this.$from,!0)},doneOut:function(e,t,i,n){this.beforeDoneOut(),this.startIn(e,t,i,n)},hideIn:function(e){this.$to.css("z-index",-10),e.call(this),this.$to.css("z-index","")},scrollPage:function(){e.event.special.scrollstart.enabled=!1,(e.mobile.hideUrlBar||this.toScroll!==e.mobile.defaultHomeScroll)&&t.scrollTo(0,this.toScroll),setTimeout(function(){e.event.special.scrollstart.enabled=!0},150)},startIn:function(t,i,n,s){this.hideIn(function(){this.$to.addClass(e.mobile.activePageClass+this.toPreClass),s||e.mobile.focusPage(this.$to),this.$to.height(t+this.toScroll),n||this.scrollPage()}),this.$to.removeClass(this.toPreClass).addClass(this.name+" in "+i),n?this.doneIn():this.$to.animationComplete(e.proxy(function(){this.doneIn()},this))},startOut:function(t,i,n){this.beforeStartOut(t,i,n),this.$from.height(t+e.mobile.window.scrollTop()).addClass(this.name+" out"+i)},toggleViewportClass:function(){e.mobile.pageContainer.toggleClass("ui-mobile-viewport-transitioning viewport-"+this.name)},slide:function(t){var i=this;i.reverse?(e(i.$from).show().css("left","0").css("right","0"),t.animate(e(i.$from)[0],{left:"100%",right:"-100%"},{easing:"ease-in-out",duration:800,begin:function(){e(i.$to).show().css("left","-100%").css("right","100%"),t.animate(e(i.$to)[0],{left:"0",right:"0"},{complete:function(){e(i.$from).hide(),i.toggleViewportClass(),i.deferred.resolve(i.name,i.reverse,i.$to,i.$from,!0)},easing:"ease-in-out",duration:800})}})):t.animate(e(i.$from)[0],{left:"-100%",right:"100%"},{easing:"ease-in-out",duration:800,begin:function(){e(i.$to).show().css("left","100%"),t.animate(e(i.$to)[0],{left:"0px"},{complete:function(){e(i.$from).hide(),i.toggleViewportClass(),i.deferred.resolve(i.name,i.reverse,i.$to,i.$from,!0)},easing:"ease-in-out",duration:800})}})},slideUp:function(t){var i=this;i.reverse?(e(i.$to).show(),t.animate(e(i.$from)[0],{top:"100%",bottom:"-100%"},{complete:function(){e(i.$from).hide(),i.toggleViewportClass(),i.deferred.resolve(i.name,i.reverse,i.$to,i.$from,!0)},easing:"ease-in-out",duration:800})):(e(i.$to).show().css("top","100%").css("bottom","-100%"),t.animate(e(i.$to)[0],{top:"0px",bottom:0},{complete:function(){e(i.$from).hide(),i.toggleViewportClass(),i.deferred.resolve(i.name,i.reverse,i.$to,i.$from,!0)},easing:"ease-in-out",duration:800}))},transition:function(){var t,i=this.reverse?" reverse":"",n=e.mobile.getScreenHeight(),s=e.mobile.maxTransitionWidth!==!1&&e.mobile.window.width()>e.mobile.maxTransitionWidth;if(this.toScroll=e.mobile.navigate.history.getActive().lastScroll||e.mobile.defaultHomeScroll,t=!e.support.cssTransitions||!e.support.cssAnimations||s||!this.name||"none"===this.name||Math.max(e.mobile.window.scrollTop(),this.toScroll)>e.mobile.getMaxScrollForTransition(),this.toggleViewportClass(),t)this.$from&&!t?this.startOut(n,i,t):this.doneOut(n,i,t,!0);else{var o=this;require(["jquery","velocity"],function(e,t){"slideup"==o.name?o.slideUp(t):o.slide(t)})}return this.deferred.promise()}})}(e,this),function(e){e.mobile.SerialTransition=function(){this.init.apply(this,arguments)},e.extend(e.mobile.SerialTransition.prototype,e.mobile.Transition.prototype,{sequential:!0,beforeDoneOut:function(){this.$from&&this.cleanFrom()},beforeStartOut:function(t,i,n){this.$from.animationComplete(e.proxy(function(){this.doneOut(t,i,n)},this))}})}(e),function(e){e.mobile.ConcurrentTransition=function(){this.init.apply(this,arguments)},e.extend(e.mobile.ConcurrentTransition.prototype,e.mobile.Transition.prototype,{sequential:!1,beforeDoneIn:function(){this.$from&&this.cleanFrom()},beforeStartOut:function(e,t,i){this.doneOut(e,t,i)}})}(e),function(e){var t=function(){return 3*e.mobile.getScreenHeight()};e.mobile.transitionHandlers={sequential:e.mobile.SerialTransition,simultaneous:e.mobile.ConcurrentTransition},e.mobile.defaultTransitionHandler=e.mobile.transitionHandlers.sequential,e.mobile.transitionFallbacks={},e.mobile._maybeDegradeTransition=function(t){return t&&!e.support.cssTransform3d&&e.mobile.transitionFallbacks[t]&&(t=e.mobile.transitionFallbacks[t]),t},e.mobile.getMaxScrollForTransition=e.mobile.getMaxScrollForTransition||t}(e),function(e,n){e.widget("mobile.pagecontainer",{options:{theme:"a"},initSelector:!1,_create:function(){this._trigger("beforecreate"),this.setLastScrollEnabled=!0,this._on(this.window,{navigate:"_disableRecordScroll",scrollstop:"_delayedRecordScroll"}),this._on(this.window,{navigate:"_filterNavigateEvents"}),this._on({pagechange:"_afterContentChange"}),this.window.one("navigate",e.proxy(function(){this.setLastScrollEnabled=!0},this))},_setOptions:function(e){e.theme!==n&&"none"!==e.theme?this.element.removeClass("ui-overlay-"+this.options.theme).addClass("ui-overlay-"+e.theme):e.theme!==n&&this.element.removeClass("ui-overlay-"+this.options.theme),this._super(e)},_disableRecordScroll:function(){this.setLastScrollEnabled=!1},_enableRecordScroll:function(){this.setLastScrollEnabled=!0},_afterContentChange:function(){this.setLastScrollEnabled=!0,this._off(this.window,"scrollstop"),this._on(this.window,{scrollstop:"_delayedRecordScroll"})},_recordScroll:function(){if(this.setLastScrollEnabled){var e,t,i,n=this._getActiveHistory();n&&(e=this._getScroll(),t=this._getMinScroll(),i=this._getDefaultScroll(),n.lastScroll=t>e?i:e)}},_delayedRecordScroll:function(){setTimeout(e.proxy(this,"_recordScroll"),100)},_getScroll:function(){return this.window.scrollTop()},_getMinScroll:function(){return e.mobile.minScrollBack},_getDefaultScroll:function(){return e.mobile.defaultHomeScroll},_filterNavigateEvents:function(t,i){var n;t.originalEvent&&t.originalEvent.isDefaultPrevented()||(n=t.originalEvent.type.indexOf("hashchange")>-1?i.state.hash:i.state.url,n||(n=this._getHash()),n&&"#"!==n&&0!==n.indexOf("#"+e.mobile.path.uiStateKey)||(n=location.href),this._handleNavigate(n,i.state))},_getHash:function(){return e.mobile.path.parseLocation().hash},getActivePage:function(){return this.activePage},_getInitialContent:function(){return e.mobile.firstPage},_getHistory:function(){return e.mobile.navigate.history},_getActiveHistory:function(){return this._getHistory().getActive()},_getDocumentBase:function(){return e.mobile.path.documentBase},back:function(){this.go(-1)},forward:function(){this.go(1)},go:function(i){if(e.mobile.hashListeningEnabled)t.history.go(i);else{var n=e.mobile.navigate.history.activeIndex,s=n+parseInt(i,10),o=e.mobile.navigate.history.stack[s].url,a=i>=1?"forward":"back";e.mobile.navigate.history.activeIndex=s,e.mobile.navigate.history.previousIndex=n,this.change(o,{direction:a,changeHash:!1,fromHashChange:!0})}},_handleDestination:function(t){var i;return"string"===e.type(t)&&(t=e.mobile.path.stripHash(t)),t&&(i=this._getHistory(),t=e.mobile.path.isPath(t)?t:e.mobile.path.makeUrlAbsolute("#"+t,this._getDocumentBase())),t||this._getInitialContent()},_transitionFromHistory:function(e,t){var i=this._getHistory(),n="back"===e?i.getLast():i.getActive();return n&&n.transition||t},_handleDialog:function(t,i){var n,s,o=this.getActivePage();return o&&!o.data("mobile-dialog")?("back"===i.direction?this.back():this.forward(),!1):(n=i.pageUrl,s=this._getActiveHistory(),e.extend(t,{role:s.role,transition:this._transitionFromHistory(i.direction,t.transition),reverse:"back"===i.direction}),n)},_handleNavigate:function(t,i){var n=e.mobile.path.stripHash(t),s=this._getHistory(),o=0===s.stack.length?"none":this._transitionFromHistory(i.direction),a={changeHash:!1,fromHashChange:!0,reverse:"back"===i.direction};e.extend(a,i,{transition:o}),s.activeIndex>0&&n.indexOf(e.mobile.dialogHashKey)>-1&&(n=this._handleDialog(a,i),n===!1)||this._changeContent(this._handleDestination(n),a)},_changeContent:function(t,i){e.mobile.changePage(t,i)},_getBase:function(){return e.mobile.base},_getNs:function(){return e.mobile.ns},_enhance:function(e,t){return e.page({role:t})},_include:function(e,t){e.appendTo(this.element),this._enhance(e,t.role),e.page("bindRemove")},_find:function(t){var i,n=this._createFileUrl(t),s=this._createDataUrl(t),o=this._getInitialContent();return i=this.element.children("[data-"+this._getNs()+"url='"+e.mobile.path.hashToSelector(s)+"']"),0===i.length&&s&&!e.mobile.path.isPath(s)&&(i=this.element.children(e.mobile.path.hashToSelector("#"+s)).attr("data-"+this._getNs()+"url",s).jqmData("url",s)),0===i.length&&e.mobile.path.isFirstPageUrl(n)&&o&&o.parent().length&&(i=e(o)),i},_getLoader:function(){return e.mobile.loading()},_showLoading:function(t,i,n,s){this._loadMsg||(this._loadMsg=setTimeout(e.proxy(function(){this._getLoader().loader("show",i,n,s),this._loadMsg=0},this),t))},_hideLoading:function(){clearTimeout(this._loadMsg),this._loadMsg=0,this._getLoader().loader("hide")},_showError:function(){this._hideLoading(),this._showLoading(0,e.mobile.pageLoadErrorMessageTheme,e.mobile.pageLoadErrorMessage,!0),setTimeout(e.proxy(this,"_hideLoading"),1500)},_parse:function(t,i){var n,s=e("
");return s.get(0).innerHTML=t,n=s.find(":jqmData(role='page'), :jqmData(role='dialog')").first(),n.length||(n=e(""+(t.split(/<\/?body[^>]*>/gim)[1]||"")+"
")),n.attr("data-"+this._getNs()+"url",this._createDataUrl(i)).attr("data-"+this._getNs()+"external-page",!0),n},_setLoadedTitle:function(t,i){var n=i.match(/]*>([^<]*)/)&&RegExp.$1;n&&!t.jqmData("title")&&(n=e(""+n+"
").text(),t.jqmData("title",n))},_isRewritableBaseTag:function(){return e.mobile.dynamicBaseEnabled&&!e.support.dynamicBaseTag},_createDataUrl:function(t){return e.mobile.path.convertUrlToDataUrl(t)},_createFileUrl:function(t){return e.mobile.path.getFilePath(t)},_triggerWithDeprecated:function(t,i,n){var s=e.Event("page"+t),o=e.Event(this.widgetName+t);return(n||this.element).trigger(s,i),this._trigger(t,o,i),{deprecatedEvent:s,event:o}},_loadSuccess:function(t,i,s,o){var a=this._createFileUrl(t);return e.proxy(function(r,l,h){var c,u=new RegExp("(<[^>]+\\bdata-"+this._getNs()+"role=[\"']?page[\"']?[^>]*>)"),d=new RegExp("\\bdata-"+this._getNs()+"url=[\"']?([^\"'>]*)[\"']?");u.test(r)&&RegExp.$1&&d.test(RegExp.$1)&&RegExp.$1&&(a=e.mobile.path.getFilePath(e(""+RegExp.$1+"
").text()),a=this.window[0].encodeURIComponent(a)),s.prefetch===n&&this._getBase().set(a),c=this._parse(r,a),this._setLoadedTitle(c,r),i.xhr=h,i.textStatus=l,i.page=c,i.content=c,i.toPage=c,this._triggerWithDeprecated("load",i).event.isDefaultPrevented()||(this._isRewritableBaseTag()&&c&&this._getBase().rewrite(a,c),this._include(c,s),s.showLoadMsg&&this._hideLoading(),o.resolve(t,s,c))},this)},_loadDefaults:{type:"get",data:n,reloadPage:!1,reload:!1,role:n,showLoadMsg:!1,loadMsgDelay:50},load:function(t,i){var s,o,a,r,l=i&&i.deferred||e.Deferred(),h=i&&i.reload===n&&i.reloadPage!==n?{reload:i.reloadPage}:{},c=e.extend({},this._loadDefaults,i,h),u=null,d=e.mobile.path.makeUrlAbsolute(t,this._findBaseWithDefault());return c.data&&"get"===c.type&&(d=e.mobile.path.addSearchParams(d,c.data),c.data=n),c.data&&"post"===c.type&&(c.reload=!0),s=this._createFileUrl(d),o=this._createDataUrl(d),u=this._find(d),0===u.length&&e.mobile.path.isEmbeddedPage(s)&&!e.mobile.path.isFirstPageUrl(s)?(l.reject(d,c),l.promise()):(this._getBase().reset(),u.length&&!c.reload?(this._enhance(u,c.role),l.resolve(d,c,u),c.prefetch||this._getBase().set(t),l.promise()):(r={url:t,absUrl:d,toPage:t,prevPage:i?i.fromPage:n,dataUrl:o,deferred:l,options:c},a=this._triggerWithDeprecated("beforeload",r),a.deprecatedEvent.isDefaultPrevented()||a.event.isDefaultPrevented()?l.promise():(c.showLoadMsg&&this._showLoading(c.loadMsgDelay),c.prefetch===n&&this._getBase().reset(),e.mobile.allowCrossDomainPages||e.mobile.path.isSameDomain(e.mobile.path.documentUrl,d)?(e.ajax({url:s,type:c.type,data:c.data,contentType:c.contentType,dataType:"html",success:this._loadSuccess(d,r,c,l),error:this._loadError(d,r,c,l)}),l.promise()):(l.reject(d,c),l.promise()))))},_loadError:function(t,i,n,s){return e.proxy(function(o,a,r){this._getBase().set(e.mobile.path.get()),i.xhr=o,i.textStatus=a,i.errorThrown=r;var l=this._triggerWithDeprecated("loadfailed",i);l.deprecatedEvent.isDefaultPrevented()||l.event.isDefaultPrevented()||(n.showLoadMsg&&this._showError(),s.reject(t,n))},this)},_getTransitionHandler:function(t){return t=e.mobile._maybeDegradeTransition(t),e.mobile.transitionHandlers[t]||e.mobile.defaultTransitionHandler},_triggerCssTransitionEvents:function(t,i,n){var s=!1;n=n||"",i&&(t[0]===i[0]&&(s=!0),this._triggerWithDeprecated(n+"hide",{nextPage:t,toPage:t,prevPage:i,samePage:s},i)),this._triggerWithDeprecated(n+"show",{prevPage:i||e(""),toPage:t},t)},_cssTransition:function(t,i,n){var s,o,a=n.transition,r=n.reverse,l=n.deferred;this._triggerCssTransitionEvents(t,i,"before"),this._hideLoading(),s=this._getTransitionHandler(a),o=new s(a,r,t,i).transition(),o.done(e.proxy(function(){this._triggerCssTransitionEvents(t,i)},this)),o.done(function(){l.resolve.apply(l,arguments)})},_releaseTransitionLock:function(){o=!1,s.length>0&&e.mobile.changePage.apply(null,s.pop())},_removeActiveLinkClass:function(t){e.mobile.removeActiveLinkClass(t)},_loadUrl:function(t,i,n){n.target=t,n.deferred=e.Deferred(),this.load(t,n),n.deferred.done(e.proxy(function(e,t,n){o=!1,t.absUrl=i.absUrl,this.transition(n,i,t)},this)),n.deferred.fail(e.proxy(function(){this._removeActiveLinkClass(!0),this._releaseTransitionLock(),this._triggerWithDeprecated("changefailed",i)},this))},_triggerPageBeforeChange:function(t,i,n){var s;return i.prevPage=this.activePage,e.extend(i,{toPage:t,options:n}),i.absUrl="string"===e.type(t)?e.mobile.path.makeUrlAbsolute(t,this._findBaseWithDefault()):n.absUrl,s=this._triggerWithDeprecated("beforechange",i),s.event.isDefaultPrevented()||s.deprecatedEvent.isDefaultPrevented()?!1:!0},change:function(t,i){if(o)return void s.unshift(arguments);var n=e.extend({},e.mobile.changePage.defaults,i),a={};n.fromPage=n.fromPage||this.activePage,this._triggerPageBeforeChange(t,a,n)&&(t=a.toPage,"string"===e.type(t)?(o=!0,this._loadUrl(t,a,n)):this.transition(t,a,n))},transition:function(t,a,r){var l,h,c,u,d,p,m,f,g,b,v,_,C,w;if(o)return void s.unshift([t,r]);if(this._triggerPageBeforeChange(t,a,r)&&(a.prevPage=r.fromPage,w=this._triggerWithDeprecated("beforetransition",a),!w.deprecatedEvent.isDefaultPrevented()&&!w.event.isDefaultPrevented())){if(o=!0,t[0]!==e.mobile.firstPage[0]||r.dataUrl||(r.dataUrl=e.mobile.path.documentUrl.hrefNoHash),l=r.fromPage,h=r.dataUrl&&e.mobile.path.convertUrlToDataUrl(r.dataUrl)||t.jqmData("url"),c=h,u=e.mobile.path.getFilePath(h),d=e.mobile.navigate.history.getActive(),p=0===e.mobile.navigate.history.activeIndex,m=0,f=i.title,g=("dialog"===r.role||"dialog"===t.jqmData("role"))&&t.jqmData("dialog")!==!0,l&&l[0]===t[0]&&!r.allowSamePageTransition)return o=!1,this._triggerWithDeprecated("transition",a),this._triggerWithDeprecated("change",a),void(r.fromHashChange&&e.mobile.navigate.history.direct({url:h}));
+t.page({role:r.role}),r.fromHashChange&&(m="back"===r.direction?-1:1);try{i.activeElement&&"body"!==i.activeElement.nodeName.toLowerCase()?e(i.activeElement).blur():e("input:focus, textarea:focus, select:focus").blur()}catch(y){}b=!1,g&&d&&(d.url&&d.url.indexOf(e.mobile.dialogHashKey)>-1&&this.activePage&&!this.activePage.hasClass("ui-dialog")&&e.mobile.navigate.history.activeIndex>0&&(r.changeHash=!1,b=!0),h=d.url||"",h+=!b&&h.indexOf("#")>-1?e.mobile.dialogHashKey:"#"+e.mobile.dialogHashKey),v=d?t.jqmData("title")||t.children(":jqmData(role='header')").find(".ui-title").text():f,v&&f===i.title&&(f=v),t.jqmData("title")||t.jqmData("title",f),r.transition=r.transition||(m&&!p?d.transition:n)||(g?e.mobile.defaultDialogTransition:e.mobile.defaultPageTransition),!m&&b&&(e.mobile.navigate.history.getActive().pageUrl=c),h&&!r.fromHashChange&&(!e.mobile.path.isPath(h)&&h.indexOf("#")<0&&(h="#"+h),_={transition:r.transition,title:f,pageUrl:c,role:r.role},r.changeHash!==!1&&e.mobile.hashListeningEnabled?e.mobile.navigate(this.window[0].encodeURI(h),_,!0):t[0]!==e.mobile.firstPage[0]&&e.mobile.navigate.history.add(h,_)),i.title=f,e.mobile.activePage=t,this.activePage=t,r.reverse=r.reverse||0>m,C=e.Deferred(),this._cssTransition(t,l,{transition:r.transition,reverse:r.reverse,deferred:C}),C.done(e.proxy(function(i,n,s,o,l){e.mobile.removeActiveLinkClass(),r.duplicateCachedPage&&r.duplicateCachedPage.remove(),l||e.mobile.focusPage(t),this._releaseTransitionLock(),this._triggerWithDeprecated("transition",a),this._triggerWithDeprecated("change",a)},this))}},_findBaseWithDefault:function(){var t=this.activePage&&e.mobile.getClosestBaseUrl(this.activePage);return t||e.mobile.path.documentBase.hrefNoHash}}),e.mobile.navreadyDeferred=e.Deferred();var s=[],o=!1}(e),function(e,n){function s(e){for(;e&&("string"!=typeof e.nodeName||"a"!==e.nodeName.toLowerCase());)e=e.parentNode;return e}var o=e.Deferred(),a=e.Deferred(),r=function(){a.resolve(),a=null},l=e.mobile.path.documentUrl,h=null;e.mobile.loadPage=function(t,i){var n;return i=i||{},n=i.pageContainer||e.mobile.pageContainer,i.deferred=e.Deferred(),n.pagecontainer("load",t,i),i.deferred.promise()},e.mobile.back=function(){var i=t.navigator;this.phonegapNavigationEnabled&&i&&i.app&&i.app.backHistory?i.app.backHistory():e.mobile.pageContainer.pagecontainer("back")},e.mobile.focusPage=function(e){var t=e.find("[autofocus]"),i=e.find(".ui-title:eq(0)");return t.length?void t.focus():void(i.length?i.focus():e.focus())},e.mobile._maybeDegradeTransition=e.mobile._maybeDegradeTransition||function(e){return e},e.mobile.changePage=function(t,i){e.mobile.pageContainer.pagecontainer("change",t,i)},e.mobile.changePage.defaults={transition:n,reverse:!1,changeHash:!0,fromHashChange:!1,role:n,duplicateCachedPage:n,pageContainer:n,showLoadMsg:!0,dataUrl:n,fromPage:n,allowSamePageTransition:!1},e.mobile._registerInternalEvents=function(){var i=function(t,i){var n,s,o,a,r=!0;return!e.mobile.ajaxEnabled||t.is(":jqmData(ajax='false')")||!t.jqmHijackable().length||t.attr("target")?!1:(n=h&&h.attr("formaction")||t.attr("action"),a=(t.attr("method")||"get").toLowerCase(),n||(n=e.mobile.getClosestBaseUrl(t),"get"===a&&(n=e.mobile.path.parseUrl(n).hrefNoSearch),n===e.mobile.path.documentBase.hrefNoHash&&(n=l.hrefNoSearch)),n=e.mobile.path.makeUrlAbsolute(n,e.mobile.getClosestBaseUrl(t)),e.mobile.path.isExternal(n)&&!e.mobile.path.isPermittedCrossDomainRequest(l,n)?!1:(i||(s=t.serializeArray(),h&&h[0].form===t[0]&&(o=h.attr("name"),o&&(e.each(s,function(e,t){return t.name===o?(o="",!1):void 0}),o&&s.push({name:o,value:h.attr("value")}))),r={url:n,options:{type:a,data:e.param(s),transition:t.jqmData("transition"),reverse:"reverse"===t.jqmData("direction"),reloadPage:!0}}),r))};e.mobile.document.delegate("form","submit",function(t){var n;t.isDefaultPrevented()||(n=i(e(this)),n&&(e.mobile.changePage(n.url,n.options),t.preventDefault()))}),e.mobile.document.bind("vclick",function(t){var n,o,a=t.target,r=!1;if(!(t.which>1)&&e.mobile.linkBindingEnabled){if(h=e(a),e.data(a,"mobile-button")){if(!i(e(a).closest("form"),!0))return;a.parentNode&&(a=a.parentNode)}else{if(a=s(a),!a||"#"===e.mobile.path.parseUrl(a.getAttribute("href")||"#").hash)return;if(!e(a).jqmHijackable().length)return}~a.className.indexOf("ui-link-inherit")?a.parentNode&&(o=e.data(a.parentNode,"buttonElements")):o=e.data(a,"buttonElements"),o?a=o.outer:r=!0,n=e(a),r&&(n=n.closest(".ui-btn")),n.length>0&&!n.hasClass("ui-state-disabled")&&(e.mobile.removeActiveLinkClass(!0),e.mobile.activeClickedLink=n,e.mobile.activeClickedLink.addClass(e.mobile.activeBtnClass))}}),e.mobile.document.bind("click",function(i){if(e.mobile.linkBindingEnabled&&!i.isDefaultPrevented()){var o,a,r,h,c,u,d,p=s(i.target),m=e(p),f=function(){t.setTimeout(function(){e.mobile.removeActiveLinkClass(!0)},200)};if(e.mobile.activeClickedLink&&e.mobile.activeClickedLink[0]===i.target.parentNode&&f(),p&&!(i.which>1)&&m.jqmHijackable().length){if(m.is(":jqmData(rel='back')"))return e.mobile.back(),!1;if(o=e.mobile.getClosestBaseUrl(m),a=e.mobile.path.makeUrlAbsolute(m.attr("href")||"#",o),!e.mobile.ajaxEnabled&&!e.mobile.path.isEmbeddedPage(a))return void f();if(!(-1===a.search("#")||e.mobile.path.isExternal(a)&&e.mobile.path.isAbsoluteUrl(a))){if(a=a.replace(/[^#]*#/,""),!a)return void i.preventDefault();a=e.mobile.path.isPath(a)?e.mobile.path.makeUrlAbsolute(a,o):e.mobile.path.makeUrlAbsolute("#"+a,l.hrefNoHash)}if(r=m.is("[rel='external']")||m.is(":jqmData(ajax='false')")||m.is("[target]"),h=r||e.mobile.path.isExternal(a)&&!e.mobile.path.isPermittedCrossDomainRequest(l,a))return void f();c=m.jqmData("transition"),u="reverse"===m.jqmData("direction")||m.jqmData("back"),d=m.attr("data-"+e.mobile.ns+"rel")||n,e.mobile.changePage(a,{transition:c,reverse:u,role:d,link:m}),i.preventDefault()}}}),e.mobile.document.delegate(".ui-page","pageshow.prefetch",function(){var t=[];e(this).find("a:jqmData(prefetch)").each(function(){var i=e(this),n=i.attr("href");n&&-1===e.inArray(n,t)&&(t.push(n),e.mobile.loadPage(n,{role:i.attr("data-"+e.mobile.ns+"rel"),prefetch:!0}))})}),e.mobile.pageContainer.pagecontainer(),e.mobile.document.bind("pageshow",function(){a?a.done(e.mobile.resetActivePageHeight):e.mobile.resetActivePageHeight()}),e.mobile.window.bind("throttledresize",e.mobile.resetActivePageHeight)},e(function(){o.resolve()}),"complete"===i.readyState?r():e.mobile.window.load(r),e.when(o,e.mobile.navreadyDeferred).done(function(){e.mobile._registerInternalEvents()})}(e),function(e){var t="ui-loader",i=e("html");e.widget("mobile.loader",{options:{theme:"a",textVisible:!1,html:"",text:"loading"},defaultHtml:"
",fakeFixLoader:function(){var t=e("."+e.mobile.activeBtnClass).first();this.element.css({top:e.support.scrollTop&&this.window.scrollTop()+this.window.height()/2||t.length&&t.offset().top||100})},checkLoaderPosition:function(){var t=this.element.offset(),i=this.window.scrollTop(),n=e.mobile.getScreenHeight();(t.topn)&&(this.element.addClass("ui-loader-fakefix"),this.fakeFixLoader(),this.window.unbind("scroll",this.checkLoaderPosition).bind("scroll",e.proxy(this.fakeFixLoader,this)))},resetHtml:function(){this.element.html(e(this.defaultHtml).html())},show:function(n,s,o){var a,r,l;this.resetHtml(),"object"===e.type(n)?(l=e.extend({},this.options,n),n=l.theme):(l=this.options,n=n||l.theme),r=s||(l.text===!1?"":l.text),i.addClass("ui-loading"),a=l.textVisible,this.element.attr("class",t+" ui-corner-all ui-body-"+n+" ui-loader-"+(a||s||n.text?"verbose":"default")+(l.textonly||o?" ui-loader-textonly":"")),l.html?this.element.html(l.html):this.element.find("h1").text(r),this.element.appendTo(e(e.mobile.pagecontainer?":mobile-pagecontainer":"body")),this.checkLoaderPosition(),this.window.bind("scroll",e.proxy(this.checkLoaderPosition,this))},hide:function(){i.removeClass("ui-loading"),this.options.text&&this.element.removeClass("ui-loader-fakefix"),this.window.unbind("scroll",this.fakeFixLoader),this.window.unbind("scroll",this.checkLoaderPosition)}})}(e,this),function(e,t,n){function s(){o.removeClass("ui-mobile-rendering")}var o=e("html"),a=e.mobile.window;e(t.document).trigger("mobileinit"),e.mobile.gradeA()&&(e.mobile.ajaxBlacklist&&(e.mobile.ajaxEnabled=!1),o.addClass("ui-mobile ui-mobile-rendering"),setTimeout(s,5e3),e.extend(e.mobile,{initializePage:function(){var t=e.mobile.path,o=e(":jqmData(role='page'), :jqmData(role='dialog')"),r=t.stripHash(t.stripQueryParams(t.parseLocation().hash)),l=e.mobile.path.parseLocation(),h=r?i.getElementById(r):n;o.length||(o=e("body").wrapInner("
").children(0)),o.each(function(){var i=e(this);i[0].getAttribute("data-"+e.mobile.ns+"url")||i.attr("data-"+e.mobile.ns+"url",i.attr("id")||t.convertUrlToDataUrl(l.pathname+l.search))}),e.mobile.firstPage=o.first(),e.mobile.pageContainer=e.mobile.firstPage.parent().addClass("ui-mobile-viewport").pagecontainer(),e.mobile.navreadyDeferred.resolve(),a.trigger("pagecontainercreate"),e.mobile.loading("show"),s(),e.mobile.hashListeningEnabled&&e.mobile.path.isHashValid(location.hash)&&(e(h).is(":jqmData(role='page')")||e.mobile.path.isPath(r)||r===e.mobile.dialogHashKey)?e.event.special.navigate.isPushStateEnabled()?(e.mobile.navigate.history.stack=[],e.mobile.navigate(e.mobile.path.isPath(location.hash)?location.hash:location.href)):a.trigger("hashchange",[!0]):(e.event.special.navigate.isPushStateEnabled()&&e.mobile.navigate.navigator.squash(t.parseLocation().href),e.mobile.changePage(e.mobile.firstPage,{transition:"none",reverse:!0,changeHash:!1,fromHashChange:!0}))}}),e(function(){e.support.inlineSVG(),e.mobile.hideUrlBar&&t.scrollTo(0,1),e.mobile.defaultHomeScroll=e.support.scrollTop&&1!==e.mobile.window.scrollTop()?1:0,e.mobile.autoInitializePage&&e.mobile.initializePage(),e.mobile.hideUrlBar&&a.load(e.mobile.silentScroll),e.support.cssPointerEvents||e.mobile.document.delegate(".ui-state-disabled,.ui-disabled","vclick",function(e){e.preventDefault(),e.stopImmediatePropagation()})}))}(e,this),function(e){e.mobile.links=function(t){e(t).find("a").jqmEnhanceable().filter(":jqmData(rel='popup')[href][href!='']").each(function(){var e=this,t=e.getAttribute("href").substring(1);t&&(e.setAttribute("aria-haspopup",!0),e.setAttribute("aria-owns",t),e.setAttribute("aria-expanded",!1))}).end().not(".ui-btn, :jqmData(role='none'), :jqmData(role='nojs')").addClass("ui-link")}}(e),function(e){e.mobile.nojs=function(t){e(":jqmData(role='nojs')",t).addClass("ui-nojs")}}(e),function(e){var t=e("meta[name=viewport]"),i=t.attr("content"),n=i+",maximum-scale=1, user-scalable=no",s=i+",maximum-scale=10, user-scalable=yes",o=/(user-scalable[\s]*=[\s]*no)|(maximum-scale[\s]*=[\s]*1)[$,\s]/.test(i);e.mobile.zoom=e.extend({},{enabled:!o,locked:!1,disable:function(i){o||e.mobile.zoom.locked||(t.attr("content",n),e.mobile.zoom.enabled=!1,e.mobile.zoom.locked=i||!1)},enable:function(i){o||e.mobile.zoom.locked&&i!==!0||(t.attr("content",s),e.mobile.zoom.enabled=!0,e.mobile.zoom.locked=!1)},restore:function(){o||(t.attr("content",i),e.mobile.zoom.enabled=!0)}})}(e),function(e){e.mobile.transitionFallbacks.pop="fade"}(e,this),function(e){e.mobile.transitionHandlers.slide=e.mobile.transitionHandlers.simultaneous,e.mobile.transitionFallbacks.slide="fade"}(e,this),function(e){e.mobile.transitionFallbacks.slidedown="fade"}(e,this),function(e){e.mobile.transitionFallbacks.slideup="fade"}(e,this),function(e){function t(t){var n,s=t.length,o=[];for(n=0;s>n;n++)t[n].className.match(i)||o.push(t[n]);return e(o)}var i=/\bui-screen-hidden\b/;e.mobile.behaviors.addFirstLastClasses={_getVisibles:function(e,i){var n;return i?n=t(e):(n=e.filter(":visible"),0===n.length&&(n=t(e))),n},_addFirstLastClasses:function(e,t,i){e.removeClass("ui-first-child ui-last-child"),t.eq(0).addClass("ui-first-child").end().last().addClass("ui-last-child"),i||this.element.trigger("updatelayout")},_removeFirstLastClasses:function(e){e.removeClass("ui-first-child ui-last-child")}}}(e),function(e,t){var i=/([A-Z])/g,n=function(e){return"ui-btn-icon-"+(null===e?"left":e)};e.widget("mobile.collapsible",{options:{enhanced:!1,expandCueText:null,collapseCueText:null,collapsed:!0,heading:"h1,h2,h3,h4,h5,h6,legend",collapsedIcon:null,expandedIcon:null,iconpos:null,theme:null,contentTheme:null,inset:null,corners:null,mini:null},_create:function(){var t=this.element,i={accordion:t.closest(":jqmData(role='collapsible-set'),:jqmData(role='collapsibleset')"+(e.mobile.collapsibleset?", :mobile-collapsibleset":"")).addClass("ui-collapsible-set")};this._ui=i,this._renderedOptions=this._getOptions(this.options),this.options.enhanced?(i.heading=this.element.children(".ui-collapsible-heading"),i.content=i.heading.next(),i.anchor=i.heading.children(),i.status=i.anchor.children(".ui-collapsible-heading-status")):this._enhance(t,i),this._on(i.heading,{tap:function(){i.heading.find("a").first().addClass(e.mobile.activeBtnClass)},click:function(e){this._handleExpandCollapse(!i.heading.hasClass("ui-collapsible-heading-collapsed")),e.preventDefault(),e.stopPropagation()}})},_getOptions:function(t){var n,s=this._ui.accordion,o=this._ui.accordionWidget;t=e.extend({},t),s.length&&!o&&(this._ui.accordionWidget=o=s.data("mobile-collapsibleset"));for(n in t)t[n]=null!=t[n]?t[n]:o?o.options[n]:s.length?e.mobile.getAttribute(s[0],n.replace(i,"-$1").toLowerCase()):null,null==t[n]&&(t[n]=e.mobile.collapsible.defaults[n]);return t},_themeClassFromOption:function(e,t){return t?"none"===t?"":e+t:""},_enhance:function(t,i){var s,o=this._renderedOptions,a=this._themeClassFromOption("ui-body-",o.contentTheme);return t.addClass("ui-collapsible "+(o.inset?"ui-collapsible-inset ":"")+(o.inset&&o.corners?"ui-corner-all ":"")+(a?"ui-collapsible-themed-content ":"")),i.originalHeading=t.children(this.options.heading).first(),i.content=t.wrapInner("
").children(".ui-collapsible-content"),i.heading=i.originalHeading,i.heading.is("legend")&&(i.heading=e(""+i.heading.html()+"
"),i.placeholder=e("
").insertBefore(i.originalHeading),i.originalHeading.remove()),s=o.collapsed?o.collapsedIcon?"ui-icon-"+o.collapsedIcon:"":o.expandedIcon?"ui-icon-"+o.expandedIcon:"",i.status=e(" "),i.anchor=i.heading.detach().addClass("ui-collapsible-heading").append(i.status).wrapInner(" ").find("a").first().addClass("ui-btn "+(s?s+" ":"")+(s?n(o.iconpos)+" ":"")+this._themeClassFromOption("ui-btn-",o.theme)+" "+(o.mini?"ui-mini ":"")),i.heading.insertBefore(i.content),this._handleExpandCollapse(this.options.collapsed),i},refresh:function(){this._applyOptions(this.options),this._renderedOptions=this._getOptions(this.options)},_applyOptions:function(e){var i,s,o,a,r,l=this.element,h=this._renderedOptions,c=this._ui,u=c.anchor,d=c.status,p=this._getOptions(e);e.collapsed!==t&&this._handleExpandCollapse(e.collapsed),i=l.hasClass("ui-collapsible-collapsed"),i?p.expandCueText!==t&&d.text(p.expandCueText):p.collapseCueText!==t&&d.text(p.collapseCueText),r=p.collapsedIcon!==t?p.collapsedIcon!==!1:h.collapsedIcon!==!1,(p.iconpos!==t||p.collapsedIcon!==t||p.expandedIcon!==t)&&(u.removeClass([n(h.iconpos)].concat(h.expandedIcon?["ui-icon-"+h.expandedIcon]:[]).concat(h.collapsedIcon?["ui-icon-"+h.collapsedIcon]:[]).join(" ")),r&&u.addClass([n(p.iconpos!==t?p.iconpos:h.iconpos)].concat(i?["ui-icon-"+(p.collapsedIcon!==t?p.collapsedIcon:h.collapsedIcon)]:["ui-icon-"+(p.expandedIcon!==t?p.expandedIcon:h.expandedIcon)]).join(" "))),p.theme!==t&&(o=this._themeClassFromOption("ui-btn-",h.theme),s=this._themeClassFromOption("ui-btn-",p.theme),u.removeClass(o).addClass(s)),p.contentTheme!==t&&(o=this._themeClassFromOption("ui-body-",h.contentTheme),s=this._themeClassFromOption("ui-body-",p.contentTheme),c.content.removeClass(o).addClass(s)),p.inset!==t&&(l.toggleClass("ui-collapsible-inset",p.inset),a=!(!p.inset||!p.corners&&!h.corners)),p.corners!==t&&(a=!(!p.corners||!p.inset&&!h.inset)),a!==t&&l.toggleClass("ui-corner-all",a),p.mini!==t&&u.toggleClass("ui-mini",p.mini)},_setOptions:function(e){this._applyOptions(e),this._super(e),this._renderedOptions=this._getOptions(this.options)},_handleExpandCollapse:function(t){var i=this._renderedOptions,n=this._ui;n.status.text(t?i.expandCueText:i.collapseCueText),n.heading.toggleClass("ui-collapsible-heading-collapsed",t).find("a").first().toggleClass("ui-icon-"+i.expandedIcon,!t).toggleClass("ui-icon-"+i.collapsedIcon,t||i.expandedIcon===i.collapsedIcon).removeClass(e.mobile.activeBtnClass),this.element.toggleClass("ui-collapsible-collapsed",t),n.content.toggleClass("ui-collapsible-content-collapsed",t).attr("aria-hidden",t).trigger("updatelayout"),this.options.collapsed=t,this._trigger(t?"collapse":"expand")},expand:function(){this._handleExpandCollapse(!1)},collapse:function(){this._handleExpandCollapse(!0)},_destroy:function(){var e=this._ui,t=this.options;t.enhanced||(e.placeholder?(e.originalHeading.insertBefore(e.placeholder),e.placeholder.remove(),e.heading.remove()):(e.status.remove(),e.heading.removeClass("ui-collapsible-heading ui-collapsible-heading-collapsed").children().contents().unwrap()),e.anchor.contents().unwrap(),e.content.contents().unwrap(),this.element.removeClass("ui-collapsible ui-collapsible-collapsed ui-collapsible-themed-content ui-collapsible-inset ui-corner-all"))}}),e.mobile.collapsible.defaults={expandCueText:" click to expand contents",collapseCueText:" click to collapse contents",collapsedIcon:"plus",contentTheme:"inherit",expandedIcon:"minus",iconpos:"left",inset:!0,corners:!0,theme:"inherit",mini:!1}}(e),function(e,t){e.widget("mobile.controlgroup",e.extend({options:{enhanced:!1,theme:null,shadow:!1,corners:!0,excludeInvisible:!0,type:"vertical",mini:!1},_create:function(){var t=this.element,i=this.options,n=e.mobile.page.prototype.keepNativeSelector();e.fn.buttonMarkup&&this.element.find(e.fn.buttonMarkup.initSelector).not(n).buttonMarkup(),e.each(this._childWidgets,e.proxy(function(t,i){e.mobile[i]&&this.element.find(e.mobile[i].initSelector).not(n)[i]()},this)),e.extend(this,{_ui:null,_initialRefresh:!0}),this._ui=i.enhanced?{groupLegend:t.children(".ui-controlgroup-label").children(),childWrapper:t.children(".ui-controlgroup-controls")}:this._enhance()},_childWidgets:["checkboxradio","selectmenu","button"],_themeClassFromOption:function(e){return e?"none"===e?"":"ui-group-theme-"+e:""},_enhance:function(){var t=this.element,i=this.options,n={groupLegend:t.children("legend"),childWrapper:t.addClass("ui-controlgroup ui-controlgroup-"+("horizontal"===i.type?"horizontal":"vertical")+" "+this._themeClassFromOption(i.theme)+" "+(i.corners?"ui-corner-all ":"")+(i.mini?"ui-mini ":"")).wrapInner("
").children()};return n.groupLegend.length>0&&e("
").append(n.groupLegend).prependTo(t),n},_init:function(){this.refresh()},_setOptions:function(e){var i,n,s=this.element;return e.type!==t&&(s.removeClass("ui-controlgroup-horizontal ui-controlgroup-vertical").addClass("ui-controlgroup-"+("horizontal"===e.type?"horizontal":"vertical")),i=!0),e.theme!==t&&s.removeClass(this._themeClassFromOption(this.options.theme)).addClass(this._themeClassFromOption(e.theme)),e.corners!==t&&s.toggleClass("ui-corner-all",e.corners),e.mini!==t&&s.toggleClass("ui-mini",e.mini),e.shadow!==t&&this._ui.childWrapper.toggleClass("ui-shadow",e.shadow),e.excludeInvisible!==t&&(this.options.excludeInvisible=e.excludeInvisible,i=!0),n=this._super(e),i&&this.refresh(),n},container:function(){return this._ui.childWrapper},refresh:function(){var t=this.container(),i=t.find(".ui-btn").not(".ui-slider-handle"),n=this._initialRefresh;e.mobile.checkboxradio&&t.find(":mobile-checkboxradio").checkboxradio("refresh"),this._addFirstLastClasses(i,this.options.excludeInvisible?this._getVisibles(i,n):i,n),this._initialRefresh=!1},_destroy:function(){var e,t,i=this.options;return i.enhanced?this:(e=this._ui,t=this.element.removeClass("ui-controlgroup ui-controlgroup-horizontal ui-controlgroup-vertical ui-corner-all ui-mini "+this._themeClassFromOption(i.theme)).find(".ui-btn").not(".ui-slider-handle"),this._removeFirstLastClasses(t),e.groupLegend.unwrap(),void e.childWrapper.children().unwrap())}},e.mobile.behaviors.addFirstLastClasses))}(e),function(e,t,i){e.widget("mobile.dialog",{options:{closeBtn:"left",closeBtnText:"Close",overlayTheme:"a",corners:!0},_handlePageBeforeShow:function(){this._isCloseable=!0,this.options.overlayTheme&&this.element.page("removeContainerBackground").page("setContainerBackground",this.options.overlayTheme)},_handlePageBeforeHide:function(){this._isCloseable=!1},_handleVClickSubmit:function(t){var i,n=e(t.target).closest("vclick"===t.type?"a":"form");n.length&&!n.jqmData("transition")&&(i={},i["data-"+e.mobile.ns+"transition"]=(e.mobile.navigate.history.getActive()||{}).transition||e.mobile.defaultDialogTransition,i["data-"+e.mobile.ns+"direction"]="reverse",n.attr(i))},_create:function(){var t=this.element,i=this.options;t.addClass("ui-dialog").wrapInner(e("
",{role:"dialog","class":"ui-dialog-contain ui-overlay-shadow"+(i.corners?" ui-corner-all":"")})),e.extend(this,{_isCloseable:!1,_inner:t.children(),_headerCloseButton:null}),this._on(t,{vclick:"_handleVClickSubmit",submit:"_handleVClickSubmit",pagebeforeshow:"_handlePageBeforeShow",pagebeforehide:"_handlePageBeforeHide"}),this._setCloseBtn(i.closeBtn)},_setOptions:function(t){var n,s,o=this.options;t.corners!==i&&this._inner.toggleClass("ui-corner-all",!!t.corners),t.overlayTheme!==i&&e.mobile.activePage[0]===this.element[0]&&(o.overlayTheme=t.overlayTheme,this._handlePageBeforeShow()),t.closeBtnText!==i&&(n=o.closeBtn,s=t.closeBtnText),t.closeBtn!==i&&(n=t.closeBtn),n&&this._setCloseBtn(n,s),this._super(t)},_setCloseBtn:function(t,i){var n,s=this._headerCloseButton;t="left"===t?"left":"right"===t?"right":"none","none"===t?s&&(s.remove(),s=null):s?(s.removeClass("ui-btn-left ui-btn-right").addClass("ui-btn-"+t),i&&s.text(i)):(n=this._inner.find(":jqmData(role='header')").first(),s=e(" ",{role:"button",href:"#","class":"ui-btn ui-corner-all ui-icon-delete ui-btn-icon-notext ui-btn-"+t}).text(i||this.options.closeBtnText||"").prependTo(n),this._on(s,{click:"close"})),this._headerCloseButton=s},close:function(){var t=e.mobile.navigate.history;this._isCloseable&&(this._isCloseable=!1,e.mobile.hashListeningEnabled&&t.activeIndex>0?e.mobile.back():e.mobile.pageContainer.pagecontainer("back"))}})}(e,this),function(e,t){e.widget("mobile.textinput",{initSelector:"input[type='text'],input[type='search'],:jqmData(type='search'),input[type='number'],:jqmData(type='number'),input[type='password'],input[type='email'],input[type='url'],input[type='tel'],textarea,input[type='time'],input[type='date'],input[type='month'],input[type='week'],input[type='datetime'],input[type='datetime-local'],input[type='color'],input:not([type]),input[type='file']",options:{theme:null,corners:!0,mini:!1,preventFocusZoom:/iPhone|iPad|iPod/.test(navigator.platform)&&navigator.userAgent.indexOf("AppleWebKit")>-1,wrapperClass:"",enhanced:!1},_create:function(){var t=this.options,i=this.element.is("[type='search'], :jqmData(type='search')"),n="TEXTAREA"===this.element[0].tagName,s=this.element.is("[data-"+(e.mobile.ns||"")+"type='range']"),o=(this.element.is("input")||this.element.is("[data-"+(e.mobile.ns||"")+"type='search']"))&&!s;this.element.prop("disabled")&&(t.disabled=!0),e.extend(this,{classes:this._classesFromOptions(),isSearch:i,isTextarea:n,isRange:s,inputNeedsWrap:o}),this._autoCorrect(),t.enhanced||this._enhance(),this._on({focus:"_handleFocus",blur:"_handleBlur"})},refresh:function(){this.setOptions({disabled:this.element.is(":disabled")})},_enhance:function(){var e=[];this.isTextarea&&e.push("ui-input-text"),(this.isTextarea||this.isRange)&&e.push("ui-shadow-inset"),this.inputNeedsWrap?this.element.wrap(this._wrap()):e=e.concat(this.classes),this.element.addClass(e.join(" "))},widget:function(){return this.inputNeedsWrap?this.element.parent():this.element},_classesFromOptions:function(){var e=this.options,t=[];return t.push("ui-body-"+(null===e.theme?"inherit":e.theme)),e.corners&&t.push("ui-corner-all"),e.mini&&t.push("ui-mini"),e.disabled&&t.push("ui-state-disabled"),e.wrapperClass&&t.push(e.wrapperClass),t},_wrap:function(){return e("
")},_autoCorrect:function(){"undefined"==typeof this.element[0].autocorrect||e.support.touchOverflow||(this.element[0].setAttribute("autocorrect","off"),this.element[0].setAttribute("autocomplete","off"))},_handleBlur:function(){this.widget().removeClass(e.mobile.focusClass),this.options.preventFocusZoom&&e.mobile.zoom.enable(!0)},_handleFocus:function(){this.options.preventFocusZoom&&e.mobile.zoom.disable(!0),this.widget().addClass(e.mobile.focusClass)},_setOptions:function(e){var i=this.widget();this._super(e),(e.disabled!==t||e.mini!==t||e.corners!==t||e.theme!==t||e.wrapperClass!==t)&&(i.removeClass(this.classes.join(" ")),this.classes=this._classesFromOptions(),i.addClass(this.classes.join(" "))),e.disabled!==t&&this.element.prop("disabled",!!e.disabled)},_destroy:function(){this.options.enhanced||(this.inputNeedsWrap&&this.element.unwrap(),this.element.removeClass("ui-input-text "+this.classes.join(" ")))}})}(e),function(e,t){e.widget("mobile.textinput",e.mobile.textinput,{options:{autogrow:!0,keyupTimeoutBuffer:100},_create:function(){this._super(),this.options.autogrow&&this.isTextarea&&this._autogrow()},_autogrow:function(){this.element.addClass("ui-textinput-autogrow"),this._on({keyup:"_timeout",change:"_timeout",input:"_timeout",paste:"_timeout"}),this._on(!0,this.document,{pageshow:"_handleShow",popupbeforeposition:"_handleShow",updatelayout:"_handleShow",panelopen:"_handleShow"})},_handleShow:function(t){e.contains(t.target,this.element[0])&&this.element.is(":visible")&&("popupbeforeposition"!==t.type&&this.element.addClass("ui-textinput-autogrow-resize").animationComplete(e.proxy(function(){this.element.removeClass("ui-textinput-autogrow-resize")},this),"transition"),this._prepareHeightUpdate())},_unbindAutogrow:function(){this.element.removeClass("ui-textinput-autogrow"),this._off(this.element,"keyup change input paste"),this._off(this.document,"pageshow popupbeforeposition updatelayout panelopen")},keyupTimeout:null,_prepareHeightUpdate:function(e){this.keyupTimeout&&clearTimeout(this.keyupTimeout),e===t?this._updateHeight():this.keyupTimeout=this._delay("_updateHeight",e)},_timeout:function(){this._prepareHeightUpdate(this.options.keyupTimeoutBuffer)},_updateHeight:function(){var e,t,i,n,s,o,a,r,l,h=this.window.scrollTop();this.keyupTimeout=0,"onpage"in this.element[0]||this.element.css({height:0,"min-height":0,"max-height":0}),n=this.element[0].scrollHeight,s=this.element[0].clientHeight,o=parseFloat(this.element.css("border-top-width")),a=parseFloat(this.element.css("border-bottom-width")),r=o+a,l=n+r+15,0===s&&(e=parseFloat(this.element.css("padding-top")),t=parseFloat(this.element.css("padding-bottom")),i=e+t,l+=i),this.element.css({height:l,"min-height":"","max-height":""}),this.window.scrollTop(h)},refresh:function(){this.options.autogrow&&this.isTextarea&&this._updateHeight()},_setOptions:function(e){this._super(e),e.autogrow!==t&&this.isTextarea&&(e.autogrow?this._autogrow():this._unbindAutogrow())}})}(e),function(e,t){e.widget("mobile.button",{initSelector:"input[type='button'], input[type='submit'], input[type='reset']",options:{theme:null,icon:null,iconpos:"left",iconshadow:!1,corners:!0,shadow:!0,inline:null,mini:null,wrapperClass:null,enhanced:!1},_create:function(){this.element.is(":disabled")&&(this.options.disabled=!0),this.options.enhanced||this._enhance(),e.extend(this,{wrapper:this.element.parent()}),this._on({focus:function(){this.widget().addClass(e.mobile.focusClass)},blur:function(){this.widget().removeClass(e.mobile.focusClass)}}),this.refresh(!0)},_enhance:function(){this.element.wrap(this._button())},_button:function(){var t=this.options,i=this._getIconClasses(this.options);return e(""+this.element.val()+"
")},widget:function(){return this.wrapper},_destroy:function(){this.element.insertBefore(this.wrapper),this.wrapper.remove()},_getIconClasses:function(e){return e.icon?"ui-icon-"+e.icon+(e.iconshadow?" ui-shadow-icon":"")+" ui-btn-icon-"+e.iconpos:""},_setOptions:function(i){var n=this.widget();i.theme!==t&&n.removeClass(this.options.theme).addClass("ui-btn-"+i.theme),i.corners!==t&&n.toggleClass("ui-corner-all",i.corners),i.shadow!==t&&n.toggleClass("ui-shadow",i.shadow),i.inline!==t&&n.toggleClass("ui-btn-inline",i.inline),i.mini!==t&&n.toggleClass("ui-mini",i.mini),i.disabled!==t&&(this.element.prop("disabled",i.disabled),n.toggleClass("ui-state-disabled",i.disabled)),(i.icon!==t||i.iconshadow!==t||i.iconpos!==t)&&n.removeClass(this._getIconClasses(this.options)).addClass(this._getIconClasses(e.extend({},this.options,i))),this._super(i)},refresh:function(t){var i,n=this.element.prop("disabled");this.options.icon&&"notext"===this.options.iconpos&&this.element.attr("title")&&this.element.attr("title",this.element.val()),t||(i=this.element.detach(),e(this.wrapper).text(this.element.val()).append(i)),this.options.disabled!==n&&this._setOptions({disabled:n})}})}(e),function(e){e.mobile.behaviors.formReset={_handleFormReset:function(){this._on(this.element.closest("form"),{reset:function(){this._delay("_reset")}})}}}(e),function(e,t){var i=e.mobile.path.hashToSelector;e.widget("mobile.checkboxradio",e.extend({initSelector:"input:not( :jqmData(role='flipswitch' ) )[type='checkbox'],input[type='radio']:not( :jqmData(role='flipswitch' ))",options:{theme:"inherit",mini:!1,wrapperClass:null,enhanced:!1,iconpos:"left"},_create:function(){var t=this.element,i=this.options,n=function(e,t){return e.jqmData(t)||e.closest("form, fieldset").jqmData(t)},s=this.options.enhanced?{element:this.element.siblings("label"),isParent:!1}:this._findLabel(),o=t[0].type,a="ui-"+o+"-on",r="ui-"+o+"-off";("checkbox"===o||"radio"===o)&&(this.element[0].disabled&&(this.options.disabled=!0),i.iconpos=n(t,"iconpos")||s.element.attr("data-"+e.mobile.ns+"iconpos")||i.iconpos,i.mini=n(t,"mini")||i.mini,e.extend(this,{input:t,label:s.element,labelIsParent:s.isParent,inputtype:o,checkedClass:a,uncheckedClass:r}),this.options.enhanced||this._enhance(),this._on(s.element,{vmouseover:"_handleLabelVMouseOver",vclick:"_handleLabelVClick"}),this._on(t,{vmousedown:"_cacheVals",vclick:"_handleInputVClick",focus:"_handleInputFocus",blur:"_handleInputBlur"}),this._handleFormReset(),this.refresh())},_findLabel:function(){var t,n,s,o=this.element,a=o[0].labels;return a&&a.length>0?(n=e(a[0]),s=e.contains(n[0],o[0])):(t=o.closest("label"),s=t.length>0,n=s?t:e(this.document[0].getElementsByTagName("label")).filter("[for='"+i(o[0].id)+"']").first()),{element:n,isParent:s}},_enhance:function(){this.label.addClass("ui-btn ui-corner-all"),this.labelIsParent?this.input.add(this.label).wrapAll(this._wrapper()):(this.element.wrap(this._wrapper()),this.element.parent().prepend(this.label)),this._setOptions({theme:this.options.theme,iconpos:this.options.iconpos,mini:this.options.mini})},_wrapper:function(){return e("
")},_handleInputFocus:function(){this.label.addClass(e.mobile.focusClass)
+},_handleInputBlur:function(){this.label.removeClass(e.mobile.focusClass)},_handleInputVClick:function(){this.element.prop("checked",this.element.is(":checked")),this._getInputSet().not(this.element).prop("checked",!1),this._updateAll(!0)},_handleLabelVMouseOver:function(e){this.label.parent().hasClass("ui-state-disabled")&&e.stopPropagation()},_handleLabelVClick:function(e){var t=this.element;return t.is(":disabled")?void e.preventDefault():(this._cacheVals(),t.prop("checked","radio"===this.inputtype&&!0||!t.prop("checked")),t.triggerHandler("click"),this._getInputSet().not(t).prop("checked",!1),this._updateAll(),!1)},_cacheVals:function(){this._getInputSet().each(function(){e(this).attr("data-"+e.mobile.ns+"cacheVal",this.checked)})},_getInputSet:function(){var t,n,s=this.element[0],o=s.name,a=s.form,r=this.element.parents().last().get(0),l=this.element;return o&&"radio"===this.inputtype&&r&&(t="input[type='radio'][name='"+i(o)+"']",a?(n=a.getAttribute("id"),n&&(l=e(t+"[form='"+i(n)+"']",r)),l=e(a).find(t).filter(function(){return this.form===a}).add(l)):l=e(t,r).filter(function(){return!this.form})),l},_updateAll:function(t){var i=this;this._getInputSet().each(function(){var n=e(this);!this.checked&&"checkbox"!==i.inputtype||t||n.trigger("change")}).checkboxradio("refresh")},_reset:function(){this.refresh()},_hasIcon:function(){var t,i,n=e.mobile.controlgroup;return n&&(t=this.element.closest(":mobile-controlgroup,"+n.prototype.initSelector),t.length>0)?(i=e.data(t[0],"mobile-controlgroup"),"horizontal"!==(i?i.options.type:t.attr("data-"+e.mobile.ns+"type"))):!0},refresh:function(){var t=this.element[0].checked,i=e.mobile.activeBtnClass,n="ui-btn-icon-"+this.options.iconpos,s=[],o=[];this._hasIcon()?(o.push(i),s.push(n)):(o.push(n),(t?s:o).push(i)),t?(s.push(this.checkedClass),o.push(this.uncheckedClass)):(s.push(this.uncheckedClass),o.push(this.checkedClass)),this.widget().toggleClass("ui-state-disabled",this.element.prop("disabled")),this.label.addClass(s.join(" ")).removeClass(o.join(" "))},widget:function(){return this.label.parent()},_setOptions:function(e){var i=this.label,n=this.options,s=this.widget(),o=this._hasIcon();e.disabled!==t&&(this.input.prop("disabled",!!e.disabled),s.toggleClass("ui-state-disabled",!!e.disabled)),e.mini!==t&&s.toggleClass("ui-mini",!!e.mini),e.theme!==t&&i.removeClass("ui-btn-"+n.theme).addClass("ui-btn-"+e.theme),e.wrapperClass!==t&&s.removeClass(n.wrapperClass).addClass(e.wrapperClass),e.iconpos!==t&&o?i.removeClass("ui-btn-icon-"+n.iconpos).addClass("ui-btn-icon-"+e.iconpos):o||i.removeClass("ui-btn-icon-"+n.iconpos),this._super(e)}},e.mobile.behaviors.formReset))}(e),function(e,t){e.widget("mobile.textinput",e.mobile.textinput,{options:{clearBtn:!1,clearBtnText:"Clear text"},_create:function(){this._super(),this.isSearch&&(this.options.clearBtn=!0),this.options.clearBtn&&this.inputNeedsWrap&&this._addClearBtn()},clearButton:function(){return e(" ").attr("title",this.options.clearBtnText).text(this.options.clearBtnText)},_clearBtnClick:function(e){this.element.val("").focus().trigger("change"),this._clearBtn.addClass("ui-input-clear-hidden"),e.preventDefault()},_addClearBtn:function(){this.options.enhanced||this._enhanceClear(),e.extend(this,{_clearBtn:this.widget().find("a.ui-input-clear")}),this._bindClearEvents(),this._toggleClear()},_enhanceClear:function(){this.clearButton().appendTo(this.widget()),this.widget().addClass("ui-input-has-clear")},_bindClearEvents:function(){this._on(this._clearBtn,{click:"_clearBtnClick"}),this._on({keyup:"_toggleClear",change:"_toggleClear",input:"_toggleClear",focus:"_toggleClear",blur:"_toggleClear",cut:"_toggleClear",paste:"_toggleClear"})},_unbindClear:function(){this._off(this._clearBtn,"click"),this._off(this.element,"keyup change input focus blur cut paste")},_setOptions:function(e){this._super(e),e.clearBtn===t||this.element.is("textarea, :jqmData(type='range')")||(e.clearBtn?this._addClearBtn():this._destroyClear()),e.clearBtnText!==t&&this._clearBtn!==t&&this._clearBtn.text(e.clearBtnText).attr("title",e.clearBtnText)},_toggleClear:function(){this._delay("_toggleClearClass",0)},_toggleClearClass:function(){this._clearBtn.toggleClass("ui-input-clear-hidden",!this.element.val())},_destroyClear:function(){this.widget().removeClass("ui-input-has-clear"),this._unbindClear(),this._clearBtn.remove()},_destroy:function(){this._super(),this.options.clearBtn&&this._destroyClear()}})}(e),function(e,t){e.widget("mobile.flipswitch",e.extend({options:{onText:"On",offText:"Off",theme:null,enhanced:!1,wrapperClass:null,corners:!0,mini:!1},_create:function(){this.options.enhanced?e.extend(this,{flipswitch:this.element.parent(),on:this.element.find(".ui-flipswitch-on").eq(0),off:this.element.find(".ui-flipswitch-off").eq(0),type:this.element.get(0).tagName}):this._enhance(),this._handleFormReset(),this._originalTabIndex=this.element.attr("tabindex"),null!=this._originalTabIndex&&this.on.attr("tabindex",this._originalTabIndex),this.element.attr("tabindex","-1"),this._on({focus:"_handleInputFocus"}),this.element.is(":disabled")&&this._setOptions({disabled:!0}),this._on(this.flipswitch,{click:"_toggle",swipeleft:"_left",swiperight:"_right"}),this._on(this.on,{keydown:"_keydown"}),this._on({change:"refresh"})},_handleInputFocus:function(){this.on.focus()},widget:function(){return this.flipswitch},_left:function(){this.flipswitch.removeClass("ui-flipswitch-active"),"SELECT"===this.type?this.element.get(0).selectedIndex=0:this.element.prop("checked",!1),this.element.trigger("change")},_right:function(){this.flipswitch.addClass("ui-flipswitch-active"),"SELECT"===this.type?this.element.get(0).selectedIndex=1:this.element.prop("checked",!0),this.element.trigger("change")},_enhance:function(){var t=e(""),i=this.options,n=this.element,s=i.theme?i.theme:"inherit",o=e("
",{href:"#"}),a=e("
"),r=n.get(0).tagName,l="INPUT"===r?i.onText:n.find("option").eq(1).text(),h="INPUT"===r?i.offText:n.find("option").eq(0).text();o.addClass("ui-flipswitch-on ui-btn ui-shadow ui-btn-inherit").text(l),a.addClass("ui-flipswitch-off").text(h),t.addClass("ui-flipswitch ui-shadow-inset ui-bar-"+s+" "+(i.wrapperClass?i.wrapperClass:"")+" "+(n.is(":checked")||n.find("option").eq(1).is(":selected")?"ui-flipswitch-active":"")+(n.is(":disabled")?" ui-state-disabled":"")+(i.corners?" ui-corner-all":"")+(i.mini?" ui-mini":"")).append(o,a),n.addClass("ui-flipswitch-input").after(t).appendTo(t),e.extend(this,{flipswitch:t,on:o,off:a,type:r})},_reset:function(){this.refresh()},refresh:function(){var e,t=this.flipswitch.hasClass("ui-flipswitch-active")?"_right":"_left";e="SELECT"===this.type?this.element.get(0).selectedIndex>0?"_right":"_left":this.element.prop("checked")?"_right":"_left",e!==t&&this[e]()},_toggle:function(){var e=this.flipswitch.hasClass("ui-flipswitch-active")?"_left":"_right";this[e]()},_keydown:function(t){t.which===e.mobile.keyCode.LEFT?this._left():t.which===e.mobile.keyCode.RIGHT?this._right():t.which===e.mobile.keyCode.SPACE&&(this._toggle(),t.preventDefault())},_setOptions:function(e){if(e.theme!==t){var i=e.theme?e.theme:"inherit",n=e.theme?e.theme:"inherit";this.widget().removeClass("ui-bar-"+i).addClass("ui-bar-"+n)}e.onText!==t&&this.on.text(e.onText),e.offText!==t&&this.off.text(e.offText),e.disabled!==t&&this.widget().toggleClass("ui-state-disabled",e.disabled),e.mini!==t&&this.widget().toggleClass("ui-mini",e.mini),e.corners!==t&&this.widget().toggleClass("ui-corner-all",e.corners),this._super(e)},_destroy:function(){this.options.enhanced||(null!=this._originalTabIndex?this.element.attr("tabindex",this._originalTabIndex):this.element.removeAttr("tabindex"),this.on.remove(),this.off.remove(),this.element.unwrap(),this.flipswitch.remove(),this.removeClass("ui-flipswitch-input"))}},e.mobile.behaviors.formReset))}(e),function(e,n){e.widget("mobile.slider",e.extend({initSelector:"input[type='range'], :jqmData(type='range'), :jqmData(role='slider')",widgetEventPrefix:"slide",options:{theme:null,trackTheme:null,corners:!0,mini:!1,highlight:!1},_create:function(){var s,o,a,r,l,h,c,u,d,p,m=this,f=this.element,g=this.options.trackTheme||e.mobile.getAttribute(f[0],"theme"),b=g?" ui-bar-"+g:" ui-bar-inherit",v=this.options.corners||f.jqmData("corners")?" ui-corner-all":"",_=this.options.mini||f.jqmData("mini")?" ui-mini":"",C=f[0].nodeName.toLowerCase(),w="select"===C,y=f.parent().is(":jqmData(role='rangeslider')"),x=w?"ui-slider-switch":"",T=f.attr("id"),k=e("[for='"+T+"']"),P=k.attr("id")||T+"-label",D=w?0:parseFloat(f.attr("min")),E=w?f.find("option").length-1:parseFloat(f.attr("max")),S=t.parseFloat(f.attr("step")||1),B=i.createElement("a"),I=e(B),O=i.createElement("div"),A=e(O),N=this.options.highlight&&!w?function(){var t=i.createElement("div");return t.className="ui-slider-bg "+e.mobile.activeBtnClass,e(t).prependTo(A)}():!1;if(k.attr("id",P),this.isToggleSwitch=w,B.setAttribute("href","#"),O.setAttribute("role","application"),O.className=[this.isToggleSwitch?"ui-slider ui-slider-track ui-shadow-inset ":"ui-slider-track ui-shadow-inset ",x,b,v,_].join(""),B.className="ui-slider-handle",O.appendChild(B),I.attr({role:"slider","aria-valuemin":D,"aria-valuemax":E,"aria-valuenow":this._value(),"aria-valuetext":this._value(),title:this._value(),"aria-labelledby":P}),e.extend(this,{slider:A,handle:I,control:f,type:C,step:S,max:E,min:D,valuebg:N,isRangeslider:y,dragging:!1,beforeStart:null,userModified:!1,mouseMoved:!1}),w){for(c=f.attr("tabindex"),c&&I.attr("tabindex",c),f.attr("tabindex","-1").focus(function(){e(this).blur(),I.focus()}),o=i.createElement("div"),o.className="ui-slider-inneroffset",a=0,r=O.childNodes.length;r>a;a++)o.appendChild(O.childNodes[a]);for(O.appendChild(o),I.addClass("ui-slider-handle-snapping"),s=f.find("option"),l=0,h=s.length;h>l;l++)u=l?"a":"b",d=l?" "+e.mobile.activeBtnClass:"",p=i.createElement("span"),p.className=["ui-slider-label ui-slider-label-",u,d].join(""),p.setAttribute("role","img"),p.appendChild(i.createTextNode(s[l].innerHTML)),e(p).prependTo(A);m._labels=e(".ui-slider-label",A)}f.addClass(w?"ui-slider-switch":"ui-slider-input"),this._on(f,{change:"_controlChange",keyup:"_controlKeyup",blur:"_controlBlur",vmouseup:"_controlVMouseUp"}),A.bind("vmousedown",e.proxy(this._sliderVMouseDown,this)).bind("vclick",!1),this._on(i,{vmousemove:"_preventDocumentDrag"}),this._on(A.add(i),{vmouseup:"_sliderVMouseUp"}),A.insertAfter(f),w||y||(o=this.options.mini?"
":"
",f.add(A).wrapAll(o)),this._on(this.handle,{vmousedown:"_handleVMouseDown",keydown:"_handleKeydown",keyup:"_handleKeyup"}),this.handle.bind("vclick",!1),this._handleFormReset(),this.refresh(n,n,!0)},_setOptions:function(e){e.theme!==n&&this._setTheme(e.theme),e.trackTheme!==n&&this._setTrackTheme(e.trackTheme),e.corners!==n&&this._setCorners(e.corners),e.mini!==n&&this._setMini(e.mini),e.highlight!==n&&this._setHighlight(e.highlight),e.disabled!==n&&this._setDisabled(e.disabled),this._super(e)},_controlChange:function(e){return this._trigger("controlchange",e)===!1?!1:void(this.mouseMoved||this.refresh(this._value(),!0))},_controlKeyup:function(){this.refresh(this._value(),!0,!0)},_controlBlur:function(){this.refresh(this._value(),!0)},_controlVMouseUp:function(){this._checkedRefresh()},_handleVMouseDown:function(){this.handle.focus()},_handleKeydown:function(t){var i=this._value();if(!this.options.disabled){switch(t.keyCode){case e.mobile.keyCode.HOME:case e.mobile.keyCode.END:case e.mobile.keyCode.PAGE_UP:case e.mobile.keyCode.PAGE_DOWN:case e.mobile.keyCode.UP:case e.mobile.keyCode.RIGHT:case e.mobile.keyCode.DOWN:case e.mobile.keyCode.LEFT:t.preventDefault(),this._keySliding||(this._keySliding=!0,this.handle.addClass("ui-state-active"))}switch(t.keyCode){case e.mobile.keyCode.HOME:this.refresh(this.min);break;case e.mobile.keyCode.END:this.refresh(this.max);break;case e.mobile.keyCode.PAGE_UP:case e.mobile.keyCode.UP:case e.mobile.keyCode.RIGHT:this.refresh(i+this.step);break;case e.mobile.keyCode.PAGE_DOWN:case e.mobile.keyCode.DOWN:case e.mobile.keyCode.LEFT:this.refresh(i-this.step)}}},_handleKeyup:function(){this._keySliding&&(this._keySliding=!1,this.handle.removeClass("ui-state-active"))},_sliderVMouseDown:function(e){return this.options.disabled||1!==e.which&&0!==e.which&&e.which!==n?!1:this._trigger("beforestart",e)===!1?!1:(this.dragging=!0,this.userModified=!1,this.mouseMoved=!1,this.isToggleSwitch&&(this.beforeStart=this.element[0].selectedIndex),this.refresh(e),this._trigger("start"),!1)},_sliderVMouseUp:function(){return this.dragging?(this.dragging=!1,this.isToggleSwitch&&(this.handle.addClass("ui-slider-handle-snapping"),this.refresh(this.mouseMoved?this.userModified?0===this.beforeStart?1:0:this.beforeStart:0===this.beforeStart?1:0)),this.mouseMoved=!1,this._trigger("stop"),!1):void 0},_preventDocumentDrag:function(e){return this._trigger("drag",e)===!1?!1:this.dragging&&!this.options.disabled?(this.mouseMoved=!0,this.isToggleSwitch&&this.handle.removeClass("ui-slider-handle-snapping"),this.refresh(e),this.userModified=this.beforeStart!==this.element[0].selectedIndex,!1):void 0},_checkedRefresh:function(){this.value!==this._value()&&this.refresh(this._value())},_value:function(){return this.isToggleSwitch?this.element[0].selectedIndex:parseFloat(this.element.val())},_reset:function(){this.refresh(n,!1,!0)},refresh:function(t,n,s){var o,a,r,l,h,c,u,d,p,m,f,g,b,v,_,C,w,y,x,T,k=this,P=e.mobile.getAttribute(this.element[0],"theme"),D=this.options.theme||P,E=D?" ui-btn-"+D:"",S=this.options.trackTheme||P,B=S?" ui-bar-"+S:" ui-bar-inherit",I=this.options.corners?" ui-corner-all":"",O=this.options.mini?" ui-mini":"";if(k.slider[0].className=[this.isToggleSwitch?"ui-slider ui-slider-switch ui-slider-track ui-shadow-inset":"ui-slider-track ui-shadow-inset",B,I,O].join(""),(this.options.disabled||this.element.prop("disabled"))&&this.disable(),this.value=this._value(),this.options.highlight&&!this.isToggleSwitch&&0===this.slider.find(".ui-slider-bg").length&&(this.valuebg=function(){var t=i.createElement("div");return t.className="ui-slider-bg "+e.mobile.activeBtnClass,e(t).prependTo(k.slider)}()),this.handle.addClass("ui-btn"+E+" ui-shadow"),u=this.element,d=!this.isToggleSwitch,p=d?[]:u.find("option"),m=d?parseFloat(u.attr("min")):0,f=d?parseFloat(u.attr("max")):p.length-1,g=d&&parseFloat(u.attr("step"))>0?parseFloat(u.attr("step")):1,"object"==typeof t){if(r=t,l=8,o=this.slider.offset().left,a=this.slider.width(),h=a/((f-m)/g),!this.dragging||r.pageX
o+a+l)return;c=h>1?(r.pageX-o)/a*100:Math.round((r.pageX-o)/a*100)}else null==t&&(t=d?parseFloat(u.val()||0):u[0].selectedIndex),c=(parseFloat(t)-m)/(f-m)*100;if(!isNaN(c)&&(b=c/100*(f-m)+m,v=(b-m)%g,_=b-v,2*Math.abs(v)>=g&&(_+=v>0?g:-g),C=100/((f-m)/g),b=parseFloat(_.toFixed(5)),"undefined"==typeof h&&(h=a/((f-m)/g)),h>1&&d&&(c=(b-m)*C*(1/g)),0>c&&(c=0),c>100&&(c=100),m>b&&(b=m),b>f&&(b=f),this.handle.css("left",c+"%"),this.handle[0].setAttribute("aria-valuenow",d?b:p.eq(b).attr("value")),this.handle[0].setAttribute("aria-valuetext",d?b:p.eq(b).getEncodedText()),this.handle[0].setAttribute("title",d?b:p.eq(b).getEncodedText()),this.valuebg&&this.valuebg.css("width",c+"%"),this._labels&&(w=this.handle.width()/this.slider.width()*100,y=c&&w+(100-w)*c/100,x=100===c?0:Math.min(w+100-y,100),this._labels.each(function(){var t=e(this).hasClass("ui-slider-label-a");e(this).width((t?y:x)+"%")})),!s)){if(T=!1,d?(T=parseFloat(u.val())!==b,u.val(b)):(T=u[0].selectedIndex!==b,u[0].selectedIndex=b),this._trigger("beforechange",t)===!1)return!1;!n&&T&&u.trigger("change")}},_setHighlight:function(e){e=!!e,e?(this.options.highlight=!!e,this.refresh()):this.valuebg&&(this.valuebg.remove(),this.valuebg=!1)},_setTheme:function(e){this.handle.removeClass("ui-btn-"+this.options.theme).addClass("ui-btn-"+e);var t=this.options.theme?this.options.theme:"inherit",i=e?e:"inherit";this.control.removeClass("ui-body-"+t).addClass("ui-body-"+i)},_setTrackTheme:function(e){var t=this.options.trackTheme?this.options.trackTheme:"inherit",i=e?e:"inherit";this.slider.removeClass("ui-body-"+t).addClass("ui-body-"+i)},_setMini:function(e){e=!!e,this.isToggleSwitch||this.isRangeslider||(this.slider.parent().toggleClass("ui-mini",e),this.element.toggleClass("ui-mini",e)),this.slider.toggleClass("ui-mini",e)},_setCorners:function(e){this.slider.toggleClass("ui-corner-all",e),this.isToggleSwitch||this.control.toggleClass("ui-corner-all",e)},_setDisabled:function(e){e=!!e,this.element.prop("disabled",e),this.slider.toggleClass("ui-state-disabled",e).attr("aria-disabled",e),this.element.toggleClass("ui-state-disabled",e)}},e.mobile.behaviors.formReset))}(e),function(e,t){e.widget("mobile.rangeslider",e.extend({options:{theme:null,trackTheme:null,corners:!0,mini:!1,highlight:!0},_create:function(){var t=this.element,i=this.options.mini?"ui-rangeslider ui-mini":"ui-rangeslider",n=t.find("input").first(),s=t.find("input").last(),o=t.find("label").first(),a=e.data(n.get(0),"mobile-slider")||e.data(n.slider().get(0),"mobile-slider"),r=e.data(s.get(0),"mobile-slider")||e.data(s.slider().get(0),"mobile-slider"),l=a.slider,h=r.slider,c=a.handle,u=e("
").appendTo(t);n.addClass("ui-rangeslider-first"),s.addClass("ui-rangeslider-last"),t.addClass(i),l.appendTo(u),h.appendTo(u),o.insertBefore(t),c.prependTo(h),e.extend(this,{_inputFirst:n,_inputLast:s,_sliderFirst:l,_sliderLast:h,_label:o,_targetVal:null,_sliderTarget:!1,_sliders:u,_proxy:!1}),this.refresh(),this._on(this.element.find("input.ui-slider-input"),{slidebeforestart:"_slidebeforestart",slidestop:"_slidestop",slidedrag:"_slidedrag",slidebeforechange:"_change",blur:"_change",keyup:"_change"}),this._on({mousedown:"_change"}),this._on(this.element.closest("form"),{reset:"_handleReset"}),this._on(c,{vmousedown:"_dragFirstHandle"})},_handleReset:function(){var e=this;setTimeout(function(){e._updateHighlight()},0)},_dragFirstHandle:function(t){return e.data(this._inputFirst.get(0),"mobile-slider").dragging=!0,e.data(this._inputFirst.get(0),"mobile-slider").refresh(t),e.data(this._inputFirst.get(0),"mobile-slider")._trigger("start"),!1},_slidedrag:function(t){var i=e(t.target).is(this._inputFirst),n=i?this._inputLast:this._inputFirst;return this._sliderTarget=!1,"first"===this._proxy&&i||"last"===this._proxy&&!i?(e.data(n.get(0),"mobile-slider").dragging=!0,e.data(n.get(0),"mobile-slider").refresh(t),!1):void 0},_slidestop:function(t){var i=e(t.target).is(this._inputFirst);this._proxy=!1,this.element.find("input").trigger("vmouseup"),this._sliderFirst.css("z-index",i?1:"")},_slidebeforestart:function(t){this._sliderTarget=!1,e(t.originalEvent.target).hasClass("ui-slider-track")&&(this._sliderTarget=!0,this._targetVal=e(t.target).val())},_setOptions:function(e){e.theme!==t&&this._setTheme(e.theme),e.trackTheme!==t&&this._setTrackTheme(e.trackTheme),e.mini!==t&&this._setMini(e.mini),e.highlight!==t&&this._setHighlight(e.highlight),e.disabled!==t&&this._setDisabled(e.disabled),this._super(e),this.refresh()},refresh:function(){var e=this.element,t=this.options;(this._inputFirst.is(":disabled")||this._inputLast.is(":disabled"))&&(this.options.disabled=!0),e.find("input").slider({theme:t.theme,trackTheme:t.trackTheme,disabled:t.disabled,corners:t.corners,mini:t.mini,highlight:t.highlight}).slider("refresh"),this._updateHighlight()},_change:function(t){if("keyup"===t.type)return this._updateHighlight(),!1;var i=this,n=parseFloat(this._inputFirst.val(),10),s=parseFloat(this._inputLast.val(),10),o=e(t.target).hasClass("ui-rangeslider-first"),a=o?this._inputFirst:this._inputLast,r=o?this._inputLast:this._inputFirst;if(this._inputFirst.val()>this._inputLast.val()&&"mousedown"===t.type&&!e(t.target).hasClass("ui-slider-handle"))a.blur();else if("mousedown"===t.type)return;return n>s&&!this._sliderTarget?(a.val(o?s:n).slider("refresh"),this._trigger("normalize")):n>s&&(a.val(this._targetVal).slider("refresh"),setTimeout(function(){r.val(o?n:s).slider("refresh"),e.data(r.get(0),"mobile-slider").handle.focus(),i._sliderFirst.css("z-index",o?"":1),i._trigger("normalize")},0),this._proxy=o?"first":"last"),n===s?(e.data(a.get(0),"mobile-slider").handle.css("z-index",1),e.data(r.get(0),"mobile-slider").handle.css("z-index",0)):(e.data(r.get(0),"mobile-slider").handle.css("z-index",""),e.data(a.get(0),"mobile-slider").handle.css("z-index","")),this._updateHighlight(),n>=s?!1:void 0},_updateHighlight:function(){var t=parseInt(e.data(this._inputFirst.get(0),"mobile-slider").handle.get(0).style.left,10),i=parseInt(e.data(this._inputLast.get(0),"mobile-slider").handle.get(0).style.left,10),n=i-t;this.element.find(".ui-slider-bg").css({"margin-left":t+"%",width:n+"%"})},_setTheme:function(e){this._inputFirst.slider("option","theme",e),this._inputLast.slider("option","theme",e)},_setTrackTheme:function(e){this._inputFirst.slider("option","trackTheme",e),this._inputLast.slider("option","trackTheme",e)},_setMini:function(e){this._inputFirst.slider("option","mini",e),this._inputLast.slider("option","mini",e),this.element.toggleClass("ui-mini",!!e)},_setHighlight:function(e){this._inputFirst.slider("option","highlight",e),this._inputLast.slider("option","highlight",e)},_setDisabled:function(e){this._inputFirst.prop("disabled",e),this._inputLast.prop("disabled",e)},_destroy:function(){this._label.prependTo(this.element),this.element.removeClass("ui-rangeslider ui-mini"),this._inputFirst.after(this._sliderFirst),this._inputLast.after(this._sliderLast),this._sliders.remove(),this.element.find("input").removeClass("ui-rangeslider-first ui-rangeslider-last").slider("destroy")}},e.mobile.behaviors.formReset))}(e),function(e){e.widget("mobile.selectmenu",e.extend({initSelector:"select:not( :jqmData(role='slider')):not( :jqmData(role='flipswitch') )",options:{theme:null,icon:"carat-d",iconpos:"right",inline:!1,corners:!0,shadow:!0,iconshadow:!1,overlayTheme:null,dividerTheme:null,hidePlaceholderMenuItems:!0,closeText:"Close",nativeMenu:!0,preventFocusZoom:/iPhone|iPad|iPod/.test(navigator.platform)&&navigator.userAgent.indexOf("AppleWebKit")>-1,mini:!1},_button:function(){return e("
")},_setDisabled:function(e){return this.element.attr("disabled",e),this.button.attr("aria-disabled",e),this._setOption("disabled",e)},_focusButton:function(){var e=this;setTimeout(function(){e.button.focus()},40)},_selectOptions:function(){return this.select.find("option")},_preExtension:function(){var t=this.options.inline||this.element.jqmData("inline"),i=this.options.mini||this.element.jqmData("mini"),n="";~this.element[0].className.indexOf("ui-btn-left")&&(n=" ui-btn-left"),~this.element[0].className.indexOf("ui-btn-right")&&(n=" ui-btn-right"),t&&(n+=" ui-btn-inline"),i&&(n+=" ui-mini"),this.select=this.element.removeClass("ui-btn-left ui-btn-right").wrap(""),this.selectId=this.select.attr("id")||"select-"+this.uuid,this.buttonId=this.selectId+"-button",this.label=e("label[for='"+this.selectId+"']"),this.isMultiple=this.select[0].multiple},_destroy:function(){var e=this.element.parents(".ui-select");e.length>0&&(e.is(".ui-btn-left, .ui-btn-right")&&this.element.addClass(e.hasClass("ui-btn-left")?"ui-btn-left":"ui-btn-right"),this.element.insertAfter(e),e.remove())},_create:function(){this._preExtension(),this.button=this._button();var i=this,n=this.options,s=n.icon?n.iconpos||this.select.jqmData("iconpos"):!1,o=this.button.insertBefore(this.select).attr("id",this.buttonId).addClass("ui-btn"+(n.icon?" ui-icon-"+n.icon+" ui-btn-icon-"+s+(n.iconshadow?" ui-shadow-icon":""):"")+(n.theme?" ui-btn-"+n.theme:"")+(n.corners?" ui-corner-all":"")+(n.shadow?" ui-shadow":""));this.setButtonText(),n.nativeMenu&&t.opera&&t.opera.version&&o.addClass("ui-select-nativeonly"),this.isMultiple&&(this.buttonCount=e("
").addClass("ui-li-count ui-body-inherit").hide().appendTo(o.addClass("ui-li-has-count"))),(n.disabled||this.element.attr("disabled"))&&this.disable(),this.select.change(function(){i.refresh(),n.nativeMenu&&i._delay(function(){i.select.blur()})}),this._handleFormReset(),this._on(this.button,{keydown:"_handleKeydown"}),this.build()},build:function(){var t=this;this.select.appendTo(t.button).bind("vmousedown",function(){t.button.addClass(e.mobile.activeBtnClass)}).bind("focus",function(){t.button.addClass(e.mobile.focusClass)}).bind("blur",function(){t.button.removeClass(e.mobile.focusClass)}).bind("focus vmouseover",function(){t.button.trigger("vmouseover")}).bind("vmousemove",function(){t.button.removeClass(e.mobile.activeBtnClass)}).bind("change blur vmouseout",function(){t.button.trigger("vmouseout").removeClass(e.mobile.activeBtnClass)}),t.button.bind("vmousedown",function(){t.options.preventFocusZoom&&e.mobile.zoom.disable(!0)}),t.label.bind("click focus",function(){t.options.preventFocusZoom&&e.mobile.zoom.disable(!0)}),t.select.bind("focus",function(){t.options.preventFocusZoom&&e.mobile.zoom.disable(!0)}),t.button.bind("mouseup",function(){t.options.preventFocusZoom&&setTimeout(function(){e.mobile.zoom.enable(!0)},0)}),t.select.bind("blur",function(){t.options.preventFocusZoom&&e.mobile.zoom.enable(!0)})},selected:function(){return this._selectOptions().filter(":selected")},selectedIndices:function(){var e=this;return this.selected().map(function(){return e._selectOptions().index(this)}).get()},setButtonText:function(){var t=this,n=this.selected(),s=this.placeholder,o=e(i.createElement("span"));this.button.children("span").not(".ui-li-count").remove().end().end().prepend(function(){return s=n.length?n.map(function(){return e(this).text()}).get().join(", "):t.placeholder,s?o.text(s):o.html(" "),o.addClass(t.select.attr("class")).addClass(n.attr("class")).removeClass("ui-screen-hidden")}())},setButtonCount:function(){var e=this.selected();this.isMultiple&&this.buttonCount[e.length>1?"show":"hide"]().text(e.length)},_handleKeydown:function(){this._delay("_refreshButton")},_reset:function(){this.refresh()},_refreshButton:function(){this.setButtonText(),this.setButtonCount()},refresh:function(){this._refreshButton()},open:e.noop,close:e.noop,disable:function(){this._setDisabled(!0),this.button.addClass("ui-state-disabled")},enable:function(){this._setDisabled(!1),this.button.removeClass("ui-state-disabled")}},e.mobile.behaviors.formReset))}(e),function(e){function t(){return i||(i=e("
",{"class":"ui-slider-popup ui-shadow ui-corner-all"})),i.clone()}var i;e.widget("mobile.slider",e.mobile.slider,{options:{popupEnabled:!1,showValue:!1},_create:function(){this._super(),e.extend(this,{_currentValue:null,_popup:null,_popupVisible:!1}),this._setOption("popupEnabled",this.options.popupEnabled),this._on(this.handle,{vmousedown:"_showPopup"}),this._on(this.slider.add(this.document),{vmouseup:"_hidePopup"}),this._refresh()},_positionPopup:function(){var e=this.handle.offset();this._popup.offset({left:e.left+(this.handle.width()-this._popup.width())/2,top:e.top-this._popup.outerHeight()-5})},_setOption:function(e,i){this._super(e,i),"showValue"===e?this.handle.html(i&&!this.options.mini?this._value():""):"popupEnabled"===e&&i&&!this._popup&&(this._popup=t().addClass("ui-body-"+(this.options.theme||"a")).hide().insertBefore(this.element))},refresh:function(){this._super.apply(this,arguments),this._refresh()},_refresh:function(){var e,t=this.options;t.popupEnabled&&this.handle.removeAttr("title"),e=this._value(),e!==this._currentValue&&(this._currentValue=e,t.popupEnabled&&this._popup&&(this._positionPopup(),this._popup.html(e)),t.showValue&&!this.options.mini&&this.handle.html(e))},_showPopup:function(){this.options.popupEnabled&&!this._popupVisible&&(this.handle.html(""),this._popup.show(),this._positionPopup(),this._popupVisible=!0)},_hidePopup:function(){var e=this.options;e.popupEnabled&&this._popupVisible&&(e.showValue&&!e.mini&&this.handle.html(this._value()),this._popup.hide(),this._popupVisible=!1)}})}(e),function(e){var t=e.mobile.getAttribute;e.widget("mobile.listview",e.extend({options:{theme:null,countTheme:null,dividerTheme:null,icon:"carat-r",splitIcon:"carat-r",splitTheme:null,corners:!0,shadow:!0,inset:!1},_create:function(){var e=this,t="";t+=e.options.inset?" ui-listview-inset":"",e.options.inset&&(t+=e.options.corners?" ui-corner-all":"",t+=e.options.shadow?" ui-shadow":""),e.element.addClass(" ui-listview"+t),e.refresh(!0)},_findFirstElementByTagName:function(e,t,i,n){var s={};for(s[i]=s[n]=!0;e;){if(s[e.nodeName])return e;e=e[t]}return null},_addThumbClasses:function(t){var i,n,s=t.length;for(i=0;s>i;i++)n=e(this._findFirstElementByTagName(t[i].firstChild,"nextSibling","img","IMG")),n.length&&e(this._findFirstElementByTagName(n[0].parentNode,"parentNode","li","LI")).addClass(n.hasClass("ui-li-icon")?"ui-li-has-icon":"ui-li-has-thumb")},_getChildrenByTagName:function(t,i,n){var s=[],o={};for(o[i]=o[n]=!0,t=t.firstChild;t;)o[t.nodeName]&&s.push(t),t=t.nextSibling;return e(s)},_beforeListviewRefresh:e.noop,_afterListviewRefresh:e.noop,refresh:function(i){var n,s,o,a,r,l,h,c,u,d,p,m,f,g,b,v,_,C,w,y,x=this.options,T=this.element,k=!!e.nodeName(T[0],"ol"),P=T.attr("start"),D={},E=T.find(".ui-li-count"),S=t(T[0],"counttheme")||this.options.countTheme,B=S?"ui-body-"+S:"ui-body-inherit";for(x.theme&&T.addClass("ui-group-theme-"+x.theme),k&&(P||0===P)&&(p=parseInt(P,10)-1,T.css("counter-reset","listnumbering "+p)),this._beforeListviewRefresh(),y=this._getChildrenByTagName(T[0],"li","LI"),s=0,o=y.length;o>s;s++)a=y.eq(s),r="",(i||a[0].className.search(/\bui-li-static\b|\bui-li-divider\b/)<0)&&(u=this._getChildrenByTagName(a[0],"a","A"),d="list-divider"===t(a[0],"role"),f=a.attr("value"),l=t(a[0],"theme"),u.length&&u[0].className.search(/\bui-btn\b/)<0&&!d?(h=t(a[0],"icon"),c=h===!1?!1:h||x.icon,u.removeClass("ui-link"),n="ui-btn",l&&(n+=" ui-btn-"+l),u.length>1?(r="ui-li-has-alt",g=u.last(),b=t(g[0],"theme")||x.splitTheme||t(a[0],"theme",!0),v=b?" ui-btn-"+b:"",_=t(g[0],"icon")||t(a[0],"icon")||x.splitIcon,C="ui-btn ui-btn-icon-notext ui-icon-"+_+v,g.attr("title",e.trim(g.getEncodedText())).addClass(C).empty(),u=u.first()):c&&(n+=" ui-btn-icon-right ui-icon-"+c),u.addClass(n)):d?(w=t(a[0],"theme")||x.dividerTheme||x.theme,r="ui-li-divider ui-bar-"+(w?w:"inherit"),a.attr("role","heading")):u.length<=0&&(r="ui-li-static ui-body-"+(l?l:"inherit")),k&&f&&(m=parseInt(f,10)-1,a.css("counter-reset","listnumbering "+m))),D[r]||(D[r]=[]),D[r].push(a[0]);for(r in D)e(D[r]).addClass(r);E.each(function(){e(this).closest("li").addClass("ui-li-has-count")}),B&&E.not("[class*='ui-body-']").addClass(B),this._addThumbClasses(y),this._addThumbClasses(y.find(".ui-btn")),this._afterListviewRefresh(),this._addFirstLastClasses(y,this._getVisibles(y,i),i)}},e.mobile.behaviors.addFirstLastClasses))}(e),function(e){function t(t){var i=e.trim(t.text())||null;return i?i=i.slice(0,1).toUpperCase():null}e.widget("mobile.listview",e.mobile.listview,{options:{autodividers:!1,autodividersSelector:t},_beforeListviewRefresh:function(){this.options.autodividers&&(this._replaceDividers(),this._superApply(arguments))},_replaceDividers:function(){var t,n,s,o,a,r=null,l=this.element;for(l.children("li:jqmData(role='list-divider')").remove(),n=l.children("li"),t=0;t-1;n--)s=e[n],s.className.match(t)?(o&&(s.className=s.className+" ui-screen-hidden"),o=!0):s.className.match(i)||(o=!1)
+}})}(e),function(e,t){e.widget("mobile.navbar",{options:{iconpos:"top",grid:null},_create:function(){var n=this.element,s=n.find("a, button"),o=s.filter(":jqmData(icon)").length?this.options.iconpos:t;n.addClass("ui-navbar").attr("role","navigation").find("ul").jqmEnhanceable().grid({grid:this.options.grid}),s.each(function(){var t=e.mobile.getAttribute(this,"icon"),i=e.mobile.getAttribute(this,"theme"),n="ui-btn";i&&(n+=" ui-btn-"+i),t&&(n+=" ui-icon-"+t+" ui-btn-icon-"+o),e(this).addClass(n)}),n.delegate("a","vclick",function(){var t=e(this);t.hasClass("ui-state-disabled")||t.hasClass("ui-disabled")||t.hasClass(e.mobile.activeBtnClass)||(s.removeClass(e.mobile.activeBtnClass),t.addClass(e.mobile.activeBtnClass),e(i).one("pagehide",function(){t.removeClass(e.mobile.activeBtnClass)}))}),n.closest(".ui-page").bind("pagebeforeshow",function(){s.filter(".ui-state-persist").addClass(e.mobile.activeBtnClass)})}})}(e),function(e,t,i){e.widget("mobile.page",e.mobile.page,{options:{closeBtn:"left",closeBtnText:"Close",overlayTheme:"a",corners:!0,dialog:!1},_create:function(){this._super(),this.options.dialog&&(e.extend(this,{_inner:this.element.children(),_headerCloseButton:null}),this.options.enhanced||this._setCloseBtn(this.options.closeBtn))},_enhance:function(){this._super(),this.options.dialog&&this.element.addClass("ui-dialog").wrapInner(e("
",{role:"dialog","class":"ui-dialog-contain ui-overlay-shadow"+(this.options.corners?" ui-corner-all":"")}))},_setOptions:function(t){var n,s,o=this.options;t.corners!==i&&this._inner.toggleClass("ui-corner-all",!!t.corners),t.overlayTheme!==i&&e.mobile.activePage[0]===this.element[0]&&(o.overlayTheme=t.overlayTheme,this._handlePageBeforeShow()),t.closeBtnText!==i&&(n=o.closeBtn,s=t.closeBtnText),t.closeBtn!==i&&(n=t.closeBtn),n&&this._setCloseBtn(n,s),this._super(t)},_handlePageBeforeShow:function(){this.options.overlayTheme&&this.options.dialog?(this.removeContainerBackground(),this.setContainerBackground(this.options.overlayTheme)):this._super()},_setCloseBtn:function(t,i){var n,s=this._headerCloseButton;t="left"===t?"left":"right"===t?"right":"none","none"===t?s&&(s.remove(),s=null):s?(s.removeClass("ui-btn-left ui-btn-right").addClass("ui-btn-"+t),i&&s.text(i)):(n=this._inner.find(":jqmData(role='header')").first(),s=e(" ",{href:"#","class":"ui-btn ui-corner-all ui-icon-delete ui-btn-icon-notext ui-btn-"+t}).attr("data-"+e.mobile.ns+"rel","back").text(i||this.options.closeBtnText||"").prependTo(n)),this._headerCloseButton=s}})}(e,this),function(e,i){e.widget("mobile.panel",{options:{classes:{panel:"ui-panel",panelOpen:"ui-panel-open",panelClosed:"ui-panel-closed",panelFixed:"ui-panel-fixed",panelInner:"ui-panel-inner",modal:"ui-panel-dismiss",modalOpen:"ui-panel-dismiss-open",pageContainer:"ui-panel-page-container",pageWrapper:"ui-panel-wrapper",pageFixedToolbar:"ui-panel-fixed-toolbar",pageContentPrefix:"ui-panel-page-content",animate:"ui-panel-animate"},animate:!0,theme:null,position:"left",dismissible:!0,display:"reveal",swipeClose:!0,positionFixed:!1},_closeLink:null,_parentPage:null,_page:null,_modal:null,_panelInner:null,_wrapper:null,_fixedToolbars:null,_create:function(){var t=this.element,i=t.closest(".ui-page, :jqmData(role='page')");e.extend(this,{_closeLink:t.find(":jqmData(rel='close')"),_parentPage:i.length>0?i:!1,_openedPage:null,_page:this._getPage,_panelInner:this._getPanelInner(),_fixedToolbars:this._getFixedToolbars}),"overlay"!==this.options.display&&this._getWrapper(),this._addPanelClasses(),e.support.cssTransform3d&&this.options.animate&&this.element.addClass(this.options.classes.animate),this._bindUpdateLayout(),this._bindCloseEvents(),this._bindLinkListeners(),this._bindPageEvents(),this.options.dismissible&&this._createModal(),this._bindSwipeEvents()},_getPanelInner:function(){var e=this.element.find("."+this.options.classes.panelInner);return 0===e.length&&(e=this.element.children().wrapAll("
").parent()),e},_createModal:function(){var t=this,i=t._parentPage?t._parentPage.parent():t.element.parent();t._modal=e("
").on("mousedown",function(){t.close()}).appendTo(i)},_getPage:function(){var t=this._openedPage||this._parentPage||e("."+e.mobile.activePageClass);return t},_getWrapper:function(){var e=this._page().find("."+this.options.classes.pageWrapper);0===e.length&&(e=this._page().children(".ui-header:not(.ui-header-fixed), .ui-content:not(.ui-popup), .ui-footer:not(.ui-footer-fixed)").wrapAll("
").parent()),this._wrapper=e},_getFixedToolbars:function(){var t=e("body").children(".ui-header-fixed, .ui-footer-fixed"),i=this._page().find(".ui-header-fixed, .ui-footer-fixed"),n=t.add(i).addClass(this.options.classes.pageFixedToolbar);return n},_getPosDisplayClasses:function(e){return e+"-position-"+this.options.position+" "+e+"-display-"+this.options.display},_getPanelClasses:function(){var e=this.options.classes.panel+" "+this._getPosDisplayClasses(this.options.classes.panel)+" "+this.options.classes.panelClosed+" ui-body-"+(this.options.theme?this.options.theme:"inherit");return this.options.positionFixed&&(e+=" "+this.options.classes.panelFixed),e},_addPanelClasses:function(){this.element.addClass(this._getPanelClasses())},_handleCloseClick:function(e){e.isDefaultPrevented()||this.close()},_bindCloseEvents:function(){this._on(this._closeLink,{click:"_handleCloseClick"}),this._on({"click a:jqmData(ajax='false')":"_handleCloseClick"})},_positionPanel:function(t){var i=this,n=i._panelInner.outerHeight(),s=n>e.mobile.getScreenHeight();s||!i.options.positionFixed?(s&&(i._unfixPanel(),e.mobile.resetActivePageHeight(n)),t&&this.window[0].scrollTo(0,e.mobile.defaultHomeScroll)):i._fixPanel()},_bindFixListener:function(){this._on(e(t),{throttledresize:"_positionPanel"})},_unbindFixListener:function(){this._off(e(t),"throttledresize")},_unfixPanel:function(){this.options.positionFixed&&e.support.fixedPosition&&this.element.removeClass(this.options.classes.panelFixed)},_fixPanel:function(){this.options.positionFixed&&e.support.fixedPosition&&this.element.addClass(this.options.classes.panelFixed)},_bindUpdateLayout:function(){var e=this;e.element.on("updatelayout",function(){e._open&&e._positionPanel()})},_bindLinkListeners:function(){this._on("body",{"click a":"_handleClick"})},_handleClick:function(t){var n,s=this.element.attr("id");t.currentTarget.href.split("#")[1]===s&&s!==i&&(t.preventDefault(),n=e(t.target),n.hasClass("ui-btn")&&(n.addClass(e.mobile.activeBtnClass),this.element.one("panelopen panelclose",function(){n.removeClass(e.mobile.activeBtnClass)})),this.toggle())},_bindSwipeEvents:function(){var e=this,t=e._modal?e.element.add(e._modal):e.element;e.options.swipeClose&&("left"===e.options.position?t.on("swipeleft.panel",function(){e.close()}):t.on("swiperight.panel",function(){e.close()}))},_bindPageEvents:function(){var e=this;this.document.on("panelbeforeopen",function(t){e._open&&t.target!==e.element[0]&&e.close()}).on("keyup.panel",function(t){27===t.keyCode&&e._open&&e.close()}),this._parentPage||"overlay"===this.options.display||this._on(this.document,{pageshow:function(){this._openedPage=null,this._getWrapper()}}),e._parentPage?this.document.on("pagehide",":jqmData(role='page')",function(){e._open&&e.close(!0)}):this.document.on("pagebeforehide",function(){e._open&&e.close(!0)})},_open:!1,_pageContentOpenClasses:null,_modalOpenClasses:null,open:function(t){if(!this._open){var i=this,n=i.options,s=function(){i._off(i.document,"panelclose"),i._page().jqmData("panel","open"),e.support.cssTransform3d&&n.animate&&"overlay"!==n.display&&(i._wrapper.addClass(n.classes.animate),i._fixedToolbars().addClass(n.classes.animate)),!t&&e.support.cssTransform3d&&n.animate?(i._wrapper||i.element).animationComplete(o,"transition"):setTimeout(o,0),n.theme&&"overlay"!==n.display&&i._page().parent().addClass(n.classes.pageContainer+"-themed "+n.classes.pageContainer+"-"+n.theme),i.element.removeClass(n.classes.panelClosed).addClass(n.classes.panelOpen),i._positionPanel(!0),i._pageContentOpenClasses=i._getPosDisplayClasses(n.classes.pageContentPrefix),"overlay"!==n.display&&(i._page().parent().addClass(n.classes.pageContainer),i._wrapper.addClass(i._pageContentOpenClasses),i._fixedToolbars().addClass(i._pageContentOpenClasses)),i._modalOpenClasses=i._getPosDisplayClasses(n.classes.modal)+" "+n.classes.modalOpen,i._modal&&i._modal.addClass(i._modalOpenClasses).height(Math.max(i._modal.height(),i.document.height()))},o=function(){i._open&&("overlay"!==n.display&&(i._wrapper.addClass(n.classes.pageContentPrefix+"-open"),i._fixedToolbars().addClass(n.classes.pageContentPrefix+"-open")),i._bindFixListener(),i._trigger("open"),i._openedPage=i._page())};i._trigger("beforeopen"),"open"===i._page().jqmData("panel")?i._on(i.document,{panelclose:s}):s(),i._open=!0}},close:function(t){if(this._open){var i=this,n=this.options,s=function(){i.element.removeClass(n.classes.panelOpen),"overlay"!==n.display&&(i._wrapper.removeClass(i._pageContentOpenClasses),i._fixedToolbars().removeClass(i._pageContentOpenClasses)),!t&&e.support.cssTransform3d&&n.animate?(i._wrapper||i.element).animationComplete(o,"transition"):setTimeout(o,0),i._modal&&i._modal.removeClass(i._modalOpenClasses).height("")},o=function(){n.theme&&"overlay"!==n.display&&i._page().parent().removeClass(n.classes.pageContainer+"-themed "+n.classes.pageContainer+"-"+n.theme),i.element.addClass(n.classes.panelClosed),"overlay"!==n.display&&(i._page().parent().removeClass(n.classes.pageContainer),i._wrapper.removeClass(n.classes.pageContentPrefix+"-open"),i._fixedToolbars().removeClass(n.classes.pageContentPrefix+"-open")),e.support.cssTransform3d&&n.animate&&"overlay"!==n.display&&(i._wrapper.removeClass(n.classes.animate),i._fixedToolbars().removeClass(n.classes.animate)),i._fixPanel(),i._unbindFixListener(),e.mobile.resetActivePageHeight(),i._page().jqmRemoveData("panel"),i._trigger("close"),i._openedPage=null};i._trigger("beforeclose"),s(),i._open=!1}},toggle:function(){this[this._open?"close":"open"]()},_destroy:function(){var t,i=this.options,n=e("body > :mobile-panel").length+e.mobile.activePage.find(":mobile-panel").length>1;"overlay"!==i.display&&(t=e("body > :mobile-panel").add(e.mobile.activePage.find(":mobile-panel")),0===t.not(".ui-panel-display-overlay").not(this.element).length&&this._wrapper.children().unwrap(),this._open&&(this._fixedToolbars().removeClass(i.classes.pageContentPrefix+"-open"),e.support.cssTransform3d&&i.animate&&this._fixedToolbars().removeClass(i.classes.animate),this._page().parent().removeClass(i.classes.pageContainer),i.theme&&this._page().parent().removeClass(i.classes.pageContainer+"-themed "+i.classes.pageContainer+"-"+i.theme))),n||this.document.off("panelopen panelclose"),this._open&&this._page().jqmRemoveData("panel"),this._panelInner.children().unwrap(),this.element.removeClass([this._getPanelClasses(),i.classes.panelOpen,i.classes.animate].join(" ")).off("swipeleft.panel swiperight.panel").off("panelbeforeopen").off("panelhide").off("keyup.panel").off("updatelayout"),this._modal&&this._modal.remove()}})}(e),function(e,i){function n(e,t,i,n){var s=n;return s=t>e?i+(e-t)/2:Math.min(Math.max(i,n-t/2),i+e-t)}function s(e){return{x:e.scrollLeft(),y:e.scrollTop(),cx:e[0].innerWidth||e.width(),cy:e[0].innerHeight||e.height()}}e.widget("mobile.popup",{options:{wrapperClass:null,theme:null,overlayTheme:null,shadow:!0,corners:!0,transition:"none",positionTo:"origin",tolerance:null,closeLinkSelector:"a:jqmData(rel='back')",closeLinkEvents:"click.popup",navigateEvents:"navigate.popup",closeEvents:"navigate.popup pagebeforechange.popup",dismissible:!0,enhanced:!1,history:!e.mobile.browser.oldIE},_handleDocumentVmousedown:function(t){this._isOpen&&e.contains(this._ui.container[0],t.target)&&this._ignoreResizeEvents()},_create:function(){var t=this.element,i=t.attr("id"),n=this.options;n.history=n.history&&e.mobile.ajaxEnabled&&e.mobile.hashListeningEnabled,this._on(this.document,{vmousedown:"_handleDocumentVmousedown"}),e.extend(this,{_scrollTop:0,_page:t.closest(".ui-page"),_ui:null,_fallbackTransition:"",_currentTransition:!1,_prerequisites:null,_isOpen:!1,_tolerance:null,_resizeData:null,_ignoreResizeTo:0,_orientationchangeInProgress:!1}),0===this._page.length&&(this._page=e("body")),n.enhanced?this._ui={container:t.parent(),screen:t.parent().prev(),placeholder:e(this.document[0].getElementById(i+"-placeholder"))}:(this._ui=this._enhance(t,i),this._applyTransition(n.transition)),this._setTolerance(n.tolerance)._ui.focusElement=this._ui.container,this._on(this._ui.screen,{vclick:"_eatEventAndClose"}),this._on(this.window,{orientationchange:e.proxy(this,"_handleWindowOrientationchange"),resize:e.proxy(this,"_handleWindowResize"),keyup:e.proxy(this,"_handleWindowKeyUp")}),this._on(this.document,{focusin:"_handleDocumentFocusIn"})},_enhance:function(t,i){var n=this.options,s=n.wrapperClass,o={screen:e(""),placeholder:e("
"),container:e("")},a=this.document[0].createDocumentFragment();return a.appendChild(o.screen[0]),a.appendChild(o.container[0]),i&&(o.screen.attr("id",i+"-screen"),o.container.attr("id",i+"-popup"),o.placeholder.attr("id",i+"-placeholder").html("")),this._page[0].appendChild(a),o.placeholder.insertAfter(t),t.detach().addClass("ui-popup "+this._themeClassFromOption("ui-body-",n.theme)+" "+(n.shadow?"ui-overlay-shadow ":"")+(n.corners?"ui-corner-all ":"")).appendTo(o.container),o},_eatEventAndClose:function(e){return e.preventDefault(),e.stopImmediatePropagation(),this.options.dismissible&&this.close(),!1},_resizeScreen:function(){var e=this._ui.screen,t=this._ui.container.outerHeight(!0),i=e.removeAttr("style").height(),n=this.document.height()-1;n>i?e.height(n):t>i&&e.height(t)},_handleWindowKeyUp:function(t){return this._isOpen&&t.keyCode===e.mobile.keyCode.ESCAPE?this._eatEventAndClose(t):void 0},_expectResizeEvent:function(){var e=s(this.window);if(this._resizeData){if(e.x===this._resizeData.windowCoordinates.x&&e.y===this._resizeData.windowCoordinates.y&&e.cx===this._resizeData.windowCoordinates.cx&&e.cy===this._resizeData.windowCoordinates.cy)return!1;clearTimeout(this._resizeData.timeoutId)}return this._resizeData={timeoutId:this._delay("_resizeTimeout",200),windowCoordinates:e},!0},_resizeTimeout:function(){this._isOpen?this._expectResizeEvent()||(this._ui.container.hasClass("ui-popup-hidden")&&(this._ui.container.removeClass("ui-popup-hidden ui-popup-truncate"),this.reposition({positionTo:"window"}),this._ignoreResizeEvents()),this._resizeScreen(),this._resizeData=null,this._orientationchangeInProgress=!1):(this._resizeData=null,this._orientationchangeInProgress=!1)},_stopIgnoringResizeEvents:function(){this._ignoreResizeTo=0},_ignoreResizeEvents:function(){this._ignoreResizeTo&&clearTimeout(this._ignoreResizeTo),this._ignoreResizeTo=this._delay("_stopIgnoringResizeEvents",1e3)},_handleWindowResize:function(){this._isOpen&&0===this._ignoreResizeTo&&(!this._expectResizeEvent()&&!this._orientationchangeInProgress||this._ui.container.hasClass("ui-popup-hidden")||this._ui.container.addClass("ui-popup-hidden ui-popup-truncate").removeAttr("style"))},_handleWindowOrientationchange:function(){!this._orientationchangeInProgress&&this._isOpen&&0===this._ignoreResizeTo&&(this._expectResizeEvent(),this._orientationchangeInProgress=!0)},_handleDocumentFocusIn:function(t){var i,n=t.target,s=this._ui;if(this._isOpen){if(n!==s.container[0]){if(i=e(n),!e.contains(s.container[0],n))return e(this.document[0].activeElement).one("focus",e.proxy(function(){this._safelyBlur(n)},this)),s.focusElement.focus(),t.preventDefault(),t.stopImmediatePropagation(),!1;s.focusElement[0]===s.container[0]&&(s.focusElement=i)}this._ignoreResizeEvents()}},_themeClassFromOption:function(e,t){return t?"none"===t?"":e+t:e+"inherit"},_applyTransition:function(t){return t&&(this._ui.container.removeClass(this._fallbackTransition),"none"!==t&&(this._fallbackTransition=e.mobile._maybeDegradeTransition(t),"none"===this._fallbackTransition&&(this._fallbackTransition=""),this._ui.container.addClass(this._fallbackTransition))),this},_setOptions:function(e){var t=this.options,n=this.element,s=this._ui.screen;return e.wrapperClass!==i&&this._ui.container.removeClass(t.wrapperClass).addClass(e.wrapperClass),e.theme!==i&&n.removeClass(this._themeClassFromOption("ui-body-",t.theme)).addClass(this._themeClassFromOption("ui-body-",e.theme)),e.overlayTheme!==i&&(s.removeClass(this._themeClassFromOption("ui-overlay-",t.overlayTheme)).addClass(this._themeClassFromOption("ui-overlay-",e.overlayTheme)),this._isOpen&&s.addClass("in")),e.shadow!==i&&n.toggleClass("ui-overlay-shadow",e.shadow),e.corners!==i&&n.toggleClass("ui-corner-all",e.corners),e.transition!==i&&(this._currentTransition||this._applyTransition(e.transition)),e.tolerance!==i&&this._setTolerance(e.tolerance),e.disabled!==i&&e.disabled&&this.close(),this._super(e)},_setTolerance:function(t){var n,s={t:30,r:15,b:30,l:15};if(t!==i)switch(n=String(t).split(","),e.each(n,function(e,t){n[e]=parseInt(t,10)}),n.length){case 1:isNaN(n[0])||(s.t=s.r=s.b=s.l=n[0]);break;case 2:isNaN(n[0])||(s.t=s.b=n[0]),isNaN(n[1])||(s.l=s.r=n[1]);break;case 4:isNaN(n[0])||(s.t=n[0]),isNaN(n[1])||(s.r=n[1]),isNaN(n[2])||(s.b=n[2]),isNaN(n[3])||(s.l=n[3])}return this._tolerance=s,this},_clampPopupWidth:function(e){var t,i=s(this.window),n={x:this._tolerance.l,y:i.y+this._tolerance.t,cx:i.cx-this._tolerance.l-this._tolerance.r,cy:i.cy-this._tolerance.t-this._tolerance.b};return e||this._ui.container.css("max-width",n.cx),t={cx:this._ui.container.outerWidth(!0),cy:this._ui.container.outerHeight(!0)},{rc:n,menuSize:t}},_calculateFinalLocation:function(e,t){var i,s=t.rc,o=t.menuSize;return i={left:n(s.cx,o.cx,s.x,e.x),top:n(s.cy,o.cy,s.y,e.y)},i.top=Math.max(0,i.top),i.top-=Math.min(i.top,Math.max(0,i.top+o.cy-this.document.height())),i},_placementCoords:function(e){return this._calculateFinalLocation(e,this._clampPopupWidth())},_createPrerequisites:function(t,i,n){var s,o=this;s={screen:e.Deferred(),container:e.Deferred()},s.screen.then(function(){s===o._prerequisites&&t()}),s.container.then(function(){s===o._prerequisites&&i()}),e.when(s.screen,s.container).done(function(){s===o._prerequisites&&(o._prerequisites=null,n())}),o._prerequisites=s},_animate:function(t){return this._ui.screen.removeClass(t.classToRemove).addClass(t.screenClassToAdd),t.prerequisites.screen.resolve(),t.transition&&"none"!==t.transition&&(t.applyTransition&&this._applyTransition(t.transition),this._fallbackTransition)?void this._ui.container.addClass(t.containerClassToAdd).removeClass(t.classToRemove).animationComplete(e.proxy(t.prerequisites.container,"resolve")):(this._ui.container.removeClass(t.classToRemove),void t.prerequisites.container.resolve())},_desiredCoords:function(t){var i,n=null,o=s(this.window),a=t.x,r=t.y,l=t.positionTo;if(l&&"origin"!==l)if("window"===l)a=o.cx/2+o.x,r=o.cy/2+o.y;else{try{n=e(l)}catch(h){n=null}n&&(n.filter(":visible"),0===n.length&&(n=null))}return n&&(i=n.offset(),a=i.left+n.outerWidth()/2,r=i.top+n.outerHeight()/2),("number"!==e.type(a)||isNaN(a))&&(a=o.cx/2+o.x),("number"!==e.type(r)||isNaN(r))&&(r=o.cy/2+o.y),{x:a,y:r}},_reposition:function(e){e={x:e.x,y:e.y,positionTo:e.positionTo},this._trigger("beforeposition",i,e),this._ui.container.offset(this._placementCoords(this._desiredCoords(e)))},reposition:function(e){this._isOpen&&this._reposition(e)},_safelyBlur:function(t){t!==this.window[0]&&"body"!==t.nodeName.toLowerCase()&&e(t).blur()},_openPrerequisitesComplete:function(){var t=this.element.attr("id"),i=this._ui.container.find(":focusable").first();this._ui.container.addClass("ui-popup-active"),this._isOpen=!0,this._resizeScreen(),e.contains(this._ui.container[0],this.document[0].activeElement)||this._safelyBlur(this.document[0].activeElement),i.length>0&&(this._ui.focusElement=i),this._ignoreResizeEvents(),t&&this.document.find("[aria-haspopup='true'][aria-owns='"+t+"']").attr("aria-expanded",!0),this._trigger("afteropen")},_open:function(t){var i=e.extend({},this.options,t),n=function(){var e=navigator.userAgent,t=e.match(/AppleWebKit\/([0-9\.]+)/),i=!!t&&t[1],n=e.match(/Android (\d+(?:\.\d+))/),s=!!n&&n[1],o=e.indexOf("Chrome")>-1;return null!==n&&"4.0"===s&&i&&i>534.13&&!o?!0:!1}();this._createPrerequisites(e.noop,e.noop,e.proxy(this,"_openPrerequisitesComplete")),this._currentTransition=i.transition,this._applyTransition(i.transition),this._ui.screen.removeClass("ui-screen-hidden"),this._ui.container.removeClass("ui-popup-truncate"),this._reposition(i),this._ui.container.removeClass("ui-popup-hidden"),this.options.overlayTheme&&n&&this.element.closest(".ui-page").addClass("ui-popup-open"),this._animate({additionalCondition:!0,transition:i.transition,classToRemove:"",screenClassToAdd:"in",containerClassToAdd:"in",applyTransition:!1,prerequisites:this._prerequisites})},_closePrerequisiteScreen:function(){this._ui.screen.removeClass("out").addClass("ui-screen-hidden")},_closePrerequisiteContainer:function(){this._ui.container.removeClass("reverse out").addClass("ui-popup-hidden ui-popup-truncate").removeAttr("style")},_closePrerequisitesDone:function(){var t=this._ui.container,n=this.element.attr("id");e.mobile.popup.active=i,e(":focus",t[0]).add(t[0]).blur(),n&&this.document.find("[aria-haspopup='true'][aria-owns='"+n+"']").attr("aria-expanded",!1),this._trigger("afterclose")},_close:function(t){this._ui.container.removeClass("ui-popup-active"),this._page.removeClass("ui-popup-open"),this._isOpen=!1,this._createPrerequisites(e.proxy(this,"_closePrerequisiteScreen"),e.proxy(this,"_closePrerequisiteContainer"),e.proxy(this,"_closePrerequisitesDone")),this._animate({additionalCondition:this._ui.screen.hasClass("in"),transition:t?"none":this._currentTransition,classToRemove:"in",screenClassToAdd:"out",containerClassToAdd:"reverse out",applyTransition:!0,prerequisites:this._prerequisites})},_unenhance:function(){this.options.enhanced||(this._setOptions({theme:e.mobile.popup.prototype.options.theme}),this.element.detach().insertAfter(this._ui.placeholder).removeClass("ui-popup ui-overlay-shadow ui-corner-all ui-body-inherit"),this._ui.screen.remove(),this._ui.container.remove(),this._ui.placeholder.remove())},_destroy:function(){return e.mobile.popup.active===this?(this.element.one("popupafterclose",e.proxy(this,"_unenhance")),this.close()):this._unenhance(),this},_closePopup:function(i,n){var s,o,a=this.options,r=!1;i&&i.isDefaultPrevented()||e.mobile.popup.active!==this||(t.scrollTo(0,this._scrollTop),i&&"pagebeforechange"===i.type&&n&&(s="string"==typeof n.toPage?n.toPage:n.toPage.jqmData("url"),s=e.mobile.path.parseUrl(s),o=s.pathname+s.search+s.hash,this._myUrl!==e.mobile.path.makeUrlAbsolute(o)?r=!0:i.preventDefault()),this.window.off(a.closeEvents),this.element.undelegate(a.closeLinkSelector,a.closeLinkEvents),this._close(r))},_bindContainerClose:function(){this.window.on(this.options.closeEvents,e.proxy(this,"_closePopup"))},widget:function(){return this._ui.container},open:function(t){var i,n,s,o,a,r,l=this,h=this.options;return e.mobile.popup.active||h.disabled?this:(e.mobile.popup.active=this,this._scrollTop=this.window.scrollTop(),h.history?(r=e.mobile.navigate.history,n=e.mobile.dialogHashKey,s=e.mobile.activePage,o=s?s.hasClass("ui-dialog"):!1,this._myUrl=i=r.getActive().url,(a=i.indexOf(n)>-1&&!o&&r.activeIndex>0)?(l._open(t),l._bindContainerClose(),this):(-1!==i.indexOf(n)||o?i=e.mobile.path.parseLocation().hash+n:i+=i.indexOf("#")>-1?n:"#"+n,this.window.one("beforenavigate",function(e){e.preventDefault(),l._open(t),l._bindContainerClose()}),this.urlAltered=!0,e.mobile.navigate(i,{role:"dialog"}),this)):(l._open(t),l._bindContainerClose(),l.element.delegate(h.closeLinkSelector,h.closeLinkEvents,function(e){l.close(),e.preventDefault()}),this))},close:function(){return e.mobile.popup.active!==this?this:(this._scrollTop=this.window.scrollTop(),this.options.history&&this.urlAltered?(e.mobile.back(),this.urlAltered=!1):this._closePopup(),this)}}),e.mobile.popup.handleLink=function(t){var i,n=e.mobile.path,s=e(n.hashToSelector(n.parseUrl(t.attr("href")).hash)).first();s.length>0&&s.data("mobile-popup")&&(i=t.offset(),s.popup("open",{x:i.left+t.outerWidth()/2,y:i.top+t.outerHeight()/2,transition:t.jqmData("transition"),positionTo:t.jqmData("position-to")})),setTimeout(function(){t.removeClass(e.mobile.activeBtnClass)},300)},e.mobile.document.on("pagebeforechange",function(t,i){"popup"===i.options.role&&(e.mobile.popup.handleLink(i.options.link),t.preventDefault())})}(e),function(e,t){function i(){var e=s.clone(),t=e.eq(0),i=e.eq(1),n=i.children();return{arEls:i.add(t),gd:t,ct:i,ar:n}}var n=e.mobile.browser.oldIE&&e.mobile.browser.oldIE<=8,s=e("");e.widget("mobile.popup",e.mobile.popup,{options:{arrow:""},_create:function(){var e,t=this._super();return this.options.arrow&&(this._ui.arrow=e=this._addArrow()),t},_addArrow:function(){var e,t=this.options,n=i();return e=this._themeClassFromOption("ui-body-",t.theme),n.ar.addClass(e+(t.shadow?" ui-overlay-shadow":"")),n.arEls.hide().appendTo(this.element),n},_unenhance:function(){var e=this._ui.arrow;return e&&e.arEls.remove(),this._super()},_tryAnArrow:function(e,t,i,n,s){var o,a,r,l={},h={};return n.arFull[e.dimKey]>n.guideDims[e.dimKey]?s:(l[e.fst]=i[e.fst]+(n.arHalf[e.oDimKey]+n.menuHalf[e.oDimKey])*e.offsetFactor-n.contentBox[e.fst]+(n.clampInfo.menuSize[e.oDimKey]-n.contentBox[e.oDimKey])*e.arrowOffsetFactor,l[e.snd]=i[e.snd],o=n.result||this._calculateFinalLocation(l,n.clampInfo),a={x:o.left,y:o.top},h[e.fst]=a[e.fst]+n.contentBox[e.fst]+e.tipOffset,h[e.snd]=Math.max(o[e.prop]+n.guideOffset[e.prop]+n.arHalf[e.dimKey],Math.min(o[e.prop]+n.guideOffset[e.prop]+n.guideDims[e.dimKey]-n.arHalf[e.dimKey],i[e.snd])),r=Math.abs(i.x-h.x)+Math.abs(i.y-h.y),(!s||rs;s++)n++,a+=", :nth-child("+(n+1)+")";e(this).jqmData("cells",t.find("tr").not(i.eq(0)).not(this).children(a)),n++})})}})}(e),function(e){e.widget("mobile.table",e.mobile.table,{options:{mode:"columntoggle",columnBtnTheme:null,columnPopupTheme:null,columnBtnText:"Columns...",classes:e.extend(e.mobile.table.prototype.options.classes,{popup:"ui-table-columntoggle-popup",columnBtn:"ui-table-columntoggle-btn",priorityPrefix:"ui-table-priority-",columnToggleTable:"ui-table-columntoggle"})},_create:function(){this._super(),"columntoggle"===this.options.mode&&(e.extend(this,{_menu:null}),this.options.enhanced?(this._menu=e(this.document[0].getElementById(this._id()+"-popup")).children().first(),this._addToggles(this._menu,!0)):(this._menu=this._enhanceColToggle(),this.element.addClass(this.options.classes.columnToggleTable)),this._setupEvents(),this._setToggleState())},_id:function(){return this.element.attr("id")||this.widgetName+this.uuid},_setupEvents:function(){this._on(this.window,{throttledresize:"_setToggleState"}),this._on(this._menu,{"change input":"_menuInputChange"})},_addToggles:function(t,i){var n,s=0,o=this.options,a=t.controlgroup("container");i?n=t.find("input"):a.empty(),this.headers.not("td").each(function(){var t,r,l=e(this),h=e.mobile.getAttribute(this,"priority");h&&(r=l.add(l.jqmData("cells")),r.addClass(o.classes.priorityPrefix+h),t=(i?n.eq(s++):e(" "+(l.children("abbr").first().attr("title")||l.text())+" ").appendTo(a).children(0).checkboxradio({theme:o.columnPopupTheme})).jqmData("header",l).jqmData("cells",r),l.jqmData("input",t))}),i||t.controlgroup("refresh")},_menuInputChange:function(t){var i=e(t.target),n=i[0].checked;i.jqmData("cells").toggleClass("ui-table-cell-hidden",!n).toggleClass("ui-table-cell-visible",n)},_unlockCells:function(e){e.removeClass("ui-table-cell-hidden ui-table-cell-visible")},_enhanceColToggle:function(){var t,i,n,s,o=this.element,a=this.options,r=e.mobile.ns,l=this.document[0].createDocumentFragment();return t=this._id()+"-popup",i=e(""+a.columnBtnText+" "),n=e(""),s=e(" ").controlgroup(),this._addToggles(s,!1),s.appendTo(n),l.appendChild(n[0]),l.appendChild(i[0]),o.before(l),n.popup(),s},rebuild:function(){this._super(),"columntoggle"===this.options.mode&&this._refresh(!1)},_refresh:function(t){var i,n,s;if(this._super(t),!t&&"columntoggle"===this.options.mode)for(i=this.headers,n=[],this._menu.find("input").each(function(){var t=e(this),s=t.jqmData("header"),o=i.index(s[0]);
+o>-1&&!t.prop("checked")&&n.push(o)}),this._unlockCells(this.element.find(".ui-table-cell-hidden, .ui-table-cell-visible")),this._addToggles(this._menu,t),s=n.length-1;s>-1;s--)i.eq(n[s]).jqmData("input").prop("checked",!1).checkboxradio("refresh").trigger("change")},_setToggleState:function(){this._menu.find("input").each(function(){var t=e(this);this.checked="table-cell"===t.jqmData("cells").eq(0).css("display"),t.checkboxradio("refresh")})},_destroy:function(){this._super()}})}(e),function(e){e.widget("mobile.table",e.mobile.table,{options:{mode:"reflow",classes:e.extend(e.mobile.table.prototype.options.classes,{reflowTable:"ui-table-reflow",cellLabels:"ui-table-cell-label"})},_create:function(){this._super(),"reflow"===this.options.mode&&(this.options.enhanced||(this.element.addClass(this.options.classes.reflowTable),this._updateReflow()))},rebuild:function(){this._super(),"reflow"===this.options.mode&&this._refresh(!1)},_refresh:function(e){this._super(e),e||"reflow"!==this.options.mode||this._updateReflow()},_updateReflow:function(){var t=this,i=this.options;e(t.allHeaders.get().reverse()).each(function(){var n,s,o=e(this).jqmData("cells"),a=e.mobile.getAttribute(this,"colstart"),r=o.not(this).filter("thead th").length&&" ui-table-cell-label-top",l=e(this).clone().contents();l.length>0&&(r?(n=parseInt(this.getAttribute("colspan"),10),s="",n&&(s="td:nth-child("+n+"n + "+a+")"),t._addLabels(o.filter(s),i.classes.cellLabels+r,l)):t._addLabels(o,i.classes.cellLabels,l))})},_addLabels:function(t,i,n){1===n.length&&"abbr"===n[0].nodeName.toLowerCase()&&(n=n.eq(0).attr("title")),t.not(":has(b."+i+")").prepend(e(" ").append(n))}})}(e)});
\ No newline at end of file
diff --git a/dashboard-ui/vulcanize-in.html b/dashboard-ui/vulcanize-in.html
index dcdb002287..4646e2dcf3 100644
--- a/dashboard-ui/vulcanize-in.html
+++ b/dashboard-ui/vulcanize-in.html
@@ -8,4 +8,5 @@
+
\ No newline at end of file
diff --git a/dashboard-ui/vulcanize-out.html b/dashboard-ui/vulcanize-out.html
index 07b8f3e465..b206314b75 100644
--- a/dashboard-ui/vulcanize-out.html
+++ b/dashboard-ui/vulcanize-out.html
@@ -9873,6 +9873,624 @@ The `aria-labelledby` attribute will be set to the header element, if one exists
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -12241,17 +13481,20 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
+
+
+