Adaptation to new login mechanism.
authorivanl
Thu, 30 Jul 2009 16:17:56 +0100
changeset 16 6544cc5386ce
parent 15 5e64ec5b1dfe
child 17 5dc2963cd75f
Adaptation to new login mechanism. Fix for font size on hi-res devices. Detection is now automatic and right font size is set immediately after installation.
Symbian.org/FeedUpdateBroker.js
Symbian.org/Main.js
--- a/Symbian.org/FeedUpdateBroker.js	Wed Jul 29 10:14:37 2009 +0100
+++ b/Symbian.org/FeedUpdateBroker.js	Thu Jul 30 16:17:56 2009 +0100
@@ -51,7 +51,8 @@
 		var text = this.httpReq.responseText;
 		if ( isLoginPrompt (text) ) {
 			var self = this;
-			login(function(){self.doFetchFeed();});
+			setTimeout(self.doFetchFeed(), 100);
+//			login(function(){self.doFetchFeed();});
 			return;
 		}
 		
--- a/Symbian.org/Main.js	Wed Jul 29 10:14:37 2009 +0100
+++ b/Symbian.org/Main.js	Thu Jul 30 16:17:56 2009 +0100
@@ -51,7 +51,7 @@
 var wikiBaseUrl = symbianOrgBaseUrl+"/wiki/index.php";
 
 // Update variables
-var myversion = "1.0rc11";
+var myversion = "1.0rc13";
 var versionWikiPageUrl = wikiBaseUrl + "/Symbian.org_WRT_Widget";
 var versionWikiPageString = "Current widget version is [";
 var downloadUrl = symbianOrgBaseUrl + "/wiki/images/c/c5/Symbian.org.wgz";
@@ -161,6 +161,7 @@
 	// add bugzilla button
 	var bugzillaButton = new NavigationButton(3, "right.gif", "Bugzilla")
 	bugzillaButton.addEventListener("ActionPerformed", function(){login(function(){bugzilla.show();});});
+//	bugzillaButton.addEventListener("ActionPerformed", function(){bugzilla.show();});
 	home.addControl(bugzillaButton);
 	
 	// soft keys
@@ -235,7 +236,7 @@
 
 	home.show();
 	setDefaultFontSizeForScreenSize();
-	login(null);	
+//	login(null);	
 }
 
 // Callback for when menu items are selected.
@@ -382,7 +383,7 @@
 			// no preference available, check screen size
 			if (window.screen.width > 400 || window.screen.height > 400) {
 				// hi res screen, use large font
-				setCssBodyFontSize(18);
+				setCssBodyFontSize(30);
 			}
 			else {
 				// lo res screen, use small font
@@ -406,7 +407,7 @@
 	}
 }
 
-function setCssBodyFontSize(size) {
+function setCssBodyFontSize(size){
     if (window.widget) {
 		currentFontSize = size;
 		var sizestring = "" + size;