ginebra/chrome/demochrome/s60-boston-chrome.html
branchGCC_SURGE
changeset 8 2e16851ffecd
parent 2 bf4420e9fa4d
parent 6 1c3b8676e58c
equal deleted inserted replaced
2:bf4420e9fa4d 8:2e16851ffecd
     1 <html>
       
     2   <head>
       
     3     <script type="text/javascript">
       
     4       function loadToMainWindow(url){
       
     5       //    alert("Loading:" + url);
       
     6             window.viewManager.pageController.currentLoad(url);
       
     7       }
       
     8 
       
     9 
       
    10       function onLoad(){
       
    11          loadToMainWindow('http://www.google.com/news/image?p2=1&ned=us&hl=en&q=boston&imv=1');
       
    12          window.chrome.setBackgroundColor(0xFF,0xFF,0xFF);
       
    13          //window.chrome.setVisibilityAnimator("BottomChromeId", "G_VISIBILITY_FLYOUT_ANIMATOR");
       
    14          //window.chrome.setAttentionAnimator("Button6", "G_ATTENTION_PULSE_ANIMATOR");
       
    15       }
       
    16       window.chrome.onLoadStarted.connect(
       
    17       function() {
       
    18         window.chrome.alert("handleLoadStart");
       
    19         //document.getElementById("PBar").style.width = "0%";
       
    20       }
       
    21       );
       
    22       window.pageController.loadProgress.connect(
       
    23       function(percent) {
       
    24         //var parentWidth = document.getElementById("PBarWrapper").offsetWidth;
       
    25         //document.getElementById("PBar").style.width = (parentWidth * percent)/100 + "px";
       
    26       }
       
    27       );
       
    28       window.pageController.loadFinished.connect(
       
    29       function(ok) {
       
    30         //window.chrome.alert("handleLoadFinished: " + ok);
       
    31         //document.getElementById("PBar").style.width = "0%";
       
    32       }
       
    33       );
       
    34       window.pageController.networkRequestError.connect(
       
    35       function(reply) {
       
    36         window.chrome.alert("networkRequestError: " + reply.error());
       
    37       }
       
    38       );
       
    39       window.pageController.titleChanged.connect(
       
    40       function(title) {
       
    41       // TBD
       
    42       }
       
    43       );
       
    44       window.pageController.currentPageUrlChanged.connect(
       
    45       function(url){
       
    46         document.getElementById("urlBox").value = url;
       
    47       //window.chrome.toggleAttention("Button6");
       
    48       );
       
    49       
       
    50     </script>
       
    51 
       
    52     <link id="CSSLink" rel="stylesheet" type="text/css" href="css/chromeStyleBoston.css" />
       
    53 
       
    54   </head>
       
    55   <body onload="onLoad();">
       
    56     <div class ="InitialChrome">      
       
    57       <div class = "BottomChrome" id="BottomChromeId" style="background-image:url('images/Boston.png');background-repeat:no-repeat;">
       
    58         <button id="Button1" onclick="window.pageController.currentLoad('http://www.google.com/news/image?p2=1&ned=us&hl=en&q=boston&imv=1')"/>
       
    59         <button id = "Button2" onclick="window.pageController.currentLoad('http://www.boston.com/ae/movies')"/>
       
    60         <button id = "Button3"  onclick="window.pageController.currentLoad('http://www.boston.com/sports')"/>
       
    61         <button id = "Button4" onclick="window.pageController.currentLoad('http://www.google.com/search?hl=en&q=weather+boston+ma&btnG=Search&aq=f&oq=&aqi=g10')"/>
       
    62         <button id = "Button5" onclick="window.chrome.popToggle('PopChromeId');"
       
    63         <button id = "Button6" onclick="window.chrome.loadChrome('file:///C:/data/Others/chrome/s60-chrome.html');"/>
       
    64 
       
    65       </div>
       
    66     </div>
       
    67 
       
    68      <div class = "PopChrome" id="PopChromeId">
       
    69       <h3>Boston Chrome</h3>
       
    70     </div>
       
    71   </body>
       
    72 </html>
       
    73