[Kimchi-devel] [PATCH] Bug 499 Fix: Disable download button of debug report when mobile

Aline Manera alinefm at linux.vnet.ibm.com
Tue Dec 9 12:55:31 UTC 2014


On 12/09/2014 06:47 AM, Yu Xin Huo wrote:
> On 12/8/2014 8:11 PM, Aline Manera wrote:
>>
>> Why should we disable Download debug reports on mobile browsers?
> I always failed to download it on iPad with both safari and chrome.

Any errors or log?
The download process should not differ from desktop browsers.

>>
>> On 12/08/2014 05:47 AM, huoyuxin at linux.vnet.ibm.com wrote:
>>> From: Yu Xin Huo <huoyuxin at linux.vnet.ibm.com>
>>>
>>> Signed-off-by: Yu Xin Huo <huoyuxin at linux.vnet.ibm.com>
>>> ---
>>>   ui/js/src/kimchi.host.js |    2 +-
>>>   ui/js/src/kimchi.main.js |    2 ++
>>>   2 files changed, 3 insertions(+), 1 deletions(-)
>>>
>>> diff --git a/ui/js/src/kimchi.host.js b/ui/js/src/kimchi.host.js
>>> index b75b9e4..295e4cc 100644
>>> --- a/ui/js/src/kimchi.host.js
>>> +++ b/ui/js/src/kimchi.host.js
>>> @@ -290,7 +290,7 @@ kimchi.host_main = function() {
>>>               $(kimchi.substitute(buttonID, {
>>>                   grid: reportGridID,
>>>                   btn: n
>>> -            })).prop('disabled', !toEnable);
>>> +            })).prop('disabled', 
>>> (n=="download"&&kimchi.isMobile)||!toEnable);
>>>           });
>>>       };
>>>       var initReportGrid = function(reports) {
>>> diff --git a/ui/js/src/kimchi.main.js b/ui/js/src/kimchi.main.js
>>> index 1424827..3f08d82 100644
>>> --- a/ui/js/src/kimchi.main.js
>>> +++ b/ui/js/src/kimchi.main.js
>>> @@ -27,6 +27,8 @@ kimchi.getCapabilities(function(result) {
>>>       kimchi.capabilities = {};
>>>   });
>>>
>>> +kimchi.isMobile = /android|iphone|ipad/i.test(navigator.userAgent);
>>> +
>>>   kimchi.main = function() {
>>>       kimchi.isLoggingOut = false;
>>>       kimchi.popable();
>>
>
>




More information about the Kimchi-devel mailing list