Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-10811] iOS: Option for disabling default spinner for WebView when opening remote URLs.

GitHub Issuen/a
TypeBug
PriorityMedium
StatusClosed
ResolutionFixed
Resolution Date2012-09-04T13:13:24.000+0000
Affected Version/sRelease 3.0.0
Fix Version/sRelease 3.0.0, Sprint 2012-18 API
ComponentsiOS
Labelsapi, module_webview, qe-review, qe-testadded
ReporterHidayet Dogan
AssigneeSabil Rahim
Created2012-08-24T05:23:54.000+0000
Updated2014-12-04T19:25:06.000+0000

Description

It would be nice to have an option to disable default spinner when calling remote urls in WebView component. There may be "disableSpinner" or "hideSpinner" option/property for Titanium.UI.WebView.

Comments

  1. Hidayet Dogan 2012-08-24

    Submitted pull request for this ticket, can be found at: https://github.com/appcelerator/titanium_mobile/pull/2825 Here are the functional test code:
    Titanium.UI.setBackgroundColor('#fff');
       
       var win = Titanium.UI.createWindow({  
           title: 'WebView Test',
           backgroundColor: '#fff'
       });
       
       var button1 = Titanium.UI.createButton({
       	top: 330,
       	title: 'Open Remote URL With Spinner',
       	style: Titanium.UI.iPhone.SystemButtonStyle.BORDERED
       });
       
       button1.addEventListener('click', function(e) {
       	var webview = Titanium.UI.createWebView({
       		top: 0,
       		width: 320,
       		height: 320,
       		url: 'http://www.nobius.org/~dbg/practical-file-system-design.pdf', // need slow loading remote url to catch spinner
       		// hideDefaultSpinner: false (default is already false)
       	});
       	
       	win.add(webview);
       });
       
       win.add(button1);
       
       var button2 = Titanium.UI.createButton({
       	top: 380,
       	title: 'Open Remote URL Without Spinner',
       	style: Titanium.UI.iPhone.SystemButtonStyle.BORDERED
       });
       
       button2.addEventListener('click', function(e) {
       	var webview = Titanium.UI.createWebView({
       		top: 0,
       		width: 320,
       		height: 320,
       		url: 'http://www.newamericancentury.org/RebuildingAmericasDefenses.pdf', // another slow loading remote url
       		hideLoadIndicator: true
       	});
       	
       	win.add(webview);
       });
       
       win.add(button2);
       
       win.open();
  2. Sabil Rahim 2012-09-04

    Pr merged: https://github.com/appcelerator/titanium_mobile/pull/2825
  3. Anshu Mittal 2012-09-10

    Verified with: SDK: 2.2.0.v20120907162025 STUDIO: 2.1.3.201209071738 Devices: iOS simulator, iPhone4s(v 5.0.1)

JSON Source