Commit d6035ba8 authored by nextime's avatar nextime

Some iOS (crap OS!) specific fixes and prevent horizontal scroll on window object

parent 76e85c65
This source diff could not be displayed because it is too large. You can view the blob instead.
html {
overflow: hidden;
overflow-y: auto;
width:100%;
}
.alert-container {
position: fixed;
......
......@@ -119,6 +119,38 @@ window.matchMedia=window.matchMedia||function(a){"use strict";var c,d=a.document
}
*/
(function () {
var previousScroll = 0;
$(window).scroll(function(event){
$(this).scrollLeft()!=0;
$(window).scrollLeft(0);
event.preventDefault();
});
}()); // to disable right scroll on panels open
$(window).scroll(function(event){
console.debug(event);
});
if(window.navigator.userAgent.match(/(iPad|iPhone|iPod)/g))
{
$(document).ready(function(){
if (("standalone" in window.navigator) && window.navigator.standalone) {
// For iOS Apps
$('a').on('click', function(e){
e.preventDefault();
var new_location = $(this).attr('href');
if (new_location != undefined && new_location.substr(0, 1) != '#' && $(this).attr('data-method') == undefined){
window.location = new_location;
}
});
}
});
}
if(window.navigator.userAgent.match(/firefox/i) && window.navigator.userAgent.match(/mobile/i))
{
......
......@@ -34,6 +34,38 @@
}
*/
(function () {
var previousScroll = 0;
$(window).scroll(function(event){
$(this).scrollLeft()!=0;
$(window).scrollLeft(0);
event.preventDefault();
});
}()); // to disable right scroll on panels open
$(window).scroll(function(event){
console.debug(event);
});
if(window.navigator.userAgent.match(/(iPad|iPhone|iPod)/g))
{
$(document).ready(function(){
if (("standalone" in window.navigator) && window.navigator.standalone) {
// For iOS Apps
$('a').on('click', function(e){
e.preventDefault();
var new_location = $(this).attr('href');
if (new_location != undefined && new_location.substr(0, 1) != '#' && $(this).attr('data-method') == undefined){
window.location = new_location;
}
});
}
});
}
if(window.navigator.userAgent.match(/firefox/i) && window.navigator.userAgent.match(/mobile/i))
{
......
......@@ -7,8 +7,8 @@
<!-- <li <? if($GUISUBSECTION=="gui") {?>class="active"<?}?>><a href="<?=$BASEGUIPATH.'/'.$GUISECTION?>/gui">GUI options</a></li> -->
</ul>
<? if($GUISUBSECTION=="") {?>
<div class="formcontainer">
<form id="userform" name="userform" class="form-horizontal" style="display:none">
<div class="formcontainer" >
<form id="userform" name="userform" class="form-horizontal" style="display:none;margin-bottom:60px;">
<div class="form-group">
<label for="username" class="col-lg-2 control-label">Username:</label>
<div class="col-lg-3">
......
......@@ -28,7 +28,7 @@ function plotGraph(settings)
});
}
<?
foreach($_SESSION[PANELS_CHARTS] as $eid => $chart)
foreach($_SESSION['PANELS_CHARTS'] as $eid => $chart)
{
?>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment