Changeset 3569

Show
Ignore:
Timestamp:
01/26/07 00:53:27 (2 years ago)
Author:
timothy
Message:

Gets the web interface working on the Wii and Opera. This also helps Firefox, but Firefox needs more work.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/Colloquy.xcodeproj/project.pbxproj

    r3560 r3569  
    19161916                        isa = PBXProject; 
    19171917                        buildConfigurationList = 1C041A700854E97700A5A5BA /* Build configuration list for PBXProject "Colloquy" */; 
     1918                        compatibilityVersion = "Xcode 2.4"; 
    19181919                        hasScannedForEncodings = 1; 
    19191920                        knownRegions = ( 
     
    19651966                        ); 
    19661967                        projectRoot = ""; 
     1968                        shouldCheckCompatibility = 1; 
    19671969                        targets = ( 
    19681970                                1CB2CCF5052DDC560094AAA4 /* Colloquy (Application) */, 
  • trunk/Plug-Ins/Web Interface/Resources/common.js

    r3568 r3569  
    207207 
    208208        var panel = this; 
    209         this.frame.onload = function() { 
    210                 panel.contentFrame = $(panel.frame.document.getElementById( "content" )); 
    211                 panel.contentFrame.onload = function() { panel.scrollToBottom() }; 
     209        this.frame.onload = function( event ) { 
     210                panel.contentFrame = $(panel.frame.contentDocument.getElementById( "content" )); 
     211                panel.contentFrame.onload = function( event ) { panel.scrollToBottom() }; 
    212212                panel.contentFrame.src = "/command/panelContents?panel=" + panel.id; 
    213213        }; 
     
    239239 
    240240        var frame = this.contentFrame; 
    241         var bodyNode = frame.document.getElementById( "contents" ); 
    242         if( ! bodyNode ) bodyNode = frame.document.body; 
     241        var bodyNode = frame.contentDocument.getElementById( "contents" ); 
     242        if( ! bodyNode ) bodyNode = frame.contentDocument.body; 
    243243 
    244244        var consecutive = ( html.indexOf( "<?message type=\"consecutive\"?>" ) != -1 ); 
    245245        if( ! consecutive ) consecutive = ( html.indexOf( "<?message type=\"subsequent\"?>" ) != -1 ); 
    246246 
    247         var insert = frame.document.getElementById( "consecutiveInsert" ); 
     247        var insert = frame.contentDocument.getElementById( "consecutiveInsert" ); 
    248248 
    249249        if( consecutive && insert ) { 
    250                 var range =  frame.document.createRange(); 
     250                var range =  frame.contentDocument.createRange(); 
    251251                range.selectNode( insert.parentNode ); 
    252252                var documentFragment = range.createContextualFragment( html ); 
     
    255255                if( insert ) insert.parentNode.removeChild( insert ); 
    256256 
    257                 var range = frame.document.createRange(); 
     257                var range = frame.contentDocument.createRange(); 
    258258                range.selectNode( bodyNode ); 
    259259                var documentFragment = range.createContextualFragment( html ); 
     
    267267DirectChatPanel.prototype.enforceScrollBackLimit = function() { 
    268268        var frame = this.contentFrame; 
    269         var bodyNode = frame.document.getElementById( "contents" ); 
    270         if( ! bodyNode ) bodyNode = frame.document.body; 
     269        var bodyNode = frame.contentDocument.getElementById( "contents" ); 
     270        if( ! bodyNode ) bodyNode = frame.contentDocument.body; 
    271271        if( UserDefaults.scrollBackMessageLimit > 0 && bodyNode.childNodes.length > UserDefaults.scrollBackMessageLimit ) 
    272272                for( var i = 0; bodyNode.childNodes.length > UserDefaults.scrollBackMessageLimit && i < ( bodyNode.childNodes.length - UserDefaults.scrollBackMessageLimit ); ++i ) 
     
    276276DirectChatPanel.prototype.scrollToBottom = function() { 
    277277        var frame = this.contentFrame; 
    278         var bodyNode = frame.document.getElementById( "contents" ); 
    279         if( ! bodyNode ) bodyNode = frame.document.body; 
     278        var bodyNode = frame.contentDocument.getElementById( "contents" ); 
     279        if( ! bodyNode ) bodyNode = frame.contentDocument.body; 
    280280        bodyNode.scrollTop = bodyNode.scrollHeight; 
    281281} 
     
    284284//      var frame = this.contentFrame; 
    285285        return true; 
    286 /*      var bodyNode = frame.document.getElementById( "contents" ); 
    287         if( ! bodyNode ) bodyNode = frame.document.body; 
     286/*      var bodyNode = frame.contentDocument.getElementById( "contents" ); 
     287        if( ! bodyNode ) bodyNode = frame.contentDocument.body; 
    288288        scrollToBottomIsNeeded = ( bodyNode.scrollTop >= ( bodyNode.offsetHeight - ( window.innerHeight * 1.1 ) ) ); */ 
    289289} 
  • trunk/Resources/base.html

    r3454 r3569  
    99                height: 100%; 
    1010                width: 100%; 
     11                overflow: hidden; 
    1112        } 
    1213 
    1314        body { 
    1415                display: table; 
     16                border: none; 
    1517                border-spacing: 0; 
    1618                margin: 0; 
     
    2628        .banner > * { 
    2729                display: table-cell; 
     30                border: none; 
    2831        } 
    2932 
    3033        .body { 
    3134                display: table-row; 
     35                border: none; 
    3236        } 
    3337 
    3438        .body > * { 
    3539                display: table-cell; 
     40                border: none; 
     41                height: 100%; 
     42                width: 100%; 
     43        } 
     44 
     45        .body > * > iframe { 
     46                border: none; 
    3647                height: 100%; 
    3748                width: 100%; 
     
    4051</head> 
    4152<body> 
    42 <div class="body"><iframe id="content"></iframe></div> 
     53<div class="body"><div><iframe id="content"></iframe></div></div> 
    4354</body> 
    4455</html> 
  • trunk/Resources/roomTopicBanner.js

    r3474 r3569  
    3434} 
    3535 
    36 function refreshTopicSize() { 
     36function refreshTopicSize( event ) { 
    3737        topicMessage = document.getElementById( 'topicMessage' ); 
    3838        if( topicMessage.clientHeight > 17 ) 
     
    4747} 
    4848 
    49 window.addEventListener( 'resize', refreshTopicSize ); 
     49window.addEventListener( 'resize', refreshTopicSize, false );